Implemented interface members:
property
Count
System.Collections.Generic.ICollection<T>.Count
property
Count
System.Collections.Generic.IReadOnlyCollection<T>.Count
property
Count
System.Collections.ICollection.Count
1507 references to Count
mscorlib (10)
system\AggregateException.cs (5)
300Exception[] innerExceptions = new Exception[m_innerExceptions.Count]; 315while (backAsAggregate != null && backAsAggregate.InnerExceptions.Count == 1) 360for (int i = 0; i < m_innerExceptions.Count; i++) 446for (int i = 0; i < m_innerExceptions.Count; i++) 470return InnerExceptions.Count;
system\collections\objectmodel\readonlycollection.cs (1)
136if (array.Length - index < Count) {
system\runtime\compilerservices\TaskAwaiter.cs (1)
185if (edis.Count > 0)
system\threading\Tasks\ConcurrentExclusiveSchedulerPair.cs (1)
234Contract.Requires(faultedTask != null && faultedTask.IsFaulted && faultedTask.Exception.InnerExceptions.Count > 0,
system\threading\Tasks\Task.cs (2)
5300exceptions = new List<Exception>(ex.InnerExceptions.Count); 7285if (lookForOce && edis.Count > 0 &&
PresentationCore (8)
Core\CSharp\MS\Internal\Ink\InkSerializedFormat\StrokeSerializer.cs (2)
753for (i = 2/*past x,y*/; i < propertyInfos.Count; i++) 874for (; i < propertyInfos.Count; i++)
Core\CSharp\System\Windows\Media\Imaging\BitmapDecoder.cs (1)
1748if ((frames != null) && (frames.Count == (i + 1)))
Core\CSharp\System\Windows\Media\Imaging\BitmapFrame.cs (2)
87if (decoder.Frames.Count == 0) 104if (decoder.Frames.Count == 0)
Core\CSharp\System\Windows\Media\Imaging\BitmapImage.cs (1)
397if (decoder.Frames.Count == 0)
Core\CSharp\System\Windows\Media\Imaging\BitmapMetadata.cs (2)
1398strAuthors = new String[value.Count]; 1583strKeywords = new String[value.Count];
PresentationFramework (298)
src\Framework\MS\Internal\Annotations\Anchoring\FixedTextSelectionProcessor.cs (4)
316if (ts == null || ts.Count <= 0) 374if (resolvedAnchor.TextSegments.Count > 0) 623if ((textView.TextSegments == null) || (textView.TextSegments.Count == 0)) 627end = textView.TextSegments[textView.TextSegments.Count - 1].End.CreatePointer(LogicalDirection.Backward);
src\Framework\MS\Internal\Annotations\Component\AnnotationHighlightLayer.cs (1)
358Debug.Assert((rangeSegments != null) && (rangeSegments.Count > 0), "invalid rangeSegments");
src\Framework\MS\Internal\AppModel\IconHelper.cs (1)
484for (int i = 0; i < frames.Count && bestScore != 0; ++i)
src\Framework\MS\Internal\Data\CollectionViewGroupInternal.cs (6)
138for (int k=0, n=Items.Count; k<n; ++k) 262for (int k=0, n=Items.Count; k<n; ++k) 309for (int k=0, n=group.Items.Count; k < n; ++k) 332for (int k=0, n=Items.Count; k<n; ++k) 814if (_index >= _group.Items.Count) 842if (_index < 0 || _index >= _group.Items.Count)
src\Framework\MS\Internal\Data\CollectionViewGroupRoot.cs (4)
544for (int n = group.Items.Count; index < n; ++index) 626for (int index=0, n=group.Items.Count; index < n; ++index) 739for (int index=0, n=group.Items.Count; index < n; ++index) 785for (int k=group.Items.Count-1; k >= 0; --k)
src\Framework\MS\Internal\Data\XmlDataCollection.cs (3)
78int count = this.Count; 99while (i < this.Count && i < nodes.Count) 138while (i < this.Count)
src\Framework\MS\Internal\Documents\ColumnResult.cs (1)
196Debug.Assert(_paragraphs != null && _paragraphs.Count > 0);
src\Framework\MS\Internal\Documents\FlowDocumentPaginator.cs (1)
405if (textView.TextSegments.Count == 0)
src\Framework\MS\Internal\Documents\HostedElements.cs (4)
81if (_textSegments.Count == 0) 101else if (_currentTextSegment < _textSegments.Count) 114while (_currentTextSegment < _textSegments.Count) 132if (_currentTextSegment < _textSegments.Count)
src\Framework\MS\Internal\Documents\MultiPageTextView.cs (2)
162for (int segmentIndex = 0; segmentIndex < textSegments.Count; segmentIndex++) 735for (index = 0; index < pageViews.Count; index++)
src\Framework\MS\Internal\Documents\ParagraphResult.cs (3)
509return (Lines.Count > 0 && !ContainsOnlyFloatingElements); 538if (Lines.Count == 0) 543else if (Lines.Count == 1)
src\Framework\MS\Internal\Documents\TextDocumentView.cs (159)
137if (FloatingElements.Count > 0) 157for (int segmentIndex = 0; segmentIndex < textSegments.Count; segmentIndex++) 173for (int columnIndex = 0; columnIndex < columns.Count; columnIndex++) 529if (!contains && segments.Count > 0) 537contains = (position.TextContainer.End.CompareTo(segments[segments.Count - 1].End) == 0); 702Invariant.Assert(!snapToTextInFloatingElements || floatingElements.Count == 0, "When snap to text is enabled a valid text position is required if paragraphs exist."); 715Invariant.Assert(!snapToText || paragraphs.Count == 0, "When snap to text is enabled a valid text position is required if paragraphs exist."); 720Invariant.Assert(paragraphIndex < paragraphs.Count); 728Invariant.Assert(paragraphIndex < floatingElements.Count); 766if (nestedParagraphs.Count > 0) 861if (columns.Count > 0 || nestedFloatingElements.Count > 0) 916if (columnIndex < 0 && floatingElements.Count == 0) 925if (columnIndex < columns.Count && columnIndex >= 0) 983Invariant.Assert(paragraphIndex < floatingElements.Count); 991Invariant.Assert(paragraphIndex < paragraphs.Count); 1025if (nestedParagraphs.Count > 0) 1034if (nestedParagraphs.Count > 0) 1098if (columnIndex < 0 && floatingElements.Count == 0) 1105ReadOnlyCollection<ParagraphResult> paragraphs = (columnIndex < columns.Count && columnIndex >= 0) ? columns[columnIndex].Paragraphs : _emptyParagraphCollection; 1132Invariant.Assert(paragraphIndex < floatingElements.Count); 1137if (paragraphIndex < paragraphs.Count) 1174if (nestedParagraphs.Count > 0) 1194if (nestedParagraphs.Count > 0) 1222if (nestedFloatingElements.Count > 0 || columns.Count > 0) 1236if (nestedFloatingElements.Count > 0 || columns.Count > 0) 1266if (columnIndex < columns.Count || floatingElements.Count > 0) 1269ReadOnlyCollection<ParagraphResult> paragraphs = (columnIndex < columns.Count && columnIndex >= 0) ? columns[columnIndex].Paragraphs : _emptyParagraphCollection; 1289int paragraphCount = paragraphs.Count; 1357if (floatingElements != null && floatingElements.Count > 0) 1384int paragraphCount = floatingElements.Count; 1471Invariant.Assert(paragraphIndex < floatingElements.Count); 1476if (paragraphIndex < paragraphs.Count) 1504if (nestedParagraphs.Count > 0) 1518if (nestedParagraphs.Count > 0) 1530if (columns.Count > 0 || nestedFloatingElements.Count > 0) 1542if (columns.Count > 0 || nestedFloatingElements.Count > 0) 1554if (columns.Count > 0 || nestedFloatingElements.Count > 0) 1568if (columnIndex < columns.Count || floatingElements.Count > 0) 1570ReadOnlyCollection<ParagraphResult> paragraphs = (columnIndex < columns.Count && columnIndex >= 0) ? columns[columnIndex].Paragraphs : _emptyParagraphCollection; 1596Invariant.Assert(paragraphIndex < floatingElements.Count); 1601if (paragraphIndex < paragraphs.Count) 1630if (nestedParagraphs.Count > 0) 1645if (nestedParagraphs.Count > 0) 1657if (columns.Count > 0 || nestedFloatingElements.Count > 0) 1669if (columns.Count > 0 || nestedFloatingElements.Count > 0) 1681if (columns.Count > 0 || nestedFloatingElements.Count > 0) 1696if (columnIndex < columns.Count || floatingElements.Count > 0) 1698ReadOnlyCollection<ParagraphResult> paragraphs = (columnIndex < columns.Count && columnIndex >= 0) ? columns[columnIndex].Paragraphs : _emptyParagraphCollection; 1722Invariant.Assert(paragraphIndex < floatingElements.Count); 1727if (paragraphIndex < paragraphs.Count) 1754if (nestedParagraphs.Count > 0) 1768if (nestedParagraphs.Count > 0) 1780if (columns.Count > 0 || nestedFloatingElements.Count > 0) 1792if (columns.Count > 0 || nestedFloatingElements.Count > 0) 1804if (columns.Count > 0 || nestedFloatingElements.Count > 0) 1818if (columnIndex < columns.Count || floatingElements.Count > 0) 1820ReadOnlyCollection<ParagraphResult> paragraphs = (columnIndex < columns.Count && columnIndex >= 0) ? columns[columnIndex].Paragraphs : _emptyParagraphCollection; 1853for (columnIndex = 0; columnIndex < columns.Count; columnIndex++) 1858if (columnIndex == columns.Count - 1) 1900if (columnIndex < columns.Count - 1) 1930if (columnIndex < columns.Count - 1) 1957Invariant.Assert(!foundHit || lastColumnWithContent < columns.Count, "Column not found."); 1985for (paragraphIndex = 0; paragraphIndex < paragraphs.Count; paragraphIndex++) 1990if (paragraphIndex == paragraphs.Count - 1) 2031if (paragraphIndex < paragraphs.Count - 1) 2061if (paragraphIndex < paragraphs.Count - 1) 2088Invariant.Assert(!foundHit || lastParagraphWithContent < paragraphs.Count, "Paragraph not found."); 2105for (int paragraphIndex = 0; paragraphIndex < floatingElements.Count; paragraphIndex++) 2141if (columns.Count > 0) 2143if (columns.Count == 1) 2149for (columnIndex = 0; columnIndex < columns.Count; columnIndex++) 2159if (columnIndex >= columns.Count) 2165else if (position.CompareTo(columns[columns.Count - 1].EndPosition) == 0) 2167columnIndex = columns.Count - 1; 2191if (paragraphIndex < floatingElements.Count) 2216int paragraphSearchIndexUpper = paragraphs.Count - 1; 2219if (paragraphs.Count > 0) 2261else if (position.CompareTo(paragraphs[paragraphs.Count - 1].EndPosition) == 0) 2263paragraphIndex = paragraphs.Count - 1; 2267paragraphIndex = paragraphs.Count; 2292Invariant.Assert(paragraphIndex < floatingElements.Count); 2297if (paragraphIndex < paragraphs.Count) 2330if (nestedParagraphs.Count > 0) 2353Invariant.Assert(lineIndex >= 0 && lineIndex < lines.Count, "Line not found."); 2363if (nestedParagraphs.Count > 0) 2375if (columns.Count > 0 || nestedFloatingElements.Count > 0) 2387if (columns.Count > 0 || nestedFloatingElements.Count > 0) 2399if (columns.Count > 0 || nestedFloatingElements.Count > 0) 2423if (columnIndex < columns.Count || floatingElements.Count > 0) 2425ReadOnlyCollection<ParagraphResult> paragraphs = (columnIndex < columns.Count && columnIndex >= 0) ? columns[columnIndex].Paragraphs : _emptyParagraphCollection; 2461if (paragraphIndex < paragraphs.Count) 2478if (nestedParagraphs.Count > 0) 2503Invariant.Assert(lineIndex >= 0 && lineIndex < lines.Count, "Line not found."); 2516else if (lineIndex + count > lines.Count - 1) 2518lineIndex = lines.Count - 1; 2519count -= (lines.Count - 1 - oldLineIndex); 2566positionOut = lines[lines.Count - 1].GetTextPositionFromDistance(suggestedX); 2570positionOut = lines[lines.Count - 1].StartPosition.CreatePointer(LogicalDirection.Forward); 2591if (nestedParagraphs.Count > 0) 2595int nesteParagraphIndex = (count > 0) ? 0 : nestedParagraphs.Count - 1; 2637if (paragraphIndex >= 0 && paragraphIndex < paragraphs.Count) 2683Invariant.Assert(paragraphIndex < floatingElements.Count); 2694if (columns.Count > 0 || nestedFloatingElements.Count > 0) 2707if (columns.Count > 0 || nestedFloatingElements.Count > 0) 2728if (floatingElements.Count > 0) 2738if (columnIndex < columns.Count) 2758if (columnIndex >= 0 && columnIndex < columns.Count) 2796Invariant.Assert(paragraphIndex >= 0 && paragraphIndex < paragraphs.Count, "Paragraph collection is empty."); 2801while (paragraphIndex >= 0 && paragraphIndex < paragraphs.Count) 2823if (nestedParagraphs.Count > 0) 2825int nesteParagraphIndex = (count > 0) ? 0 : nestedParagraphs.Count - 1; 2863if (nestedParagraphs.Count > 0) 2865int nesteParagraphIndex = (count > 0) ? 0 : nestedParagraphs.Count - 1; 2888if (nestedParagraphs.Count > 0) 2890int nesteParagraphIndex = (count > 0) ? 0 : nestedParagraphs.Count - 1; 2981int lineIndex = (count > 0) ? 0 : lines.Count - 1; 3000else if (lineIndex + count > lines.Count - 1) 3002count -= (lines.Count - 1 - lineIndex); 3044positionOut = lines[lines.Count - 1].GetTextPositionFromDistance(suggestedX); 3048positionOut = lines[lines.Count - 1].StartPosition.CreatePointer(LogicalDirection.Forward); 3080while (columnIndex >= 0 && columnIndex < columns.Count) 3086if (paragraphs.Count > 0) 3090int paragraphIndex = (count > 0) ? 0 : paragraphs.Count - 1; 3144for (int index = 0; index < paragraphs.Count; index++) 3167if (nestedParagraphs.Count > 0) 3196for (int index = 0; index < floatingElements.Count; index++) 3211if (columns.Count > 0 || nestedFloatingElements.Count > 0) 3223if (columns.Count > 0 || nestedFloatingElements.Count > 0) 3243if (floatingElements.Count > 0) 3251for (columnIndexStart = 0; columnIndexStart < columns.Count; columnIndexStart++) 3257for (columnIndexEnd = columnIndexStart; columnIndexEnd < columns.Count; columnIndexEnd++) 3263Invariant.Assert(columnIndexStart < columns.Count && columnIndexEnd < columns.Count, "Start or End position does not belong to TextView's content range"); 3269if (paragraphs != null && paragraphs.Count > 0) 3312for (int index = 0; index < columns.Count; index++)
src\Framework\MS\Internal\Documents\TextParagraphView.cs (18)
174Debug.Assert(lines != null && lines.Count > 0); 178if (!(lineIndex >= 0 && lineIndex < lines.Count)) 187lineIndex = Math.Min(lines.Count - 1, lineIndex); 295Debug.Assert(lines != null && lines.Count > 0); 299Debug.Assert(lineIndex >= 0 && lineIndex < lines.Count); 354Debug.Assert(lines != null && lines.Count > 0, "Line array is empty."); 358Debug.Assert(lineIndex < lines.Count); 388int indexEnd = lines.Count - 1; 396dcp > lines[lines.Count - 1].EndPositionCP) 398return dcp < lines[0].StartPositionCP ? 0 : lines.Count - 1; 428if (position.LogicalDirection == LogicalDirection.Forward && (lineIndex != lines.Count - 1)) 557Debug.Assert(lines != null && lines.Count > 0); 594Debug.Assert(lines != null && lines.Count > 0); 603lineIndex = Math.Max(Math.Min((int)(point.Y / approximatedLineHeight), lines.Count - 1), 0); 627if (lineIndex < lines.Count - 1) 680if (lineIndex < lines.Count - 1) 721Debug.Assert(lines != null && lines.Count > 0); 766else if ((point.X > lineBox.X + lineBox.Width) && (lineIndex < lines.Count - 1))
src\Framework\MS\Internal\Ink\InkCanvasSelection.cs (10)
117return SelectedStrokes.Count != 0 || SelectedElements.Count != 0; 535&& SelectedElements.Count == 1 579if ( SelectedElements.Count == 0 ) 613if ( SelectedElements.Count == 1 ) 746int count = SelectedElements.Count; 763if ( SelectedElements.Count == 0 ) 784Debug.Assert( SelectedElements.Count != 0, 854if ( SelectedElements.Count != 0 ) 872if ( SelectedElements.Count == 0 ) 977if ( SelectedElements.Count != 0 )
src\Framework\MS\Internal\LayoutDump.cs (6)
655writer.WriteAttributeString("Count", lines.Count.ToString(CultureInfo.InvariantCulture)); 657for (int index = 0; index < lines.Count; index++) 696writer.WriteAttributeString("Count", paragraphs.Count.ToString(CultureInfo.InvariantCulture)); 698for (int index = 0; index < paragraphs.Count; index++) 883writer.WriteAttributeString("Count", columns.Count.ToString(CultureInfo.InvariantCulture)); 885for (int index = 0; index < columns.Count; index++)
src\Framework\MS\Internal\PtsHost\ContainerParaClient.cs (1)
469if (paragraphs.Count > 0)
src\Framework\MS\Internal\PtsHost\FigureParaClient.cs (4)
820Invariant.Assert(columns != null && columns.Count <= 1, "Columns collection is null."); 822ReadOnlyCollection<ParagraphResult> paragraphs = (columns.Count > 0) ? columns[0].Paragraphs : new ReadOnlyCollection<ParagraphResult>(new List<ParagraphResult>(0)); 824if (paragraphs.Count > 0 || floatingElements.Count > 0)
src\Framework\MS\Internal\PtsHost\FloaterParaClient.cs (4)
826Invariant.Assert(columns != null && columns.Count <= 1, "Columns collection is null."); 828ReadOnlyCollection<ParagraphResult> paragraphs = (columns.Count > 0) ? columns[0].Paragraphs : new ReadOnlyCollection<ParagraphResult>(new List<ParagraphResult>(0)); 830if (paragraphs.Count > 0 || floatingElements.Count > 0)
src\Framework\MS\Internal\PtsHost\FlowDocumentPage.cs (2)
374Invariant.Assert(_textView != null && ((ITextView)_textView).TextSegments.Count > 0); 1015for (int segmentIndex = 0; segmentIndex < ((ITextView)_textView).TextSegments.Count; segmentIndex++)
src\Framework\System\Windows\Annotations\AnnotationHelper.cs (1)
563if (viewer.PageViews.Count <= endPage - startPage)
src\Framework\System\Windows\Automation\Peers\GroupItemAutomationPeer.cs (1)
85sizeOfSet = parent.Items.Count;
src\Framework\System\Windows\Controls\DataGrid.cs (3)
5637if (cvg != null && cvg.Items.Count > 0) 5641(e.Key == Key.Down && ItemsControl.EqualsEx(cvg.Items[cvg.Items.Count - 1], currentInfo.Item))) 7890itemProperties.Count > 0)
src\Framework\System\Windows\Controls\FlowDocumentScrollViewer.cs (1)
1167if (rects.Count > 0)
src\Framework\System\Windows\Controls\GridViewHeaderRowPresenter.cs (1)
732int count = e.ClearedColumns.Count;
src\Framework\System\Windows\Controls\InkCanvas.cs (1)
1104if (results.Count > 0)
src\Framework\System\Windows\Controls\Primitives\BulletDecorator.cs (3)
352if (cr != null && cr.Count > 0) 356if (pr != null && pr.Count > 0) 373if (lr != null && lr.Count > 0)
src\Framework\System\Windows\Controls\Primitives\DocumentViewerBase.cs (8)
424for (index = 0; index < _pageViews.Count; index++) 436masterPageView = _pageViews.Count > 0 ? _pageViews[0] : null; 462for (int index = 0; index < _pageViews.Count; index++) 647for (index = 0; index < _pageViews.Count; index++) 866for (index = 0; index < _pageViews.Count; index++) 903for (index = 0; index < pageViews.Count; index++) 1252if (_document != null && _pageViews.Count > 0) 1293for (index = 0; index < _pageViews.Count; index++)
src\Framework\System\Windows\Controls\ScrollViewer.cs (1)
2529if (rects.Count > 0)
src\Framework\System\Windows\Controls\SinglePageViewer.cs (7)
696for (int index = 0; index < pageViews.Count; index++) 840if (pageViews.Count > 0) 843pageRects = new Rect[pageViews.Count]; 844for (index = 0; index < pageViews.Count; index++) 1019for (int index = 0; index < pageViews.Count; index++) 1101for (int index = 0; index < pageViews.Count; index++) 1140for (index = 0; index < pageViews.Count; index++)
src\Framework\System\Windows\Controls\TextAdaptor.cs (3)
110if (textSegments.Count > 0) 116if (!textView.Contains(end) && end.CompareTo(textSegments[textSegments.Count-1].End) > 0) 118end = textSegments[textSegments.Count - 1].End.CreatePointer();
src\Framework\System\Windows\Controls\TextBlock.cs (1)
3479if (rects.Count > 0)
src\Framework\System\Windows\Controls\TextRangeAdaptor.cs (9)
687if (textSegments != null && textSegments.Count > 0) 704if (textSegments != null && textSegments.Count > 0) 706if (_end.CompareTo(textSegments[textSegments.Count - 1].End) != 0) 708_end = textSegments[textSegments.Count - 1].End.CreatePointer(); 926if (textSegments != null && textSegments.Count > 0) 933while (position.CompareTo(textSegments[textSegments.Count - 1].End) != 0) 937position.MoveToPosition(textSegments[textSegments.Count - 1].End); 1149if (textSegments == null || textSegments.Count == 0) 1161position.MoveToPosition(textSegments[textSegments.Count - 1].End);
src\Framework\System\Windows\Data\BindingGroup.cs (1)
978for (int i=0, n=errors.Count; i<n; ++i)
src\Framework\System\Windows\Data\BindingListCollectionView.cs (8)
541int index = (oldIndex == 0) ? 0 : _group.Items.Count - 1; 546int index = (newIndex == 0) ? 0 : _group.Items.Count; 824index = _group.Items.Count - 1; 830index = _group.Items.Count - 2; 2311_group.InsertSpecialItem(_group.Items.Count, _newItem, true /*loading*/); 2315_group.InsertSpecialItem(_group.Items.Count, NewItemPlaceholder, true /*loading*/); 2363index = _group.Items.Count; 2369index = _group.Items.Count - 1;
src\Framework\System\Windows\Data\ListCollectionView.cs (8)
656int index = (oldIndex == 0) ? 0 : _group.Items.Count - 1; 661int index = (newIndex == 0) ? 0 : _group.Items.Count; 929index = _group.Items.Count - 1; 935index = _group.Items.Count - 2; 3013_group.InsertSpecialItem(_group.Items.Count, _newItem, true /*loading*/); 3017_group.InsertSpecialItem(_group.Items.Count, NewItemPlaceholder, true /*loading*/); 3066index = _group.Items.Count; 3072index = _group.Items.Count - 1;
src\Framework\System\Windows\Documents\DocumentSequenceTextView.cs (1)
578List<TextSegment> parentSegments = new List<TextSegment>(childSegments.Count);
src\Framework\System\Windows\Documents\WpfPayload.cs (2)
670imageBitmap1.Decoder.Frames.Count == 1 && imageBitmap2.Decoder.Frames.Count == 1 &&
src\Framework\System\Windows\Input\KeyboardNavigation.cs (4)
640if (_canvasChildren.Count == _contentRects.Count) 780if (_contentRects != null && oldRects != null && _contentRects.Count == oldRects.Count) 782for (int i=0; i<oldRects.Count; i++)
System (1)
net\System\Net\WebSockets\WebSocketBase.cs (1)
1363if (unwrappedExceptions.Count == 0)
System.Activities (70)
Microsoft\VisualBasic\Activities\VisualBasicDesignerHelper.cs (15)
448for (int i = 0; i < invocation.Arguments.Count; i++) 457for (int i = 0; i < lambda.Parameters.Count; i++) 466for (int i = 0; i < listInit.Initializers.Count; i++) 469for (int argumentIndex = 0; argumentIndex < arguments.Count; argumentIndex++) 498for (int i = 0; i < bindings.Count; i++) 511for (int i = 0; i < arguments.Count; i++) 555for (int i = 0; i < callArguments.Count; i++) 565for (int i = 0; i < expressions.Count; i++) 575for (int i = 0; i < boundExpressions.Count; i++) 593for (int i = 0; i < ctorArguments.Count; i++) 628for (int i = 0; i < variables.Count; i++) 633for (int i = 0; i < blockExpressions.Count; i++) 662for (int i = 0; i < initializers.Count; i++) 665for (int j = 0; j < arguments.Count; j++) 675for (int i = 0; i < bindings.Count; i++)
Microsoft\VisualBasic\Activities\VisualBasicHelper.cs (34)
766if (tmpArguments.Count > 0) 768arguments = new List<Expression>(tmpArguments.Count); 769for (i = 0; i < tmpArguments.Count; i++) 802List<ElementInit> initializers = new List<ElementInit>(tmpInitializers.Count); 803for (i = 0; i < tmpInitializers.Count; i++) 807arguments = new List<Expression>(tmpArguments.Count); 808for (j = 0; j < tmpArguments.Count; j++) 911List<MemberBinding> bindings = new List<MemberBinding>(tmpMemberBindings.Count); 912for (i = 0; i < tmpMemberBindings.Count; i++) 936List<Expression> indexes = new List<Expression>(tmpArguments.Count); 937for (i = 0; i < tmpArguments.Count; i++) 972if (tmpArguments.Count > 0) 974arguments = new List<Expression>(tmpArguments.Count); 975for (i = 0; i < tmpArguments.Count; i++) 992List<Expression> arrayInitializers = new List<Expression>(tmpExpressions.Count); 993for (i = 0; i < tmpExpressions.Count; i++) 1009List<Expression> bounds = new List<Expression>(tmpExpressions.Count); 1010for (i = 0; i < tmpExpressions.Count; i++) 1027Fx.Assert(newExpression.Arguments.Count == 0, "NewExpression with null Constructor but some arguments"); 1033if (tmpArguments.Count > 0) 1035arguments = new List<Expression>(tmpArguments.Count); 1036for (i = 0; i < tmpArguments.Count; i++) 1091List<ParameterExpression> parameterList = new List<ParameterExpression>(tmpVariables.Count); 1092for (i = 0; i < tmpVariables.Count; i++) 1103List<Expression> expressionList = new List<Expression>(tmpExpressions.Count); 1104for (i = 0; i < tmpExpressions.Count; i++) 1160if (tmpInitializers.Count > 0) 1162initializers = new List<ElementInit>(tmpInitializers.Count); 1163for (i = 0; i < tmpInitializers.Count; i++) 1168if (tmpArguments.Count > 0) 1170arguments = new List<Expression>(tmpArguments.Count); 1171for (j = 0; j < tmpArguments.Count; j++) 1191List<MemberBinding> bindings = new List<MemberBinding>(tmpBindings.Count); 1192for (i = 0; i < tmpBindings.Count; i++)
System\Activities\Expressions\ExpressionServices.cs (3)
1266if (methodCallExpression.Arguments.Count != parameterInfoArray.Length)//no optional argument call for LINQ expression 1411if (newExpression.Arguments.Count != parameterInfoArray.Length)//no optional argument call for LINQ expression 1450for (int i = 0; i < source.Count; i++)
System\Activities\ExpressionUtilities.cs (11)
237int parameterCount = lambdaParameters.Count; 523this.setItemArgumentFunctions = new Func<ActivityContext, object>[callExpression.Arguments.Count]; 524for (int i = 0; i < callExpression.Arguments.Count; i++) 668this.indexFunctions = new Func<ActivityContext, int>[callExpression.Arguments.Count]; 1106Fx.Assert(objectCreationExpression.Arguments.Count == 0, "NewExpression with null Constructor but some arguments"); 1449if (argumentExpressions.Count == 1) 1475if (argumentExpressions.Count == 1) 1509if (argumentExpressions.Count == 1) 1535if (argumentExpressions.Count == 1) 1673if (argumentExpressions.Count == 1) 1711if (argumentExpressions.Count == 1)
System\Activities\Statements\InternalState.cs (1)
899if (children.Count > 0)
System\Activities\Statements\Pick.cs (3)
161if (executingChildren.Count == 0 && !pickState.HasBranchCompletedSuccessfully) 173if (executingChildren.Count == 1 && pickState.ExecuteActionBookmark != null) 189for (int i = 0; i < children.Count; i++)
System\Activities\Tracking\RuntimeTrackingProfile.cs (1)
316for (int i = 0; i < subscriptions.Count; i++)
System\Activities\Validation\ValidationResults.cs (2)
60if (this.allValidationErrors.Count == 0) 70for (int i = 0; i < this.allValidationErrors.Count; i++)
System.Activities.Presentation (6)
System.Activities.Presentation\System\Activities\Presentation\Model\ModelTreeManager.cs (2)
837Fx.Assert(editingScopes.Count == 0 || (modelEditingScopeImpl.ItemsAdded.Count == 0 && modelEditingScopeImpl.ItemsRemoved.Count == 0), "Inner editing scope shouldn't have changes applied.");
System.Activities.Presentation\System\Activities\Presentation\View\TreeView\TreeViewItemModelItemViewModel.cs (1)
142if (this.Children.Count == 1 && this.Children[0] == DummyNode)
System.Activities.Presentation\System\Activities\Presentation\View\TreeView\TreeViewItemViewModel.cs (2)
92if (this.isExpanded && this.Children.Count == 1 && this.Children[0] == DummyNode) 219if (this.Children.Count == 1 && this.Children[0] == DummyNode)
System.Activities.Presentation\System\Activities\Presentation\View\TreeView\UniqueModelItemHelper.cs (1)
53if (0 == expectedImpl.InternalParents.Count)
System.AddIn (1)
System\Addin\Hosting\InspectionWorker.cs (1)
284activatableAs = new TypeInfo[types.Count];
System.Core (160)
Microsoft\Scripting\Actions\CallInfo.cs (1)
73if (argCount < argNameCol.Count) throw Error.ArgCntMustBeGreaterThanNameCnt();
Microsoft\Scripting\Actions\DynamicMetaObjectBinder.cs (3)
80if (parameters.Count == 0) { 83if (args.Length != parameters.Count) { 171for (int i = 0; i < parameters.Count; i++) {
Microsoft\Scripting\Ast\BinaryExpression.cs (5)
263var vars = new List<ParameterExpression>(index.Arguments.Count + 2); 264var exprs = new List<Expression>(index.Arguments.Count + 3); 270var tempArgs = new List<Expression>(index.Arguments.Count); 1345Debug.Assert(pms.Length == conversion.Parameters.Count); 1479Debug.Assert(pms.Length == conversion.Parameters.Count);
Microsoft\Scripting\Ast\BlockExpression.cs (11)
210Debug.Assert(variables == null || variables.Count == 0); 247Debug.Assert(variables == null || variables.Count == 0); 286Debug.Assert(variables == null || variables.Count == 0); 327Debug.Assert(variables == null || variables.Count == 0); 359Debug.Assert(variables == null || variables.Count == 0); 431Debug.Assert(variables == null || variables.Count == VariableCount); 461Debug.Assert(variables == null || variables.Count == VariableCount); 481Debug.Assert(variables == null || variables.Count == VariableCount); 788if (expressionList.Count == 1) { 798if (varList.Count == 0) { 802int count = varList.Count;
Microsoft\Scripting\Ast\DebugViewWriter.cs (1)
807if (node.Arguments.Count == 1) {
Microsoft\Scripting\Ast\DynamicExpression.cs (2)
1075for (int i = 0; i < args.Count; i++) { 1086switch (args.Count) {
Microsoft\Scripting\Ast\ElementInit.cs (1)
63return _arguments.Count;
Microsoft\Scripting\Ast\ExpressionStringBuilder.cs (9)
348if (node.Parameters.Count == 1) { 363for (int i = 0, n = node.Initializers.Count; i < n; i++) { 440if (node.NewExpression.Arguments.Count == 0 && 448for (int i = 0, n = node.Bindings.Count; i < n; i++) { 469for (int i = 0, n = binding.Initializers.Count; i < n; i++) { 482for (int i = 0, n = binding.Bindings.Count; i < n; i++) { 509for (int i = 0, n = node.Arguments.Count; i < n; i++) { 532for (int i = start, n = node.Arguments.Count; i < n; i++) { 581for (int i = 0; i < node.Arguments.Count; i++) {
Microsoft\Scripting\Ast\ExpressionVisitor.cs (3)
70for (int i = 0, n = nodes.Count; i < n; i++) { 119for (int i = 0, n = nodes.Count; i < n; i++) { 168for (int i = 0, n = nodes.Count; i < n; i++) {
Microsoft\Scripting\Ast\IndexExpression.cs (4)
190if (arrayType.GetArrayRank() != indexList.Count) { 418if (indexes.Length != arguments.Count) { 437newArgs = new Expression[arguments.Count]; 450} else if (arguments.Count > 0) {
Microsoft\Scripting\Ast\LambdaExpression.cs (4)
468int paramCount = parameterList.Count; 471var set = new Set<ParameterExpression>(parameterList.Count); 540if (pis.Length != parameters.Count) { 564} else if (parameters.Count > 0) {
Microsoft\Scripting\Ast\ListInitExpression.cs (5)
150if (initializerlist.Count == 0) { 189if (initializerlist.Count == 0) { 192ElementInit[] initList = new ElementInit[initializerlist.Count]; 193for (int i = 0; i < initializerlist.Count; i++) { 230if (initializerlist.Count == 0) {
Microsoft\Scripting\Ast\MemberInitExpression.cs (2)
101int count = bindings.Count; 113int count = initializers.Count;
Microsoft\Scripting\Ast\MemberListBinding.cs (1)
134for (int i = 0, n = initializers.Count; i < n; i++) {
Microsoft\Scripting\Ast\MemberMemberBinding.cs (1)
146for (int i = 0, n = bindings.Count; i < n; i++) {
Microsoft\Scripting\Ast\MethodCallExpression.cs (3)
839ValidateArgumentCount(method, nodeKind, arguments.Count, pis); 848newArgs = new Expression[arguments.Count]; 1035if (arrayType.GetArrayRank() != indexList.Count) {
Microsoft\Scripting\Ast\NewArrayExpression.cs (3)
156for (int i = 0, n = initializerList.Count; i < n; i++) { 165newList = new Expression[initializerList.Count]; 214int dimensions = boundsList.Count;
Microsoft\Scripting\Ast\NewExpression.cs (8)
231if (arguments.Count != pis.Length) { 234if (arguments.Count != members.Count) { 239for (int i = 0, n = arguments.Count; i < n; i++) { 265newArguments = new Expression[arguments.Count]; 275newMembers = new MemberInfo[members.Count]; 290} else if (arguments != null && arguments.Count > 0) { 292} else if (members != null && members.Count > 0) {
Microsoft\Scripting\Ast\RuntimeVariablesExpression.cs (1)
109for (int i = 0; i < vars.Count; i++) {
Microsoft\Scripting\Ast\SwitchExpression.cs (2)
232for (int i = 0; i < c.TestValues.Count; i++) { 255for (int i = 0; i < c.TestValues.Count; i++) {
Microsoft\Scripting\Ast\TryExpression.cs (2)
188if (@finally != null || @catch.Count > 0) { 194} else if (@catch.Count == 0) {
Microsoft\Scripting\Ast\UnaryExpression.cs (1)
245int count = index.Arguments.Count;
Microsoft\Scripting\Compiler\CompilerScope.cs (3)
180var indexes = new List<long>(vars.Count); 290if (hoistedVars.Count > 0) { 303lc.IL.EmitInt(_hoistedLocals.Variables.Count);
Microsoft\Scripting\Compiler\DelegateHelpers.Generated.cs (1)
105for (int i = 0; i < types.Count; i++) {
Microsoft\Scripting\Compiler\ExpressionQuoter.cs (3)
88if (node.Variables.Count > 0) { 92if (node.Variables.Count > 0) { 117int count = node.Variables.Count;
Microsoft\Scripting\Compiler\HoistedLocals.cs (2)
82Dictionary<Expression, int> indexes = new Dictionary<Expression, int>(vars.Count); 83for (int i = 0; i < vars.Count; i++) {
Microsoft\Scripting\Compiler\LambdaCompiler.Address.cs (1)
187if (node.Arguments.Count == 1) {
Microsoft\Scripting\Compiler\LambdaCompiler.Expressions.cs (8)
277} else if (node.Arguments.Count != 1) { 291} else if (node.Arguments.Count != 1) { 522Debug.Assert(node.Arguments.Count == 0, "Node with arguments must have a constructor."); 733node.Expressions.Count, 740for (int i = 0; i < bounds.Count; i++) { 841if (init.NewExpression.Type.IsValueType && init.Bindings.Count > 0) { 855int n = bindings.Count; 888int n = initializers.Count;
Microsoft\Scripting\Compiler\LambdaCompiler.Lambda.cs (1)
173for (int i = _lambda.Parameters.Count - 1; i >= 0; i--) {
Microsoft\Scripting\Compiler\LambdaCompiler.Logical.cs (2)
124Debug.Assert(b.Conversion.Parameters.Count == 1); 177Debug.Assert(b.Conversion.Parameters.Count == 1);
Microsoft\Scripting\Compiler\LambdaCompiler.Statements.cs (10)
120return block.Variables.Count > 0; 186var labels = new Label[node.Cases.Count]; 187var isGoto = new bool[node.Cases.Count]; 188for (int i = 0, n = node.Cases.Count; i < n; i++) { 344var labels = new Label[node.Cases.Count]; 345var isGoto = new bool[node.Cases.Count]; 349for (int i = 0; i < node.Cases.Count; i++) { 435for (int i = 0, n = node.Cases.Count; i < n; i++) { 582var cases = new List<SwitchCase>(node.Cases.Count); 586for (int i = 0, n = node.Cases.Count; i < n; i++) {
Microsoft\Scripting\Compiler\StackSpiller.Bindings.cs (17)
73_bindingRewriters = new BindingRewriter[_bindings.Count]; 74for (int i = 0; i < _bindings.Count; i++) { 86MemberBinding[] newBindings = new MemberBinding[_bindings.Count]; 87for (int i = 0; i < _bindings.Count; i++) { 104Expression[] block = new Expression[_bindings.Count + 2]; 107for (int i = 0; i < _bindings.Count; i++) { 114block[_bindings.Count + 1] = Expression.Block( 119block[_bindings.Count + 1] = Expression.Empty(); 134_childRewriters = new ChildRewriter[_inits.Count]; 135for (int i = 0; i < _inits.Count; i++) { 138ChildRewriter cr = new ChildRewriter(spiller, stack, init.Arguments.Count); 151ElementInit[] newInits = new ElementInit[_inits.Count]; 152for (int i = 0; i < _inits.Count; i++) { 174Expression[] block = new Expression[_inits.Count + 2]; 177for (int i = 0; i < _inits.Count; i++) { 185block[_inits.Count + 1] = Expression.Block( 190block[_inits.Count + 1] = Expression.Empty();
Microsoft\Scripting\Compiler\StackSpiller.cs (27)
182ChildRewriter cr = new ChildRewriter(this, stack, 2 + index.Arguments.Count); 386ChildRewriter cr = new ChildRewriter(this, stack, node.Arguments.Count + 1); 412ChildRewriter cr = new ChildRewriter(this, stack, node.Arguments.Count + 1); 442ChildRewriter cr = new ChildRewriter(this, stack, node.Expressions.Count); 467cr = new ChildRewriter(this, stack, node.Arguments.Count); 486cr = new ChildRewriter(this, stack, node.Arguments.Count + 1); 507ChildRewriter cr = new ChildRewriter(this, stack, node.Arguments.Count); 586ChildRewriter[] cloneCrs = new ChildRewriter[inits.Count]; 588for (int i = 0; i < inits.Count; i++) { 592ChildRewriter cr = new ChildRewriter(this, Stack.NonEmpty, init.Arguments.Count); 603ElementInit[] newInits = new ElementInit[inits.Count]; 604for (int i = 0; i < inits.Count; i++) { 618Expression[] comma = new Expression[inits.Count + 2]; 621for (int i = 0; i < inits.Count; i++) { 626comma[inits.Count + 1] = tempNew; 646BindingRewriter[] bindingRewriters = new BindingRewriter[bindings.Count]; 647for (int i = 0; i < bindings.Count; i++) { 659MemberBinding[] newBindings = new MemberBinding[bindings.Count]; 660for (int i = 0; i < bindings.Count; i++) { 669Expression[] comma = new Expression[bindings.Count + 2]; 671for (int i = 0; i < bindings.Count; i++) { 676comma[bindings.Count + 1] = tempNew; 787for (int i = 0; i < cases.Count; i++) { 792for (int j = 0; j < testValues.Count; j++) { 855for (int i = 0; i < handlers.Count; i++) { 927Debug.Assert(max < original.Count); 929T[] clone = new T[original.Count];
Microsoft\Scripting\Compiler\VariableBinder.cs (3)
118if (node.Variables.Count == 0) { 155while (body.Count == 1 && body[0].NodeType == ExpressionType.Block) { 158if (block.Variables.Count > 0) {
System\Linq\Expressions\ExpressionVisitor.cs (3)
174for (int i = 0, n = original.Count; i < n; i++) { 218for (int i = 0, n = original.Count; i < n; i++) { 239for (int i = 0, n = original.Count; i < n; i++)
System\Linq\Parallel\Scheduling\QueryTaskGroupState.cs (1)
119for (int i = 0; i < flattenedAE.InnerExceptions.Count; i++)
System\Linq\SequenceQuery.cs (5)
231newArgs = new List<Expression>(argList.Count); 260List<Expression> exprs = new List<Expression>(na.Expressions.Count); 261for (int i = 0, n = na.Expressions.Count; i < n; i++) { 339if (mParams.Length != args.Count) 355for (int i = 0, n = args.Count; i < n; i++) {
System.Data (8)
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\Model\ModelTreeManager.cs (2)
837Fx.Assert(editingScopes.Count == 0 || (modelEditingScopeImpl.ItemsAdded.Count == 0 && modelEditingScopeImpl.ItemsRemoved.Count == 0), "Inner editing scope shouldn't have changes applied.");
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\View\TreeView\TreeViewItemModelItemViewModel.cs (1)
142if (this.Children.Count == 1 && this.Children[0] == DummyNode)
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\View\TreeView\TreeViewItemViewModel.cs (2)
92if (this.isExpanded && this.Children.Count == 1 && this.Children[0] == DummyNode) 219if (this.Children.Count == 1 && this.Children[0] == DummyNode)
cdf\src\NetFx40\Tools\System.Activities.Presentation\System\Activities\Presentation\View\TreeView\UniqueModelItemHelper.cs (1)
53if (0 == expectedImpl.InternalParents.Count)
fx\src\data\System\Data\Common\FieldNameLookup.cs (1)
44int length = columnNames.Count;
fx\src\data\System\Data\SqlClient\SqlUtil.cs (1)
158Debug.Assert(ae.InnerExceptions.Count == 1, "There is more than one exception in AggregateException");
System.Data.Entity (329)
System\Data\Common\CommandTrees\Aggregates.cs (1)
34Debug.Assert(arguments.Count == 1, "DbAggregate requires a single argument");
System\Data\Common\CommandTrees\DbFunctionCommandTree.cs (1)
97for (int idx = 0; idx < this._parameterNames.Count; idx++)
System\Data\Common\CommandTrees\ExpressionBuilder\Internal\ArgumentValidation.cs (8)
642if (0 == validKeys.Count && 0 == validAggregates.Count) 1423Debug.Assert(validWhens.Count > 0, "CreateExpressionList(arguments, argumentName, validationCallback) allowed empty Whens?"); 1442Debug.Assert(validWhens.Count > 0, "CreateExpressionList(arguments, argumentName, validationCallback) allowed empty Thens?"); 1453if (validWhens.Count != validThens.Count) 1546Debug.Assert(validElements.Count > 0, "CreateExpressionList(arguments, argumentName, validationCallback) allowed empty elements list?"); 2090|| clrEnumType.GetEnumNames().Length != edmEnumType.Members.Count)
System\Data\Common\CommandTrees\Internal\ExpressionCopier.cs (3)
68List<TypeUsage> paramTypes = new List<TypeUsage>(function.Parameters.Count); 136for (int idx = 0; idx < rowType.Properties.Count; idx++) 188Facet[] facets = new Facet[type.Facets.Count];
System\Data\Common\CommandTrees\Internal\ExpressionDumper.cs (1)
253if (function.ReturnParameters.Count == 1)
System\Data\Common\CommandTrees\Internal\ExpressionPrinter.cs (2)
339if (idx < rowType.Properties.Count) 918for (int idx = e.Keys.Count; idx < outputType.Properties.Count; idx++)
System\Data\Common\CommandTrees\Internal\ViewSimplifier.cs (2)
308if (fkConstraint.FromProperties.Count == 1) 642for (int ordinal = 0; ordinal < innerResultType.Members.Count; ordinal++)
System\Data\Common\CommandTrees\OperatorExpressions.cs (4)
140(DbExpressionKind.UnaryMinus == kind && 1 == args.Count) || 1412 == args.Count, 191Debug.Assert(whens.Count == thens.Count, "DbCaseExpression whens count must match thens count");
System\Data\Common\CommandTrees\RelationalExpressions.cs (3)
246Debug.Assert(groupKeys.Count > 0 || aggregates.Count > 0, "At least one key or aggregate is required"); 328Debug.Assert(inputs.Count >= 2, "DbCrossJoin requires at least two inputs");
System\Data\Common\CommandTrees\ValueExpressions.cs (3)
331Debug.Assert(lambda.Variables.Count == args.Count, "DbLambdaExpression argument count does not match Lambda parameter count"); 642Debug.Assert(args.Count > 0 || TypeSemantics.IsCollectionType(type), "DbNewInstanceExpression requires at least one argument when not creating an empty collection"); 653this._relatedEntityRefs = (relationships.Count > 0 ? relationships : null);
System\Data\Common\DataRecord.cs (1)
67Debug.Assert(_values.Length == _recordInfo.FieldMetadata.Count, "wrong values array size");
System\Data\Common\EntitySql\CqlErrorHelper.cs (6)
119if (leftRow.Members.Count != rightRow.Members.Count) 139for (int i = 0 ; i < leftRow.Members.Count ; i++) 178if (leftComplex.Members.Count != rightComplex.Members.Count) 197for (int i = 0 ; i < leftComplex.Members.Count ; i++)
System\Data\Common\EntitySql\SemanticAnalyzer.cs (5)
1282Debug.Assert((1 == functionType.Parameters.Count), "(1 == functionType.Parameters.Count)"); // we only support monadic aggregate functions 1884if (entityKeyRowType.Members.Count != inputKeyRowType.Members.Count) 2967Debug.Assert(projectionItemErrCtxs.Count == rowType.Members.Count); 2968for (int i = 0; i < rowType.Members.Count; i++)
System\Data\Common\FieldNameLookup.cs (1)
36int length = columnNames.Count;
System\Data\Common\Internal\Materialization\CoordinatorFactory.cs (1)
296if (this.RecordStateFactories.Count > 0)
System\Data\Common\Internal\Materialization\CoordinatorScratchpad.cs (2)
344for (var i = 0; i < arguments.Count; ++i) 493m.Arguments.Count == 1,
System\Data\Common\Utils\MetadataHelper.cs (3)
81return functionImport.ReturnParameters.Count > resultSetIndex 243Debug.Assert(members.Count == 2, "only expecting two end members"); 624int count = baseEntitySets.Count;
System\Data\EntityClient\EntityCommandDefinition.cs (1)
174EntitySet entitySet = functionImport.EntitySets.Count > resultSetIndex ? functionImport.EntitySets[resultSetIndex] : null;
System\Data\EntityKey.cs (11)
723if (((EntitySetBase)entitySet).ElementType.KeyMembers.Count != numKeyMembers) 942int numExpectedKeyValues = ((EntitySetBase)entitySet).ElementType.KeyMembers.Count; 1009if (keyMembers.Count != 1) 1013throw EntityUtil.IncorrectNumberOfKeyValuePairs(argumentName, entitySet.ElementType.FullName, keyMembers.Count, 1); 1017throw EntityUtil.IncorrectNumberOfKeyValuePairsInvalidOperation(entitySet.ElementType.FullName, keyMembers.Count, 1); 1040if (keyMembers.Count != _compositeKeyValues.Length) 1044throw EntityUtil.IncorrectNumberOfKeyValuePairs(argumentName, entitySet.ElementType.FullName, keyMembers.Count, _compositeKeyValues.Length); 1048throw EntityUtil.IncorrectNumberOfKeyValuePairsInvalidOperation(entitySet.ElementType.FullName, keyMembers.Count, _compositeKeyValues.Length); 1164Debug.Assert(entitySet.ElementType.KeyMembers.Count == 1, "For a singleton key, the number of key fields must be exactly 1."); 1172Debug.Assert(entitySet.ElementType.KeyMembers.Count > 1, "For a composite key, the number of key fields should be greater than 1."); 1173Debug.Assert(entitySet.ElementType.KeyMembers.Count == _compositeKeyValues.Length, "Incorrect number of values specified to composite key.");
System\Data\Mapping\DefaultObjectMappingItemCollection.cs (6)
277Debug.Assert(clrRowType.Properties.Count == edmRowType.Properties.Count, "Property count mismatch"); 278for (int idx = 0; idx < clrRowType.Properties.Count; idx++) 385int currIndex = this.Count; 667if (cdmStructuralType.Members.Count != objectStructuralType.Members.Count)
System\Data\Mapping\FunctionImportMapping.cs (15)
111var columnMappings = new List<FunctionImportEntityTypeMappingCondition>(this.DiscriminatorColumns.Count); 112for (int i = 0; i < this.DiscriminatorColumns.Count; i++) 128bool[] impliedEntityTypesBitMap = new bool[this.MappedEntityTypes.Count]; 130for (int i = 0; i < this.MappedEntityTypes.Count; i++) 297var discriminatorDomains = new Set<ValueCondition>[this.DiscriminatorColumns.Count]; 308for (int i = 0; i < this.DiscriminatorColumns.Count; i++) 334Vertex[] conditions = new Vertex[this.NormalizedEntityTypeMappings.Count]; 341for (int j = 0; j < this.DiscriminatorColumns.Count; j++) 377Vertex[] candidateFunctions = new Vertex[this.MappedEntityTypes.Count]; 382for (int j = 0; j < this.NormalizedEntityTypeMappings.Count; j++) 427Vertex[] candidateFunctions = new Vertex[this.MappedEntityTypes.Count]; 432for (int j = 0; j < this.NormalizedEntityTypeMappings.Count; j++) 485if (reachableTypes.Count == this.MappedEntityTypes.Count) 525Debug.Assert(columnConditions.Count == parent.DiscriminatorColumns.Count, 527Debug.Assert(impliedEntityTypes.Count == parent.MappedEntityTypes.Count,
System\Data\Mapping\FunctionImportMappingComposable.cs (2)
252Debug.Assert(this.FunctionImport.Parameters.Count == m_commandParameters.Length, "this.FunctionImport.Parameters.Count == m_commandParameters.Length"); 253Debug.Assert(this.TargetFunction.Parameters.Count == m_commandParameters.Length, "this.TargetFunction.Parameters.Count == m_commandParameters.Length");
System\Data\Mapping\FunctionImportMappingNonComposable.cs (6)
47Debug.Assert(functionImport.ReturnParameters.Count == structuralTypeMappingsList.Count); 74Debug.Assert(this.ResultMappings.Count == 1, "this.ResultMappings.Count == 1"); 79if (ResultMappings.Count <= resultSetIndex) 106BitArray typeCandidates = new BitArray(resultMapping.MappedEntityTypes.Count, true); 113for (int i = 0; i < columnConditions.Count; i++) 181if (0 == resultMapping.NormalizedEntityTypeMappings.Count)
System\Data\Mapping\ObjectTypeMapping.cs (1)
35m_memberMapping = new Dictionary<string, ObjectMemberMapping>(((StructuralType)cdmType).Members.Count);
System\Data\Mapping\StorageAssociationSetMapping.cs (2)
66if ((this.TypeMappings.Count != 0) && (this.TypeMappings.First().MappingFragments.Count != 0))
System\Data\Mapping\StorageEntityContainerMapping.cs (1)
365if (typeMap.MappingFragments.Count > 0)
System\Data\Mapping\StorageMappingItemCollection.ViewDictionary.cs (1)
289Debug.Assert(aSet.ElementType.ReferentialConstraints.Count == 1, "aSet.ElementType.ReferentialConstraints.Count == 1");
System\Data\Mapping\StorageMappingItemLoader.cs (20)
437if (entityContainerMapping.EdmEntityContainer.BaseEntitySets.Count != 0 && !anyEntitySetMapped) 1143if (entityTypeMapping.IsOfTypes.Count != 0 || entityTypeMapping.Types.Count != 1) 1577if (typeMappingsList.Count > 0 && typeMappingsList.Count != functionImport.ReturnParameters.Count) 1602Debug.Assert(functionImport.ReturnParameters.Count == 1, "functionImport.ReturnParameters.Count == 1 for a composable function import."); 1665for (int i = 0; i < mapping.ResultMappings.Count; i++) 1670mapping.GetResultMapping(i).NormalizedEntityTypeMappings.Count == 0) 1692if (functionOverloads.Count == 0) 1699else if (functionOverloads.Count > 1) 1846EntitySet entitySet = functionImport.EntitySets.Count > resultSetIndex ? 2128if (functionImportKB.MappedEntityTypes.Count > 0) 2137for (int i = 0; i < functionImportKB.MappedEntityTypes.Count; ++i) 2152if (structuralTypeMappings.Count < functionImportKB.MappedEntityTypes.Count) 2243keys = new EdmProperty[entityType.KeyMembers.Count]; 2270if (cTypeTvfElementType.Properties.Count > 1) 3679if (facets == null || facets.Count == 0) 3684int numFacets = facets.Count; 3862if (1 < columnNames.Count) 4354if (functionOverloads.Count == 0) 4362if (1 < functionOverloads.Count)
System\Data\Mapping\StorageModificationFunctionMapping.cs (1)
303Debug.Assert(2 == this.Members.Count, "Association bindings must always consist of the end and the key");
System\Data\Mapping\Update\Internal\ExtractorMetadata.cs (4)
146identifier = m_translator.KeyManager.GetKeyIdentifierForMemberOffset(key, keyOrdinal, ((EntityType)m_type).KeyMembers.Count); 205int keyMemberCount = keyRowType.Properties.Count; 208for (int ordinal = 0; ordinal < keyRowType.Properties.Count; ordinal++) 214int keyIdentifier = m_translator.KeyManager.GetKeyIdentifierForMemberOffset(entityKey, ordinal, keyRowType.Properties.Count);
System\Data\Mapping\Update\Internal\FunctionMappingTranslator.cs (2)
273for (int i = parameterBinding.MemberPath.Members.Count; i > 0;) 335Debug.Assert(2 == parameterBinding.MemberPath.Members.Count, "relationship parameter binding member " +
System\Data\Mapping\Update\Internal\KeyManager.cs (2)
310object[] keyValues = new object[keyMembers.Count]; 313for (int i = 0, n = keyMembers.Count; i < n; i++)
System\Data\Mapping\Update\Internal\Propagator.ExtentPlaceholderCreator.cs (6)
143PropagatorResult[] memberValues = new PropagatorResult[members.Count]; 145for (int ordinal = 0; ordinal < members.Count; ordinal++) 166PropagatorResult[] endReferenceValues = new PropagatorResult[endMetadata.Count]; 169for (int endOrdinal = 0; endOrdinal < endMetadata.Count; endOrdinal++) 175PropagatorResult[] keyValues = new PropagatorResult[entityType.KeyMembers.Count]; 176for (int memberOrdinal = 0; memberOrdinal < entityType.KeyMembers.Count; memberOrdinal++)
System\Data\Mapping\Update\Internal\Propagator.JoinPropagator.cs (2)
483PropagatorResult[] keyValues = new PropagatorResult[keySelectors.Count]; 484for (int i = 0; i < keySelectors.Count; i++)
System\Data\Mapping\Update\Internal\Propagator.JoinPropagator.JoinPredicateVisitor.cs (2)
93Debug.Assert(leftKeySelectors.Count == rightKeySelectors.Count,
System\Data\Mapping\Update\Internal\UpdateCommandOrderer.cs (1)
103if (2 == ends.Count)
System\Data\Mapping\Update\Internal\UpdateCompiler.cs (1)
201for (int propertyOrdinal = 0; propertyOrdinal < processor.Table.ElementType.Properties.Count; propertyOrdinal++)
System\Data\Mapping\Update\Internal\UpdateTranslator.cs (6)
171if (0 < associationSet.ElementType.ReferentialConstraints.Count) 242object[] keyValues = new object[principalType.KeyMembers.Count]; 299for (int i = 0, n = constraint.FromProperties.Count; i < n; i++) 353keyMemberCount = entityType.KeyMembers.Count; 689if (null != functionMapping.ResultBindings && 0 < functionMapping.ResultBindings.Count) 691List<EdmProperty> properties = new List<EdmProperty>(functionMapping.ResultBindings.Count);
System\Data\Mapping\ViewGeneration\BasicViewGenerator.cs (4)
449if (pkColumns.Count == fkColumns.Count) 453for (; i < pkColumns.Count && pkColumns[i].EdmEquals(fkColumns[i]); ++i); 454if (i == pkColumns.Count)
System\Data\Mapping\ViewGeneration\CqlGeneration\CaseCqlBlock.cs (2)
54Debug.Assert(Children.Count == 1, "CaseCqlBlock can have exactly one child."); 81Debug.Assert(Children.Count == 1, "CaseCqlBlock can have exactly one child.");
System\Data\Mapping\ViewGeneration\CqlGeneration\CqlBlock.cs (4)
125Debug.Assert(slotNum < m_slots.Count, "Slotnum too high"); 131Debug.Assert(slotNum < m_slots.Count, "Slotnum too high"); 140Debug.Assert(slotNum < m_slots.Count, "Slotnum too high"); 226for (int i = 0; i < m_slots.Count; i++)
System\Data\Mapping\ViewGeneration\CqlGeneration\JoinCqlBlock.cs (1)
100for (int i = 1; i < this.Children.Count; ++i)
System\Data\Mapping\ViewGeneration\CqlGeneration\UnionCqlBlock.cs (3)
37Debug.Assert(this.Children.Count > 0, "UnionCqlBlock: Children collection must not be empty"); 59Debug.Assert(this.Children.Count > 0, "UnionCqlBlock: Children collection must not be empty"); 61for (int i = 1; i < this.Children.Count; ++i)
System\Data\Mapping\ViewGeneration\CqlGenerator.cs (1)
276int numSlotsAddedByChildBlock = childBlock.Slots.Count - TotalSlots;
System\Data\Mapping\ViewGeneration\DiscriminatorMap.cs (2)
198Debug.Assert(entityType.Properties.Count == constructor.Arguments.Count, "invalid new instance"); 199for (int j = 0; j < entityType.Properties.Count; j++)
System\Data\Mapping\ViewGeneration\Structures\CellQuery.cs (5)
233Debug.Assert(indexes.Count >= 1, "Each slot must have one index at least"); 235if (indexes.Count > 1 && 249for (int i = 0; i < indexes.Count; i++) 300Debug.Assert(cSideSlotIndexes.Count > 1, "Method called when no duplicate mapping"); 301if (cSideSlotIndexes.Count > 2)
System\Data\Mapping\ViewGeneration\Structures\OpCellTreeNode.cs (3)
235for (int qualifiedSlotNumber = childProjectedSlots.Length; qualifiedSlotNumber < childBlock.Slots.Count; qualifiedSlotNumber++) 241SlotInfo[] paddedSlotInfo = new SlotInfo[childBlock.Slots.Count]; 356for (int qualifiedSlotNumber = childProjectedSlots.Length; qualifiedSlotNumber < childBlock.Slots.Count; qualifiedSlotNumber++)
System\Data\Metadata\Converter.cs (1)
501Debug.Assert(associationType.ReferentialConstraints.Count == 0, "This must never have been initialized");
System\Data\Metadata\Edm\EdmFunction.cs (4)
62Debug.Assert(_returnParameters.Count == payload.EntitySets.Length, "The number of entity sets should match the number of return parameters"); 68if (_returnParameters.Count != 0) 70Debug.Assert(_returnParameters.Count == 1, "If there was more than one result set payload.EntitySets should not have been null"); 164return _entitySets.Count != 0 ? _entitySets[0] : null;
System\Data\Metadata\Edm\EdmType.cs (2)
182((EntityTypeBase)this).KeyMembers.Count == 0 || 183((EntityTypeBase)value).KeyMembers.Count == 0,
System\Data\Metadata\Edm\EntitySet.cs (1)
141Debug.Assert(associationSet.ElementType.ReferentialConstraints.Count == 1, "Expected exactly one constraint for FK");
System\Data\Metadata\Edm\EntityType.cs (1)
187List<EdmProperty> keyProperties = new List<EdmProperty>(KeyMembers.Count);
System\Data\Metadata\Edm\EntityTypeBase.cs (5)
53if (this.BaseType != null && ((EntityTypeBase)this.BaseType).KeyMembers.Count != 0) 55Debug.Assert(_keyMembers.Count == 0, "Since the base type have keys, current type cannot have keys defined"); 76keyNames = new string[this.KeyMembers.Count]; 83Debug.Assert(_keyMemberNames.Length == this.KeyMembers.Count, "This list is out of sync with the key members count. This property was called before all the keymembers were added"); 101Debug.Assert(this.BaseType == null || ((EntityTypeBase)this.BaseType).KeyMembers.Count == 0,
System\Data\Metadata\Edm\FilteredReadOnlyMetadataCollection.cs (1)
151List<TDerived> list = new List<TDerived>(collection.Count);
System\Data\Metadata\Edm\ItemCollection.cs (5)
199if (_itemsCache == null || this._itemCount != this.Count) 205this._itemCount = this.Count; 359List<EdmFunction> caseSensitiveFunctionOverloads = new List<EdmFunction>(functionOverloads.Count); 361for (int i = 0; i < functionOverloads.Count; i++) 370if (caseSensitiveFunctionOverloads.Count != functionOverloads.Count)
System\Data\Metadata\Edm\MemberCollection.cs (1)
308return baseType.Members.Count;
System\Data\Metadata\Edm\NavigationProperty.cs (3)
147if (associationType.ReferentialConstraints.Count > 0) 156var dependantProperties = new List<EdmProperty>(keyMembers.Count); 157for (int i = 0; i < keyMembers.Count; i++)
System\Data\Metadata\Edm\Provider\EdmProviderManifestFunctionBuilder.cs (1)
27TypeUsage[] primitiveTypeUsages = new TypeUsage[edmPrimitiveTypes.Count];
System\Data\Metadata\Edm\RowType.cs (3)
208if (this.Members.Count != other.Members.Count) { return false; } 211for (int ordinal = 0; ordinal < this.Members.Count; ordinal++)
System\Data\Metadata\Edm\TypeUsage.cs (5)
414EdmProperty[] properties = new EdmProperty[sspaceRowType.Properties.Count]; 501if (this.Facets.Count == 0) 570for (int j = 0; j < this.Facets.Count; j++) 618if (this.Facets.Count != other.Facets.Count) { return false; }
System\Data\Metadata\EdmItemCollection.cs (2)
415for (int i = 0; i < primitiveTypes.Count; i++) 421for (int i = 0; i < functions.Count; i++)
System\Data\Metadata\EdmValidator.cs (1)
306if (item.KeyMembers.Count < 1)
System\Data\Metadata\ObjectLayer\ObjectItemConventionAssemblyLoader.cs (2)
681Debug.Assert(cspaceAssociation.RelationshipEndMembers.Count == 2, "Relationships are assumed to have exactly two ends"); 699for (int i = 0; i < cspaceAssociation.RelationshipEndMembers.Count; i++)
System\Data\Metadata\StoreItemCollection.cs (1)
387if (sTypeFunction.Parameters.Count > 0)
System\Data\Metadata\TypeSemantics.cs (12)
763if (fromRowType.Properties.Count != toRowType.Properties.Count) 768for (int i = 0; i < fromRowType.Properties.Count; i++) 871if (superTypes.Count == 0) 897if (superTypes.Count > 0) 934if (rowType1.Properties.Count != rowType2.Properties.Count || 943for (int i = 0; i < rowType1.Properties.Count; i++) 1070if (fromRow.Properties.Count != toRow.Properties.Count) 1077for (int idx = 0; idx < fromRow.Properties.Count; idx++) 1142if (i == j && commonTypeClosure[i, j].Count != 0)
System\Data\Objects\DataClasses\EntityReference.cs (3)
484int numValues = principalProps.Count; 581for (int i = 0; i < constraint.FromProperties.Count; i++) 663for (int i = 0; i < constraint.FromProperties.Count; i++)
System\Data\Objects\DataClasses\EntityReference_TResultType.cs (3)
620Debug.Assert(constraint.FromProperties.Count == constraint.ToProperties.Count, "Referential constraints From/To properties list have different size"); 630for (int i = 0; i < constraint.FromProperties.Count; ++i)
System\Data\Objects\DataClasses\RelatedEnd.cs (7)
420Debug.Assert(principalProps.Count == dependentProps.Count, "Mismatched foreign key properties?"); 449for (int idx = 0; idx < dependentProps.Count; idx++) 481for (int idx = 0; idx < principalProps.Count; idx++) 1911Debug.Assert(constraint.FromProperties.Count == constraint.ToProperties.Count, "RIC: Referential constraints From/To properties list have different size"); 1914for (int i = 0; i < constraint.FromProperties.Count; ++i)
System\Data\Objects\DataClasses\RelationshipManager.cs (1)
463Debug.Assert(relationship.AssociationEndMembers.Count == 2, "Only 2-way relationships are currently supported");
System\Data\Objects\ELinq\CompiledELinqQueryState.cs (1)
153if (plan.CompiledQueryParameters != null && plan.CompiledQueryParameters.Count > 0)
System\Data\Objects\ELinq\ELinqQueryState.cs (1)
144if (_linqParameters != null && _linqParameters.Count > 0)
System\Data\Objects\ELinq\EntityExpressionVisitor.cs (3)
204for (int i = 0, n = original.Count; i < n; i++) 259for (int i = 0, n = original.Count; i < n; i++) 284for (int i = 0, n = original.Count; i < n; i++)
System\Data\Objects\ELinq\InitializerFacet.cs (7)
279if (this._newExpression.Members.Count != otherProjection._newExpression.Members.Count) 284for (int i = 0; i < this._newExpression.Members.Count; i++) 371if (this._initExpression.Bindings.Count != otherProjection._initExpression.Bindings.Count) 376for (int i = 0; i < this._initExpression.Bindings.Count; i++) 395MemberBinding[] memberBindings = new MemberBinding[_initExpression.Bindings.Count];
System\Data\Objects\ELinq\LinqExpressionNormalizer.cs (8)
146if (m.Arguments.Count == 2) 201if (m.Arguments.Count == 1) 229if (m.Method.Name == "Equals" && m.Arguments.Count > 1) 247if (m.Method.Name == "Compare" && m.Arguments.Count > 1 && m.Method.ReturnType == typeof(int)) 258if (m.Method.Name == "Equals" && m.Arguments.Count > 0) 272if (m.Method.Name == "CompareTo" && m.Arguments.Count == 1 && m.Method.ReturnType == typeof(int)) 281if (m.Method.Name == "Contains" && m.Arguments.Count == 1) { 351if (2 <= callExpression.Arguments.Count &&
System\Data\Objects\ELinq\MethodCallTranslator.cs (33)
287if (selectorLambda.Parameters.Count != 2 || 295if (newExpression.Arguments.Count != 2) 434Debug.Assert(call.Object != null && call.Arguments.Count == 1 && call.Arguments[0] != null && call.Arguments[0].Type.Equals(typeof(string)), "Invalid Include arguments?"); 470Debug.Assert(call.Object != null && call.Arguments.Count == 1 && call.Arguments[0] != null && call.Arguments[0].Type.Equals(typeof(MergeOption)), "Invalid MergeAs arguments?"); 506Debug.Assert(call.Object != null && call.Arguments.Count == 1 && call.Arguments[0] != null && call.Arguments[0].Type.Equals(typeof(Span)), "Invalid IncludeSpan arguments?"); 864List<LinqExpression> arguments = new List<LinqExpression>(call.Arguments.Count + 1); 1017Debug.Assert(call.Arguments.Count == 1, "Expecting 1 argument for String.IndexOf"); 1106Debug.Assert(call.Arguments.Count == 1 || call.Arguments.Count == 2, "Expecting 1 or 2 arguments for String.Substring"); 1114if (call.Arguments.Count == 1) 1145Debug.Assert(call.Arguments.Count == 1 || call.Arguments.Count == 2, "Expecting 1 or 2 arguments for String.Remove"); 1158if (call.Arguments.Count == 2) 1224Debug.Assert(call.Arguments.Count == 2, "Expecting 2 arguments for String.Insert"); 1267Debug.Assert(call.Arguments.Count == 1, "Expecting 1 argument for String.IsNullOrEmpty"); 1300Debug.Assert(call.Arguments.Count >= 2 && call.Arguments.Count <= 4, "Expecting between 2 and 4 arguments for String.Concat"); 1303for (int argIndex = 1; argIndex < call.Arguments.Count; argIndex++) 1340if (newArray.Expressions.Count == 0) 1349if (newArray.Expressions.Count == 1 && 1499Debug.Assert(call.Arguments.Count == 4, "Expecting 4 arguments for Microsoft.VisualBasic.DateAndTime.DatePart"); 1542Debug.Assert(call.Arguments.Count == 2, "Skip and Take must have 2 arguments"); 1574Debug.Assert(5 == call.Arguments.Count); 1672Debug.Assert(1 == call.Arguments.Count); 1680Debug.Assert(2 == call.Arguments.Count); 1747bool isUnary = 1 == call.Arguments.Count; 1748Debug.Assert(isUnary || 2 == call.Arguments.Count); 2026Debug.Assert(0 <= call.Arguments.Count); 2033Debug.Assert(1 <= call.Arguments.Count); 2115Debug.Assert(2 <= call.Arguments.Count); 2180DbExpression defaultValue = call.Arguments.Count == 2 ? 2493LambdaExpression resultSelector = (call.Arguments.Count == 3) ? parent.GetLambdaExpression(call, 2) : null; 3014Debug.Assert(2 == call.Arguments.Count);
System\Data\Objects\ELinq\Translator.cs (7)
711int memberCount = null == linq.Members ? 0 : linq.Members.Count; 714linq.Arguments.Count != memberCount) 762if (linq.Expressions.Count > 0) 801if (linq.Initializers.Any(i => i.Arguments.Count != 1)) 825new List<KeyValuePair<string, DbExpression>>(linq.Bindings.Count + 1); 826MemberInfo[] members = new MemberInfo[linq.Bindings.Count]; 829for (int i = 0; i < linq.Bindings.Count; i++)
System\Data\Objects\EntityEntry.cs (3)
2742for (int i = 0; i < constraint.FromProperties.Count; ++i) 2813for (int i = 0; i < constraint.FromProperties.Count; ++i) 3844Debug.Assert(associationSet.AssociationSetEnds.Count == 2, "Expected an association set with only two ends.");
System\Data\Objects\Internal\ComplexTypeMaterializer.cs (2)
146Properties = new PlanEdmProperty[fields.Count]; 153Debug.Assert(unchecked((uint)field.Ordinal) < unchecked((uint)fields.Count), "FieldMetadata.Ordinal out of range of Fields.Count");
System\Data\Objects\Internal\EntityProxyFactory.cs (1)
1121if (ospaceEntityType.Members.Count != _scalarMembers.Count + _relationshipMembers.Count)
System\Data\Objects\Internal\ForeignKeyFactory.cs (1)
99int numValues = dependentProps.Count;
System\Data\Objects\Internal\ObjectSpanRewriter.cs (5)
357for(int idx = 0; idx < rowType.Properties.Count; idx++) 408List<DbExpression> columnArguments = new List<DbExpression>(rowType.Properties.Count); 409List<EdmProperty> properties = new List<EdmProperty>(rowType.Properties.Count); 410for (int idx = 0; idx < rowType.Properties.Count; idx++) 608if (2 == association.AssociationEndMembers.Count)
System\Data\Objects\ObjectContext.cs (2)
2580int returnTypeCount = Math.Max(1, functionImport.ReturnParameters.Count); 2712EntitySet entitySet = entitySets.Count > resultSetIndex ? entitySets[resultSetIndex] : null;
System\Data\Objects\ObjectStateManager.cs (4)
1480for (int i = 0; i < entitySetForKey.ElementType.KeyMembers.Count; ++i) 3268for (int i = 0; i < constraint.FromProperties.Count; ++i) 3724object[] keyValues = new object[keyMembers.Count]; 3726for (int i = 0; i < keyMembers.Count; ++i)
System\Data\Objects\ObjectStateManagerMetadata.cs (3)
165_members = new StateManagerMemberMetadata[members.Count]; 166_objectNameToOrdinal = new Dictionary<string, int>(members.Count); 167_cLayerNameToOrdinal = new Dictionary<string, int>(members.Count);
System\Data\Objects\RelationshipEntry.cs (1)
275return _relationshipWrapper.AssociationEndMembers.Count;
System\Data\Objects\RelationshipWrapper.cs (1)
59Debug.Assert(extent.ElementType.AssociationEndMembers.Count == 2, "only 2 ends are supported");
System\Data\Query\InternalTrees\ColumnMapFactory.cs (1)
37if (resultMapping.NormalizedEntityTypeMappings.Count == 0) // no explicit mapping; use default non-polymorphic reader
System\Data\Query\InternalTrees\RelPropertyHelper.cs (1)
160if (associationType.AssociationEndMembers.Count != 2)
System\Data\Query\PlanCompiler\ColumnMapProcessor.cs (2)
414ColumnMap[] propertyColumnMapList = new ColumnMap[properties.Count]; 443SimpleColumnMap[] keyColList = new SimpleColumnMap[entityType.KeyMembers.Count];
System\Data\Query\PlanCompiler\ITreeGenerator.cs (1)
2217List<Node> newArgs = new List<Node>(_discriminatorMap.PropertyMap.Count + 1);
System\Data\Query\PlanCompiler\NominalTypeEliminator.cs (5)
974PlanCompiler.Assert(typeInfo.RootType.FlattenedType.Properties.Count == varInfo.NewVars.Count, 975"Var count mismatch; Expected " + typeInfo.RootType.FlattenedType.Properties.Count + "; got " + varInfo.NewVars.Count + " instead."); 2601List<Node> children = new List<Node>(op.DiscriminatorMap.TypeMap.Count * 2 - 1); 2602for (int i = 0; i < op.DiscriminatorMap.TypeMap.Count; i++) 2610if (i == op.DiscriminatorMap.TypeMap.Count - 1)
System\Data\Query\PlanCompiler\PreProcessor.cs (3)
1778for (int i = n.Children.Count - 1; i >= entityType.Properties.Count; i--, j--) 1801for (int i = entityType.Properties.Count; i < n.Children.Count; i++, j++) 1810for (int i = 0; i < entityType.Properties.Count; i++)
System\Data\SqlClient\SqlGen\SqlFunctionCallHandler.cs (2)
769Debug.Assert(functionExpression.Function.Parameters.Count > 0 && Helper.IsSpatialType(functionExpression.Function.Parameters[0].TypeUsage), "Instance property function does not have instance parameter?"); 775Debug.Assert(functionExpression.Function.Parameters.Count > 0 && Helper.IsSpatialType(functionExpression.Function.Parameters[0].TypeUsage), "Instance method function does not have instance parameter?");
System\Data\SqlClient\SqlProviderManifest.cs (1)
300if (funParams == null || funParams.Count == 0)
System.Data.Entity.Design (31)
System\Data\Entity\Design\Common\MetadataItemSerializer.cs (2)
368if (entityType.KeyMembers.Count != 0 && 372for (int i = 0; i < entityType.KeyMembers.Count; i++)
System\Data\Entity\Design\Common\OneToOneMappingSerializer.cs (8)
138Debug.Assert(set.ElementType.ReferentialConstraints.Count == 1, "no referenctial constraint for association[0]"); 141Debug.Assert(set.AssociationSetEnds.Count == 2, "Associations are assumed to have two ends"); 219return names.Count == _storeEntitySet.ElementType.Properties.Count; 238Debug.Assert(_storeAssociationSets[0].ElementType.ReferentialConstraints.Count == 1, "no referenctial constraint for association[0]"); 239Debug.Assert(_storeAssociationSets[1].ElementType.ReferentialConstraints.Count == 1, "no referenctial constraint for association[1]"); 309Debug.Assert(storeFunction.ReturnParameters.Count == 1, "storeFunction.ReturnParameters.Count == 1"); 311Debug.Assert(functionImport.ReturnParameters.Count == 1, "functionImport.ReturnParameters.Count == 1"); 449for (int i = 0; i < constraint.FromProperties.Count; i++)
System\Data\Entity\Design\EntityModelSchemaGenerator.cs (12)
942if (storeAssociation.ReferentialConstraints.Count == 0) 976Debug.Assert(storeAssociation.ReferentialConstraints.Count <= 1, "We don't have a reason to have more than one constraint yet"); 979if (storeAssociation.ReferentialConstraints.Count == 0) 985Debug.Assert(storeConstraint.FromProperties.Count == storeConstraint.ToProperties.Count, "FromProperties and ToProperties have different counts"); 986Debug.Assert(storeConstraint.FromProperties.Count != 0, "No properties in the constraint, why does the constraint exist?"); 999int count = storeConstraint.FromProperties.Count; 1022if (storeAssociation.ReferentialConstraints.Count == 0) 1028Debug.Assert(storeConstraint.FromProperties.Count == storeConstraint.ToProperties.Count, "FromProperties and ToProperties have different counts"); 1029Debug.Assert(storeConstraint.FromProperties.Count != 0, "No properties in the constraint, why does the constraint exist?"); 1043Debug.Assert(association.Members.Count == 2, "this code assumes two ends");
System\Data\Entity\Design\EntityStoreSchemaGenerator.cs (6)
172Debug.Assert(type.KeyMembers.Count > 0, "Why do we have Entities without keys in our valid Entities collection"); 419Debug.Assert(containers.Count != 0, "no s space containers found"); 420Debug.Assert(containers[0].BaseEntitySets.Count != 0, "no entity sets in the sspace container"); 918if (entity.KeyMembers.Count != columns.Count) 1294if (rowType.Properties.Count == 0) 1601List<KeyValuePair<string, DbExpression>> projectList = new List<KeyValuePair<string, DbExpression>>(entitySet.ElementType.Members.Count);
System\Data\EntityModel\Emitters\AssociationTypeEmitter.cs (1)
33Debug.Assert(Item.AssociationEndMembers.Count == 2, "must have exactly two ends");
System\Data\EntityModel\Emitters\EntityTypeEmitter.cs (1)
56if ( Item.KeyMembers.Count > 0 && typeDecls.Count == 1 )
System\Data\EntityModel\Emitters\StructuredTypeEmitter.cs (1)
148List<EdmProperty> parameters = new List<EdmProperty>(properties.Count);
System.Data.Linq (150)
ChangeConflicts.cs (1)
366if (nResolved == this.memberConflicts.Count) {
ChangeProcessor.cs (1)
235for (int i = 0, n = assoc.ThisKey.Count; i < n; i++) {
ChangeTracker.cs (3)
257dirtyMemberCache = new BitArray(this.type.DataMembers.Count); 577for (int i = 0, n = assoc.ThisKey.Count; i < n; i++) { 588for (int i = 0, n = assoc.ThisKey.Count; i < n; i++) {
DataServices.cs (11)
218for (int i = 0, n = type.IdentityMembers.Count; i < n; i++) { 272for (int i = 0, n = keyMembers.Count; i < n; i++) { 335object[] keyValues = new object[keys.Count]; 336for (int i = 0, n = keys.Count; i < n; i++) { 473if (mc == null || mc.Arguments.Count < 1 || mc.Arguments.Count > 2) 488if (mc.Arguments.Count == 1) { 522if (predicate.Parameters.Count != 1) 526&& keys.Count == type.IdentityMembers.Count) { 537if (mex != null && mex.Method.Name == "op_Equality" && mex.Arguments.Count == 2) { 578if (ie != null && ie.Arguments != null && ie.Arguments.Count == 0) {
IdentityManager.cs (1)
77int n = type.IdentityMembers.Count;
Mapping\AttributedMetaModel.cs (6)
110if (this.staticTables.Count > 0) { 684return table.RowType.IdentityMembers.Count > 0; 1358if (this.thisKey.Count != this.otherKey.Count && this.thisKey.Count > 0 && this.otherKey.Count > 0) {
Mapping\MappedMetaModel.cs (5)
758return table.RowType.IdentityMembers.Count > 0; 1232if (this.thisKey.Count != this.otherKey.Count && this.thisKey.Count > 0 && this.otherKey.Count > 0) {
SqlClient\Query\Funcletizer.cs (3)
301for (int i = 0, n = original.Count; i < n; i++) { 345for (int i = 0, n = original.Count; i < n; i++) { 365for (int i = 0, n = original.Count; i < n; i++) {
SqlClient\Query\QueryConverter.cs (112)
329for (int i = 0, n = invoke.Arguments.Count; i < n; i++) { 344} else if (invoke.Arguments.Count == 0) { 355SqlExpression [] args = new SqlExpression[invoke.Arguments.Count]; 368for (int i = 0, n = lambda.Parameters.Count; i < n; i++) { 822if (TypeSystem.IsNullableType(qn.Type) && qn.Arguments.Count == 1 && 826else if (qn.Type == typeof(decimal) && qn.Arguments.Count == 1) { 838if (qn.Arguments.Count > 0) { 839args = new SqlExpression[qn.Arguments.Count]; 840for (int i = 0, n = qn.Arguments.Count; i < n; i++) { 858if (qn.Type == typeof(decimal) && qn.Arguments.Count == 1) { 862if (qn.Arguments.Count > 0) { 863args = new SqlExpression[qn.Arguments.Count]; 869int cBindings = init.Bindings.Count; 939if (mce != null && IsSequenceOperatorCall(mce) && mce.Method.Name == "Skip" && mce.Arguments.Count == 2) { 1217List<SqlExpression> sqlParams = new List<SqlExpression>(mce.Arguments.Count); 1220for (int i = 0, n = mce.Arguments.Count; i < n; i++) { 1645if (!outerNode && !isCount && (lambda == null || (lambda.Parameters.Count == 1 && lambda.Parameters[0] == lambda.Body)) && 1888if (mc.Arguments.Count == 2) { 1932&& mc.Arguments.Count == 1 1940SqlExpression[] args = new SqlExpression[mc.Arguments.Count]; 2000else if (function.ResultRowTypes.Count > 0) { 2038if (mc.Arguments.Count == 2 && 2039this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2045if (mc.Arguments.Count == 2 && 2046this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2049else if (mc.Arguments.Count == 3 && 2050this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1 && 2051this.IsLambda(mc.Arguments[2]) && this.GetLambda(mc.Arguments[2]).Parameters.Count == 2) { 2057if (mc.Arguments.Count == 5 && 2058this.IsLambda(mc.Arguments[2]) && this.GetLambda(mc.Arguments[2]).Parameters.Count == 1 && 2059this.IsLambda(mc.Arguments[3]) && this.GetLambda(mc.Arguments[3]).Parameters.Count == 1 && 2060this.IsLambda(mc.Arguments[4]) && this.GetLambda(mc.Arguments[4]).Parameters.Count == 2) { 2066if (mc.Arguments.Count == 5 && 2067this.IsLambda(mc.Arguments[2]) && this.GetLambda(mc.Arguments[2]).Parameters.Count == 1 && 2068this.IsLambda(mc.Arguments[3]) && this.GetLambda(mc.Arguments[3]).Parameters.Count == 1 && 2069this.IsLambda(mc.Arguments[4]) && this.GetLambda(mc.Arguments[4]).Parameters.Count == 2) { 2075if (mc.Arguments.Count == 1) { 2081if (mc.Arguments.Count == 1) { 2088if (mc.Arguments.Count == 1) { 2095if (mc.Arguments.Count == 2 && 2096this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2103if (mc.Arguments.Count == 1) { 2106else if (mc.Arguments.Count == 2 && 2107this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2114if (mc.Arguments.Count == 1) { 2117else if (mc.Arguments.Count == 2 && 2118this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2124if (mc.Arguments.Count == 1) { 2130if (mc.Arguments.Count == 2) { 2136if (mc.Arguments.Count == 2) { 2142if (mc.Arguments.Count == 2) { 2148if (mc.Arguments.Count == 2) { 2154if (mc.Arguments.Count == 1) { 2157else if (mc.Arguments.Count == 2 && 2158this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2164if (mc.Arguments.Count == 2 && 2165this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2171if (mc.Arguments.Count == 1) { 2174else if (mc.Arguments.Count == 2 && 2175this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2181if (mc.Arguments.Count == 1) { 2184else if (mc.Arguments.Count == 2 && 2185this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2191if (mc.Arguments.Count == 1) { 2194else if (mc.Arguments.Count == 2 && 2195this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2201if (mc.Arguments.Count == 1) { 2204else if (mc.Arguments.Count == 2 && 2205this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2211if (mc.Arguments.Count == 1) { 2214else if (mc.Arguments.Count == 2 && 2215this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2221if (mc.Arguments.Count == 1) { 2224else if (mc.Arguments.Count == 2 && 2225this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2231if (mc.Arguments.Count == 2 && 2232this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2235else if (mc.Arguments.Count == 3 && 2236this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1 && 2237this.IsLambda(mc.Arguments[2]) && this.GetLambda(mc.Arguments[2]).Parameters.Count == 1) { 2240else if (mc.Arguments.Count == 3 && 2241this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1 && 2242this.IsLambda(mc.Arguments[2]) && this.GetLambda(mc.Arguments[2]).Parameters.Count == 2) { 2245else if (mc.Arguments.Count == 4 && 2246this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1 && 2247this.IsLambda(mc.Arguments[2]) && this.GetLambda(mc.Arguments[2]).Parameters.Count == 1 && 2248this.IsLambda(mc.Arguments[3]) && this.GetLambda(mc.Arguments[3]).Parameters.Count == 2) { 2254if (mc.Arguments.Count == 2 && 2255this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2261if (mc.Arguments.Count == 2 && 2262this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2268if (mc.Arguments.Count == 2 && 2269this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2275if (mc.Arguments.Count == 2 && 2276this.IsLambda(mc.Arguments[1]) && this.GetLambda(mc.Arguments[1]).Parameters.Count == 1) { 2282if (mc.Arguments.Count == 2) { 2288if (mc.Arguments.Count == 2) { 2294if (mc.Arguments.Count == 2) { 2302if (mc.Arguments.Count == 1) { 2329if (mc.Arguments.Count == 2) { 2332else if (mc.Arguments.Count == 1) { 2338if (mc.Arguments.Count == 3) { 2341else if (mc.Arguments.Count == 2) { 2349else if (mc.Arguments.Count == 1) { 2355if (mc.Arguments.Count == 2) { 2358else if (mc.Arguments.Count == 1) { 2445System.Diagnostics.Debug.Assert(resultSelector.Parameters.Count == 1); 2504if (array != null && array.Expressions.Count == 1) { 2683SqlExpression[] exprs = new SqlExpression[arr.Expressions.Count]; 2691if (null != list.NewExpression.Constructor && 0 != list.NewExpression.Arguments.Count) { 2696SqlExpression[] exprs = new SqlExpression[list.Initializers.Count]; 2698if (1 != list.Initializers[i].Arguments.Count) {
SqlClient\Query\SqlFormatter.cs (1)
559int pc = spc.Function.Parameters.Count;
SqlClient\Query\SqlParameterizer.cs (1)
200for (int i = 0, n = spc.Function.Parameters.Count; i < n; i++) {
SqlClient\Query\Translator.cs (1)
120SqlExpression[] exprs = new SqlExpression[member.Association.ThisKey.Count];
SqlClient\SqlProvider.cs (4)
1750if (parentArgs == null && !(this.parameters == null || this.parameters.Count == 0)) { 1763for (int i = 0, n = this.parameters.Count; i < n; i++) { 1825for (int i = 0, n = this.parameters.Count; i < n; i++) { 1843if (this.parameters == null || parameterIndex < 0 || parameterIndex > this.parameters.Count) {
System.Data.Services (37)
parent\Client\System\Data\Services\Client\ALinq\ALinqExpressionVisitor.cs (3)
347for (int i = 0, n = original.Count; i < n; i++) 430for (int i = 0, n = original.Count; i < n; i++) 465for (int i = 0, n = original.Count; i < n; i++)
System\Data\Services\ExpandSegment.cs (2)
208if (lambda.Parameters.Count != 1) 211Strings.ExpandSegment_FilterBodyShouldTakeOneParameter(lambda.Parameters.Count), "filter");
System\Data\Services\Internal\PropertyAccessVisitor.cs (1)
72m.Arguments.Count == 2,
System\Data\Services\KeyInstance.cs (3)
140Debug.Assert(type.KeyProperties.Count == this.ValueCount, "type.KeyProperties.Count == this.ValueCount -- will change with containment"); 143for (int i = 0; i < type.KeyProperties.Count; i++) 165for (int i = 0; i < type.KeyProperties.Count; i++)
System\Data\Services\Providers\BasicExpandProvider.cs (4)
1507MemberBinding[] skipTokenPropertyBindings = new MemberBinding[this.OrderingInfo.OrderingExpressions.Count + 2]; 1510for (int i = 0; i < this.OrderingInfo.OrderingExpressions.Count; i++) 1799Type[] skipTokenTypes = new Type[this.OrderingInfo.OrderingExpressions.Count + 1]; 1804for (int i = 0; i < this.OrderingInfo.OrderingExpressions.Count; i++)
System\Data\Services\Providers\ObjectContextServiceProvider.cs (4)
268if (useBasicExpandProvider || rootNode.OrderingInfo.OrderingExpressions.Count > 0 || 1500string[] result = new string[properties.Count]; 1501for (int i = 0; i < properties.Count; i++) 1768for (int i = 0; i < associationSet.AssociationSetEnds.Count; i++)
System\Data\Services\Providers\ReflectionServiceProvider.cs (2)
659if (parentResourceType.KeyProperties.Count != 0) 763(parentResourceType.KeyProperties == null || parentResourceType.KeyProperties.Count == 0))
System\Data\Services\Providers\ResourceType.cs (3)
336(this.ResourceTypeKind != ResourceTypeKind.EntityType && this.keyProperties.Count == 0) || 337(this.ResourceTypeKind == ResourceTypeKind.EntityType && this.keyProperties.Count > 0), 869Debug.Assert(key.Count == 1, "Key Properties count must be zero");
System\Data\Services\RequestQueryProcessor.cs (6)
898if (this.topLevelOrderingInfo.OrderingExpressions.Count != k.PositionalValues.Count) 900throw DataServiceException.CreateBadRequestError(Strings.DataService_SDP_SkipTokenNotMatchingOrdering(k.PositionalValues.Count, skipToken, this.topLevelOrderingInfo.OrderingExpressions.Count)); 956if (this.topLevelOrderingInfo.OrderingExpressions.Count > 0) 1096this.description.SkipTokenExpressionCount = this.topLevelOrderingInfo.OrderingExpressions.Count; 1213Type[] skipTokenTypes = new Type[this.topLevelOrderingInfo.OrderingExpressions.Count + 1]; 1239MemberBinding[] skipTokenBindings = new MemberBinding[this.topLevelOrderingInfo.OrderingExpressions.Count + 2];
System\Data\Services\RequestUriProcessor.cs (6)
955if (resourceType.KeyProperties.Count != key.ValueCount) 1046Debug.Assert(input.Parameters.Count == 1, "Assuming a single parameter for input lambda expression in this function."); 1066object[] operationParameters = new object[operation.Parameters.Count]; 1067for (int i = 0; i < operation.Parameters.Count; i++) 1219Debug.Assert(resourceType.KeyProperties.Count == key.ValueCount, "resourceType.KeyProperties.Count == key.ValueCount"); 1221for (int i = 0; i < resourceType.KeyProperties.Count; i++)
System\Data\Services\Serializers\SyndicationSerializer.cs (3)
415DictionaryContent valueProperties = new DictionaryContent(expectedType.Properties.Count); 522DictionaryContent content = new DictionaryContent(actualResourceType.Properties.Count); 772navProperties = new List<ResourcePropertyInfo>(resourceType.Properties.Count);
System.Data.Services.Client (40)
System\Data\Services\Client\ALinq\ALinqExpressionVisitor.cs (3)
347for (int i = 0, n = original.Count; i < n; i++) 430for (int i = 0, n = original.Count; i < n; i++) 465for (int i = 0, n = original.Count; i < n; i++)
System\Data\Services\Client\ALinq\ExpressionNormalizer.cs (7)
252if (visited.Arguments.Count == 2) 307if (visited.Arguments.Count == 1) 335if (visited.Method.IsStatic && visited.Method.Name == "Equals" && visited.Arguments.Count > 1) 344if (!visited.Method.IsStatic && visited.Method.Name == "Equals" && visited.Arguments.Count > 0) 362if (!visited.Method.IsStatic && visited.Method.Name == "CompareTo" && visited.Arguments.Count == 1 && visited.Method.ReturnType == typeof(int)) 371if (visited.Method.IsStatic && visited.Method.Name == "Compare" && visited.Arguments.Count > 1 && visited.Method.ReturnType == typeof(int)) 431if (2 <= callExpression.Arguments.Count &&
System\Data\Services\Client\ALinq\ExpressionWriter.cs (4)
212Debug.Assert(m.Arguments.Count == 1, "m.Arguments.Count == 1"); 224if (m.Arguments.Count > 0) 231for (int ii = 0; ii < m.Arguments.Count; ii++) 234if (ii < m.Arguments.Count - 1)
System\Data\Services\Client\ALinq\ResourceBinder.cs (12)
652if (mce.Arguments.Count != 2 && mce.Arguments.Count != 3) 687if (mce.Arguments.Count == 3) 784if (mce.Arguments.Count != 1) 1376if (lambda == null || lambda.Parameters.Count != 1) 1633if (selector.Parameters.Count != 1) 1716if (ne.Arguments.Count < 2) 1730if (ne.Members.Count != constructorParams.Length) 1743MemberInfo[] memberProperties = new MemberInfo[ne.Members.Count]; 1746for (int i = 0; i < ne.Arguments.Count; i++) 1880return MatchResource(source, out resource) && (mie != null) && (mie.NewExpression.Arguments.Count == 0); 2185if (le != null && le.Parameters.Count == parameterCount)
System\Data\Services\Client\ClientType.cs (1)
253else if (this.KeyCount != dska.KeyNames.Count)
System\Data\Services\Client\ProjectionPathBuilder.cs (1)
140Debug.Assert(lambda.Parameters.Count == 1, "lambda.Parameters.Count == 1");
System\Data\Services\Client\ProjectionPlanCompiler.cs (12)
79Debug.Assert(projection.Parameters.Count == 1, "projection.Parameters.Count == 1"); 261if (this.pathBuilder.CurrentIsEntity && init.Bindings.Count > 0) 347if (!this.topLevelProjectionFound || lambda.Parameters.Count == 1 && ClientType.CheckElementTypeIsEntity(lambda.Parameters[0].Type)) 521Debug.Assert(init.Bindings.Count > 0, "init.Bindings.Count > 0 -- otherwise this is just empty construction"); 584for (int i = 0; i < init.Bindings.Count; i++) 850if (result.Arguments.Count == 1 && result.Constructor == nex.Type.GetConstructor(new[] { enumerable }) && 867else if (result.Arguments.Count == 2 && 885else if (result.Arguments.Count == 5 && 907else if (result.Arguments.Count == 6 && 954Debug.Assert(call.Arguments.Count == 2, "call.Arguments.Count == 2 -- otherwise this isn't the expected Select() call on IQueryable"); 1017Debug.Assert(call.Arguments.Count == 1, "call.Arguments.Count == 1 -- otherwise this isn't the expected ToList() call on IEnumerable"); 1048Debug.Assert(call.Arguments.Count == 2, "call.Arguments.Count == 2 -- otherwise this isn't the argument we expected");
System.Data.Services.Design (3)
System\Data\EntityModel\Emitters\AssociationTypeEmitter.cs (1)
29Debug.Assert((base.Item as AssociationType).AssociationEndMembers.Count == 2, "must have exactly two ends");
System\Data\EntityModel\Emitters\EntityTypeEmitter.cs (1)
57if (Item.KeyMembers.Count > 0 && typeDecls.Count == 1)
System\Data\EntityModel\Emitters\StructuredTypeEmitter.cs (1)
140List<EdmProperty> parameters = new List<EdmProperty>(properties.Count);
System.IdentityModel (38)
System\IdentityModel\Policy\UnconditionalPolicy.cs (3)
95for (int i = 0; i < issuances.Count; ++i) 138for (int i = 0; i < this.issuances.Count; ++i) 217for (int i = 0; i < this.issuances.Count; ++i)
System\IdentityModel\RsaEncryptionCookieTransform.cs (1)
155if (0 == decryptionKeys.Count)
System\IdentityModel\RsaSignatureCookieTransform.cs (1)
151if (0 == verificationKeys.Count)
System\IdentityModel\SecurityUtils.cs (13)
107for (int i = 0; i < wrappingToken.SecurityKeys.Count; ++i) 507for (int i = 0; i < unwrappingToken.SecurityKeys.Count; ++i) 620for (int i = 0; i < token.SecurityKeys.Count; ++i) 728for (int i = 0; i < claimSets.Count; ++i) 738List<ClaimSet> ret = new List<ClaimSet>(claimSets.Count); 739for (int i = 0; i < claimSets.Count; ++i) 761for (int i = 0; i < claimSets.Count; ++i) 770if (authorizationPolicies != null && authorizationPolicies.Count > 0) 773for (int i = 0; i < authorizationPolicies.Count; ++i) 784List<IAuthorizationPolicy> ret = new List<IAuthorizationPolicy>(authorizationPolicies.Count); 785for (int i = 0; i < authorizationPolicies.Count; ++i) 805if (authorizationPolicies != null && authorizationPolicies.Count > 0) 807for (int i = 0; i < authorizationPolicies.Count; ++i)
System\IdentityModel\Selectors\SamlSecurityTokenAuthenticator.cs (4)
110|| (this.audienceUriMode == AudienceUriMode.BearerKeyOnly) && (samlToken.SecurityKeys.Count < 1)) 174if (authContext.ClaimSets.Count > 0) 212if (authorizationPolicies != null && authorizationPolicies.Count != 0) 214for (int j = 0; j < authorizationPolicies.Count; ++j)
System\IdentityModel\Selectors\SecurityTokenResolver.cs (2)
123for (int i = 0; i < this.tokens.Count; ++i) 199for (int i = 0; i < this.tokens.Count; ++i)
System\IdentityModel\Tokens\Saml2SecurityTokenHandler.cs (1)
1651if (samlToken.SecurityKeys.Count != 0)
System\IdentityModel\Tokens\SamlAttributeStatement.cs (1)
167for (int j = 0; j < attributeClaims.Count; ++j)
System\IdentityModel\Tokens\SamlAuthenticationClaimResource.cs (5)
125for (int i = 0; i < this.authorityBindings.Count; ++i) 168(this.AuthorityBindings.Count != rhs.AuthorityBindings.Count) || 174for (i = 0; i < this.AuthorityBindings.Count; ++i) 177for (int j = 0; j < rhs.AuthorityBindings.Count; ++j)
System\IdentityModel\Tokens\SamlSecurityTokenHandler.cs (1)
790if (samlToken.SecurityKeys.Count != 0)
System\IdentityModel\Tokens\SamlSecurityTokenRequirement.cs (1)
312return (null == token.SecurityKeys || 0 == token.SecurityKeys.Count);
System\IdentityModel\Tokens\SamlSubjectStatement.cs (1)
78for (int i = 0; i < subjectClaims.Count; ++i)
System\IdentityModel\Tokens\SecurityToken.cs (1)
41if (this.SecurityKeys.Count != 0 && MatchesKeyIdentifierClause(keyIdentifierClause))
System\IdentityModel\Tokens\SessionSecurityTokenHandler.cs (2)
177for (int i = 0; i < _transforms.Count; i++) 184for (int i = _transforms.Count; i > 0; i--)
System\IdentityModel\Tokens\X509CertificateStoreTokenResolver.cs (1)
113if (token.SecurityKeys.Count > 0)
System.Runtime.Caching (6)
System\Caching\HostFileChangeMonitor.cs (3)
32if (_filePaths.Count == 1) { 45Hashtable fcnState = new Hashtable(_filePaths.Count); 101if (_filePaths.Count > 1) {
System\Caching\MemoryCacheEntryChangeMonitor.cs (3)
30_dependencies = new List<MemoryCacheEntry>(_keys.Count); 31if (_keys.Count == 1) { 116Dbg.Assert(keys != null && keys.Count > 0, "keys != null && keys.Count > 0");
System.ServiceModel (75)
System\ServiceModel\Administration\EndpointInstanceProvider.cs (1)
97string[] headers = new string[endpoint.Headers.Count];
System\ServiceModel\Administration\ServiceInfo.cs (1)
47if (this.Service.BaseAddresses.Count > 0)
System\ServiceModel\Channels\AddressHeaderCollection.cs (3)
62return Count; 86for (int i = 0; i < Count; i++) 107for (int i = 0; i < Count; i++)
System\ServiceModel\Channels\CorrelationMessageProperty.cs (2)
169if (this.AdditionalKeys.Count == 0) 190if (this.TransientCorrelations.Count == 0)
System\ServiceModel\Channels\PeerHelpers.cs (1)
555&& address.IPAddresses.Count > 0
System\ServiceModel\Channels\PeerIPHelper.cs (3)
78if (addresses.Count != this.localAddresses.Length) 123IPAddress[] cloneArray = new IPAddress[sourceCollection.Count]; 124for (int i = 0; i < sourceCollection.Count; i++)
System\ServiceModel\Channels\PeerMaintainer.cs (1)
380if (addresses.Count > 0)
System\ServiceModel\Channels\PeerNeighborManager.cs (2)
1421Fx.Assert(remoteAddress != null && remoteAddress.IPAddresses.Count > 0, "Non-empty IPAddress collection expected"); 1441while (this.currentIndex < this.remoteAddress.IPAddresses.Count)
System\ServiceModel\Channels\PeerNodeImplementation.cs (2)
1026if (nodeAddress.IPAddresses.Count > 0) 1059if (nodeAddress.IPAddresses.Count > 0)
System\ServiceModel\Channels\PeerSecurityHelpers.cs (1)
792if (context != null && context.AuthorizationContext != null && context.AuthorizationContext.ClaimSets != null && context.AuthorizationContext.ClaimSets.Count > 0)
System\ServiceModel\Channels\PeerSecurityManager.cs (1)
553for (int i = 0; i < context.AuthorizationContext.ClaimSets.Count; ++i)
System\ServiceModel\Channels\PeerUnsafeNativeMethods.cs (1)
72if (socket == null || addresses.Count <= 1)
System\ServiceModel\Channels\SecurityChannelListener.cs (2)
450for (int i = 0; i < this.cacheManagers.Count; ++i) 465for (int i = 0; i < this.cacheManagers.Count; ++i)
System\ServiceModel\Channels\TransportOutputChannel.cs (1)
54this.anyHeadersToAdd = to.Headers.Count > 0;
System\ServiceModel\Configuration\AddressHeaderCollectionElement.cs (1)
80bool dataToWrite = this.Headers.Count != 0;
System\ServiceModel\Diagnostics\MessageTraceRecord.cs (1)
59for (int i = 0; i < authContext.ClaimSets.Count; ++i)
System\ServiceModel\Diagnostics\SecurityTraceRecordHelper.cs (1)
1107for (int i = 0; i < this.authContext.ClaimSets.Count; ++i)
System\ServiceModel\Dispatcher\ActionMessageFilterTable.cs (4)
115if (filter.Actions.Count == 0) 121for (int i = 0; i < filter.Actions.Count; ++i) 430if (filter.Actions.Count == 0) 437for (int i = 0; i < filter.Actions.Count; ++i)
System\ServiceModel\Dispatcher\EndpointAddressMessageFilter.cs (2)
195if (this.address.Headers.Count > 0) 219for (int i = 0; i < this.address.Headers.Count; ++i)
System\ServiceModel\Dispatcher\EndpointAddressMessageFilterTable.cs (2)
185for (int i = 0; i < address.Headers.Count; ++i) 765for (int i = 0; i < address.Headers.Count; ++i)
System\ServiceModel\Dispatcher\SecurityImpersonationBehavior.cs (1)
475for (int i = 0; i < authContext.ClaimSets.Count; i++)
System\ServiceModel\EndpointAddress.cs (2)
1133if (this.headers != null && this.headers.Count > 0) 1290for (int i = 0; i < address.Headers.Count; i++)
System\ServiceModel\PeerResolvers\PeerDefaultCustomResolverClient.cs (1)
110if (nodeAddress.IPAddresses.Count == 0)
System\ServiceModel\Security\DerivedKeyCachingSecurityTokenSerializer.cs (1)
272if (token.SecurityKeys.Count != 1)
System\ServiceModel\Security\IdentityModelServiceAuthorizationManager.cs (1)
454if (authContext.ClaimSets.Count == 1)
System\ServiceModel\Security\IdentityVerifier.cs (2)
132for (int i = 0; i < authorizationContext.ClaimSets.Count; ++i) 283for (int i = 0; i < authContext.ClaimSets.Count; ++i)
System\ServiceModel\Security\IssuanceTokenProviderBase.cs (2)
293for (int i = 0; i < this.targetAddress.Headers.Count; ++i) 660if (issuedKeys != null && issuedKeys.Count == 1)
System\ServiceModel\Security\IssuedTokensHeader.cs (2)
172if (this.tokenIssuances.Count == 1) 222for (int k = 0; k < issuedTokensHeader.TokenIssuances.Count; ++k)
System\ServiceModel\Security\ReceiveSecurityHeader.cs (1)
555if (outOfBandResolvers.Count == 0)
System\ServiceModel\Security\SctClaimsHandler.cs (4)
84( sct.AuthorizationPolicies.Count > 0 ) && 97( sct.AuthorizationPolicies.Count > 0 ) ) 132for ( int i = 0; i < policies.Count; ++i ) 152for ( int i = 0; i < authContext.ClaimSets.Count; ++i )
System\ServiceModel\Security\SecurityAlgorithmSuite.cs (2)
295if (keys == null || keys.Count == 0) 300for (int i = 0; i < keys.Count; i++)
System\ServiceModel\Security\SecurityMessageProperty.cs (2)
228if (spec != null && spec.SecurityTokenPolicies != null && spec.SecurityTokenPolicies.Count > 0) 230for (int i = 0; i < spec.SecurityTokenPolicies.Count; ++i)
System\ServiceModel\Security\SecurityProtocol.cs (1)
661for (int i = 0; i < primaryResolvers.Count; ++i)
System\ServiceModel\Security\SecuritySessionSecurityTokenAuthenticator.cs (2)
621(security.TransportToken.SecurityTokenPolicies.Count > 0)) 634for (int i = 0; i < currentTokenPolicies.Count; ++i)
System\ServiceModel\Security\SecuritySessionSecurityTokenProvider.cs (1)
801if (issuedKeys != null && issuedKeys.Count == 1)
System\ServiceModel\Security\SecurityUtils.cs (6)
559for (int i = 0; i < token.SecurityKeys.Count; ++i) 637for (int i = 0; i < unwrappingToken.SecurityKeys.Count; ++i) 658for (int i = 0; i < wrappingToken.SecurityKeys.Count; ++i) 772for (int i = 0; i < token.SecurityKeys.Count; ++i) 791for (int i = 0; i < authContext.ClaimSets.Count; ++i) 1002for (int i = 0; i < authContext.ClaimSets.Count; ++i)
System\ServiceModel\Security\Tokens\SecurityContextCookieSerializer.cs (2)
194if (authContext != null && authContext.ClaimSets.Count != 0) 202for (int i = 0; i < authContext.ClaimSets.Count; i++)
System\ServiceModel\Security\Tokens\SecurityContextSecurityTokenHelper.cs (4)
25for (int i = 0; i < sct.AuthorizationPolicies.Count; ++i) 36for (int i = 0; i < sct.AuthorizationPolicies.Count; i++) 52if (sct.AuthorizationPolicies != null && sct.AuthorizationPolicies.Count > 0) 55for (int i = 0; i < sct.AuthorizationPolicies.Count; ++i)
System\ServiceModel\Security\WSSecureConversation.cs (1)
390for (int i = 0; i < aggregateTokenResolve.TokenResolvers.Count; ++i)
System\ServiceModel\Security\WSSecurityOneDotZeroReceiveSecurityHeader.cs (1)
590SecurityKey securityKey = (keys != null && keys.Count > 0) ? keys[0] : null;
System\ServiceModel\Security\WSTrustServiceHost.cs (1)
93if (this.BaseAddresses == null || this.BaseAddresses.Count == 0)
System\ServiceModel\ServiceAuthorizationManager.cs (1)
69if (externalPolicies == null || externalPolicies.Count <= 0)
System\UriTemplate.cs (1)
637int lastPathParameter = ((this.variables == null) ? -1 : this.variables.PathSegmentVariableNames.Count - 1);
System.ServiceModel.Activities (2)
System\ServiceModel\Activities\Dispatcher\BufferedReceiveManager.cs (1)
111for (int i = 0; i < bookmarks.Count; ++i)
System\ServiceModel\Activities\WorkflowService.cs (1)
619if (validationResults.Errors != null && validationResults.Errors.Count > 0)
System.ServiceModel.Discovery (2)
System\ServiceModel\Discovery\DefaultDiscoveryService.cs (2)
54for (int i = 0; i < this.publishedEndpoints.Count; i++) 79for (int i = 0; i < this.publishedEndpoints.Count; i++)
System.ServiceModel.Internals (2)
System\Runtime\ExceptionTrace.cs (2)
140if (innerExceptions.Count == 0) 167Fx.Assert(innerExceptions.Count > 0, "InnerException.Count is known to be > 0 here.");
System.ServiceModel.Web (2)
System\ServiceModel\Description\WebHttpBehavior.cs (1)
347if (address.Headers.Count > 0)
System\ServiceModel\Web\WebServiceHost.cs (1)
57if (host.BaseAddresses.Count > 0)
System.Web.DynamicData (14)
DynamicData\ControlFilterExpression.cs (2)
123Debug.Assert(names.Count == columns.Count); 125for (int i = 0; i < names.Count; i++) {
DynamicData\DynamicControlParameter.cs (2)
135Debug.Assert(column.ForeignKeyNames.Count == parentTable.PrimaryKeyColumns.Count);
DynamicData\FilterUserControlBase.cs (1)
353for (int i = 0; i < fkColumn.ForeignKeyNames.Count; i++) {
DynamicData\MetaChildrenColumn.cs (2)
112Debug.Assert(fkColumn.ForeignKeyNames.Count == pkValues.Count); 113for (int i = 0; i < fkColumn.ForeignKeyNames.Count; i++) {
DynamicData\MetaForeignKeyColumn.cs (2)
84Debug.Assert(fkValues.Length == ForeignKeyNames.Count); 95object[] values = new object[ForeignKeyNames.Count];
DynamicData\MetaTable.cs (1)
152return PrimaryKeyColumns.Count > 0;
DynamicData\ModelProviders\DLinqAssociationProvider.cs (1)
32int count = column.Member.Association.ThisKey.Count;
DynamicData\Util\RouteParametersHelper.cs (3)
34Debug.Assert(fkColumn.ForeignKeyNames.Count == fkColumn.ParentTable.PrimaryKeyColumns.Count); 36for (int i = 0; i < fkColumn.ForeignKeyNames.Count; i++) {
System.Web.Entity (4)
System\Data\WebControls\EntityDataSourceUtil.cs (1)
758Debug.Assert(associationSet.AssociationSetEnds.Count == 2, "non binary association?");
System\Data\WebControls\EntityDataSourceWrapperCollection.cs (2)
82List<PropertyDescriptor> visiblePropertyDescriptors = new List<PropertyDescriptor>(columns.Count); 83List<EntityDataSourceWrapperPropertyDescriptor> propertyDescriptors = new List<EntityDataSourceWrapperPropertyDescriptor>(columns.Count);
System\Data\WebControls\OrderByBuilder.cs (1)
237keyMemberNames = new List<string>(entityType.KeyMembers.Count);
System.Workflow.Activities (60)
Common\ValidationHelpers.cs (1)
172for (int i = 0; i < requestParent.EnabledActivities.Count; i++)
Conditional.cs (3)
81for (int i = 0; i < this.EnabledActivities.Count; ++i) 102for (int i = 0; i < this.EnabledActivities.Count; ++i) 148if (ifElse.EnabledActivities.Count < 1)
ConditionalBranch.cs (2)
75bool isLastBranch = (ifElse != null && ifElse.EnabledActivities.Count > 1 && (ifElse.EnabledActivities[ifElse.EnabledActivities.Count - 1] == ifElseBranch));
ConstrainedGroup.cs (2)
118for (int i = 0; i < this.EnabledActivities.Count; ++i) 759int len = cag.EnabledActivities.Count;
Designers\ConditionalDesigner.cs (5)
59if ((ContainedDesigners.Count - activitiesToRemove.Count) < 1) 67if ((ContainedDesigners.Count - activitiesToMove.Count) < 1) 85if (!Expanded || ContainedDesigners.Count == 0 || this != ActiveView.AssociatedDesigner)
Designers\EventHandlersDesigner.cs (4)
66if (PreviewedDesigner != null || ContainedDesigners.Count > 0) 68else if (ContainedDesigners.Count == 0) 82if (PreviewedDesigner != null || ContainedDesigners.Count > 0) 84else if (ContainedDesigners.Count == 0)
Designers\ListenDesigner.cs (1)
65if (!Expanded || ContainedDesigners.Count == 0 || this != ActiveView.AssociatedDesigner)
Designers\StateDesigner.cs (7)
1598if (e.Activities.Count == 0) 1629if (e.Activities.Count == 0 || (!this.DragDropActive)) 1671Connector[] connectors = new Connector[this.Connectors.Count]; 1958int designerCount = ContainedDesigners.Count; 1972if (ContainedDesigners.Count > designerCount && ContainedDesigners.Count > 0) 1973ContainedDesigners[ContainedDesigners.Count - 1].EnsureVisible();
Designers\StateDesigner.Layouts.cs (1)
1200if (this.StateDesigner.ContainedDesigners.Count == 0 &&
Designers\StateDesignerConnector.cs (1)
192for (int i = 1; i < endSegmentEditPoints.Count - 1; i++)
Designers\TaskDesigner.cs (2)
28if (compositeActivity != null && compositeActivity.EnabledActivities.Count > 0) 31if (activitiesToInsert.Count > 1)
Designers\WhileDesigner.cs (1)
97if (this == ActiveView.AssociatedDesigner && ContainedDesigners.Count > 0)
EventDriven.cs (2)
47if (enabledActivities.Count == 0) 75Activity firstActivity = (eventDriven.EnabledActivities.Count > 0) ? eventDriven.EnabledActivities[0] : null;
EventHandlers.cs (6)
99for (int i = 0; i < this.EnabledActivities.Count; ++i) 119for (int i = 0; i < this.EnabledActivities.Count; ++i) 259for (int i = 0; i < eventHandlers.EnabledActivities.Count; ++i) 300for (int i = 0; i < handlers.EnabledActivities.Count; ++i) 328for (int i = 0; i < handlers.EnabledActivities.Count; ++i) 449for (int i = 0; i < this.EnabledActivities.Count; ++i)
Listen.cs (4)
58for (int i = 0; i < this.EnabledActivities.Count; ++i) 81for (int i = 0; i < this.EnabledActivities.Count; ++i) 272for (int i = 0; i < parentActivity.EnabledActivities.Count; ++i) 300if (listen.EnabledActivities.Count < 2)
Parallel.cs (6)
56for (int i = 0; i < this.EnabledActivities.Count; ++i) 63return (this.EnabledActivities.Count == 0) ? ActivityExecutionStatus.Closed : ActivityExecutionStatus.Executing; 72for (int i = 0; i < this.EnabledActivities.Count; ++i) 125for (int i = 0; i < this.EnabledActivities.Count; ++i) 160for (int i = 0; i < parallel.EnabledActivities.Count; ++i) 205if (parallel.EnabledActivities.Count < 2)
Sequence.cs (2)
52if (this.EnabledActivities.Count == 0) 70for (int i = (this.EnabledActivities.Count - 1); i >= 0; i--)
State.cs (1)
91for (int i = 0; i < this.EnabledActivities.Count; ++i)
StateMachineHelpers.cs (1)
243Debug.Assert(eventDriven.EnabledActivities.Count > 0);
StateValidator.cs (2)
297if (completedState.EnabledActivities.Count > 0) 339if (eventDriven.EnabledActivities.Count > 0)
Task.cs (2)
70if (this.EnabledActivities.Count > 0) 1245if ((replicator.EnabledActivities.Count != 1))
While.cs (4)
69if (this.EnabledActivities.Count > 0) 96if (this.EnabledActivities.Count == 0) 121if (this.EnabledActivities.Count > 0) 170if (whileActivity.EnabledActivities.Count != 1)
System.Workflow.ComponentModel (134)
AuthoringOM\ActivityExecutionContextCollection.cs (1)
84for (int i = 0; i < compositeActivity.EnabledActivities.Count; ++i)
AuthoringOM\Behaviors\CancellationHandler.cs (1)
73if (cancellationHandlerActivity.EnabledActivities.Count == 0)
AuthoringOM\Behaviors\Compensate.cs (1)
133for (int index = contextManager.CompletedExecutionContexts.Count - 1; index >= 0; index--)
AuthoringOM\Behaviors\Compensation.cs (1)
78if (compensation.EnabledActivities.Count == 0)
AuthoringOM\Behaviors\ExceptionHandler.cs (1)
199if (exceptionHandler.EnabledActivities.Count == 0)
AuthoringOM\Behaviors\ExceptionHandlers.cs (1)
81for (int i = 0; i < this.EnabledActivities.Count; ++i)
AuthoringOM\Behaviors\ExceptionHandlersDesigner.cs (4)
72if (PreviewedDesigner != null || ContainedDesigners.Count > 0) 74else if (ContainedDesigners.Count == 0) 88if (PreviewedDesigner != null || ContainedDesigners.Count > 0) 90else if (ContainedDesigners.Count == 0)
AuthoringOM\Compiler\TypeSystem\AttributeInfo.cs (1)
136if (argumentIndex >= this.ArgumentValues.Count || argumentIndex < 0)
AuthoringOM\Compiler\Validation\DependencyObjectValidator.cs (1)
118bool checkNotSet = (activity.Parent != null) || ((activity is CompositeActivity) && (((CompositeActivity)activity).EnabledActivities.Count != 0));
AuthoringOM\Design\ActivityDesigner.cs (7)
506DesignerActions.Count > 0) 932for (int j = 0; j < connectionPoints.Count; j++) 984for (int i = 0; i < GetConnections(DesignerEdges.Left).Count; i++) 990for (int i = 0; i < GetConnections(DesignerEdges.Right).Count; i++) 996for (int i = 0; i < GetConnections(DesignerEdges.Top).Count; i++) 1002for (int i = 0; i < GetConnections(DesignerEdges.Bottom).Count; i++) 3115if (designer.SmartTagVerbs.Count > 0)
AuthoringOM\Design\ActivityPreviewDesigner.cs (6)
185else if (ContainedDesigners.Count > 0) 207else if (ContainedDesigners.Count > 0) 209return ContainedDesigners[ContainedDesigners.Count - 1].Activity; 296if (!Expanded || ContainedDesigners.Count > 0 || ShowPreview || ActiveDesigner != this) 346if (activityDesigner != null && activityDesigner.DesignerActions.Count > 0 && designMode) 379if (ContainedDesigners.Count == 0 && HelpTextRectangle.Contains(point))
AuthoringOM\Design\CompositeActivityDesigner.cs (1)
1088for (int i = containedDesigners.Count - 1; i >= 0; i--)
AuthoringOM\Design\CompositeDesignerAccessibleObject.cs (2)
60if (index >= 0 && index < compositeDesigner.ContainedDesigners.Count) 69return compositeDesigner.ContainedDesigners.Count;
AuthoringOM\Design\Connector.cs (5)
76if (connectionIndex < 0 || connectionIndex >= associatedDesigner.GetConnections(designerEdge).Count) 334for (int i = 1; i < segments.Count; i++) 466for (int i = 1; i < endSegmentEditPoints.Count - 1; i++) 603if (connectorContainer != null && index >= 0 && index < connectorContainer.Connectors.Count) 1600for (int j = 0; j < containedDesigners.Count; j++)
AuthoringOM\Design\CustomActivityDesigner.cs (5)
468if (attributeInfo.AttributeType == typeof(BrowsableAttribute) && attributeInfo.ArgumentValues.Count > 0) 472else if (attributeInfo.AttributeType == typeof(CategoryAttribute) && attributeInfo.ArgumentValues.Count > 0) 476else if (attributeInfo.AttributeType == typeof(DescriptionAttribute) && attributeInfo.ArgumentValues.Count > 0) 480else if (attributeInfo.AttributeType == typeof(DesignerSerializationVisibilityAttribute) && attributeInfo.ArgumentValues.Count > 0) 484else if (attributeInfo.AttributeType == typeof(EditorAttribute) && attributeInfo.ArgumentValues.Count > 1)
AuthoringOM\Design\DesignerHelpers.cs (1)
1522for (int i = 0; i < designerActions.Count; i++)
AuthoringOM\Design\DesignerWidgets.cs (1)
3570if (previewDesigner.ContainedDesigners.Count > 0)
AuthoringOM\Design\Dialogs\ActivityBindForm.cs (1)
752if (argumentValues.Count > 0)
AuthoringOM\Design\FreeFormDesigner.cs (16)
59int connectorsCount = designer.Connectors.Count; 67int containedDesignersCount = designer.ContainedDesigners.Count; 78int count = base.GetChildCount() + designer.Connectors.Count; 313if (this.retainContainedDesignerLocations && containedDesigners.Count == containedDesignerLocations.Count) 315for (int i = 0; i < containedDesigners.Count; i++) 604if (connectorContainer != null && connectorContainer.Connectors.Count > 0) 678if (freeFormDesigner != null && freeFormDesigner.Connectors.Count > 0) 887if (movedLocations.Length == e.Activities.Count) 889for (int i = 0; i < e.Activities.Count; i++) 1013if (connectorIndex < connectors.Count) 1019if (connectors.Count > 0) 1164if (containedDesigners.Count > 1 && containedDesigners[(zorder == ZOrder.Background) ? 0 : containedDesigners.Count - 1] != childDesigner) 1195if (containedDesigners.Count > 1 && containedDesigners[(zorder == ZOrder.Background) ? 0 : containedDesigners.Count - 1] != childDesigner) 1197int moveIndex = (zorder == ZOrder.Background) ? 0 : containedDesigners.Count;
AuthoringOM\Design\Glyphs\ConfigErrorGlyph.cs (1)
112if (designer.DesignerActions.Count > 0)
AuthoringOM\Design\MessageFilters\GlyphManager.cs (2)
381if (compositeDesigner != null && compositeDesigner.ContainedDesigners.Count > 0) 396if (compositeDesigner != null && compositeDesigner.ContainedDesigners.Count > 0)
AuthoringOM\Design\ParallelActivityDesigner.cs (32)
64if (ContainedDesigners.Count > 0) 81object firstComponent = (ContainedDesigners.Count > 0) ? ContainedDesigners[0].Activity : null; 139if (direction == DesignerNavigationDirection.Left && index >= 0 && index < containedDesigners.Count) 140nextObject = ((ActivityDesigner)containedDesigners[(index > 0) ? index - 1 : containedDesigners.Count - 1]).Activity; 141else if (direction == DesignerNavigationDirection.Right && index <= containedDesigners.Count - 1) 142nextObject = ((ActivityDesigner)containedDesigners[(index < containedDesigners.Count - 1) ? index + 1 : 0]).Activity; 155if ((ContainedDesigners.Count - activitiesToRemove.Count) < 2) 172if ((ContainedDesigners.Count - activitiesToMove.Count) < 2) 199if (ContainedDesigners.Count > 0) 221Point location = (connectionPoints.Count > 0) ? new Point(Location.X, connectionPoints[0].Y) : Location; 258containerSize.Width += (ContainedDesigners.Count > 0) ? compositeDesignerTheme.ConnectorSize.Width : 0; 284Rectangle[] dropTargets = new Rectangle[containedDesigners.Count + 1]; 285if (containedDesigners.Count > 0) 292for (int i = 0; i < containedDesigners.Count - 1; i++) 305ActivityDesigner lastDesigner = containedDesigners[containedDesigners.Count - 1]; 306dropTargets[containedDesigners.Count].Location = new Point(bounds.Right - ((designerTheme != null) ? designerTheme.ConnectorSize.Width : 0), lastDesigner.Location.Y); 307dropTargets[containedDesigners.Count].Size = new Size(((designerTheme != null) ? designerTheme.ConnectorSize.Width : 0), lastDesigner.Size.Height); 345ActivityDesigner lastDesigner = containedDesigners[containedDesigners.Count - 1]; 365parallelLinks[0].X = firstDesignerConnections[firstDesignerConnections.Count - 1].X; 367parallelLinks[1].X = lastDesignerConnections[lastDesignerConnections.Count - 1].X; 381int connectionCount = designerConnections.Count; 416parallelConnectorTop += (containedDesigners.Count > 0) ? compositeDesignerTheme.ConnectorSize.Height * 3 / 4 : 0; 420heightDelta -= (containedDesigners.Count > 0) ? compositeDesignerTheme.ConnectorSize.Height * 3 / 4 : 0; 426if (containedDesigners.Count > 0) 444else if (index == containedDesigners.Count) 446ActivityDesigner lastDesigner = containedDesigners[containedDesigners.Count - 1]; 470int designerCount = ContainedDesigners.Count; 476if (ContainedDesigners.Count > designerCount && ContainedDesigners.Count > 0) 477ContainedDesigners[ContainedDesigners.Count - 1].EnsureVisible();
AuthoringOM\Design\PropertyDescriptors.cs (1)
460if (attributeInfoAttribute != null && attributeInfoAttribute.AttributeInfo.ArgumentValues.Count > 0)
AuthoringOM\Design\SecondaryViewProvider.cs (2)
93for (int i = 1; i < views.Count; i++) 104for (int i = 1; i < views.Count; i++)
AuthoringOM\Design\SequenceDesignerAccessibleObject.cs (2)
62return sequentialActivityDesigner.ContainedDesigners.Count + sequentialActivityDesigner.ContainedDesigners.Count + 1;
AuthoringOM\Design\SequentialActivityDesigner.cs (21)
158if (this.HelpText.Length == 0 || ContainedDesigners.Count > 0 || !Expanded || connectors.Length == 0) 187int connectorCount = (containedDesigners.Count > 0) ? (2 + (containedDesigners.Count - 1)) : 1; 193if (containerConnections != null && containerConnections.Count > 0) 196containerEndConnection = containerConnections[containerConnections.Count - 1]; 199if (containedDesigners.Count > 0) 204if (startDesignerConnections.Count == 0) 217for (int i = 0; i < containedDesigners.Count - 1; i++) 224int designerFromPointCount = designerFromConnections.Count; 232ActivityDesigner endDesigner = containedDesigners[containedDesigners.Count - 1]; 234if (endDesignerConnections.Count == 0) 243connectorBounds[connectorCount - 1].Location = new Point(endDesignerConnections[endDesignerConnections.Count - 1].X - ((designerTheme != null) ? designerTheme.ConnectorSize.Width : 0) / 2, endDesignerConnections[endDesignerConnections.Count - 1].Y); 244connectorBounds[connectorCount - 1].Size = new Size(((designerTheme != null) ? designerTheme.ConnectorSize.Width : 0), containerEndConnection.Y - endDesignerConnections[endDesignerConnections.Count - 1].Y); 310else if (ContainedDesigners.Count == 0 && HelpTextRectangle.Contains(point)) 349if (currentIndex >= 0 && currentIndex < containedDesigners.Count) 446Point location = (connectionPoints.Count > 0) ? connectionPoints[0] : Location; 448if (ContainedDesigners.Count == 1) 451if (connectionPoints.Count > 0) 452heightDelta = Size.Height - (connectionPoints[connectionPoints.Count - 1].Y - connectionPoints[0].Y); 490if (ContainedDesigners.Count == 0)
AuthoringOM\Design\SequentialWorkflowRootDesigner.cs (2)
149if (Header != null && !String.IsNullOrEmpty(Header.Text) && this.Views.Count > 1) 215if (ContainedDesigners.Count == 0)
AuthoringOM\Design\StructuredCompositeActivityDesigner.cs (9)
216return (!String.IsNullOrEmpty(Text) && !TextRectangle.Size.IsEmpty && Views.Count > 1); 227if (Views.Count > 1) 229for (int i = 0; i < Views.Count; i++) 277if (views.Count == 0) 599if (activeDesignerIndex != -1 && activeDesignerIndex < views.Count) 645if (newViews.Count != oldViews.Count) 705if (e.Activities.Count == 0) 746if (e.Activities.Count == 0)
AuthoringOM\Filters\CompensationHandlingFilter.cs (2)
237ActivityExecutionContext[] activeContextsClone = new ActivityExecutionContext[context.ExecutionContextManager.ExecutionContexts.Count]; 379for (int index = contextManager.CompletedExecutionContexts.Count - 1; index >= 0; index--)
AuthoringOM\Sequence.cs (2)
27if (activity.EnabledActivities.Count == 0) 40for (int i = (activity.EnabledActivities.Count - 1); i >= 0; i--)
Shared\ValidationHelpers.cs (1)
171for (int i = 0; i < requestParent.EnabledActivities.Count; i++)
System.Workflow.Runtime (10)
DebugEngine\DebugController.cs (2)
548for (int i = 0; i < types.Count; i++) 557for (int i = 0; i < keys.Count; i++)
WorkflowRuntime.cs (8)
1120if (GetAllServices(typeof(WorkflowCommitWorkBatchService)).Count == 0) 1123if (GetAllServices(typeof(WorkflowSchedulerService)).Count == 0) 1126if (GetAllServices(typeof(WorkflowLoaderService)).Count == 0) 1129if (GetAllServices(typeof(WorkflowCommitWorkBatchService)).Count != 1) 1135if (GetAllServices(typeof(WorkflowSchedulerService)).Count != 1) 1140if (GetAllServices(typeof(WorkflowLoaderService)).Count != 1) 1145if (GetAllServices(typeof(WorkflowPersistenceService)).Count > 1) 1150if (GetAllServices(typeof(WorkflowTimerService)).Count == 0)
System.WorkflowServices (3)
System\ServiceModel\Security\SerializableAuthorizationContext.cs (2)
117if ((authorizationContext != null) && (authorizationContext.ClaimSets.Count != 0)) 125for (int i = 0; i < authorizationContext.ClaimSets.Count; i++)
System\Workflow\Activities\ReceiveActivity.cs (1)
1520if (index >= inputs.Count)
XamlBuildTask (3)
Microsoft\Build\Tasks\Xaml\ClassGenerator.cs (3)
242if (paramInfo.ArrayContents != null && paramInfo.ArrayContents.Count > 0) 244codeInitializationArray = new CodeExpression[paramInfo.ArrayContents.Count]; 245for (int i = 0; i < paramInfo.ArrayContents.Count; i++)