ebgeo.maprequest.cs
Class MRDatum

java.lang.Object
  extended byebgeo.maprequest.cs.MRDatum

public class MRDatum
extends Object

Class to model a map datum. e.g. WGS84.


Nested Class Summary
 class MRDatum.DatumFileFilter
          Helper class to find *_datum.txt files.
 
Field Summary
protected  boolean known
           
protected  String wkt
           
 
Constructor Summary
MRDatum()
          Creates a new instance of MRDatum
 
Method Summary
 MRDatum getInstance(String name)
          Get a datum for a name.
 String getName()
          Get the well known name of this datum.
 String getName(String realm)
          Get the name of this datum in a particular realm.
 String getWkt()
          Get the Open GIS Well Known Text format of this datum.
 boolean isKnown()
          Check if this datum is known.
protected  void setKnown(boolean known)
           
 void setName(String name)
          Set the well known name for this datum.
 void setName(String name, String realm)
          Set the name for this datum for a particular realm.
 void setWkt(String wkt)
          Set the Open GIS Well Known Text format for this projection.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

wkt

protected String wkt

known

protected boolean known
Constructor Detail

MRDatum

public MRDatum()
Creates a new instance of MRDatum

Method Detail

getInstance

public MRDatum getInstance(String name)
Get a datum for a name. If the name is not recognised then a datum is returned for which isKnown() will return false.


getName

public String getName()
Get the well known name of this datum.


getName

public String getName(String realm)
Get the name of this datum in a particular realm.

Parameters:
realm - The realm for which you want to know the name of this datum.
Returns:
Returns the name of this datum in the requested realm. If this datum does not have a special name in the requested realm then the well known name of the datum is returned instead.
See Also:
getName()

setName

public void setName(String name)
Set the well known name for this datum.


setName

public void setName(String name,
                    String realm)
Set the name for this datum for a particular realm.

Parameters:
name - The name that this datum is known by for the realm.
realm - The realm.

getWkt

public String getWkt()
Get the Open GIS Well Known Text format of this datum.


setWkt

public void setWkt(String wkt)
Set the Open GIS Well Known Text format for this projection.


isKnown

public boolean isKnown()
Check if this datum is known.

Returns:
Returns true if this datum is known (and can be used for calculations).

setKnown

protected void setKnown(boolean known)