org.h2gis.h2spatialext.function.spatial.affine_transformations
Class ST_Rotate

java.lang.Object
  extended by org.h2gis.h2spatialapi.AbstractFunction
      extended by org.h2gis.h2spatialapi.DeterministicScalarFunction
          extended by org.h2gis.h2spatialext.function.spatial.affine_transformations.ST_Rotate
All Implemented Interfaces:
Function, ScalarFunction

public class ST_Rotate
extends DeterministicScalarFunction

ST_Rotate rotates a geometry by a given angle (in radians) about the geometry's center.

Author:
Adam Gouge

Field Summary
 
Fields inherited from interface org.h2gis.h2spatialapi.ScalarFunction
PROP_DETERMINISTIC, PROP_NOBUFFER
 
Fields inherited from interface org.h2gis.h2spatialapi.Function
PROP_NAME, PROP_REMARKS
 
Constructor Summary
ST_Rotate()
           
 
Method Summary
 String getJavaStaticMethod()
           
static com.vividsolutions.jts.geom.Geometry rotate(com.vividsolutions.jts.geom.Geometry geom, double theta)
          Rotates a geometry by a given angle (in radians) about the center of the geometry's envelope.
static com.vividsolutions.jts.geom.Geometry rotate(com.vividsolutions.jts.geom.Geometry geom, double theta, double x0, double y0)
          Rotates a geometry by a given angle (in radians) about the specified point at (x0, y0).
static com.vividsolutions.jts.geom.Geometry rotate(com.vividsolutions.jts.geom.Geometry geom, double theta, com.vividsolutions.jts.geom.Point point)
          Rotates a geometry by a given angle (in radians) about the specified point.
 
Methods inherited from class org.h2gis.h2spatialapi.AbstractFunction
addProperty, getProperty, removeProperty
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 
Methods inherited from interface org.h2gis.h2spatialapi.Function
getProperty
 

Constructor Detail

ST_Rotate

public ST_Rotate()
Method Detail

getJavaStaticMethod

public String getJavaStaticMethod()

rotate

public static com.vividsolutions.jts.geom.Geometry rotate(com.vividsolutions.jts.geom.Geometry geom,
                                                          double theta)
Rotates a geometry by a given angle (in radians) about the center of the geometry's envelope.

Parameters:
geom - Geometry
theta - Angle
Returns:
The geometry rotated about the center of its envelope

rotate

public static com.vividsolutions.jts.geom.Geometry rotate(com.vividsolutions.jts.geom.Geometry geom,
                                                          double theta,
                                                          com.vividsolutions.jts.geom.Point point)
Rotates a geometry by a given angle (in radians) about the specified point.

Parameters:
geom - Geometry
theta - Angle
point - The point about which to rotate
Returns:
The geometry rotated by theta about the given point

rotate

public static com.vividsolutions.jts.geom.Geometry rotate(com.vividsolutions.jts.geom.Geometry geom,
                                                          double theta,
                                                          double x0,
                                                          double y0)
Rotates a geometry by a given angle (in radians) about the specified point at (x0, y0).

Parameters:
geom - Geometry
theta - Angle
x0 - x-coordinate of point about which to rotate
y0 - y-coordinate of point about which to rotate
Returns:
The geometry rotated by theta about (x0, y0)


Copyright © 2015 IRSTV CNRS-FR-2488. All Rights Reserved.