C# Class NVelocity.Runtime.Parser.Node.ObjectComparer

ObjectComparer allows you to compare primitive types and some others using IComparable interface whenever possible, and performing type conversions to get the best possible result.
Inheritance: IComparer
Show file Open project: rasmus-toftdahl-olesen/NVelocity Class Usage Examples

Public Methods

Method Description
Compare ( object x, object y ) : int
CompareObjects ( object x, object y ) : int

Tries to compare two random objects. -1 is returned if x is smaller than y, 1 the other way around, or 0 if they are equal.

ComparePrimitive ( object x, object y ) : int
ReType ( object value ) : object

Private Methods

Method Description
ObjectComparer ( ) : System

Method Details

Compare() public method

public Compare ( object x, object y ) : int
x object
y object
return int

CompareObjects() public static method

Tries to compare two random objects. -1 is returned if x is smaller than y, 1 the other way around, or 0 if they are equal.
public static CompareObjects ( object x, object y ) : int
x object
y object
return int

ComparePrimitive() public method

public ComparePrimitive ( object x, object y ) : int
x object
y object
return int

ReType() public method

public ReType ( object value ) : object
value object
return object