144 references to Add
Microsoft.Build.Tasks.Core (46)
CodeTaskFactory.cs (4)
376
prop.GetStatements.
Add
(new CodeMethodReturnStatement(fieldRef));
383
prop.SetStatements.
Add
(fieldAssign);
397
executeMethod.Statements.
Add
(new CodeSnippetStatement(executeCode));
399
executeMethod.Statements.
Add
(new CodeMethodReturnStatement(new CodeFieldReferenceExpression(null, "_Success")));
RoslynCodeTaskFactory\RoslynCodeTaskFactory.cs (4)
237
executeMethod.Statements.
Add
(new CodeSnippetStatement(taskInfo.SourceCode));
238
executeMethod.Statements.
Add
(new CodeMethodReturnStatement(new CodePropertyReferenceExpression(null, successProperty.Name)));
642
property.GetStatements.
Add
(new CodeMethodReturnStatement(fieldReference));
650
property.SetStatements.
Add
(fieldAssign);
system.design\stronglytypedresourcebuilder.cs (6)
469
resMgr.GetStatements.
Add
(new CodeConditionStatement(isResMgrNull, init));
470
resMgr.GetStatements.
Add
(new CodeMethodReturnStatement(field_resMgr));
479
culture.GetStatements.
Add
(new CodeMethodReturnStatement(field_resCulture));
482
culture.SetStatements.
Add
(new CodeAssignStatement(field_resCulture, newCulture));
654
prop.GetStatements.
Add
(returnObj);
658
prop.GetStatements.
Add
(ret);
XamlTaskFactory\TaskGenerator.cs (32)
451
removeExisting.TrueStatements.
Add
(new CodeAssignStatement(new CodeVariableReferenceExpression(property.Name), new CodeSnippetExpression(property.DefaultValue)));
455
removeExisting.TrueStatements.
Add
(new CodeAssignStatement(new CodeVariableReferenceExpression(property.Name), new CodeSnippetExpression(SurroundWithQuotes(property.DefaultValue))));
457
addToActiveSwitchList.Statements.
Add
(removeExisting);
491
removeExisting.TrueStatements.
Add
(new CodeAssignStatement(new CodeVariableReferenceExpression(fallbackParameter.Key), new CodeVariableReferenceExpression(fallbackParameter.Value)));
492
addToActiveSwitchList.Statements.
Add
(removeExisting);
601
propertyName.SetStatements.
Add
(setStatement);
613
propertyName.SetStatements.
Add
(setStatement);
653
isSet.TrueStatements.
Add
(new CodeMethodReturnStatement(new CodePropertyReferenceExpression(new CodeArrayIndexerExpression(new CodeVariableReferenceExpression(DictionaryOfSwitches), new CodeVariableReferenceExpression(SurroundWithQuotes(property.Name))), valueName)));
656
isSet.FalseStatements.
Add
(new CodeMethodReturnStatement(new CodeSnippetExpression(IsOff)));
660
isSet.FalseStatements.
Add
(new CodeMethodReturnStatement(new CodePrimitiveExpression(0)));
664
isSet.FalseStatements.
Add
(new CodeMethodReturnStatement(new CodeSnippetExpression("null")));
666
propertyName.GetStatements.
Add
(isSet);
670
propertyName.SetStatements.
Add
(createNewToolSwitch);
702
propertyName.SetStatements.
Add
(setInclude);
727
propertyName.SetStatements.
Add
(setValue);
749
propertyName.SetStatements.
Add
(setToolName);
787
isValid.TrueStatements.
Add
(new CodeAssignStatement(new CodePropertyReferenceExpression(new CodeVariableReferenceExpression(SwitchToAdd), IsValidProperty), new CodeSnippetExpression(IsOn)));
788
isValid.FalseStatements.
Add
(new CodeAssignStatement(new CodePropertyReferenceExpression(new CodeVariableReferenceExpression(SwitchToAdd), IsValidProperty), new CodeSnippetExpression(IsOff)));
789
propertyName.SetStatements.
Add
(isValid);
795
propertyName.SetStatements.
Add
(setToolName);
815
propertyName.SetStatements.
Add
(setToolName);
860
propertyName.SetStatements.
Add
(createArray);
868
propertyName.SetStatements.
Add
(indexDecl);
903
propertyName.SetStatements.
Add
(conditionalStatement);
909
propertyName.SetStatements.
Add
(setSeparator);
916
propertyName.SetStatements.
Add
(setToolName);
927
propertyName.SetStatements.
Add
(setToolName);
931
propertyName.SetStatements.
Add
(setToolSwitchName);
1061
propertyName.SetStatements.
Add
(setToolName);
1085
toolNameAccessor.GetStatements.
Add
(new CodeCommentStatement(commentContent, false));
1088
toolNameAccessor.GetStatements.
Add
(new CodeMethodReturnStatement(new CodeSnippetExpression(SurroundWithQuotes(_taskParser.ToolName))));
1199
addValidateRelationsMethod.Statements.
Add
(checkRequired);
PresentationBuildTasks (46)
MS\Internal\MarkupCompiler\MarkupCompiler.cs (46)
910
_ccRoot.StyleConnectorFn.Statements.
Add
(css);
935
_ccRoot.StyleConnectorFn.Statements.
Add
(cssBreak);
941
_ccRoot.StyleConnectorFn.Statements.
Add
(cssCase);
1015
_ccRoot.StyleConnectorFn.Statements.
Add
(casES);
1016
_ccRoot.StyleConnectorFn.Statements.
Add
(casEvent);
1017
_ccRoot.StyleConnectorFn.Statements.
Add
(casHandler);
1018
_ccRoot.StyleConnectorFn.Statements.
Add
(new CodeExpressionStatement(cmieAdd));
1022
ccsConnector.TrueStatements.
Add
(casES);
1023
ccsConnector.TrueStatements.
Add
(casEvent);
1024
ccsConnector.TrueStatements.
Add
(casHandler);
1025
ccsConnector.TrueStatements.
Add
(new CodeExpressionStatement(cmieAdd));
1029
_ccRoot.StyleConnectorFn.Statements.
Add
(ccsConnector);
1072
_ccRoot.StyleConnectorFn.Statements.
Add
( csAddCLREvent );
1076
ccsConnector.TrueStatements.
Add
( csAddCLREvent );
1081
_ccRoot.StyleConnectorFn.Statements.
Add
(ccsConnector);
1099
_ccRoot.StyleConnectorFn.Statements.
Add
(cssBreak);
1106
_ccRoot.StyleConnectorFn.Statements.
Add
(css);
1146
_ccRoot.HookupFn.Statements.
Add
(css);
1175
_ccRoot.HookupFn.Statements.
Add
(cssCase);
1204
_ccRoot.HookupFn.Statements.
Add
(casName);
1208
ccsConnector.TrueStatements.
Add
(casName);
1220
_ccRoot.HookupFn.Statements.
Add
(csEvent);
1224
ccsConnector.TrueStatements.
Add
(csEvent);
1233
_ccRoot.HookupFn.Statements.
Add
(new CodeMethodReturnStatement());
1237
ccsConnector.TrueStatements.
Add
(new CodeMethodReturnStatement());
1238
_ccRoot.HookupFn.Statements.
Add
(ccsConnector);
1278
_ccRoot.HookupFn.Statements.
Add
(css);
1286
_ccRoot.HookupFn.Statements.
Add
(casContentLoaded);
2068
cmmEventHandlerHelper.Statements.
Add
(new CodeExpressionStatement(cmieOnEvent));
2591
cmmCD.Statements.
Add
(new CodeMethodReturnStatement(cmieCD));
2620
ccsCL.TrueStatements.
Add
(new CodeMethodReturnStatement());
2623
cmmLC.Statements.
Add
(ccsCL);
2636
cmmLC.Statements.
Add
(casCL);
2693
cmmLC.Statements.
Add
(cvdsresLocator);
2711
cmmLC.Statements.
Add
(cesLC);
2806
cmmCI.Statements.
Add
(new CodeMethodReturnStatement(cmieCI));
2839
cmmGPV.Statements.
Add
(new CodeMethodReturnStatement(cmieGPV));
2872
cmmSPV.Statements.
Add
(new CodeExpressionStatement(cmieSPV));
2931
cmmCD.Statements.
Add
(new CodeMethodReturnStatement(cceCD));
2960
cmmAEH.Statements.
Add
(new CodeExpressionStatement(cmieAEH));
3166
cmmMain.Statements.
Add
(cvds);
3186
_ccRoot.EnsureInitializeComponentFn.Statements.
Add
(csPropSet);
3199
_ccRoot.EnsureInitializeComponentFn.Statements.
Add
(csEvent);
3258
cmmMain.Statements.
Add
(new CodeExpressionStatement(cmieIT));
3272
cmmMain.Statements.
Add
(csRun);
3329
cmmMain.Statements.
Add
(cvdsAppSplash);
System.CodeDom (3)
System\CodeDom\CodeStatementCollection.cs (3)
30
public int Add(CodeExpression value) =>
Add
(new CodeExpressionStatement(value));
41
Add
(value[i]);
55
Add
(value[i]);
System.Runtime.Serialization.Schema (19)
System\Runtime\Serialization\Schema\CodeExporter.cs (19)
1730
readXmlMethod.Statements.
Add
(setNode);
1766
getSchemaMethod.Statements.
Add
(new CodeMethodReturnStatement(NullReference));
1789
getSchemaStaticMethod.Statements.
Add
(
1809
baseConstructor.Statements.
Add
(setObjectData);
1813
baseConstructor.Statements.
Add
(new CodeAssignStatement(new CodePropertyReferenceExpression(ThisReference, PropertyChangedEvent.Name), NullReference));
1870
returnIfNull.TrueStatements.
Add
(new CodeMethodReturnStatement());
1907
loop.Statements.
Add
(getCurrent);
1908
loop.Statements.
Add
(addValue);
1910
getObjectDataMethod.Statements.
Add
(returnIfNull);
1911
getObjectDataMethod.Statements.
Add
(getEnumerator);
1912
getObjectDataMethod.Statements.
Add
(loop);
1942
extensionDataObjectProperty.GetStatements.
Add
(propertyGet);
1947
extensionDataObjectProperty.SetStatements.
Add
(propertySet);
1963
raisePropertyChangedEventMethod.Statements.
Add
(new CodeVariableDeclarationStatement(typeof(PropertyChangedEventHandler), propertyChanged.VariableName, new CodeEventReferenceExpression(ThisReference, PropertyChangedEvent.Name)));
1965
raisePropertyChangedEventMethod.Statements.
Add
(ifStatement);
2002
property.GetStatements.
Add
(propertyGet);
2023
ifStatement.TrueStatements.
Add
(propertySet);
2025
property.SetStatements.
Add
(ifStatement);
2028
property.SetStatements.
Add
(propertySet);
System.Windows.Forms.Design (30)
System\ComponentModel\Design\Serialization\CodeDomComponentSerializationService.CodeDomSerializationStore.ComponentListCodeDomSerializer.cs (1)
43
completeStatements.
Add
(statement);
System\ComponentModel\Design\Serialization\CodeDomSerializer.cs (1)
186
statements.
Add
(varDecl);
System\ComponentModel\Design\Serialization\CodeDomSerializerBase.cs (1)
2818
statements.
Add
(statement);
System\ComponentModel\Design\Serialization\CodeMethodMap.cs (7)
56
ContainerStatements.
Add
(statement);
60
FieldAssignments.
Add
(fieldAssignment);
64
VariableAssignments.
Add
(variableAssignment);
68
LocalVariables.
Add
(statement);
75
BeginStatements.
Add
(statement);
79
EndStatements.
Add
(statement);
83
Statements.
Add
(statement);
System\ComponentModel\Design\Serialization\CollectionCodeDomSerializer.cs (2)
205
resultCollection.
Add
(resultStatement);
646
statements.
Add
(new CodeExpressionStatement(methodInvoke));
System\ComponentModel\Design\Serialization\ComponentCodeDomSerializer.cs (4)
242
statements.
Add
(local);
296
statements.
Add
(assign);
521
statements.
Add
(statement);
548
statements.
Add
(statement);
System\ComponentModel\Design\Serialization\ContainerCodeDomSerializer.cs (2)
63
statements.
Add
(var);
74
statements.
Add
(assign);
System\ComponentModel\Design\Serialization\EventMemberCodeDomSerializer.cs (1)
56
statements.
Add
(attach);
System\ComponentModel\Design\Serialization\PropertyMemberCodeDomSerializer.cs (2)
210
statements.
Add
(cs);
351
statements.
Add
(assign);
System\ComponentModel\Design\Serialization\ResourceCodeDomSerializer.cs (1)
299
statements.
Add
(new CodeVariableDeclarationStatement(typeof(ComponentResourceManager), ResourceManagerName, initExpression));
System\Resources\Tools\StronglyTypedResourceBuilder.cs (6)
621
resourceManagerProperty.GetStatements.
Add
(new CodeConditionStatement(isResourceManagerNull, assignNewResourceManager));
622
resourceManagerProperty.GetStatements.
Add
(new CodeMethodReturnStatement(resourceManagerField));
631
culture.GetStatements.
Add
(new CodeMethodReturnStatement(cultureInfoField));
634
culture.SetStatements.
Add
(new CodeAssignStatement(cultureInfoField, newCulture));
801
property.GetStatements.
Add
(returnObject);
805
property.GetStatements.
Add
(returnStatement);
System\Windows\Forms\Design\ControlCodeDomSerializer.cs (2)
388
statements.
Add
(statement);
448
statements.
Add
(statement);