Equivalent Method

public abstract bool Equivalent([Type] obj, bool unitsMatter)

public override bool Equivalent([Type] obj, bool unitsMatter)

 

Above, [Type] is a placeholder for the class name of the objects to be compared.

 

Description

The Equivalent method is a member of many classes in GeoCalc. The signature for this method, takes two arguments. The first parameter is the object to compare against, and the second is a boolean determining if units should matter or not (i.e. 1m ~= 3.2ft). It returns a boolean value indicating if the two instances have nearly the same value.  

The following example shows how to use the Equivalent method for the ProjectedCoordSys object, but the usage is the same for all objects.

 

Example

void Equivalent(GeoCalc.ProjectedCoordSys cs1, GeoCalc.ProjectedCoordSys cs2, bool unitsMatter)

{

if(cs1.Equivalent(cs2, unitsMatter))

{

// then they are equva;emt

}

}