54 references to CodeSnippetExpression
Microsoft.Build.Tasks.Core (53)
WriteCodeFragment.cs (1)
410value = new CodeSnippetExpression(parameter.Value);
XamlTaskFactory\TaskGenerator.cs (52)
445new CodeSnippetExpression(SurroundWithQuotes(property.Name))), 447new CodeSnippetExpression("false")) 451removeExisting.TrueStatements.Add(new CodeAssignStatement(new CodeVariableReferenceExpression(property.Name), new CodeSnippetExpression(property.DefaultValue))); 455removeExisting.TrueStatements.Add(new CodeAssignStatement(new CodeVariableReferenceExpression(property.Name), new CodeSnippetExpression(SurroundWithQuotes(property.DefaultValue)))); 488var isPropertySet = new CodeMethodInvokeExpression(new CodeThisReferenceExpression(), IsPropertySetMethod, new CodeSnippetExpression(SurroundWithQuotes(fallbackParameter.Value))); 489var propertyNotSet = new CodeBinaryOperatorExpression(new CodeMethodInvokeExpression(new CodeThisReferenceExpression(), IsPropertySetMethod, new CodeSnippetExpression(SurroundWithQuotes(fallbackParameter.Key))), CodeBinaryOperatorType.ValueEquality, new CodeSnippetExpression(IsOff)); 600CodeAssignStatement setStatement = new CodeAssignStatement(new CodePropertyReferenceExpression(new CodeVariableReferenceExpression(SwitchToAdd), property), new CodeSnippetExpression(SurroundWithQuotes(value))); 651new CodeSnippetExpression(SurroundWithQuotes(property.Name))) 656isSet.FalseStatements.Add(new CodeMethodReturnStatement(new CodeSnippetExpression(IsOff))); 664isSet.FalseStatements.Add(new CodeMethodReturnStatement(new CodeSnippetExpression("null"))); 673GenerateAssignPropertyToValue(propertyName, ReversibleProperty, new CodeSnippetExpression(property.Reversible)); 685GenerateAssignPropertyToValue(propertyName, RequiredProperty, new CodeSnippetExpression(property.Required)); 694CodeMethodInvokeExpression setParent = new CodeMethodInvokeExpression(new CodePropertyReferenceExpression(new CodeVariableReferenceExpression(SwitchToAdd), ParentProperty), AddLastMethod, new CodeSnippetExpression(SurroundWithQuotes(parentName))); 730propertyName.SetStatements.Add(new CodeMethodInvokeExpression(new CodeThisReferenceExpression(), ReplaceToolSwitchMethod, new CodeSnippetExpression(SwitchToAdd))); 748new CodeSnippetExpression(SurroundWithQuotes(property.Name))); 768parameters = [new CodeSnippetExpression(SurroundWithQuotes(name)), new CodePrimitiveExpression(Int32.Parse(property.Min, CultureInfo.CurrentCulture)), new CodePrimitiveExpression(Int32.Parse(property.Max, CultureInfo.CurrentCulture)), new CodePropertySetValueReferenceExpression()]; 772parameters = [new CodeSnippetExpression(SurroundWithQuotes(name)), new CodePrimitiveExpression(Int32.Parse(property.Min, CultureInfo.CurrentCulture)), new CodeSnippetExpression("Int32.MaxValue"), new CodePropertySetValueReferenceExpression()]; 776parameters = [new CodeSnippetExpression(SurroundWithQuotes(name)), new CodeSnippetExpression("Int32.MinValue"), new CodePrimitiveExpression(Int32.Parse(property.Max, CultureInfo.CurrentCulture)), new CodePropertySetValueReferenceExpression()]; 780parameters = [new CodeSnippetExpression(SurroundWithQuotes(name)), new CodeSnippetExpression("Int32.MinValue"), new CodeSnippetExpression("Int32.MaxValue"), new CodePropertySetValueReferenceExpression()]; 787isValid.TrueStatements.Add(new CodeAssignStatement(new CodePropertyReferenceExpression(new CodeVariableReferenceExpression(SwitchToAdd), IsValidProperty), new CodeSnippetExpression(IsOn))); 788isValid.FalseStatements.Add(new CodeAssignStatement(new CodePropertyReferenceExpression(new CodeVariableReferenceExpression(SwitchToAdd), IsValidProperty), new CodeSnippetExpression(IsOff))); 794new CodeSnippetExpression(SurroundWithQuotes(property.Name))); 814new CodeSnippetExpression(SurroundWithQuotes(property.Name))); 843new CodeSnippetExpression(SurroundWithQuotes(arg.Parameter)), 849new CodeSnippetExpression(SurroundWithQuotes(val.Name)), 850val.SwitchName != String.Empty ? new CodeSnippetExpression(SurroundWithQuotes(val.Prefix + val.SwitchName)) : new CodeSnippetExpression(SurroundWithQuotes("")), 865new CodeSnippetExpression(SurroundWithQuotes(property.Name)), 908new CodeSnippetExpression(SurroundWithQuotes(property.Separator))); 915new CodeSnippetExpression(SurroundWithQuotes(property.Name))); 919GenerateAssignPropertyToValue(propertyName, MultiValues, new CodeSnippetExpression(IsOn)); 926new CodeSnippetExpression(SurroundWithQuotes(property.Name))); 930CodeAssignStatement setToolSwitchName = new CodeAssignStatement(new CodePropertyReferenceExpression(new CodeVariableReferenceExpression(SwitchToAdd), SwitchValueProperty), property.SwitchName != String.Empty ? new CodeSnippetExpression(SurroundWithQuotes(property.Prefix + property.SwitchName)) : new CodeSnippetExpression(SurroundWithQuotes(""))); 1018new CodeSnippetExpression(SurroundWithQuotes(rel.SwitchValue)), 1019new CodeSnippetExpression(SurroundWithQuotes(overrided))))); 1035new CodeSnippetExpression(SurroundWithQuotes(rel.SwitchValue)), 1036new CodeSnippetExpression(SurroundWithQuotes(overrided))))); 1060new CodeSnippetExpression(SurroundWithQuotes(property.Name))); 1088toolNameAccessor.GetStatements.Add(new CodeMethodReturnStatement(new CodeSnippetExpression(SurroundWithQuotes(_taskParser.ToolName)))); 1134var resourceNamespaceString = new CodeSnippetExpression(SurroundWithQuotes(_taskParser.ResourceNamespace)); 1144valueExpressions.Add(new CodeSnippetExpression(SurroundWithQuotes(switchName))); 1187checkRequired.Condition, CodeBinaryOperatorType.BooleanAnd, new CodeBinaryOperatorExpression(new CodeMethodInvokeExpression(new CodeMethodReferenceExpression(new CodeThisReferenceExpression(), IsSwitchValueSetMethod), new CodeSnippetExpression(SurroundWithQuotes(required))), CodeBinaryOperatorType.IdentityEquality, new CodeSnippetExpression("false"))); 1191checkRequired.Condition = new CodeBinaryOperatorExpression(new CodeMethodInvokeExpression(new CodeMethodReferenceExpression(new CodeThisReferenceExpression(), IsSwitchValueSetMethod), new CodeSnippetExpression(SurroundWithQuotes(required))), CodeBinaryOperatorType.IdentityEquality, new CodeSnippetExpression("false")); 1197new CodeSnippetExpression(SurroundWithQuotes(switchRelations.Key))));
System.Runtime.Serialization.Schema (1)
System\Runtime\Serialization\Schema\CodeExporter.cs (1)
1094enumMember.InitExpression = new CodeSnippetExpression(XmlConvert.ToString((ulong)longValue));