public And ( |
||
x | Other container | |
return | Container |
public override Container And(ArrayContainer x)
{
ArrayContainer answer = new ArrayContainer(x.Content.Length);
int c = x.Cardinality;
for (int i=0; i<c; i++)
{
ushort v = x.Content[i];
if (this.Contains(v))
{
answer.Content[answer.Cardinality++] = v;
}
}
return answer;
}
BitsetContainer::And ( |
/// <summary> /// Computes the bitwise AND of this container with another /// (intersection). This container as well as the provided container are /// left unaffected. /// </summary> /// <param name="x">Other container</param> /// <returns>Aggregated container</returns> public override Container And(BitsetContainer x) { return(x.And(this)); }