com.iver.cit.gvsig.fmap.core.v02
Class FConverter

java.lang.Object
  extended bycom.iver.cit.gvsig.fmap.core.v02.FConverter

public class FConverter
extends java.lang.Object

Clase con varios métodos estáticos utilizados para pasar de java2d a jts y viceversa.

Author:
fjp

Nested Class Summary
static interface FConverter.PointConverter
          Interfazaz para convertir una Coordinate de JTS a Point2D.
 
Field Summary
protected static CGAlgorithms cga
           
 
Constructor Summary
FConverter()
           
 
Method Summary
static Geometry java2d_to_jts(FShape shp)
          Convierte un FShape a una Geometry del JTS.
static FShape jts_to_java2d(Geometry geo)
          Converts JTS Geometry objects into Java 2D Shape objects
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

cga

protected static CGAlgorithms cga
Constructor Detail

FConverter

public FConverter()
Method Detail

java2d_to_jts

public static Geometry java2d_to_jts(FShape shp)
Convierte un FShape a una Geometry del JTS. Para ello, utilizamos un "flattened PathIterator". El flattened indica que las curvas las pasa a segmentos de línea recta AUTOMATICAMENTE!!!.

Parameters:
shp - FShape que se quiere convertir.
Returns:
Geometry de JTS.

jts_to_java2d

public static FShape jts_to_java2d(Geometry geo)
Converts JTS Geometry objects into Java 2D Shape objects

Parameters:
geo - Geometry de JTS.
Returns:
FShape.