43 instantiations of BitArray
illink (1)
Microsoft.CodeAnalysis.CSharp.Scripting.UnitTests (1)
ObjectFormatterTests.cs (1)
551var obj = new System.Collections.BitArray(new int[] { 1 });
Microsoft.CodeAnalysis.UnitTests (1)
Collections\List\IEnumerable.Generic.Tests.cs (1)
230new BitArray(
Microsoft.CodeAnalysis.Workspaces (2)
Shared\Utilities\BloomFilter.cs (1)
48_bitArray = new BitArray(length: sizeInEvenBytes);
Shared\Utilities\BloomFilter_Serialization.cs (1)
80return new BitArray(bytes);
Microsoft.DotNet.XUnitAssert.Tests (16)
CollectionAssertsTests.cs (16)
1512 var expected = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 1513 var actual = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 1525 var expected = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 1526 var actual = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 1552 var expected = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 1553 var actual = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, true }) }; 1569 var expected = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 1570 var actual = new HashSet<BitArray> { new BitArray(new[] { true, true }) }; 2187 var expected = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 2188 var actual = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 2208 var expected = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 2209 var actual = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 2235 var expected = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 2236 var actual = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, true }) }; 2244 var expected = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 2245 var actual = new HashSet<BitArray> { new BitArray(new[] { true, true }) };
Microsoft.ML.Core (1)
Utilities\Stream.cs (1)
830var returnArray = new BitArray(bytes);
Microsoft.ML.Data (1)
DataView\ArrayDataViewBuilder.cs (1)
273_active = new BitArray(view.Schema.Count);
Microsoft.ML.Ensemble (1)
Selector\FeatureSelector\RandomFeatureSelector.cs (1)
54var features = new BitArray(len);
Microsoft.ML.FastTree (1)
FastTree.cs (1)
1678BitArray rowHasMissing = new BitArray(temp.Length);
Microsoft.ML.Transforms (3)
MissingValueReplacing.cs (2)
259_repIsDefault[iinfo] = new BitArray(srcType.Size); 370BitArray defaultSlots = new BitArray(values.Length);
SvmLight\SvmLightLoader.cs (1)
356_indexUsed = new BitArray((int)_keyMax);
PresentationCore (1)
MS\Internal\Shaping\OpenTypeLayoutCache.cs (1)
448BitArray lookupUsage = new BitArray(lookupCount);
PresentationFramework (4)
System\Windows\Documents\FixedDSBuilder.cs (1)
76_visitedArray = new BitArray(fixedNodes.Count);
System\Windows\SystemColors.cs (2)
2467private static BitArray _colorCacheValid = new BitArray((int)CacheSlot.NumSlots); 2469private static BitArray _brushCacheValid = new BitArray((int)CacheSlot.NumSlots);
System\Windows\SystemParameters.cs (1)
5956private static BitArray _cacheValid = new BitArray((int)CacheSlot.NumSlots);
System.Collections (1)
System\Collections\BitArray.cs (1)
1041public object Clone() => new BitArray(this);
System.Data.Common (4)
System\Data\Common\DataStorage.cs (1)
265_dbNullBits = new BitArray(capacity);
System\Data\DataSet.cs (1)
1303_rowChanges = new BitArray(rowCount);
System\Data\DataTable.cs (2)
693BitArray rowStates = new BitArray(rowCount * 3, false); //All bit flags are set to false on initialization of the BitArray. 741BitArray nullbits = new BitArray(recordCount);
System.Formats.Asn1 (1)
System\Formats\Asn1\AsnDecoder.NamedBitList.cs (1)
356BitArray ret = new BitArray(rented);
System.Private.Xml (1)
System\Xml\Xsl\QIL\QilPatternVisitor.cs (1)
279_bits = new BitArray(szBits, allSet);
System.Security.Cryptography (1)
src\libraries\Common\src\System\Security\Cryptography\EccKeyFormatHelper.cs (1)
393BitArray poly = new BitArray(m + 1);
System.Text.Json (1)
System\Text\Json\Serialization\ReadStackFrame.cs (1)
147RequiredPropertiesSet = new BitArray(typeInfo.NumberOfRequiredProperties);
System.Windows.Forms (1)
System\Windows\Forms\Layout\TableLayout.ReservationGrid.cs (1)
36_rows.Add(new BitArray(_numColumns));
196 references to BitArray
illink (7)
Microsoft.CodeAnalysis.CSharp.Scripting.UnitTests (1)
ObjectFormatterTests.cs (1)
551var obj = new System.Collections.BitArray(new int[] { 1 });
Microsoft.CodeAnalysis.UnitTests (1)
Collections\List\IEnumerable.Generic.Tests.cs (1)
229var itemsVisited =
Microsoft.CodeAnalysis.Workspaces (7)
Shared\Utilities\BloomFilter.cs (4)
22private readonly BitArray _bitArray; 69private BloomFilter(BitArray bitArray, int hashFunctionCount, bool isCaseSensitive) 385private static bool IsEquivalent(BitArray array1, BitArray array2)
Shared\Utilities\BloomFilter_Serialization.cs (3)
25private static void WriteBitArray(ObjectWriter writer, BitArray bitArray) 65var bitArray = ReadBitArray(reader); 69private static BitArray ReadBitArray(ObjectReader reader)
Microsoft.DotNet.XUnitAssert.Tests (26)
CollectionAssertsTests.cs (26)
1512 var expected = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 1513 var actual = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 1525 var expected = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 1526 var actual = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 1552 var expected = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 1553 var actual = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, true }) }; 1569 var expected = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 1570 var actual = new HashSet<BitArray> { new BitArray(new[] { true, true }) }; 1583 public class BitArrayComparer : IEqualityComparer<BitArray> 1586 BitArray? x, 1587 BitArray? y) => 1590 public int GetHashCode(BitArray obj) => 1593 static string ToBitString(BitArray? bitArray) 2187 var expected = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 2188 var actual = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 2208 var expected = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 2209 var actual = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 2235 var expected = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, false }) }; 2236 var actual = new HashSet<BitArray>(comparer) { new BitArray(new[] { true, true }) }; 2244 var expected = new HashSet<BitArray> { new BitArray(new[] { true, false }) }; 2245 var actual = new HashSet<BitArray> { new BitArray(new[] { true, true }) }; 2250 public class BitArrayComparer : IEqualityComparer<BitArray> 2253 BitArray? x, 2254 BitArray? y) => 2257 public int GetHashCode(BitArray obj) => 2260 static string ToBitString(BitArray? bitArray)
Microsoft.ML.Core (5)
Utilities\Stream.cs (3)
270public static void WriteBitArray(this BinaryWriter writer, BitArray arr) 822public static BitArray ReadBitArray(this BinaryReader reader) 830var returnArray = new BitArray(bytes);
Utilities\Utils.cs (2)
114public static int Size(BitArray x) 949public static int GetCardinality(BitArray bitArray)
Microsoft.ML.Data (2)
DataView\ArrayDataViewBuilder.cs (2)
12using BitArray = System.Collections.BitArray; 254private readonly BitArray _active;
Microsoft.ML.Ensemble (7)
EnsembleUtils.cs (2)
18public static RoleMappedData SelectFeatures(IHost host, RoleMappedData data, BitArray features) 47public static void SelectFeatures<T>(in VBuffer<T> src, BitArray includedIndices, int cardinality, ref VBuffer<T> dst)
FeatureSubsetModel.cs (2)
15public readonly BitArray SelectedFeatures; 20public FeatureSubsetModel(IPredictorProducing<TOutput> predictor, BitArray features = null,
Selector\FeatureSelector\RandomFeatureSelector.cs (1)
54var features = new BitArray(len);
Subset.cs (2)
14public readonly BitArray SelectedFeatures; 16public Subset(RoleMappedData data, BitArray features = null)
Microsoft.ML.FastTree (1)
FastTree.cs (1)
1678BitArray rowHasMissing = new BitArray(temp.Length);
Microsoft.ML.Transforms (10)
MissingValueReplacing.cs (9)
41private static readonly FuncInstanceMethodInfo1<MissingValueReplacingTransformer, DataViewType, Array, BitArray> _computeDefaultSlotsMethodInfo 42= FuncInstanceMethodInfo1<MissingValueReplacingTransformer, DataViewType, Array, BitArray>.Create(target => target.ComputeDefaultSlots<int>); 200private readonly BitArray[] _repIsDefault; 228_repIsDefault = new BitArray[columnsLength]; 277private void GetReplacementValues(IDataView input, MissingValueReplacingEstimator.ColumnOptions[] columns, out object[] repValues, out BitArray[] slotIsDefault, out DataViewType[] types) 280slotIsDefault = new BitArray[columns.Length]; 367private BitArray ComputeDefaultSlots<T>(DataViewType type, Array values) 370BitArray defaultSlots = new BitArray(values.Length); 778private void FillValues<T>(in VBuffer<T> src, ref VBuffer<T> dst, InPredicate<T> isNA, T[] rep, BitArray repIsDefault)
SvmLight\SvmLightLoader.cs (1)
347private readonly BitArray _indexUsed;
mscorlib (1)
src\libraries\shims\mscorlib\ref\mscorlib.cs (1)
72[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Collections.BitArray))]
netstandard (1)
netstandard.cs (1)
88[assembly: System.Runtime.CompilerServices.TypeForwardedTo(typeof(System.Collections.BitArray))]
PresentationCore (1)
MS\Internal\Shaping\OpenTypeLayoutCache.cs (1)
448BitArray lookupUsage = new BitArray(lookupCount);
PresentationFramework (6)
System\Windows\Documents\FixedDSBuilder.cs (1)
261private BitArray _visitedArray;
System\Windows\SystemColors.cs (2)
2467private static BitArray _colorCacheValid = new BitArray((int)CacheSlot.NumSlots); 2469private static BitArray _brushCacheValid = new BitArray((int)CacheSlot.NumSlots);
System\Windows\SystemParameters.cs (1)
5956private static BitArray _cacheValid = new BitArray((int)CacheSlot.NumSlots);
System\Windows\SystemResources.cs (2)
1451internal static bool ClearBitArray(BitArray cacheValid) 1466internal static bool ClearSlot(BitArray cacheValid, int slot)
System.Collections (17)
System\Collections\BitArray.cs (17)
219public BitArray(BitArray bits) 315public unsafe BitArray And(BitArray value) 388public unsafe BitArray Or(BitArray value) 461public unsafe BitArray Xor(BitArray value) 534public unsafe BitArray Not() 600public BitArray RightShift(int count) 664public BitArray LeftShift(int count) 974/// Determines whether all bits in the <see cref="BitArray"/> are set to <c>true</c>. 976/// <returns><c>true</c> if every bit in the <see cref="BitArray"/> is set to <c>true</c>, or if <see cref="BitArray"/> is empty; otherwise, <c>false</c>.</returns> 1005/// Determines whether any bit in the <see cref="BitArray"/> is set to <c>true</c>. 1007/// <returns><c>true</c> if <see cref="BitArray"/> is not empty and at least one of its bit is set to <c>true</c>; otherwise, <c>false</c>.</returns> 1112private readonly BitArray _bitArray; 1117internal BitArrayEnumeratorSimple(BitArray bitArray)
System.Data.Common (89)
System\Data\Common\BigIntegerStorage.cs (2)
165protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 172protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\BooleanStorage.cs (2)
185protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 192protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\ByteStorage.cs (2)
257protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 264protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\CharStorage.cs (2)
189protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 196protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\DataStorage.cs (6)
117private System.Collections.BitArray _dbNullBits = default!; // Late-initialized 540internal void CopyValueInternal(int record, object store, BitArray nullbits, int storeIndex) 545internal void SetStorageInternal(object store, BitArray nullbits) 551protected abstract void CopyValue(int record, object store, BitArray nullbits, int storeIndex); 552protected abstract void SetStorage(object store, BitArray nullbits); 553protected void SetNullStorage(BitArray nullbits)
System\Data\Common\DateTimeOffsetStorage.cs (2)
192protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 199protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\DateTimeStorage.cs (2)
249protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 264protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\DecimalStorage.cs (2)
253protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 260protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\DoubleStorage.cs (2)
257protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 264protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\Int16Storage.cs (2)
271protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 278protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\Int32Storage.cs (2)
270protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 277protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\Int64Storage.cs (2)
262protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 269protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\ObjectStorage.cs (2)
519protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 535protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SByteStorage.cs (2)
259protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 266protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SingleStorage.cs (2)
258protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 265protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLBinaryStorage.cs (2)
133protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 140protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQlBooleanStorage.cs (2)
167protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 174protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLBytesStorage.cs (2)
131protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 138protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLByteStorage.cs (2)
243protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 250protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLCharsStorage.cs (2)
134protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 141protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLDateTimeStorage.cs (2)
169protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 176protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLDecimalStorage.cs (2)
241protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 248protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLDoubleStorage.cs (2)
242protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 249protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLGuidStorage.cs (2)
134protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 141protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLInt16Storage.cs (2)
242protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 249protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLInt32Storage.cs (2)
242protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 249protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLInt64Storage.cs (2)
243protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 250protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLMoneyStorage.cs (2)
242protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 249protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLSingleStorage.cs (2)
240protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 247protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SQLTypes\SQLStringStorage.cs (2)
195protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 202protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\SqlUDTStorage.cs (2)
242protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 249protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\StringStorage.cs (2)
207protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 214protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\TimeSpanStorage.cs (2)
277protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 284protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\UInt16Storage.cs (2)
270protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 277protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\UInt32Storage.cs (2)
269protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 276protected override void SetStorage(object store, BitArray nullbits)
System\Data\Common\UInt64Storage.cs (2)
260protected override void CopyValue(int record, object store, BitArray nullbits, int storeIndex) 267protected override void SetStorage(object store, BitArray nullbits)
System\Data\DataColumn.cs (2)
1789internal void CopyValueIntoStore(int record, object store, BitArray nullbits, int storeIndex) 1796internal void SetStorage(object store, BitArray nullbits)
System\Data\DataRow.cs (3)
1403_columns[i].CopyValueIntoStore(_oldRecord, storeList[i]!, (BitArray)nullbitList[i]!, storeIndex); 1415_columns[i].CopyValueIntoStore(_newRecord, storeList[i]!, (BitArray)nullbitList[i]!, storeIndex); 1426_columns[i].CopyValueIntoStore(_tempRecord, storeList[i]!, (BitArray)nullbitList[i]!, storeIndex);
System\Data\DataSet.cs (1)
1299private readonly BitArray _rowChanges;
System\Data\DataTable.cs (7)
693BitArray rowStates = new BitArray(rowCount * 3, false); //All bit flags are set to false on initialization of the BitArray. 741BitArray nullbits = new BitArray(recordCount); 782BitArray rowStates = (BitArray)info.GetValue(string.Format(formatProvider, "DataTable_{0}.RowStates", serIndex), typeof(BitArray))!; 799Columns[i].SetStorage(storeList[i]!, (BitArray)nullbitList[i]!); 861private static DataRowState ConvertToRowState(BitArray bitStates, int bitIndex)
System.Formats.Asn1 (7)
System\Formats\Asn1\AsnDecoder.NamedBitList.cs (4)
321public static BitArray ReadNamedBitList( 356BitArray ret = new BitArray(rented); 576public BitArray ReadNamedBitList(Asn1Tag? expectedTag = null) 578BitArray ret = AsnDecoder.ReadNamedBitList(_data.Span, RuleSet, out int consumed, expectedTag);
System\Formats\Asn1\AsnWriter.NamedBitList.cs (3)
93/// different than the value produced by <see cref="BitArray.CopyTo"/> with a byte array. 97public void WriteNamedBitList(BitArray value, Asn1Tag? tag = null) 179private void WriteBitArray(BitArray value, Asn1Tag? tag)
System.Private.Xml (1)
System\Xml\Xsl\QIL\QilPatternVisitor.cs (1)
275private readonly BitArray _bits;
System.Security.Cryptography (1)
src\libraries\Common\src\System\Security\Cryptography\EccKeyFormatHelper.cs (1)
393BitArray poly = new BitArray(m + 1);
System.Text.Json (2)
System\Text\Json\Serialization\ReadStackFrame.cs (1)
83public BitArray? RequiredPropertiesSet;
System\Text\Json\ThrowHelper.Serialization.cs (1)
291public static void ThrowJsonException_JsonRequiredPropertyMissing(JsonTypeInfo parent, BitArray requiredPropertiesSet)
System.Text.RegularExpressions (1)
System\Text\RegularExpressions\Symbolic\BitVector.cs (1)
13/// This differs from <see cref="BitArray"/> in that it's a value type rather than a reference type
System.Windows.Forms (1)
System\Windows\Forms\Layout\TableLayout.ReservationGrid.cs (1)
14private readonly List<BitArray> _rows = [];
xunit.assert (1)
Sdk\ArgumentFormatter.cs (1)
644 collection is BitArray ||