Package mil.nga.oapi.features.json
Class Crs
- java.lang.Object
-
- mil.nga.oapi.features.json.Crs
-
public class Crs extends Object
Coordinate Reference Systemhttp://www.opengis.net/def/crs/{authority}/{version}/{code}
- Author:
- osbornb
-
-
Field Summary
Fields Modifier and Type Field Description static StringBASE_URLBase CRS URLstatic PatternPATTERNCRS patternstatic intPATTERN_AUTHORITY_GROUPCRS pattern authority groupstatic intPATTERN_CODE_GROUPCRS pattern code groupstatic intPATTERN_VERSION_GROUPCRS pattern code group
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description StringgetAuthority()Get the authorityStringgetCode()Get the codeStringgetVersion()Get the versionbooleanisValid()Determine if all parts of the CRS are setvoidsetAuthority(String authority)Set the authorityvoidsetCode(String code)Set the codebooleansetCrs(String crs)Set the CRSvoidsetVersion(String version)Set the versionStringtoString()
-
-
-
Field Detail
-
PATTERN
public static final Pattern PATTERN
CRS pattern
-
PATTERN_AUTHORITY_GROUP
public static final int PATTERN_AUTHORITY_GROUP
CRS pattern authority group- See Also:
- Constant Field Values
-
PATTERN_VERSION_GROUP
public static final int PATTERN_VERSION_GROUP
CRS pattern code group- See Also:
- Constant Field Values
-
PATTERN_CODE_GROUP
public static final int PATTERN_CODE_GROUP
CRS pattern code group- See Also:
- Constant Field Values
-
BASE_URL
public static final String BASE_URL
Base CRS URL- See Also:
- Constant Field Values
-
-
Method Detail
-
setCrs
public boolean setCrs(String crs)
Set the CRS- Parameters:
crs- CRS URL- Returns:
- true if a valid CRS and values were set
-
getAuthority
public String getAuthority()
Get the authority- Returns:
- authority
-
setAuthority
public void setAuthority(String authority)
Set the authority- Parameters:
authority- authority
-
getVersion
public String getVersion()
Get the version- Returns:
- version
-
setVersion
public void setVersion(String version)
Set the version- Parameters:
version- version
-
getCode
public String getCode()
Get the code- Returns:
- code
-
setCode
public void setCode(String code)
Set the code- Parameters:
code- code
-
isValid
public boolean isValid()
Determine if all parts of the CRS are set- Returns:
- true if valid
-
-