예제 #1
0
 public string OCUnitsToString(OCSampleUnitsEnum Units)
 {
     if (Units == OCSampleUnitsEnum.WalkleyBlack)
     {
         return("Walkley Black %");
     }
     return("Total %");
 }
예제 #2
0
 /// <summary>Ocs the units set.</summary>
 /// <param name="ToUnits">To units.</param>
 public void OCUnitsSet(OCSampleUnitsEnum ToUnits)
 {
     if (ToUnits != OCUnits)
     {
         // convert the numbers
         if (ToUnits == OCSampleUnitsEnum.WalkleyBlack)
         {
             OC = OCWalkleyBlack;
         }
         else
         {
             OC = OCTotal;
         }
         OCUnits = ToUnits;
     }
 }
예제 #3
0
 public void OCUnitsSet(OCSampleUnitsEnum ToUnits)
 {
     if (ToUnits != OCUnits && OC != null)
     {
         // convert the numbers
         if (ToUnits == OCSampleUnitsEnum.WalkleyBlack)
         {
             OC = MathUtility.Divide_Value(OC, 1.3);
         }
         else
         {
             OC = MathUtility.Multiply_Value(OC, 1.3);
         }
     }
     OCUnits = ToUnits;
 }
예제 #4
0
파일: Sample.cs 프로젝트: hol353/ApsimX
 /// <summary>Ocs the units set.</summary>
 /// <param name="ToUnits">To units.</param>
 public void OCUnitsSet(OCSampleUnitsEnum ToUnits)
 {
     if (ToUnits != OCUnits)
     {
         // convert the numbers
         if (ToUnits == OCSampleUnitsEnum.WalkleyBlack)
             OC = OCWalkleyBlack;
         else
             OC = OCTotal;
         OCUnits = ToUnits;
     }
 }