コード例 #1
0
 public new static bool Validate(System.Collections.Generic.IList <System.Activities.LocationReference> locationReferences, bool validateLocationCount, int offset)
 {
     if (((validateLocationCount == true) &&
          (locationReferences.Count < 4)))
     {
         return(false);
     }
     if ((validateLocationCount == true))
     {
         offset = (locationReferences.Count - 4);
     }
     expectedLocationsCount = 4;
     if (((locationReferences[(offset + 3)].Name != "varCandidate") ||
          (locationReferences[(offset + 3)].Type != typeof(Sample.VariableAndArgument.Person))))
     {
         return(false);
     }
     return(Workflow1_TypedDataContext1.Validate(locationReferences, false, offset));
 }
 public new static bool Validate(System.Collections.Generic.IList <System.Activities.LocationReference> locationReferences, bool validateLocationCount, int offset)
 {
     if (((validateLocationCount == true) &&
          (locationReferences.Count < 1)))
     {
         return(false);
     }
     if ((validateLocationCount == true))
     {
         offset = (locationReferences.Count - 1);
     }
     expectedLocationsCount = 1;
     if (((locationReferences[(offset + 0)].Name != "TempResult") ||
          (locationReferences[(offset + 0)].Type != typeof(int))))
     {
         return(false);
     }
     return(Workflow1_TypedDataContext1.Validate(locationReferences, false, offset));
 }
コード例 #3
0
 public new static bool Validate(System.Collections.Generic.IList <System.Activities.LocationReference> locationReferences, bool validateLocationCount, int offset)
 {
     if (((validateLocationCount == true) &&
          (locationReferences.Count < 3)))
     {
         return(false);
     }
     if ((validateLocationCount == true))
     {
         offset = (locationReferences.Count - 3);
     }
     expectedLocationsCount = 3;
     if (((locationReferences[(offset + 1)].Name != "YesOrNo") ||
          (locationReferences[(offset + 1)].Type != typeof(string))))
     {
         return(false);
     }
     if (((locationReferences[(offset + 2)].Name != "DriveNames") ||
          (locationReferences[(offset + 2)].Type != typeof(string[]))))
     {
         return(false);
     }
     return(Workflow1_TypedDataContext1.Validate(locationReferences, false, offset));
 }
コード例 #4
0
 public bool CanExecuteExpression(string expressionText, bool isReference, System.Collections.Generic.IList <System.Activities.LocationReference> locations, out int expressionId)
 {
     if (((isReference == false) &&
          ((expressionText == "new string[] { \"B Bytes\", \"KB Kilobytes\", \"MB Megabytes\", \"GB Gigabytes\", \"TB Ter" +
            "abytes\", \"PB Petabytes\", \"EB Exabytes\", \"ZB Zettabytes\", \"YB Yottabytes\", \"BB Br" +
            "ontobytes\" }") &&
           (Workflow1_TypedDataContext0_ForReadOnly.Validate(locations, true, 0) == true))))
     {
         expressionId = 0;
         return(true);
     }
     if (((isReference == false) &&
          ((expressionText == "12345678") &&
           (Workflow1_TypedDataContext0_ForReadOnly.Validate(locations, true, 0) == true))))
     {
         expressionId = 1;
         return(true);
     }
     if (((isReference == false) &&
          ((expressionText == "\"Input: \" + argInput.ToString()") &&
           (Workflow1_TypedDataContext1_ForReadOnly.Validate(locations, true, 0) == true))))
     {
         expressionId = 2;
         return(true);
     }
     if (((isReference == false) &&
          ((expressionText == "argInput/1024") &&
           (Workflow1_TypedDataContext1_ForReadOnly.Validate(locations, true, 0) == true))))
     {
         expressionId = 3;
         return(true);
     }
     if (((isReference == true) &&
          ((expressionText == "argInput") &&
           (Workflow1_TypedDataContext1.Validate(locations, true, 0) == true))))
     {
         expressionId = 4;
         return(true);
     }
     if (((isReference == false) &&
          ((expressionText == "count+1") &&
           (Workflow1_TypedDataContext1_ForReadOnly.Validate(locations, true, 0) == true))))
     {
         expressionId = 5;
         return(true);
     }
     if (((isReference == true) &&
          ((expressionText == "count") &&
           (Workflow1_TypedDataContext1.Validate(locations, true, 0) == true))))
     {
         expressionId = 6;
         return(true);
     }
     if (((isReference == false) &&
          ((expressionText == "argInput > 1024") &&
           (Workflow1_TypedDataContext1_ForReadOnly.Validate(locations, true, 0) == true))))
     {
         expressionId = 7;
         return(true);
     }
     if (((isReference == false) &&
          ((expressionText == "argInput.ToString(\"0.00\")+ unitName[count]") &&
           (Workflow1_TypedDataContext1_ForReadOnly.Validate(locations, true, 0) == true))))
     {
         expressionId = 8;
         return(true);
     }
     expressionId = -1;
     return(false);
 }