public class Crs extends java.lang.Object implements ICrs
Constructor and Description |
---|
Crs(int epsgCode,
int aut) |
Crs(int epsg_cod,
java.lang.String code)
Construye un CRS a partir del código EPSG o de la cadena WKT.
|
Crs(int epsg_cod,
java.lang.String code,
java.lang.String params)
Construye un CRS a partir del código EPSG o de la cadena WKT.
|
Crs(SpatialReference spatialReference) |
Modifier and Type | Method and Description |
---|---|
void |
changeTrans(java.lang.String code) |
java.lang.Object |
clone()
Creates a copy of the object.
|
java.awt.geom.Point2D |
createPoint(double x,
double y) |
void |
drawGrid(java.awt.Graphics2D g,
ViewPortData vp) |
boolean |
equals(java.lang.Object obj) |
java.lang.String |
export(java.lang.String format)
Return the string representation of projection in the format.
|
java.awt.geom.Point2D |
fromGeo(java.awt.geom.Point2D gPt,
java.awt.geom.Point2D mPt) |
java.lang.String |
getAbrev() |
int |
getCode()
Código del CRS
|
CrsProj |
getCrsProj() |
CrsWkt |
getCrsWkt()
Campos de la cadena wkt
|
ICoordTrans |
getCT(IProjection dest)
Crea un ICoordTrans para transformar coordenadas
desde el IProjection actual al dest.
|
IDatum |
getDatum() |
java.awt.geom.Rectangle2D |
getExtent(java.awt.geom.Rectangle2D extent,
double scale,
double wImage,
double hImage,
double mapUnits,
double distanceUnits,
double dpi) |
java.lang.String |
getFullCode()
Devuelve getAbrev() mas los parametros de transformacion si los hay
ej.: (EPSG:23030:proj@+proj...@...)
|
java.awt.Color |
getGridColor() |
java.lang.String |
getProj4String() |
double |
getScale(double minX,
double maxX,
double width,
double dpi)
First two parameters must be in meters.
|
double |
getScale(double minX,
double maxX,
double minY,
double maxY,
double width,
double dpi) |
java.lang.String |
getSourceTransformationParams()
Devuelve los parametros de la transformacion del crs fuente
|
java.lang.String |
getTargetTransformationParams()
Devuelve los parametros de la transformacion del crs destino
|
java.lang.String |
getTransformationParams() |
java.lang.String |
getWKT()
Cadena WKT del CRS utilizado
|
int |
hashCode() |
boolean |
isProjected() |
protected void |
setAbrev(java.lang.String code) |
void |
setCode(int epsg_cod) |
void |
setGridColor(java.awt.Color c) |
void |
setName(java.lang.String nom) |
void |
setTrans(java.lang.String code) |
void |
setTransformationParams(java.lang.String sourceParams,
java.lang.String targetParams)
Establece los parámetros de transformación para el CRS fuente y para
el destino
|
void |
setWKT(java.lang.String wkt) |
java.awt.geom.Point2D |
toGeo(java.awt.geom.Point2D pt) |
java.lang.String |
toString() |
finalize, getClass, notify, notifyAll, wait, wait, wait
cloneQuietly, cloneQuietly
public Crs(SpatialReference spatialReference)
spatialReference
- public Crs(int epsgCode, int aut) throws CrsException
epsgCode
- aut
- CrsException
public Crs(int epsg_cod, java.lang.String code) throws CrsException
epsg_cod
- code
- CrsException
public Crs(int epsg_cod, java.lang.String code, java.lang.String params) throws CrsException
epsg_cod
- code
- params
- CrsException
public void setTrans(java.lang.String code)
code
- public void changeTrans(java.lang.String code)
code
- public java.lang.String getAbrev()
getAbrev
in interface IProjection
protected void setAbrev(java.lang.String code)
code
- public void setName(java.lang.String nom)
nom
- public IDatum getDatum()
getDatum
in interface IProjection
public void setWKT(java.lang.String wkt)
wkt
- public java.lang.String getWKT()
ICrs
public void setTransformationParams(java.lang.String sourceParams, java.lang.String targetParams)
ICrs
setTransformationParams
in interface ICrs
params
- public java.lang.String getSourceTransformationParams()
getSourceTransformationParams
in interface ICrs
public java.lang.String getTargetTransformationParams()
getTargetTransformationParams
in interface ICrs
public java.lang.String getTransformationParams()
public CrsProj getCrsProj()
getCrsProj
in interface ICrs
public java.awt.geom.Point2D createPoint(double x, double y)
createPoint
in interface IProjection
x
- y
- public void drawGrid(java.awt.Graphics2D g, ViewPortData vp)
drawGrid
in interface IProjection
g
- vp
- public void setGridColor(java.awt.Color c)
setGridColor
in interface IProjection
c
- public java.awt.Color getGridColor()
getGridColor
in interface IProjection
public ICoordTrans getCT(IProjection dest)
IProjection
getCT
in interface IProjection
dest
- public java.awt.geom.Point2D toGeo(java.awt.geom.Point2D pt)
toGeo
in interface IProjection
pt
- public java.awt.geom.Point2D fromGeo(java.awt.geom.Point2D gPt, java.awt.geom.Point2D mPt)
fromGeo
in interface IProjection
gPt
- mPt
- public boolean isProjected()
isProjected
in interface IProjection
public double getScale(double minX, double maxX, double width, double dpi)
IProjection
getScale
in interface IProjection
minX
- maxX
- width
- dpi
- public double getScale(double minX, double maxX, double minY, double maxY, double width, double dpi)
minX
- maxX
- minY
- maxY
- width
- dpi
- public void setCode(int epsg_cod)
epsg_cod
- public int getCode()
ICrs
public java.lang.String getFullCode()
IProjection
getFullCode
in interface IProjection
public java.awt.geom.Rectangle2D getExtent(java.awt.geom.Rectangle2D extent, double scale, double wImage, double hImage, double mapUnits, double distanceUnits, double dpi)
getExtent
in interface IProjection
public java.lang.String getProj4String() throws CrsException
getProj4String
in interface ICrs
CrsException
public java.lang.Object clone() throws java.lang.CloneNotSupportedException
Cloneable
clone
in class java.lang.Object
java.lang.CloneNotSupportedException
- if the instance of the object cannot
be cloned. As this is extending Cloneable
so its sure
it implements it, so this exception may be used for problems on specific
object instances.Object#clone()}.
public java.lang.String toString()
toString
in class java.lang.Object
public java.lang.String export(java.lang.String format)
IProjection
export
in interface IProjection
public boolean equals(java.lang.Object obj)
equals
in class java.lang.Object
public int hashCode()
hashCode
in class java.lang.Object