org.deegree.cs.refs
Class CRSResourceRef<T extends CRSResource>
java.lang.Object
org.deegree.commons.tom.Reference<T>
org.deegree.cs.refs.CRSResourceRef<T>
- All Implemented Interfaces:
- Object, TypedObjectNode, CRSResource
- Direct Known Subclasses:
- AxisRef, CRSRef, DatumRef, EllipsoidRef, PrimeMeridianRef, ProjectionRef, UnitRef
public abstract class CRSResourceRef<T extends CRSResource>
- extends Reference<T>
- implements CRSResource
Represents a reference to a CRSResource
, which is usually expressed using an xlink:href
attribute in GML (may be document-local or remote).
- Version:
- $Revision: $, $Date: $
- Author:
- Lyn Buesching, last edited by: $Author: lyn $
Methods inherited from interface org.deegree.commons.tom.Object |
getId |
CRSResourceRef
public CRSResourceRef(ReferenceResolver resolver,
String uri,
String baseURL)
- Parameters:
resolver
- uri
- baseURL
-
getAreaOfUse
public String getAreaOfUse()
- Specified by:
getAreaOfUse
in interface CRSResource
- Returns:
- the first of all areasOfUse or
null
if no areasOfUse were given.
getName
public String getName()
- Specified by:
getName
in interface CRSResource
- Returns:
- the first of all names or
null
if no names were given.
getAreaOfUseBBox
public double[] getAreaOfUseBBox()
- Description copied from interface:
CRSResource
- Returns the area of use, i.e. the domain where this
CRSIdentifiable
is valid.
- Specified by:
getAreaOfUseBBox
in interface CRSResource
- Returns:
- the domain of validity (EPSG:4326 coordinates), order: minX, minY, maxX, maxY, never
null
(-180,-90,180,90) if no such information is available
getDescription
public String getDescription()
- Specified by:
getDescription
in interface CRSResource
- Returns:
- the first of all descriptions or
null
if no descriptions were given.
getCode
public CRSCodeType getCode()
- Specified by:
getCode
in interface CRSResource
- Returns:
- the first of all identifiers.
getVersion
public String getVersion()
- Specified by:
getVersion
in interface CRSResource
- Returns:
- the first of all versions or
null
if no versions were given.
getCodeAndName
public String getCodeAndName()
- Specified by:
getCodeAndName
in interface CRSResource
- Returns:
- the first id and the name (if given) as id: id, name: name.
getAreasOfUse
public String[] getAreasOfUse()
- Specified by:
getAreasOfUse
in interface CRSResource
- Returns:
- the areasOfUse or
null
if no areasOfUse were given.
getDescriptions
public String[] getDescriptions()
- Specified by:
getDescriptions
in interface CRSResource
- Returns:
- the descriptions or
null
if no descriptions were given.
getCodes
public CRSCodeType[] getCodes()
- Specified by:
getCodes
in interface CRSResource
- Returns:
- the identifiers, each identifiable object has atleast one id.
getOrignalCodeStrings
public String[] getOrignalCodeStrings()
- Specified by:
getOrignalCodeStrings
in interface CRSResource
- Returns:
- the codetypes as the original strings, each identifiable object has atleast one id.
getNames
public String[] getNames()
- Specified by:
getNames
in interface CRSResource
- Returns:
- the names or
null
if no names were given.
getVersions
public String[] getVersions()
- Specified by:
getVersions
in interface CRSResource
- Returns:
- the versions or
null
if no versions were given.
hasCode
public boolean hasCode(CRSCodeType id)
- Specified by:
hasCode
in interface CRSResource
- Parameters:
id
- a string which could match this identifiable.
- Returns:
- true if this identifiable can be identified with the given string, false otherwise.
hasIdOrName
public boolean hasIdOrName(String idOrName,
boolean caseSensitive,
boolean exact)
- Description copied from interface:
CRSResource
- Iterates over all Ids (code type originals) and Names and tests if either one matches the given string.
- Specified by:
hasIdOrName
in interface CRSResource
- Parameters:
idOrName
- a String which might be an id or a name.caseSensitive
- should the match me case sensitiveexact
- should the names and ids contain the given string or match exact.
- Returns:
- true if any of the names or codes match without case the given string.
hasId
public boolean hasId(String id,
boolean caseSensitive,
boolean exact)
- Specified by:
hasId
in interface CRSResource
- Returns:
- true if the given id is present in this objects id's.
setDefaultId
public void setDefaultId(CRSCodeType newCodeType,
boolean override)
- Specified by:
setDefaultId
in interface CRSResource
setDefaultAreaOfUse
public void setDefaultAreaOfUse(double[] bbox)
- Specified by:
setDefaultAreaOfUse
in interface CRSResource
- Parameters:
bbox
- an envelope of validity in epsg:4326 coordinates, min(lon,lat) max(lon,lat);
addAreaOfUse
public void addAreaOfUse(String areaOfUse)
- Specified by:
addAreaOfUse
in interface CRSResource
addName
public void addName(String name)
- Specified by:
addName
in interface CRSResource
setDefaultName
public void setDefaultName(String defaultName,
boolean override)
- Specified by:
setDefaultName
in interface CRSResource
- Parameters:
defaultName
- the new default nameoverride
- true if the new name should override the name currently at position 0
setDefaultDescription
public void setDefaultDescription(String newDescription,
boolean override)
- Specified by:
setDefaultDescription
in interface CRSResource
- Parameters:
newDescription
- the new default descriptionoverride
- true if the new description should override the description currently at position 0
setDefaultVersion
public void setDefaultVersion(String newVersion,
boolean override)
- Specified by:
setDefaultVersion
in interface CRSResource
- Parameters:
newVersion
- the new default versionoverride
- true if the new version should override the version currently at position 0
equals
public boolean equals(Object obj)
- Overrides:
equals
in class Object
Copyright © 2011. All Rights Reserved.