Class VMath
Namespace: FastReport.Olap.Utils
Assembly: FastCube.Core.dll
Variant mathematics methods.
public static class VMath
Inheritance
Methods
Add(object, object)
Adds right value to left value.
public static object Add(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
Arithmetic(SimpleMathAction, object, object)
Makes arithmetic action with two objects. Converts right object type to left object type for math. If Left object is null then use only right object type.
public static object Arithmetic(SimpleMathAction action, object value1, object value2)
Parameters
action
SimpleMathAction
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
Compare(SimpleCompareAction, object, object)
Compares two objects with specified action. Converts right object type to left object type for comparing.
public static bool Compare(SimpleCompareAction action, object value1, object value2)
Parameters
action
SimpleCompareAction
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
Divide(object, object)
Divides left value by right value.
public static object Divide(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
Equal(object, object)
Compares two objects with specified action. Converts right object type to left object type for comparing.
public static bool Equal(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
GreaterThan(object, object)
Compares two objects with specified action. Converts right object type to left object type for comparing.
public static bool GreaterThan(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
GreaterThanOrEqual(object, object)
Compares two objects with specified action. Converts right object type to left object type for comparing.
public static bool GreaterThanOrEqual(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
Inequal(object, object)
Compares two objects with specified action. Converts right object type to left object type for comparing.
public static bool Inequal(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
LessThan(object, object)
Compares two objects with specified action. Converts right object type to left object type for comparing.
public static bool LessThan(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
LessThanOrEqual(object, object)
Compares two objects with specified action. Converts right object type to left object type for comparing.
public static bool LessThanOrEqual(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
Multiply(object, object)
Multiplies left value by right value.
public static object Multiply(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
Subtract(object, object)
Subtracts right value from left value.
public static object Subtract(object value1, object value2)
Parameters
value1
object
value2
object
Returns
Remarks
This method is intended solely for unknown math, where both objects are the same type or the type of the right object does not matter. Do not use it when strongly typing.
ToBoolean(object)
Converts type to System.Boolean.
public static bool ToBoolean(object value)
Parameters
value
object
Returns
ToByte(object)
Converts type to System.Byte.
public static byte ToByte(object value)
Parameters
value
object
Returns
ToDateTime(object)
Converts type to System.DateTime.
public static DateTime ToDateTime(object value)
Parameters
value
object
Returns
ToDecimal(object)
Converts type to System.Decimal.
public static decimal ToDecimal(object value)
Parameters
value
object
Returns
ToDouble(object)
Converts type to System.Double.
public static double ToDouble(object value)
Parameters
value
object
Returns
ToInt16(object)
Converts type to System.Int16.
public static short ToInt16(object value)
Parameters
value
object
Returns
ToInt32(object)
Converts type to System.Int32.
public static int ToInt32(object value)
Parameters
value
object
Returns
ToInt64(object)
Converts type to System.Int64.
public static long ToInt64(object value)
Parameters
value
object
Returns
ToSByte(object)
Converts type to System.SByte.
public static sbyte ToSByte(object value)
Parameters
value
object
Returns
ToTimeSpan(object)
Converts type to System.TimeSpan.
public static TimeSpan ToTimeSpan(object value)
Parameters
value
object
Returns
ToUInt16(object)
Converts type to System.UInt16.
public static ushort ToUInt16(object value)
Parameters
value
object
Returns
ToUInt32(object)
Converts type to System.UInt32.
public static uint ToUInt32(object value)
Parameters
value
object
Returns
ToUInt64(object)
Converts type to System.UInt64.
public static ulong ToUInt64(object value)
Parameters
value
object