/// <summary> /// Performs the set difference, defined as the set in A and not in B. /// </summary> /// <param name="otherSet">the other IBitset</param> /// <returns>The set difference of this set and the other.</returns> public IBitset Difference(IBitset otherSet) { RLEBitset otherRLESet = (RLEBitset)otherSet; // cast to an RLEBitset - errors if cannot cast IBitset rtnVal = And(otherRLESet.Not()); return(rtnVal); }
/// <summary> /// Performs the set difference, defined as the set in A and not in B. /// </summary> /// <param name="otherSet">the other IBitset</param> public void DifferenceWith(IBitset otherSet) { RLEBitset otherRLESet = (RLEBitset)otherSet; // cast to an RLEBitset - errors if cannot cast AndWith(otherRLESet.Not()); }