Implemented interface member:
property
Count
System.Collections.ICollection.Count
5 overrides of Count
System.Private.CoreLib (5)
src\libraries\System.Private.CoreLib\src\System\Collections\ArrayList.cs (5)
726public override int Count => _list.Count; 1172public override int Count 1669public override int Count => _list.Count; 1927public override int Count => _list.Count; 2308public override int Count
1015 references to Count
dotnet-svcutil-lib (113)
FrameworkFork\Microsoft.CodeDom\System\CodeNamespaceImportCollection.cs (1)
55return _data.Count;
FrameworkFork\Microsoft.CodeDom\System\CodeTypeReference.cs (3)
254for (int i = 0; i < typeArgumentList.Count; i++) 270else if (typeArgumentList.Count > 0) 272for (int i = 0; i < typeArgumentList.Count; i++)
FrameworkFork\Microsoft.Xml\Xml\Core\XsdValidatingReader.cs (3)
1280else if (_defaultAttributes.Count > 0) 2085_attributeCount += _defaultAttributes.Count; 2169for (int i = 0; i < _defaultAttributes.Count; i++)
FrameworkFork\Microsoft.Xml\Xml\Dom\DocumentSchemaValidator.cs (1)
440for (int i = 0; i < _defaultAttributes.Count; i++)
FrameworkFork\Microsoft.Xml\Xml\Dom\XmlDocument.cs (1)
259if (elementList.Count == 0)
FrameworkFork\Microsoft.Xml\Xml\Dom\XmlNamedNodeMap.SmallXmlNodeList.cs (1)
32return list.Count;
FrameworkFork\Microsoft.Xml\Xml\schema\AstTree.cs (11)
152get { return _stack.Count; } 218for (int i = 0; i < _stack.Count; ++i) 240for (int i = 0; i < _stack.Count; ++i) 272for (int i = 0; i < _stack.Count; ++i) 314_axisStack = new ArrayList(axisTree.SubtreeArray.Count); // defined length 316for (int i = 0; i < axisTree.SubtreeArray.Count; ++i) 334for (int i = 0; i < _axisStack.Count; ++i) 371for (int i = 0; i < _axisStack.Count; ++i) 387for (int i = 0; i < _axisStack.Count; ++i) 521for (int i = 0; i < _fAxisArray.Count; ++i) 597for (int i = 0; i < AstArray.Count; ++i)
FrameworkFork\Microsoft.Xml\Xml\schema\basevalidator.cs (1)
185Debug.Assert(names.Count > 0);
FrameworkFork\Microsoft.Xml\Xml\schema\ConstraintStruct.cs (1)
118if (_KSpointer < _KSs.Count)
FrameworkFork\Microsoft.Xml\Xml\schema\ContentValidator.cs (4)
97Debug.Assert(_particles.Count == _last + 1); 137Debug.Assert(_particles.Count == _last + 1); 271get { return _positions.Count; } 1107for (int i = 0; i < grp.Members.Count; ++i)
FrameworkFork\Microsoft.Xml\Xml\schema\DatatypeImplementation.cs (2)
1164if (values.Count < _minListSize) 3142for (int i = 0; i < dt.Restriction.Enumeration.Count; ++i)
FrameworkFork\Microsoft.Xml\Xml\schema\FacetChecker.cs (11)
880for (int i = 0; i < restriction.Patterns.Count; ++i) 1096for (int i = 0; i < enumeration.Count; ++i) 1197for (int i = 0; i < enumeration.Count; ++i) 1268for (int i = 0; i < enumeration.Count; ++i) 1340for (int i = 0; i < enumeration.Count; ++i) 1433for (int i = 0; i < enumeration.Count; ++i) 1443for (int i = 0; i < enumeration.Count; ++i) 1562for (int i = 0; i < enumeration.Count; ++i) 1631for (int i = 0; i < enumeration.Count; ++i) 1692for (int i = 0; i < enumeration.Count; ++i) 1722for (int i = 0; i < enumeration.Count; ++i)
FrameworkFork\Microsoft.Xml\Xml\schema\Inference\infer.cs (2)
372if (col != null && col.Count > 0) 543if (col != null && col.Count > 0)
FrameworkFork\Microsoft.Xml\Xml\schema\Preprocessor.cs (1)
149for (int i = 0; i < _redefinedList.Count; ++i)
FrameworkFork\Microsoft.Xml\Xml\schema\SchemaCollectionCompiler.cs (4)
424if (substitutionGroup.IsProcessing && substitutionGroup.Members.Count > 0) 442for (int i = 0; i < substitutionGroup.Members.Count; ++i) 463else if (substitutionGroup.Members.Count > 0) 475for (int i = 0; i < substitutionGroup.Members.Count; ++i)
FrameworkFork\Microsoft.Xml\Xml\schema\SchemaSetCompiler.cs (5)
476if (substitutionGroup.IsProcessing && substitutionGroup.Members.Count > 0) 496for (int i = 0; i < substitutionGroup.Members.Count; ++i) 506for (int j = 0; j < g.Members.Count; ++j) 522for (int i = 0; i < newMembers.Count; ++i) 1235for (int i = 0; i < substitutionGroup.Members.Count; ++i)
FrameworkFork\Microsoft.Xml\Xml\schema\XmlSchemaSet.cs (12)
525for (int i = 0; i < schemaToRemove.ImportedNamespaces.Count; i++) 550for (int i = 0; i < needToCheckSchemaList.Count; i++) 554if (mainSchema.ImportedNamespaces.Count > 0) 568for (int i = 0; i < schemaToRemove.ImportedSchemas.Count; ++i) 769for (int i = 0; i < schema.ImportedSchemas.Count; ++i) 977if (schema.ImportedSchemas.Count > 0) 980for (int i = 0; i < schema.ImportedSchemas.Count; ++i) 1083for (int i = 0; i < schema.ImportedSchemas.Count; ++i) 1118for (int i = 0; i < substGroup.Members.Count; ++i) 1141for (int i = 0; i < substitutionGroup.Members.Count; ++i) 1150for (int j = 0; j < g.Members.Count; ++j) 1504for (int j = 0; j < removalList.Count; ++j)
FrameworkFork\Microsoft.Xml\Xml\schema\XmlSchemaValidator.cs (15)
361for (int i = 0; i < schema.ImportedSchemas.Count; ++i) 822if (names == null || names.Count == 0) 828Debug.Assert(names.Count > 0); 2276for (int k = 0; k < constraintStructures[j].axisFields.Count; ++k) 2320for (int j = 0; j < constraintStructures[i].axisFields.Count; ++j) 2367for (int j = 0; j < constraints[i].axisFields.Count; ++j) 2545if (names == null || names.Count == 0) 2558Debug.Assert(names.Count > 0); 2598if (names == null || names.Count == 0) 2608Debug.Assert(names.Count > 0); 2631if (expected.Count == 1) 2637for (int i = 1; i < expected.Count; i++) 2673for (int i = 1; i < expected.Count; ++i) 2686if (expected.Count == 1) 2709for (int i = 0; i < expected.Count; i++)
FrameworkFork\Microsoft.Xml\Xml\schema\XsdBuilder.cs (1)
801if (_unhandledAttributes.Count != 0)
FrameworkFork\Microsoft.Xml\Xml\schema\xsdvalidator.cs (3)
951for (int k = 0; k < constraints[j].axisFields.Count; ++k) 996for (int j = 0; j < constraints[i].axisFields.Count; ++j) 1050for (int j = 0; j < constraints[i].axisFields.Count; ++j)
FrameworkFork\Microsoft.Xml\Xml\Serialization\CodeIdentifiers.cs (1)
187Array array = Array.CreateInstance(type, _list.Count);
FrameworkFork\Microsoft.Xml\Xml\Serialization\ImportContext.cs (5)
160for (int i = 0; i < list.Count; i++) 208for (int i = 0; i < list.Count; i++) 221for (int i = 0; i < list.Count; i++) 226tmp += (int)cachedHash / list.Count; 237for (int i = 0; i < items.Count; i++)
FrameworkFork\Microsoft.Xml\Xml\Serialization\Mappings.cs (2)
1389if (srcSchemas.Count == 0) 1393if (srcSchemas.Count > 1)
FrameworkFork\Microsoft.Xml\Xml\Serialization\SchemaObjectWriter.cs (4)
222for (int i = 0; i < attrs.Count; i++) 292for (int i = 0; i < list.Count; i++) 606for (int i = 0; i < list.Count; i++) 660for (int ia = 0; ia < a.Count; ia++)
FrameworkFork\Microsoft.Xml\Xml\Serialization\SoapReflectionImporter.cs (1)
610if (constants.Count == 0)
FrameworkFork\Microsoft.Xml\Xml\Serialization\XmlReflectionImporter.cs (5)
592if (srcSchemas.Count == 0) 596if (srcSchemas.Count > 1) 903for (int i = 0; i < members.Count; i++) 1216if (constants.Count == 0) 2309return _list.Count;
FrameworkFork\Microsoft.Xml\Xml\Serialization\XmlSerializationReader.cs (3)
1619for (int i = 0; i < _fixups.Count; i++) 1626for (int i = 0; i < _collectionFixups.Count; i++) 2056if (xmlNodeList.Count <= skippableNodeCount)
FrameworkFork\Microsoft.Xml\Xml\Serialization\XmlSerializationWriter.cs (1)
1456for (int i = 0; i < _referencesToWrite.Count; i++)
FrameworkFork\Microsoft.Xml\Xml\XPath\Internal\querybuilder.cs (3)
379if (root.ArgumentList != null && root.ArgumentList.Count > 0) 405if (root.ArgumentList != null && root.ArgumentList.Count > 0) 444int numArgs = args != null ? args.Count : 0;
FrameworkFork\Microsoft.Xml\Xml\XPath\Internal\XPathMultyIterator.cs (1)
23this.arr = new ResetableIterator[inputArray.Count];
FrameworkFork\Microsoft.Xml\Xml\XPath\Internal\XPathParser.cs (1)
540int argCount = argList.Count;
FrameworkFork\System.ServiceModel\Internals\System\Runtime\UrlUtility.cs (1)
594int numValues = (values != null) ? values.Count : 0;
FrameworkFork\System.ServiceModel\System\ServiceModel\Security\TimeBoundedCache.cs (2)
316for (int i = 0; i < keysToBeRemoved.Count; ++i) 400for (int i = 0; i < expiredItems.Count; ++i)
Microsoft.Build (1)
Logging\BaseConsoleLogger.cs (1)
569if (itemTypeList.Count == 0)
Microsoft.VisualBasic.Core (1)
Microsoft\VisualBasic\CompilerServices\ProjectData.vb (1)
27If (lChannel < m_Files.Count) Then
PresentationBuildTasks (81)
Microsoft\Build\Tasks\Windows\GenerateTemporaryTargetAssembly.cs (1)
653if (itemToRemove.Count > 0)
Microsoft\Build\Tasks\Windows\MarkupCompilePass1.cs (2)
1335if (localRefAppdefList.Count > 0) 1340if (localRefPageList.Count > 0)
MS\Internal\Localization\LocalizationParserHooks.cs (1)
100if (_commentList.Count > 0)
MS\Internal\MarkupCompiler\MarkupCompiler.cs (9)
257if (_pendingLocalFiles != null && _pendingLocalFiles.Count == 1) 279if (_pendingLocalFiles != null && _pendingLocalFiles.Count > 0) 293Debug.Assert(_pendingLocalFiles == null || _pendingLocalFiles.Count == 0); 1159if ((elementName == null || !isAllowedNameScope) && (events == null || events.Count == 0)) 1310var paths = new List<string>(ReferenceAssemblyList?.Count ?? 0); 1311if (ReferenceAssemblyList != null && ReferenceAssemblyList.Count > 0) 1313for (int i = 0; i < ReferenceAssemblyList.Count; i++) 1328if (ReferenceAssemblyList != null && ReferenceAssemblyList.Count > 0) 1330for (int i = 0; i < ReferenceAssemblyList.Count; i++)
MS\Internal\Tasks\CompilerLocalReference.cs (1)
275if (alMarkupPages.Count > 0)
MS\Internal\Tasks\CompilerWrapper.cs (1)
255for (int i = 0; i < _mc.ReferenceAssemblyList.Count; i++)
src\Microsoft.DotNet.Wpf\src\PresentationFramework\System\Windows\Markup\BamlRecordWriter.cs (20)
351((KeyDeferRecord)_deferKeys[_deferKeys.Count-1]).RecordList.Add(deferRecord); 494KeyDeferRecord keyRecord = (KeyDeferRecord)(_deferKeys[_deferKeys.Count-1]); 534for (int i = 0; i < record.RecordList.Count; i++) 567KeyDeferRecord keyRecord = (KeyDeferRecord)(_deferKeys[_deferKeys.Count-1]); 601KeyDeferRecord keyRecord = (KeyDeferRecord)(_deferKeys[_deferKeys.Count-1]); 699if (asmList.Count > 0) 701short[] assemblyIds = new short[asmList.Count]; 703for (int i = 0; i < asmList.Count; i++) 835KeyDeferRecord keyRecord = (KeyDeferRecord)(_deferKeys[_deferKeys.Count-1]); 838Debug.Assert(keyRecord.RecordList.Count == 0, "Should have empty record list"); 1167KeyDeferRecord keyDeferRecord = ((KeyDeferRecord)_deferKeys[_deferKeys.Count-1]); 1491((KeyDeferRecord)_deferKeys[_deferKeys.Count-1]).RecordList.Add(deferRec); 1525for (int h = 0; h<_deferElement.Count; h++) 1544for (int i = 0; i<_deferKeys.Count; i++) 1557keyRecord.RecordList.Count > 0) 1559for (int j = 0; j < keyRecord.RecordList.Count; j++) 1608for (int j = 0; j<_deferValues.Count; j++) 1617deferKeyRecord.RecordList.Count > 0) 1634Debug.Assert(keyIndex == _deferKeys.Count, 1685KeyDeferRecord keyDeferRecord = ((KeyDeferRecord)_deferKeys[_deferKeys.Count-1]);
src\Microsoft.DotNet.Wpf\src\PresentationFramework\System\Windows\Markup\MarkupExtensionParser.cs (22)
310if (tokens.Count == 1) 316if (tokens.Count == 3 && 610ArrayList xamlNodes = new ArrayList(markupExtensionList.Count * 5); 612for (int i = 0; i<markupExtensionList.Count; i++) 782(list.Count == 1 || 783(list.Count > 1 && !(list[1] is String) && ((Char)list[1] == ',')))) 820ArrayList xamlNodes = new ArrayList(complexDefAttributesList.Count * 5); 821for (int i = 0; i<complexDefAttributesList.Count; i++) 858(list.Count == 1 || 859(list.Count > 1 && !(list[1] is String) && ((Char)list[1] == ',')))) 1091else if (list.Count == 0) 1097else if (list[list.Count - 1] is Char) 1110parameterName = (string) list[list.Count - 1]; 1130else if (list.Count > 0 && (list[list.Count-1] is Char)) 1230if (list != null && listIndex < list.Count) 1240for (; listIndex < list.Count; listIndex+=2) 1250if (list.Count > (listIndex+1) && 1338if (list != null && listIndex < list.Count) 1340ArrayList propertyNamesSoFar = new ArrayList(list.Count/4); 1342for (int k = listIndex; k < list.Count; k+=4) 1344if (k > (list.Count-3) ||
src\Microsoft.DotNet.Wpf\src\PresentationFramework\System\Windows\Markup\ParserStack.cs (8)
61object o = this[Count - 1]; 62RemoveAt(Count - 1); 88get { return Count > 0 ? this[Count - 1] : null; } 96get { return Count > 1 ? this[Count - 2] : null; } 104get { return Count > 2 ? this[Count - 3] : null; }
src\Microsoft.DotNet.Wpf\src\PresentationFramework\System\Windows\Markup\XamlReaderHelper.cs (16)
2938for (int i = 0; i < xamlNodes.Count; i++) 2950for (int i = 0; i < xamlNodes.Count; i++) 5830Debug.Assert((_nodeIndex == 0 && _xamlNodes.Count == 0 ) || (_nodeIndex < _xamlNodes.Count), 5832if (_xamlNodes.Count > 0) 5837if (_nodeIndex == _xamlNodes.Count) 5850Debug.Assert((_nodeIndex == 0 && _xamlNodes.Count == 0 ) || (_nodeIndex < _xamlNodes.Count), 5861get { return _xamlNodes.Count; } 5878_insertionIndex = value ? _xamlNodes.Count : -1; 5919if (_xamlNodes.Count > 0) 5921for (int i = _xamlNodes.Count - 1; i >= _nodeIndex; i--) 5932if (_nodeIndex >= _xamlNodes.Count) 5936Debug.Assert(_nodeIndex == _xamlNodes.Count, "NodeIndex is larger than node count."); 6084_typeConverterCandidateIndex = _xamlNodes.Count - 1; 6108_typeConverterCandidateIndex = _xamlNodes.Count - 1;
PresentationCore (17)
MS\Internal\IO\Packaging\ByteRangeDownloader.cs (2)
155int rangeCount = _byteRangesAvailable.Count / 2; 663if (_requestsOnWait != null && _requestsOnWait.Count > 0)
MS\Internal\IO\Packaging\NetStream.cs (3)
698System.Diagnostics.Trace.TraceInformation("NetStream.GetData() total byteranges:{0} after merging:{1}", _unmergedBlocks, _byteRangesAvailable.Count); 910for (int i = 0; i + 1 < ranges.Count; i++) 921if (i + 1 >= ranges.Count)
MS\Internal\TextFormatting\FullTextLine.cs (3)
1715if (boundsList.Count > 0) 1723bounds = new TextBounds[boundsList.Count]; 1724for (int i = 0; i < boundsList.Count; i++)
MS\Internal\TextFormatting\SimpleTextLine.cs (2)
274while(count < runs.Count) 400int left = runs != null ? runs.Count : 0;
MS\Internal\TextFormatting\TextStore.cs (1)
1784Plsrun plsrun = (Plsrun)((uint)_lsrunList.Count + Plsrun.FormatAnchor);
System\Windows\Input\AccessKeyManager.cs (6)
70if (elements.Count == 0) 562for (int i = 0; i < elements.Count; ) 589List<IInputElement> copy = new List<IInputElement>(elements.Count); 591for (int i = 0; i < elements.Count; ) 676for (int i = 0; i < elements.Count; i++) 697for (int i = 0; i < elements.Count; i++)
PresentationFramework (388)
MS\Internal\Annotations\Anchoring\PathNode.cs (1)
313while (fp.Node.Equals(sp.Node) && sp._children.Count > 0)
MS\Internal\Controls\InnerItemCollectionView.cs (4)
231for (int i = _rawList.Count - 1; i >= 0; --i) 522for (int k = 0; k < _rawList.Count; ++k) 618get { return _rawList.Count; } 623get { return _viewList.Count; }
MS\Internal\Data\DefaultAsyncDataDispatcher.cs (1)
38for (int i = 0; i < _list.Count; ++i)
MS\Internal\Data\SortFieldComparer.cs (1)
88int n = al.Count;
MS\Internal\Data\ViewManager.cs (4)
271for (int k = 0; k < al.Count; ++k) 276return (al.Count > 0 || this.Count == 0); 818for (int k = 0; k < al.Count; ++k) 823return (al.Count > 0 || foundViewTableDirt);
MS\Internal\DataStreams.cs (1)
238for (int subStreamIndex = 0; subStreamIndex < subStreams.Count; ++subStreamIndex)
MS\Internal\Documents\DocumentGrid.cs (1)
1493for (int i = 0; i < visiblePages.Count; i++)
MS\Internal\PtsHost\PtsContext.cs (2)
82for (index = 0; index < _pageBreakRecords.Count; index++) 100for (index = 0; index < _pages.Count; index++)
MS\Internal\Utility\TraceLog.cs (2)
40if (_log.Count == _size) 50for (int k=0; k<_log.Count; ++k)
System\Windows\Controls\PasswordTextContainer.cs (8)
311for (index = 0; index < _positionList.Count; index++) 721for (; index < _positionList.Count; index++) 761for (; index < _positionList.Count; index++) 786for (index = _positionList.Count-1; index >= 0; index--) 810for (index = 0; index < _positionList.Count; index++) 843for (index = 0; index < _positionList.Count; index++) 901Debug.WriteLine($"{_positionList.Count} entries."); 903for (index = 0; index < _positionList.Count; index++)
System\Windows\Controls\RadioButton.cs (3)
105if (elements.Count == 0) 116for (int i = 0; i < elements.Count; ) 143for (int i = 0; i < elements.Count; )
System\Windows\Controls\TextBlock.cs (1)
1971for (int index = 0; index < inlineObjects.Count; index++)
System\Windows\Data\BindingOperations.cs (1)
258for (int i = 0; i < batch.Count; i++)
System\Windows\Data\CompositeCollection.cs (2)
127for (int k=0, n=InternalList.Count; k < n; ++k) 283return InternalList.Count;
System\Windows\Documents\AdornerLayer.cs (14)
214while (i < adornerInfos.Count) 239while (i < adornerInfos.Count) 259if (adornerInfos == null || adornerInfos.Count == 0) 262Adorner[] adorners = new Adorner[adornerInfos.Count]; 264for (int i = 0; i < adornerInfos.Count; i++) 422while (j < adornerInfos.Count) 457while (j < adornerInfos.Count) 643if (adornerInfos.Count > 1) 665int insertionIndex = _children.IndexOf(((AdornerInfo)adornerInfos[adornerInfos.Count - 1]).Adorner) + 1; 684while (adornerInfos.Count > 0) 723for (int i = 0; i < adornerInfos.Count; i++) 809for (int i = 0; i < removeList.Count; i++) 912if (adornerInfos.Count == 0) 928while (i < adornerInfos.Count)
System\Windows\Documents\CompositionAdorner.cs (4)
146for (int i = 0; i < _attributeRanges.Count; i++) 154if (attributeRange.CompositionLines.Count == 0) 233for (int j = 0; j < attributeRange.CompositionLines.Count; j++) 339for (int i = 0; i < _attributeRanges.Count; i++)
System\Windows\Documents\FixedFlowMap.cs (2)
219 if (range.Count == 0) 228 if (!element.FixedNode.Equals(range[range.Count - 1]))
System\Windows\Documents\Highlights.cs (1)
390return (_layers == null) ? 0 : _layers.Count;
System\Windows\Documents\MoveSizeWinEventHandler.cs (2)
65for (int i = 0; i < _arTextStore.Count; i++) 104return _arTextStore.Count;
System\Windows\Documents\RtfFormatStack.cs (7)
52Invariant.Assert(Count != 0); 54if (Count > 0) 56RemoveAt(Count - 1); 62return Count > 0 ? EntryAt(Count - 1) : null; 67int index = Count - 1 - fromTop; 69if (index < 0 || index >= Count)
System\Windows\Documents\RtfToXamlReader.cs (149)
2831return _cellFormats.Count; 3578for (int i = 0; i < Count; i++) 3593for (int i = 0; i < Count; i++) 3614for (int i = 0; i < Count; i++) 3642for (int i = 0; i < Count; i++) 3681if (Count == 0) 3687for (int i = Count - 1; i >= 0; i--) 3697return EntryAt(Count - 1); 3926if (index >= 0 && index < Count) 3954for (int i = 0; i < Count; i++) 3968return Count - 1; 3973if (index >= 0 && index < Count) 4034return EntryAt(Count - 1); 4174if (index > Count) 4176index = Count - 1; 4178return (ListLevel)(Count > index && index >= 0 ? this[index] : null); 4204return Count > 0 ? EntryAt(Count - 1) : null; 4334for (int i = 0; i < Count; i++) 4370return Count > 0 ? EntryAt(Count - 1) : null; 4509for (int i = 0; i < Count; i++) 4545return Count > 0 ? EntryAt(Count - 1) : null; 5319if (ColumnStateArray != null && ColumnStateArray.Count > 0) 5327for (int i = 0; i < ColumnStateArray.Count; i++) 5576for (int i = 0; i < dnaRows.Count; i++) 5594for (int k = 0; k < cols.Count; k++) 6221for (int i = 0; i < Count; i++) 6283InsertNode(Count, documentNode); 6290if (Count > 0) 6292Excise(Count - 1, 1); 6300for (int i = Count - 1; i >= 0; i--) 6315return ((Count > 0) && (EntryAt(Count - 1).Type == documentNodeType)); 6327Debug.Assert(nStart + nChild < Count); 6328if (nStart + nChild >= Count) 6330nChild = Count - nStart - 1; 6413Debug.Assert(Count == 0 || (nStart >= 0 && nStart < Count)); 6414if (nStart >= Count || nStart < 0) 6424Debug.Assert(nStart + nChild < Count); 6425if (nStart + nChild >= Count) 6427nChild = Count - nStart - 1; 6474Debug.Assert(Count == 0 || (nStart >= 0 && nStart < Count)); 6475if (nStart >= Count || nStart < 0) 6485Debug.Assert(nStart + nChild < Count); 6486if (nStart + nChild >= Count) 6488nChild = Count - nStart - 1; 6533for (int nAt = 0; nAt < Count; nAt++) 6541Debug.Assert(Count == 0 || (index >= 0 && index < Count)); 6542Debug.Assert(index + nChildCount < Count); 6543if (index >= Count || index < 0 || index + nChildCount >= Count) 6571Debug.Assert(Count == 0 || (index >= 0 && index < Count)); 6572if (index >= Count || index < 0) 6587for (int i = Count - 1; i > index; i--) 6597CloseAtHelper(index, Count - index - 1); 6607for (int nAt = 0; nAt < Count; nAt++) 6616Debug.Assert(nAt + dn.ChildCount < Count); 6630for (int nAt = 0; nAt < Count; nAt++) 6656for (int nAt = 0; nAt < Count; nAt++) 6673for (int i = _dnaOpen.Count - 1; i >= 0; i--) 6706for (int i = _dnaOpen.Count - 1; i >= 0; i--) 6725for (int i = _dnaOpen.Count - 1; i >= 0; i--) 6759for (int i = 0; i < _dnaOpen.Count; i++) 6769for (int i = nShape; i < _dnaOpen.Count; i++) 6788if (mlHave.Count > 0 || mlWant.Count == 0) 6794for (int i = Count - 1; i >= 0; i--) 6848if (ml.Count == 1 && bAllBullet) 6858for (int i = Count - 1; i >= 0; i--) 6891for (int i = _dnaOpen.Count - 1; i >= 0; i--) 6907for (int j = Count - 1; j >= 0; j--) 6939for (int i = _dnaOpen.Count - 1; i >= 0; i--) 6973return FindPendingFrom(documentNodeType, Count - 1, nLow); 6985for (int i = _dnaOpen.Count - 1; i >= 0; i--) 7003for (i = 0; i < Count; i++) 7008for (i = 1; i < Count; i++) 7031int i = Count - 1; 7041int nCull = Count - (i + 1); 7052int i = Count; 7072for (nAt++; nAt < Count; nAt++) 7144for (; nAt < Count; nAt++) 7167return Count > 0 ? EntryAt(Count - 1) : null; 7339int nCount = dnaCells.Count < rf.CellCount ? dnaCells.Count : rf.CellCount; 7386while (nColsSeen < csa.Count) 7414for (int i = 0; i < dnaTables.Count; i++) 7418if (csa == null || csa.Count == 0) 7422int nDim = csa.Count; 7431for (int j = 0; j < dnaRows.Count; j++) 7441if (dnaCells.Count < nCount) 7443nCount = dnaCells.Count; 7454for (int k = 0; k < nCount && kCSA < dnaSpanCells.Count; k++) 7787int nStartCount = _converterState.RtfFormatStack.Count; 7816while (_converterState.RtfFormatStack.Count > 2 && _converterState.RtfFormatStack.Count > nStartCount) 7950for (int i = 0; i < dna.Count; i++) 7970while (dna.Count > 0) 7972DocumentNode dnLast = dna.EntryAt(dna.Count - 1); 7976dna.Excise(dna.Count - 1, 1); 7987if (dna.Count > 0) 7989DocumentNode dnLast = dna.EntryAt(dna.Count - 1); 8018for (int i = 0; i < dna.Count; i++) 8052for (int i = dna.Count - 1; i >= 0 && dnFieldBegin == null; i--) 8256for (int i = nInsertAt; !bBlock && i < dna.Count; i++) 8748dna.CloseAt(dna.Count - 1); 8942if (_converterState.RtfFormatStack.Count > 2) 9814int nNoOpValue = dna.Count; 9815int nInsertAt = dna.Count; // Default insertion location 9826&& nInsertAt + dn.ChildCount == dna.Count) 9853int nInsertAt = dna.Count; // Default insertion location 9881Debug.Assert(nInsertAt >= 0 && nChildren > 0 && nInsertAt + nChildren - 1 < dna.Count); 9911for (int i = dna.Count - 1; i >= 0; i--) 9927dna.Excise(dna.Count - nExcise, nExcise); 10061for (int i = formats.Count - 1; i >= 0; i--) 10084for (int i = formats.Count - 1; i >= 0; i--) 10975Debug.Assert(dna.Count > 0 && dna.EntryAt(dna.Count - 1).Type == DocumentNodeType.dnParagraph); 10977int nInsertAt = dna.Count - 1; 10999nInsertAt = dna.Count - 1; 11032for (int i = 0; i < mlHave.Count; i++) 11055if (levels == null || levels.Count == 0) 11096DocumentNode dnPara = dna.EntryAt(dna.Count - 1); 11132int nLists = mlHave.Count; 11133int nLevel = mlWant.Count; 11171if (nMatch < mlCouldHave.Count && mlCouldWant.Count > nMatch) 11188if (dna.Count > 1 && dna.EntryAt(dna.Count - 2).Type == DocumentNodeType.dnListItem) 11395dna.CloseAt(dna.Count - 1); 11422dna.CloseAt(dna.Count - 1); 11430dna.CloseAt(dna.Count - 1); 11431dna.CoalesceChildren(_converterState, dna.Count - 1); 11503for (; nMatch < mlHave.Count && nMatch < mlWant.Count; nMatch++) 11529int nLists = mlHave.Count; 11530int nLevel = mlWant.Count; 11551mlHave.RemoveRange(mlHave.Count - 1, 1); 11563if (nLevel <= mlWant.Count) 11565mlWant[nLists] = mlWant[mlWant.Count - 1]; 11572nInsertAt = dna.Count - 1; 11596nInsertAt = dna.Count - 1; 11611nInsertAt = dna.Count - 1;
System\Windows\Documents\Speller.cs (7)
713if (segments.Count != 0) 1141if (segments.Count == 0) 1186sTextRange = (SpellerInteropBase.ITextRange)segments[Math.Min(i, segments.Count-1)]; 1253sTextRange = (SpellerInteropBase.ITextRange)segments[segments.Count - 1]; 1258index = segments.Count; 1263for (index = 0; index < segments.Count; index++) 1278if (index < segments.Count - 1 &&
System\Windows\Documents\SpellerStatusTable.cs (13)
90for (index = FindIndex(searchStart.CreateStaticPointer(), LogicalDirection.Forward); index >= 0 && index < _runList.Count; index++) 200for (i = index+1; i < _runList.Count; i++) 339maxIndex = _runList.Count; 486if (index < _runList.Count - 1 && GetRun(index + 1).RunType == runType) 541if (index < _runList.Count - 1 && GetRun(index + 1).RunType == run.RunType) 620for (i = index; i < _runList.Count; i++) 635if (index < _runList.Count) 642if (index < _runList.Count && GetRun(index).RunType == RunType.Dirty) 676Invariant.Assert(_runList.Count >= 1, "Run list should never be empty!"); 682for (i = 0; i < _runList.Count; i++) 686if (_runList.Count == 1) 719for (i = 0; i < _runList.Count; i++) 758if (index + 1 < _runList.Count)
System\windows\Documents\TextEditor.cs (1)
318for (int i = 0; i < _registeredEditingTypes.Count; i++)
System\windows\Documents\TextEditorTyping.cs (1)
157for (int i = 0; i < threadLocalStore.PendingInputItems.Count; i++)
System\Windows\Documents\TextMapOffsetErrorLogger.cs (3)
62SegmentCount = segments.Count, 63SegmentStartsAndLengths = new SegmentInfo[segments.Count], 80for (int i = 0; i < segments.Count; i++)
System\Windows\Documents\TextStore.cs (8)
853if (_preparedattributes.Count == 0) 873if (_preparedattributes.Count == 0) 902if (i >= _preparedattributes.Count) 1534for (dwCookie = 0; dwCookie < _mouseSinks.Count; dwCookie++) 1548if (_mouseSinks.Count == 1) 1565for (i = 0; i < _mouseSinks.Count; i++) 1572if (_mouseSinks.Count == 0) 3046for (i = 0; (i < _mouseSinks.Count) && (!eaten); i++)
System\Windows\Documents\XamlToRtfParser.cs (8)
118if (xamlToRtfError == XamlToRtfError.None && _xamlTagStack.Count != 0) 505if (Count > 0) 507RemoveAt(Count - 1); 513if (Count == 0) 518string top = (string)this[Count - 1]; 591length = (_xamlParsePoints.Count - 1) / 2; 626int nLength = (_xamlParsePoints.Count - 1) / 2; 671int nLength = (_xamlParsePoints.Count - 1) / 2;
System\Windows\Documents\XamlToRtfWriter.cs (55)
200if (lltComputed.Count > i) 225for (i = 0; i < dna.Count; i++) 230Debug.Assert(openLists.Count > 0); 231if (openLists.Count > 0) 233openLists.RemoveRange(openLists.Count - 1, 1); 234if (openLists.Count > 0) 236DocumentNode dn1 = (DocumentNode)openLists[openLists.Count - 1]; 276if (bFirst && openLists.Count > 0) 279DocumentNode dnList = (DocumentNode)openLists[openLists.Count - 1]; 280int iLevel = openLists.Count; 295for (j = 0; j < listLevelTable.Count; j++) 305if (j == listLevelTable.Count) 313if (listLevelTable.Count > nListStyles) 315nListStyles = listLevelTable.Count; 324for (j = 0; j < openLists.Count; j++) 356for (int i = 0; i < dna.Count; i++) 393long[] openCounts = new long[dna.Count]; 394long[] openStarts = new long[dna.Count]; 399for (int i = 0; i < dna.Count; i++) 404Debug.Assert(openLists.Count > 0); 405if (openLists.Count > 0) 407openLists.RemoveRange(openLists.Count - 1, 1); 408if (openLists.Count > 0) 410DocumentNode dn1 = (DocumentNode)openLists[openLists.Count - 1]; 429openCounts[openLists.Count - 1] = dn.FormatState.StartIndex - 1; 430openStarts[openLists.Count - 1] = dn.FormatState.StartIndex; 435Debug.Assert(openLists.Count > 0); 438if (openLists.Count > 0) 440openCounts[openLists.Count - 1] += 1; 444if (dn.FormatState.ListLevel > 0 && openLists.Count > 0) 446DocumentNode dnList = (DocumentNode)openLists[openLists.Count - 1]; 447long nCount = openCounts[openLists.Count - 1]; 448long nStart = openStarts[openLists.Count - 1]; 461for (int i = 0; i < dna.Count; i++) 498for (int i = 0; i < dna.Count; i++) 530for (i = 0; i < fontTable.Count; i++) 554for (int i = 0; i < colorTable.Count; i++) 575if (listTable.Count > 0) 580for (int i = 0; i < listTable.Count; i++) 591for (int j = 0; j < listLevelTable.Count; j++) 646if (listOverrideTable.Count > 0) 650for (int i = 0; i < listOverrideTable.Count; i++) 1467if (cellArray.Count > 0) 1509for (int i = 0; i < cellArray.Count; i++) 1523for (int i = 0; i < cellArray.Count; i++) 1715for (int cellIndex = 0; cellIndex < cellArray.Count; cellIndex++) 1751for (int i = 0; i < dnaRows.Count; i++) 1757for (int j = 0; j < dnaCells.Count; j++) 1763while (nColExtra < spanCounts.Count && ((int)spanCounts[nColExtra]) > 0) 1780while (nColHere < spanCounts.Count && ((int)spanCounts[nColHere]) > 0) 1794if (nColHere < spanCounts.Count) 1818while (nColExtra < spanCounts.Count) 1843while (nColHere < spanCounts.Count) 1982while (i < dna.Count) 3524fontTableEntry = fontTable.DefineEntry(fontTable.Count + 1);
System\Windows\FrameworkElement.cs (2)
1434exactMatch = keys.Count; 1446int bestMatch = keys.Count; // index of best match so far
System\Windows\Interop\HwndHost.cs (2)
104if(_hooks.Count == 0) 1114for(int i = 0, nCount = _hooks.Count; i < nCount; i++)
System\Windows\Markup\BamlReader.cs (2)
190get { return _properties.Count; } 376if (_propertiesIndex < _properties.Count - 1)
System\Windows\Markup\BamlRecordReader.cs (7)
458int stackDepth = ReaderContextStack.Count; 509Debug.Assert( stackDepth == ReaderContextStack.Count ); 537Debug.Assert(0 == ReaderContextStack.Count); // if not zero we missed an EndElement 1050if (RootList.Count == 0) 1479paramCount = paramList.Count; 4064for (int i = contextStack.Count-1; i >= 0; i--) 4595if (RootList.Count == 0)
System\Windows\Markup\BamlRecordWriter.cs (17)
351((KeyDeferRecord)_deferKeys[_deferKeys.Count-1]).RecordList.Add(deferRecord); 494KeyDeferRecord keyRecord = (KeyDeferRecord)(_deferKeys[_deferKeys.Count-1]); 534for (int i = 0; i < record.RecordList.Count; i++) 567KeyDeferRecord keyRecord = (KeyDeferRecord)(_deferKeys[_deferKeys.Count-1]); 601KeyDeferRecord keyRecord = (KeyDeferRecord)(_deferKeys[_deferKeys.Count-1]); 835KeyDeferRecord keyRecord = (KeyDeferRecord)(_deferKeys[_deferKeys.Count-1]); 838Debug.Assert(keyRecord.RecordList.Count == 0, "Should have empty record list"); 1167KeyDeferRecord keyDeferRecord = ((KeyDeferRecord)_deferKeys[_deferKeys.Count-1]); 1491((KeyDeferRecord)_deferKeys[_deferKeys.Count-1]).RecordList.Add(deferRec); 1525for (int h = 0; h<_deferElement.Count; h++) 1544for (int i = 0; i<_deferKeys.Count; i++) 1557keyRecord.RecordList.Count > 0) 1559for (int j = 0; j < keyRecord.RecordList.Count; j++) 1608for (int j = 0; j<_deferValues.Count; j++) 1617deferKeyRecord.RecordList.Count > 0) 1634Debug.Assert(keyIndex == _deferKeys.Count, 1685KeyDeferRecord keyDeferRecord = ((KeyDeferRecord)_deferKeys[_deferKeys.Count-1]);
System\Windows\Markup\BamlWriter.cs (2)
952for (int i=0; i < _markupExtensionNodes.Count; i++) 1297if (_nodeTypeStack.Count > 0)
System\Windows\Markup\MarkupExtensionParser.cs (22)
310if (tokens.Count == 1) 316if (tokens.Count == 3 && 610ArrayList xamlNodes = new ArrayList(markupExtensionList.Count * 5); 612for (int i = 0; i<markupExtensionList.Count; i++) 782(list.Count == 1 || 783(list.Count > 1 && !(list[1] is String) && ((Char)list[1] == ',')))) 820ArrayList xamlNodes = new ArrayList(complexDefAttributesList.Count * 5); 821for (int i = 0; i<complexDefAttributesList.Count; i++) 858(list.Count == 1 || 859(list.Count > 1 && !(list[1] is String) && ((Char)list[1] == ',')))) 1091else if (list.Count == 0) 1097else if (list[list.Count - 1] is Char) 1110parameterName = (string) list[list.Count - 1]; 1130else if (list.Count > 0 && (list[list.Count-1] is Char)) 1230if (list != null && listIndex < list.Count) 1240for (; listIndex < list.Count; listIndex+=2) 1250if (list.Count > (listIndex+1) && 1338if (list != null && listIndex < list.Count) 1340ArrayList propertyNamesSoFar = new ArrayList(list.Count/4); 1342for (int k = listIndex; k < list.Count; k+=4) 1344if (k > (list.Count-3) ||
System\Windows\Markup\ParserStack.cs (11)
61object o = this[Count - 1]; 62RemoveAt(Count - 1); 70return this[Count - 1]; 88get { return Count > 0 ? this[Count - 1] : null; } 96get { return Count > 1 ? this[Count - 2] : null; } 104get { return Count > 2 ? this[Count - 3] : null; } 113get { return Count > 3 ? this[Count - 4] : null; }
System\Windows\Markup\XamlStream.cs (2)
375if (bufferArray.Count <= bufferIndex) 377Debug.Assert(bufferArray.Count == bufferIndex,"Need to allocate more than one buffer");
System\Windows\Navigation\NavigationService.cs (10)
553for (int i = ChildNavigationServices.Count - 1; i >= 0; i--) 1314if (_recursiveNavigateList.Count > 0) 1318return BindUriHelper.GetUriRelativeToPackAppBase((_recursiveNavigateList[_recursiveNavigateList.Count - 1] as NavigateQueueItem).Source); 1839if (clearRecursiveNavigations && _recursiveNavigateList.Count > 0) 1870for (; i < _childNavigationServices.Count; ++i) 1881if (++i < _childNavigationServices.Count) 1883for (; i < _childNavigationServices.Count; ++i) 1893Debug.Assert(PendingNavigationList.Count == 0, 2105Debug.Assert(PendingNavigationList.Count == 0, 2464if (!(PendingNavigationList.Count == 0 && _navStatus == NavigationStatus.Navigated))
System\Windows\WindowCollection.cs (4)
111return _list.Count; 149clone = new WindowCollection(_list.Count); 150for (int i = 0; i < _list.Count; i++) 186for (int i = 0; i < _list.Count; i++)
ReachFramework (13)
AlphaFlattener\BrushProxy.cs (5)
389str = str + "BrushList[" + _brushList.Count + "]"; 534if (list.Count == 0) 678if ((_brushList != null) && (_brushList.Count != 0)) 2133int count = _brushList.Count; 2169if (first && (count == _brushList.Count))
AlphaFlattener\DrawingContext.cs (2)
482if (from >= brushes.Count) // Only single brush left 495Debug.Assert(one.BrushList.Count == 2, "Only two brushes allowed here");
AlphaFlattener\Flattener.cs (2)
98if ((children == null) || (children.Count == 0)) 136if (children.Count == 1)
AlphaFlattener\Primitive.cs (2)
483if (cp.Children.Count > 0) 2089for (int index = 0; index < _children.Count; index++)
Serialization\VisualSerializer.cs (2)
273for (int i = 0; i < _objects.Count; i++) 297return _objnams[_objects.Count - 1] as string;
System.CodeDom (1)
System\CodeDom\CodeNamespaceImportCollection.cs (1)
24public int Count => _data.Count;
System.Collections.NonGeneric (3)
System\Collections\CollectionBase.cs (2)
60return _list.Count; 151OnInsert(InnerList.Count, value);
System\Collections\ReadOnlyCollectionBase.cs (1)
25get { return InnerList.Count; }
System.Collections.Specialized (15)
System\Collections\Specialized\NameObjectCollectionBase.cs (7)
211for (int i = _entriesArray.Count - 1; i >= 0; i--) 223for (int i = _entriesArray.Count - 1; i >= 0; i--) 367return _entriesArray.Count; 382if (array.Length - index < _entriesArray.Count) 408int n = _entriesArray.Count; 423int n = _entriesArray.Count; 442int n = _entriesArray.Count;
System\Collections\Specialized\NameValueCollection.cs (2)
114int n = (list != null) ? list.Count : 0; 142int n = (list != null) ? list.Count : 0;
System\Collections\Specialized\OrderedDictionary.cs (5)
89return _objectsArray.Count; 164if (_objectsArray == null || index < 0 || index >= _objectsArray.Count) 286for (int i = 0; i < _objectsArray.Count; i++) 569int ICollection.Count => _objects.Count; 602for (int i = 0; i < _objects.Count; i++)
System\Collections\Specialized\StringCollection.cs (1)
39return data.Count;
System.ComponentModel.TypeConverter (9)
System\ComponentModel\Design\DesignerOptionService.cs (3)
148return _children.Count; 201var propArray = new PropertyDescriptor[propList.Count]; 218if (index < 0 || index >= _children.Count)
System\ComponentModel\ListSortDescriptionCollection.cs (1)
62public int Count => _sorts.Count;
System\ComponentModel\TypeDescriptor.cs (5)
1134var descriptors = new EventDescriptor[filteredEvents.Count]; 1371var descriptors = new PropertyDescriptor[filteredProperties.Count]; 2250Attribute[] attrArray = new Attribute[list.Count]; 2256PropertyDescriptor[] propArray = new PropertyDescriptor[list.Count]; 2262EventDescriptor[] eventArray = new EventDescriptor[list.Count];
System.Configuration.ConfigurationManager (26)
System\Configuration\BaseConfigurationRecord.cs (2)
213&& ((_locationSections == null) || (_locationSections.Count == 0)); 362while (i < _parent._locationSections.Count)
System\Configuration\ConfigurationElement.cs (1)
487if (errorsList.Count == 0) return null;
System\Configuration\ConfigurationElementCollection.cs (5)
119public int Count => Items.Count - _removedItemCount; 511for (int index = 0; index < Items.Count; index++) 660if (index > Items.Count) 934for (int checkIndex = 0; checkIndex < Items.Count; checkIndex++) 941for (int removeIndex = Items.Count - 1; removeIndex >= 0; removeIndex--)
System\Configuration\ConfigurationErrorsException.cs (3)
97this((ConfigurationException)(coll.Count > 0 ? coll[0] : null)) 99if (coll.Count <= 1) return; 100_errors = new ConfigurationException[coll.Count];
System\Configuration\ConfigurationPropertyCollection.cs (4)
19for (int index = 0; index < _items.Count; index++) 28public int Count => _items.Count; 51for (int index = 0; index < _items.Count; index++) 66for (int index = 0; index < _items.Count; index++)
System\Configuration\ElementInformation.cs (2)
73count = arrayList.Count; 76ConfigurationException[] exceptionList = new ConfigurationException[arrayList.Count];
System\Configuration\MgmtConfigurationRecord.cs (2)
781while (i < _locationSections.Count) 1913while (i < _locationSections.Count)
System\Configuration\SectionUpdates.cs (4)
217if (unretrievedGroups.Count == 0) 220string[] groupNames = new string[unretrievedGroups.Count]; 238if (newsGroups.Count == 0) 241string[] groupNames = new string[newsGroups.Count];
System\Configuration\SettingsPropertyValueCollection.cs (3)
50if (ipos >= _values.Count) 77if (ipos >= _values.Count) 109public int Count { get { return _values.Count; } }
System.Data.Common (75)
System\Data\BaseCollection.cs (1)
21public virtual int Count => List.Count;
System\Data\ConstraintCollection.cs (11)
49if (index >= 0 && index < List.Count) 442int oldLength = List.Count; 444Constraint[] constraints = new Constraint[List.Count]; 491if (array.Length - index < _list.Count) 493for (int i = 0; i < _list.Count; ++i) 504int constraintCount = List.Count; 518int constraintCount = List.Count; 535int constraintCount = List.Count; 550int constraintCount = List.Count; 625int constraintCount = List.Count; 669int constraintCount = List.Count;
System\Data\DataColumnCollection.cs (10)
122if (_list.Capacity < capacity + _list.Count) 124_list.Capacity = capacity + _list.Count; 270column.SetOrdinalInternal(_list.Count - 1); 285int count = _list.Count; 589int oldLength = _list.Count; 591DataColumn[] columns = new DataColumn[_list.Count]; 662if (array.Length - index < _list.Count) 667for (int i = 0; i < _list.Count; ++i) 678int columnCount = _list.Count; 782int count = _list.Count;
System\Data\DataRelationCollection.cs (9)
295if (array.Length - index < alist.Count) 300for (int i = 0; i < alist.Count; ++i) 311int relationCount = List.Count; 338int count = List.Count; 559if (index >= 0 && index < _relations.Count) 650for (int i = 0; i < _relations.Count; i++) 740if (index >= 0 && index < _relations.Count) 786for (int i = 0; i < _relations.Count; i++) 842for (int i = 0; i < _relations.Count; i++)
System\Data\DataTableCollection.cs (13)
109for (int i = 0; i < _list.Count; i++) 126for (int i = 0; i < _list.Count; i++) 465int oldLength = _list.Count; 466DataTable[] tables = new DataTable[_list.Count]; 515int count = _list.Count; 537int count = _list.Count; 559if (array.Length - index < _list.Count) 563for (int i = 0; i < _list.Count; ++i) 574int tableCount = _list.Count; 618Debug.Assert(_list.Count == tableList.Count, "Both lists should have equal numbers of tables"); 633int count = _list.Count; 670int count = _list.Count; 740int tableCount = _list.Count;
System\Data\XMLDiffLoader.cs (3)
240for (int i = 0; i < dt.Count; i++) 279if (_tables.Count == 0) 282for (int i = 0; i < _tables.Count; i++)
System\Data\xmlsaver.cs (20)
324for (int i = 0; i < tables.Count; i++) 425for (int i = 0; i < dt.Count; i++) 507for (int i = 0; i < _tables.Count; i++) 531if (topTables.Count == 0) 536var temp = new DataTable[topTables.Count]; 765if (ds != null && _tables.Count > 0) 773else if (writeHierarchy && _tables.Count > 0) 776rels = new DataRelation[_relations.Count]; 2071if (_tables.Count > 0) 2321for (int i = 0; i < tables.Count; i++) 2326for (int i = 0; i < tables.Count; i++) 2338for (int i = 0; i < _tables.Count; i++) 2382for (int i = 0; i < _tables.Count; i++) 2400for (int i = 0; i < _tables.Count; i++) 2729for (int i = 0; i < _dTables.Count; i++) 2753if (topTables.Count == 0) 2758var temp = new DataTable[topTables.Count]; 2820for (int i = 0; i < _dTables.Count; i++) 2878for (int i = 0; i < _dTables.Count; i++) 2900for (int i = 0; i < _dTables.Count; i++)
System\Data\XMLSchema.cs (2)
804for (int i = 0; i < _columnExpressions.Count; i++) 1208DataColumn[] key = new DataColumn[keyColumns.Count];
System\Data\XmlToDatasetMap.cs (2)
371_tableSchemaMap = new XmlNodeIdHashtable(tableList.Count); 422while (nCounter < tableList.Count)
System\Xml\XmlDataDocument.cs (4)
70for (int i = 0; i < al.Count; i++) 1627if (_columnChangeList.Count > 0) 2692while (rowElemList.Count > 0) 2721while (rowElemList.Count > 0)
System.Data.Odbc (1)
System\Data\Odbc\OdbcErrorCollection.cs (1)
32return _items.Count;
System.Net.Primitives (5)
System\Net\CookieCollection.cs (5)
40ArgumentOutOfRangeException.ThrowIfGreaterThanOrEqual(index, m_list.Count); 64m_version = m_list.Count; 125return m_list.Count; 197int listCount = m_list.Count; 214if (idx == m_list.Count)
System.Net.WebProxy (3)
System\Net\WebProxy.cs (3)
80var bypassList = new string[_bypassList.Count]; 135if (bypassList.Count > 0) 137regexBypassList = new Regex[bypassList.Count];
System.Private.CoreLib (25)
src\libraries\System.Private.CoreLib\src\System\Collections\ArrayList.cs (11)
202return BinarySearch(0, Count, value, null); 207return BinarySearch(0, Count, value, comparer); 468if (Count != 0) 564Reverse(0, Count); 616Sort(0, Count, Comparer.Default); 623Sort(0, Count, comparer); 1174get { lock (_root) { return _list.Count; } } 1669public override int Count => _list.Count; 1927public override int Count => _list.Count; 2593if (_index < _list.Count - 1) 2600_index = _list.Count;
src\libraries\System.Private.CoreLib\src\System\Security\SecurityElement.cs (14)
78if (_attributes == null || _attributes.Count == 0) 84Hashtable hashtable = new Hashtable(_attributes.Count / 2); 86int iMax = _attributes.Count; 175int iMax = _attributes.Count; 236int iMax = _attributes.Count; 240if (iMax != other._attributes.Count) 263if (_children.Count != other._children.Count) 416if (_attributes != null && _attributes.Count > 0) 420int iMax = _attributes.Count; 433if (i != _attributes.Count - 2) 440if (_text == null && (_children == null || _children.Count == 0)) 459for (int i = 0; i < _children.Count; ++i) 484int iMax = _attributes.Count;
System.Private.Windows.Core (1)
System\Private\Windows\BinaryFormat\BinaryFormatWriter.cs (1)
485list.Count,
System.Private.Xml (157)
System\Xml\Core\XsdValidatingReader.cs (3)
1328else if (_defaultAttributes.Count > 0) 2194_attributeCount += _defaultAttributes.Count; 2285for (int i = 0; i < _defaultAttributes.Count; i++)
System\Xml\Dom\DocumentSchemaValidator.cs (1)
418for (int i = 0; i < _defaultAttributes.Count; i++)
System\Xml\Dom\XmlDocument.cs (1)
337if (elementList.Count == 0)
System\Xml\Schema\Asttree.cs (10)
153get { return _stack.Count; } 219for (int i = 0; i < _stack.Count; ++i) 241for (int i = 0; i < _stack.Count; ++i) 273for (int i = 0; i < _stack.Count; ++i) 315_axisStack = new ArrayList(axisTree.SubtreeArray.Count); // defined length 317for (int i = 0; i < axisTree.SubtreeArray.Count; ++i) 335for (int i = 0; i < _axisStack.Count; ++i) 373for (int i = 0; i < _axisStack.Count; ++i) 390for (int i = 0; i < _axisStack.Count; ++i) 578for (int i = 0; i < AstArray.Count; ++i)
System\Xml\Schema\BaseValidator.cs (1)
191Debug.Assert(names.Count > 0);
System\Xml\Schema\ConstraintStruct.cs (1)
115if (_KSpointer < _KSs.Count)
System\Xml\Schema\ContentValidator.cs (4)
86Debug.Assert(_particles.Count == _last + 1); 123Debug.Assert(_particles.Count == _last + 1); 253get { return _positions.Count; } 1027for (int i = 0; i < grp.Members.Count; ++i)
System\Xml\Schema\DataTypeImplementation.cs (3)
1132if (values.Count < _minListSize) 1137Array array = Array.CreateInstanceFromArrayType(arrayType, values.Count); 3082for (int i = 0; i < dt.Restriction.Enumeration!.Count; ++i)
System\Xml\Schema\FacetChecker.cs (11)
872for (int i = 0; i < restriction.Patterns!.Count; ++i) 1084for (int i = 0; i < enumeration.Count; ++i) 1185for (int i = 0; i < enumeration.Count; ++i) 1256for (int i = 0; i < enumeration.Count; ++i) 1330for (int i = 0; i < enumeration.Count; ++i) 1412for (int i = 0; i < enumeration.Count; ++i) 1422for (int i = 0; i < enumeration.Count; ++i) 1543for (int i = 0; i < enumeration.Count; ++i) 1612for (int i = 0; i < enumeration.Count; ++i) 1680for (int i = 0; i < enumeration.Count; ++i) 1719for (int i = 0; i < enumeration.Count; ++i)
System\Xml\Schema\Inference\Infer.cs (2)
350if (col != null && col.Count > 0) 525if (col != null && col.Count > 0)
System\Xml\Schema\Preprocessor.cs (1)
142for (int i = 0; i < _redefinedList.Count; ++i)
System\Xml\Schema\SchemaCollectionCompiler.cs (4)
435if (substitutionGroup.IsProcessing && substitutionGroup.Members.Count > 0) 455for (int i = 0; i < substitutionGroup.Members.Count; ++i) 476else if (substitutionGroup.Members.Count > 0) 488for (int i = 0; i < substitutionGroup.Members.Count; ++i)
System\Xml\Schema\SchemaSetCompiler.cs (5)
492if (substitutionGroup.IsProcessing && substitutionGroup.Members.Count > 0) 515for (int i = 0; i < substitutionGroup.Members.Count; ++i) 525for (int j = 0; j < g.Members.Count; ++j) 539for (int i = 0; i < newMembers.Count; ++i) 1243for (int i = 0; i < substitutionGroup.Members.Count; ++i)
System\Xml\Schema\XmlSchemaSet.cs (12)
414for (int i = 0; i < schemaToRemove.ImportedNamespaces.Count; i++) 437for (int i = 0; i < needToCheckSchemaList.Count; i++) 441if (mainSchema.ImportedNamespaces.Count > 0) 455for (int i = 0; i < schemaToRemove.ImportedSchemas.Count; ++i) 638for (int i = 0; i < schema.ImportedSchemas.Count; ++i) 826if (schema!.ImportedSchemas.Count > 0) 829for (int i = 0; i < schema.ImportedSchemas.Count; ++i) 931for (int i = 0; i < schema.ImportedSchemas.Count; ++i) 966for (int i = 0; i < substGroup.Members.Count; ++i) 989for (int i = 0; i < substitutionGroup.Members.Count; ++i) 998for (int j = 0; j < g.Members.Count; ++j) 1338for (int j = 0; j < removalList.Count; ++j)
System\Xml\Schema\XmlSchemaValidator.cs (15)
349for (int i = 0; i < schema.ImportedSchemas.Count; ++i) 776if (names == null || names.Count == 0) 782Debug.Assert(names.Count > 0); 2248for (int k = 0; k < constraintStructures[j].axisFields.Count; ++k) 2292for (int j = 0; j < constraintStructures[i].axisFields.Count; ++j) 2339for (int j = 0; j < constraints[i].axisFields.Count; ++j) 2530if (names == null || names.Count == 0) 2543Debug.Assert(names.Count > 0); 2584if (names == null || names.Count == 0) 2595Debug.Assert(names.Count > 0); 2618if (expected.Count == 1) 2624for (int i = 1; i < expected.Count; i++) 2662for (int i = 1; i < expected.Count; ++i) 2675if (expected.Count == 1) 2698for (int i = 0; i < expected.Count; i++)
System\Xml\Schema\XsdValidator.cs (3)
933for (int k = 0; k < constraints[j].axisFields.Count; ++k) 978for (int j = 0; j < constraints[i].axisFields.Count; ++j) 1033for (int j = 0; j < constraints[i].axisFields.Count; ++j)
System\Xml\Serialization\CodeIdentifiers.cs (1)
176Array array = Array.CreateInstance(type, _list.Count);
System\Xml\Serialization\Compilation.cs (1)
291for (int i = 0; i < list.Count; i++)
System\Xml\Serialization\ImportContext.cs (5)
82for (int i = 0; i < list.Count; i++) 130for (int i = 0; i < list.Count; i++) 143for (int i = 0; i < list.Count; i++) 148tmp += (int)cachedHash / list.Count; 161for (int i = 0; i < items.Count; i++)
System\Xml\Serialization\Mappings.cs (2)
1346if (srcSchemas.Count == 0) 1350if (srcSchemas.Count > 1)
System\Xml\Serialization\SchemaObjectWriter.cs (4)
220for (int i = 0; i < attrs.Count; i++) 291for (int i = 0; i < list.Count; i++) 605for (int i = 0; i < list.Count; i++) 659for (int ia = 0; ia < a.Count; ia++)
System\Xml\Serialization\XmlReflectionImporter.cs (3)
592if (srcSchemas.Count == 0) 596if (srcSchemas.Count > 1) 2356return _list.Count;
System\Xml\Serialization\XmlSerializationReader.cs (4)
1518for (int i = 0; i < _fixups.Count; i++) 1525for (int i = 0; i < _collectionFixups.Count; i++) 3770if (attributes.Count > 0) 3775for (int i = 0; i < attributes.Count; i++)
System\Xml\Serialization\XmlSerializationWriter.cs (1)
1423for (int i = 0; i < _referencesToWrite.Count; i++)
System\Xml\XPath\Internal\XPathMultyIterator.cs (1)
22this.arr = new ResettableIterator[inputArray.Count];
System\Xml\Xsl\IlGen\XmlILConstructAnalyzer.cs (2)
870for (idx = 0; idx < _dupAttrs.Count; idx++) 881if (idx >= _dupAttrs.Count)
System\Xml\Xsl\IlGen\XmlILOptimizerVisitor.cs (1)
5635isUsed = XmlILConstructInfo.Read(nd).CallersInfo.Count != 0;
System\Xml\Xsl\QIL\SubstitutionList.cs (3)
41_s.RemoveRange(_s.Count - 2, 2); 51Debug.Assert(_s.Count % 2 == 0); 52for (int i = _s.Count - 2; i >= 0; i -= 2)
System\Xml\Xsl\Runtime\WhitespaceRuleLookup.cs (1)
99for (int pos = _wildcards.Count; pos-- != 0;)
System\Xml\Xsl\Runtime\XmlQueryRuntime.cs (1)
903for (int i = 0; i < docIndexes.Count; i += 2)
System\Xml\Xsl\XsltOld\ActionFrame.cs (2)
143Debug.Assert(0 < sortarray.Count); 144int numSorts = sortarray.Count;
System\Xml\Xsl\XsltOld\ApplyTemplatesAction.cs (2)
140if (this.containedActions != null && this.containedActions.Count > 0) 161if (processor.SortArray.Count != 0)
System\Xml\Xsl\XsltOld\Avt.cs (2)
28_events = new TextEvent[eventList.Count]; 29for (int i = 0; i < eventList.Count; i++)
System\Xml\Xsl\XsltOld\CallTemplateAction.cs (1)
89if (this.containedActions != null && this.containedActions.Count > 0)
System\Xml\Xsl\XsltOld\Compiler.cs (1)
944Debug.Assert(!constant || list.Count <= 1, "We can't have more then 1 text event if now {avt} found");
System\Xml\Xsl\XsltOld\ContainerAction.cs (4)
227for (int i = imports.Count - 1; 0 <= i; i--) 958if (this.containedActions != null && this.containedActions.Count > 0) 983if (this.containedActions != null && actionIndex < this.containedActions.Count) 1014for (int i = 0; i < this.containedActions.Count; i++)
System\Xml\Xsl\XsltOld\CopyCodeAction.cs (4)
37int count = _copyEvents.Count; 47Debug.Assert(_copyEvents != null && _copyEvents.Count > 0); 61Debug.Assert(frame.Counter < _copyEvents.Count); 70if (frame.IncrementCounter() >= _copyEvents.Count)
System\Xml\Xsl\XsltOld\ForEachAction.cs (1)
71Debug.Assert(processor.SortArray.Count != 0);
System\Xml\Xsl\XsltOld\newinstructionaction.cs (1)
60if (this.containedActions != null && this.containedActions.Count > 0)
System\Xml\Xsl\XsltOld\NumberAction.cs (2)
528int numberlistCount = numberlist.Count; 559for (int i = 0; i < numberlist.Count; i++)
System\Xml\Xsl\XsltOld\ReaderOutput.cs (1)
605Debug.Assert(0 <= attrib && attrib < _attributeList!.Count);
System\Xml\Xsl\XsltOld\RecordBuilder.cs (5)
257Debug.Assert(_attributeCount <= _attributeList.Count); 310if (_attributeCount >= _attributeList.Count) 312Debug.Assert(_attributeCount == _attributeList.Count); 738if (_namespaceCount >= _namespaceList.Count) 740Debug.Assert(_namespaceCount == _namespaceList.Count);
System\Xml\Xsl\XsltOld\RootAction.cs (3)
46for (int i = 0; i < _keyNodes.Count; i++) 154for (int src = srcAttList.Count - 1; 0 <= src; src--) 262if (this.containedActions != null && this.containedActions.Count > 0)
System\Xml\Xsl\XsltOld\SequentialOutput.cs (2)
405for (int record = 0; record < _outputCache.Count; record++) 687Debug.Assert(count <= list.Count);
System\Xml\Xsl\XsltOld\Stylesheet.cs (11)
92for (int i = 0; i < _whitespaceList!.Count; i++) 94for (int j = _whitespaceList.Count - 1; j > i; j--) 110for (int importIndex = _imports.Count - 1; importIndex >= 0; importIndex--) 127for (int i = _whitespaceList.Count - 1; 0 <= i; i--) 138for (int importIndex = _imports.Count - 1; importIndex >= 0; importIndex--) 228for (int importIndex = _imports.Count - 1; importIndex >= 0; importIndex--) 254for (int i = 0; i < manager.templates.Count; i++) 273for (int importIndex = _imports.Count - 1; importIndex >= 0; importIndex--) 318for (int importIndex = _imports.Count - 1; importIndex >= 0; importIndex--) 386for (int importIndex = _imports.Count - 1; importIndex >= 0; importIndex--) 418for (int importIndex = _imports.Count - 1; importIndex >= 0; importIndex--)
System\Xml\Xsl\XsltOld\TemplateAction.cs (1)
234if (this.containedActions != null && this.containedActions.Count > 0)
System\Xml\Xsl\XsltOld\TemplateManager.cs (1)
83for (int templateIndex = this.templates.Count - 1; templateIndex >= 0; templateIndex--)
System\Xml\Xsl\XsltOld\WriterOutput.cs (1)
91Debug.Assert(list.Count >= count);
System\Xml\Xsl\XsltOld\XsltCompileContext.cs (5)
330value.ComparePosition((XPathNavigator?)list[list.Count - 1]) != XmlNodeOrder.Before, 337if (value.ComparePosition((XPathNavigator?)list[list.Count - 1]) == XmlNodeOrder.Same) 345value.ComparePosition((XPathNavigator?)list[list.Count - 1]) != XmlNodeOrder.Same, 920Debug.Assert(resultCollection.Count != 0); 921Debug.Assert(newList.Count != 0);
System.Security.Cryptography.Xml (21)
System\Security\Cryptography\Xml\AncestralNamespaceContextManager.cs (4)
20return GetScopeAt(_ancestorStack.Count - 1); 27for (int i = _ancestorStack.Count - 1; i >= 0; i--) 42for (int i = _ancestorStack.Count - 1; i >= 0; i--) 60_ancestorStack.RemoveAt(_ancestorStack.Count - 1);
System\Security\Cryptography\Xml\C14NAncestralNamespaceContextManager.cs (1)
76for (int i = _ancestorStack.Count - 1; i >= 0; i--)
System\Security\Cryptography\Xml\CanonicalXmlNodeList.cs (1)
30get { return _nodeArray.Count; }
System\Security\Cryptography\Xml\EncryptionPropertyCollection.cs (1)
24get { return _props.Count; }
System\Security\Cryptography\Xml\KeyInfo.cs (2)
51for (int i = 0; i < _keyInfoClauses.Count; ++i) 114get { return _keyInfoClauses.Count; }
System\Security\Cryptography\Xml\ReferenceList.cs (1)
24get { return _references.Count; }
System\Security\Cryptography\Xml\SignedInfo.cs (2)
193if (_references.Count == 0) 196for (int i = 0; i < _references.Count; ++i)
System\Security\Cryptography\Xml\SignedXml.cs (4)
830for (int j = 0; j < references.Count; ++j) 885_refProcessed = new bool[references.Count]; 886_refLevelCache = new int[references.Count]; 921for (int i = 0; i < references.Count; ++i)
System\Security\Cryptography\Xml\TransformChain.cs (2)
47get { return _transforms.Count; } 54if (index >= _transforms.Count)
System\Security\Cryptography\Xml\XmlDecryptionTransform.cs (3)
119if (ExceptUris.Count == 0) 195if (ExceptUris.Count > 0) 197for (int index = 0; index < ExceptUris.Count; index++)
System.Security.Permissions (2)
System\Security\Permissions\PrincipalPermission.cs (2)
282if (elem.Children != null && elem.Children.Count != 0) 284int numChildren = elem.Children.Count;
System.Windows.Forms (18)
System\Windows\Forms\BaseCollection.cs (1)
19public virtual int Count => List!.Count;
System\Windows\Forms\Controls\UpDown\DomainUpDown.cs (13)
101ArgumentOutOfRangeException.ThrowIfGreaterThanOrEqual(value, Items.Count); 135for (int i = 0; i < Items.Count; i++) 205if (_domainItems.Count <= 0) 227if (_domainIndex < _domainItems.Count - 1) 264if (_domainItems.Count <= 0) 271startPosition = _domainItems.Count - 1; 274if (startPosition >= _domainItems.Count) 306if (index >= _domainItems.Count) 378Debug.Assert(index < _domainItems.Count && index >= -1, "SelectValue: index out of range"); 379if (_domainItems is null || index < -1 || index >= _domainItems.Count) 447s = $"{s}, Items.Count: {Items.Count}, SelectedIndex: {SelectedIndex}"; 464if (_domainItems.Count <= 0) 491SelectIndex(_domainItems.Count - 1);
System\Windows\Forms\DataBinding\BindingManagerBase.cs (3)
86PropertyDescriptor[] properties = new PropertyDescriptor[listAccessors.Count]; 100if (listAccessors.Count < offset) 105if (listAccessors.Count == offset)
System\Windows\Forms\DataBinding\CurrencyManager.cs (1)
599PropertyDescriptor[] properties = new PropertyDescriptor[listAccessors.Count];
System.Windows.Forms.Design (7)
System\ComponentModel\Design\Serialization\CodeDomSerializerBase.cs (1)
988array = Array.CreateInstance(arrayType, arrayList.Count);
System\Windows\Forms\Design\ToolStripDesignerUtils.cs (2)
448if ((originalSelComps.Count > 1) || 449(originalSelComps.Count == 1 && selItem.GetCurrentParent() != nextSelection.GetCurrentParent()) ||
System\Windows\Forms\Design\ToolStripItemBehavior.cs (1)
305if (origSel.Count == 0)
System\Windows\Forms\Design\ToolStripKeyboardHandlingService.cs (1)
2040if (origSel.Count == 0)
System\Windows\Forms\Design\ToolStripMenuItemDesigner.cs (2)
2184if (origSel.Count == 0) 2192if (origSel.Count > 0)
System.Windows.Forms.Tests (9)
System\Windows\Forms\DomainUpDownTests.cs (9)
114_sub.Items.Count.Should().Be(0); 625_sub.Items.Count.Should().Be(0); 633_sub.Items.Count.Should().Be(0); 641_sub.Items.Count.Should().Be(0); 748_sub.Items.Count.Should().Be(0); 759_sub.Items.Count.Should().Be(0); 770_sub.Items.Count.Should().Be(0); 995_sub.Items.Count.Should().Be(0); 1219_sub.Items.Count.Should().Be(0);
UIAutomationClient (12)
MS\Internal\Automation\ClientEventManager.cs (5)
160for (int i = _listeners.Count - 1; i >= 0; i--) 235if (_listeners.Count == 0) 297for (int i = _listeners.Count - 1; i >= 0; i--) 556for (int i = 0; i < _listeners.Count; i++) 619for (int i = 0; i < _listeners.Count; i++)
MS\Internal\Automation\ProxyManager.cs (3)
151count += ((ArrayList)o).Count; 519if (proxy == null && _partialClassHandlers.Count > 0) 597count = array.Count;
MS\Internal\Automation\WinEventWrap.cs (4)
88if (_clientCallbacks.Count == 0) 93listIsEmpty = (_clientCallbacks.Count == 0); 150object[] handlers = new object[_clientCallbacks.Count]; 151for (int i = 0; i < _clientCallbacks.Count; i++)
UIAutomationClientSideProviders (11)
MS\Internal\AutomationProxies\MSAANativeProvider.cs (1)
105for (int i = actualParentChain.Count - 1; i >= 0; i--)
MS\Internal\AutomationProxies\WindowsEditBoxRange.cs (1)
278Rect[] rectArray = new Rect[rects.Count];
MS\Internal\AutomationProxies\WindowsListViewGroupHelper.cs (7)
136if (index >= _groups.Count) 145int count = _groups.Count; 157int count = _groups.Count; 174if (index >= _groups.Count) 184return _groups.Count; 189int count = _groups.Count; 350int count = _groups.Count;
MS\Internal\AutomationProxies\WindowsRichEditRange.cs (1)
202Rect[] rectArray = new Rect[rects.Count];
MS\Internal\AutomationProxies\WindowsTab.cs (1)
407int count = list.Count;