|
deegree 2.1 (2007/11/08 09:57 build-328-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.deegree.model.csct.cs.Info
public class Info
A base class for metadata applicable to coordinate system objects. The metadata items "Abbreviation", "Alias", "Authority", "AuthorityCode", "Name" and "Remarks" were specified in the Simple Features interfaces, so they have been kept here. This specification does not dictate what the contents of these items should be. However, the following guidelines are suggested:
CoordinateSystemAuthorityFactory
is used to create an
object, the "Authority" and "AuthorityCode" values should be set to the authority name of the
factory object, and the authority code supplied by the client, respectively. The other values may
or may not be set. (If the authority is EPSG, the implementer may consider using the
corresponding metadata values in the EPSG tables.)CoordinateSystemFactory
creates an object, the "Name"
should be set to the value supplied by the client. All of the other metadata items should be left
empty.
Field Summary | |
---|---|
(package private) static WeakHashSet |
pool
Set of weak references to existing coordinate systems. |
Constructor Summary | |
---|---|
Info(Map properties)
Create an object with the specified properties. |
|
Info(String name)
Create an object with the specified name. |
Method Summary | |
---|---|
(package private) String |
addString()
Add more information inside the "[...]" part of toString() . |
(package private) void |
addUnit(StringBuffer buffer,
Unit unit)
Add a unit in WKT form. |
(package private) static void |
ensureAngularUnit(Unit unit)
Make sure that the specified unit is an angular one. |
(package private) static void |
ensureLinearUnit(Unit unit)
Make sure that the specified unit is a linear one. |
protected static void |
ensureNonNull(String name,
Object object)
Make sure an argument is non-null. |
(package private) static void |
ensureNonNull(String name,
Object[] array,
int index)
Make sure an array element is non-null. |
(package private) static void |
ensureTimeUnit(Unit unit)
Make sure that the specified unit is a temporal one. |
boolean |
equals(Object object)
Compares the specified object with this info for equality. |
String |
getAbbreviation()
Gets the abbreviation, or null if there is none. |
String |
getAlias()
Gets the alias, or null if there is none. |
String |
getAuthority()
Gets the authority name, or null if unspecified. |
String |
getAuthorityCode()
Gets the authority-specific identification code, or null if unspecified. |
String |
getName()
Gets the name of this object. |
String |
getRemarks()
Gets the provider-supplied remarks, or null if there is none. |
int |
hashCode()
Returns a hash value for this info. |
(package private) Object |
readResolve()
Returns a reference to an unique instance of this Info . |
String |
toString()
Returns a Well Know Text (WKT) for this info. |
Methods inherited from class java.lang.Object |
---|
clone, finalize, getClass, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
static final WeakHashSet pool
Constructor Detail |
---|
public Info(String name)
name
- This object name.Info(Map properties)
String
, or may be null
if a particular property is
not defined. The "name" property is mandatory.
properties
- The set of properties.Method Detail |
---|
public String getName()
locale
- The desired locale, or null
for a default locale. If no string is
available for the specified locale, an arbitrary locale is used.
public String getAuthority()
null
if unspecified. An Authority is an
organization that maintains definitions of Authority Codes. For example the European
Petroleum Survey Group (EPSG) maintains a database of coordinate systems, and other spatial
referencing objects, where each object has a code number ID. For example, the EPSG code for a
WGS84 Lat/Lon coordinate system is '4326'.
null
if unspecified.public String getAuthorityCode()
null
if unspecified. The
AuthorityCode is a compact string defined by an Authority to reference a particular spatial
reference object. For example, the European Survey Group (EPSG) authority uses 32 bit
integers to reference coordinate systems, so all their code strings will consist of a few
digits. The EPSG code for WGS84 Lat/Lon is '4326'.
null
if unspecified.public String getAlias()
null
if there is none.
null
if there is none.public String getAbbreviation()
null
if there is none.
null
if there is none.public String getRemarks()
null
if there is none.
null
if there is none.public int hashCode()
hashCode
in class Object
public boolean equals(Object object)
equals
in class Object
public String toString()
toString
in class Object
String addString()
toString()
. The default
implementation add nothing. Subclasses will override this method in order to complete string
representation.
final void addUnit(StringBuffer buffer, Unit unit)
buffer
- unit
- protected static void ensureNonNull(String name, Object object) throws IllegalArgumentException
name
- Argument name.object
- User argument.
IllegalArgumentException
- if object
is null.static void ensureNonNull(String name, Object[] array, int index) throws IllegalArgumentException
name
- Argument name.array
- User argument.index
- Element to check.
IllegalArgumentException
- if array[i]
is null.static void ensureTimeUnit(Unit unit) throws IllegalArgumentException
unit
- Unit to check.
IllegalArgumentException
- if unit
is not a temporal unit.static void ensureLinearUnit(Unit unit) throws IllegalArgumentException
unit
- Unit to check.
IllegalArgumentException
- if unit
is not a linear unit.static void ensureAngularUnit(Unit unit) throws IllegalArgumentException
unit
- Unit to check.
IllegalArgumentException
- if unit
is not an angular unit.Object readResolve()
Info
. This method is
automatically invoked during deserialization.
NOTE ABOUT ACCESS-MODIFIER: This method can't be private, because it would prevent it from
being invoked from subclasses in this package (e.g. CoordinateSystem
). This method
will not be invoked for classes outside this package, unless we give it
protected
access. TODO: Would it be a good idea?
Info
.
|
deegree 2.1 (2007/11/08 09:57 build-328-official) | |||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://deegree.sourceforge.net