示例#1
0
 internal virtual DoubleValue GetNthCoordinate(int n, string fieldName, bool onlyGeographic)
 {
     if (onlyGeographic && !this.CoordinateReferenceSystem.Geographic)
     {
         throw new InvalidValuesArgumentException("Field: " + fieldName + " is not available on cartesian point: " + this);
     }
     else if (n >= this.Coordinate().Length)
     {
         throw new InvalidValuesArgumentException("Field: " + fieldName + " is not available on point: " + this);
     }
     else
     {
         return(Values.DoubleValue(_coordinate[n]));
     }
 }
示例#2
0
 private static Test ShouldNotMatch(double propertyValue, object value)
 {
     return(new Test(Values.DoubleValue(propertyValue), value, false));
 }
示例#3
0
 private void InitializeInstanceFields()
 {
     _scalars = Arrays.asList(ShouldGivePublic(Values.ByteValue(( sbyte )1), ( sbyte )1), ShouldGivePublic(Values.ShortValue(( short )2), ( short )2), ShouldGivePublic(Values.IntValue(3), 3), ShouldGivePublic(Values.LongValue(4L), 4L), ShouldGivePublic(Values.FloatValue(5.0f), 5.0f), ShouldGivePublic(Values.DoubleValue(6.0), 6.0), ShouldGivePublic(Values.BooleanValue(false), false), ShouldGivePublic(Values.CharValue('a'), 'a'), ShouldGivePublic(Values.StringValue("b"), "b"));
 }
示例#4
0
 public override DoubleValue DividedBy(double b)
 {
     return(Values.DoubleValue(DoubleValue() / b));
 }
示例#5
0
 public override AnyValue Value(int position)
 {
     return(Values.DoubleValue(DoubleValue(position)));
 }