BitsetsNET.RoaringArray.GetEnumerator C# (CSharp) Method

GetEnumerator() public method

Get an enumerator of the set indices of this bitset.
public GetEnumerator ( ) : IEnumerator
return IEnumerator
        public IEnumerator<int> GetEnumerator()
        {
            for(int i = 0; i < Size; i++)
            {
                int highbits = keys[i] << 16;
                foreach(ushort lowbits in values[i])
                {
                    yield return highbits + lowbits;
                }
            }
        }

Usage Example

Example #1
0
 /// <summary>
 /// Get an enumerator of the set indices of this bitset.
 /// </summary>
 /// <returns>A enumerator giving the set (i.e. for which the bit is '1' or true) indices for this bitset.</returns>
 public IEnumerator GetEnumerator()
 {
     return(containers.GetEnumerator());
 }
All Usage Examples Of BitsetsNET.RoaringArray::GetEnumerator