Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| deegree 2.4 (2010/11/11 10:47 build-27-official)
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

## org.deegree.model.spatialschema
Class PointImpl

    java.lang.Object
      org.deegree.model.spatialschema.GeometryImpl
          org.deegree.model.spatialschema.PrimitiveImpl
              org.deegree.model.spatialschema.PointImpl

All Implemented Interfaces:
  Serializable, Geometry, Point, Primitive

    public class PointImpl

extends PrimitiveImpl
implements Point, Serializable

default implementation of the Point interface.

------------------------------------------------------------

Version:
  5.6.2001
Author:
  Andreas Poth

See Also:
  Serialized Form

Field Summary

Fields inherited from class org.deegree.model.spatialschema.GeometryImpl
`boundary, centroid, convexHull, crs, empty, envelope, mute, valid`

Fields inherited from interface org.deegree.model.spatialschema.Geometry
`BUFFER_CAP_BUTT, BUFFER_CAP_ROUND, BUFFER_CAP_SQUARE`

Constructor Summary
`protected` | `PointImpl(CoordinateSystem crs)` constructor. initializes a point to the coordinate 0/0
`protected` | `PointImpl(double x, double y, CoordinateSystem crs)` constructor for initializing a point within a two-dimensional coordinate system
`protected` | `PointImpl(double x, double y, double z, CoordinateSystem crs)` constructor for initializing a point within a three-dimensional coordinate system
`protected` | `PointImpl(Point otherPoint)` constructor
`protected` | `PointImpl(Position position, CoordinateSystem crs)` constructor

Method Summary
`protected void` | `calculateParam()` recalculates internal parameters
`Object` | `clone()`
`boolean` | `contains(Geometry gmo)` The Boolean valued operation "contains" shall return TRUE if this Geometry contains another Geometry.
`boolean` | `equals(Object other)` checks if this point is completely equal to the submitted geometry
`double[]` | `getAsArray()`
`int` | `getCoordinateDimension()` The operation "coordinateDimension" shall return the dimension of the coordinates that define this Geometry, which must be the same as the coordinate dimension of the coordinate reference system for this Geometry.
`int` | `getDimension()` The operation "dimension" shall return the inherent dimension of this Geometry, which shall be less than or equal to the coordinate dimension.
`Position` | `getPosition()`
`double` | `getX()`
`double` | `getY()`
`double` | `getZ()`
`boolean` | `intersects(Geometry gmo)` The Boolean valued operation "intersects" shall return TRUE if this Geometry intersects another Geometry.
`String` | `toString()`
`void` | `translate(double[] d)` translate the point by the submitted values. the `dz`- value will be ignored.

Methods inherited from class org.deegree.model.spatialschema.GeometryImpl
`contains, difference, distance, getBoundary, getBuffer, getBuffer, getCentroid, getConvexHull, getCoordinateSystem, getEnvelope, getTolerance, intersection, isEmpty, isValid, isWithinDistance, setCoordinateSystem, setEmpty, setTolerance, setValid, union`

Methods inherited from class java.lang.Object
`finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait`

Methods inherited from interface org.deegree.model.spatialschema.Geometry
`contains, difference, distance, getBoundary, getBuffer, getBuffer, getCentroid, getConvexHull, getCoordinateSystem, getEnvelope, getTolerance, intersection, isEmpty, isWithinDistance, setTolerance, union`

Constructor Detail

### PointImpl

    protected PointImpl(CoordinateSystem crs)

  constructor. initializes a point to the coordinate 0/0

  Parameters:
    `crs` - spatial reference system of the point

### PointImpl

    protected PointImpl(double x,
                        double y,
                        CoordinateSystem crs)

  constructor for initializing a point within a two-dimensional coordinate system

  Parameters:
    `x` - x-value of the point
    `y` - y-value of the point
    `crs` - spatial reference system of the point

### PointImpl

    protected PointImpl(double x,
                        double y,
                        double z,
                        CoordinateSystem crs)

  constructor for initializing a point within a three-dimensional coordinate system

  Parameters:
    `x` - x-value of the point
    `y` - y-value of the point
    `z` - z-value of the point
    `crs` - spatial reference system of the point

### PointImpl

    protected PointImpl(Point otherPoint)

  constructor

  Parameters:
    `otherPoint` - existing GM_Point

### PointImpl

    protected PointImpl(Position position,
                        CoordinateSystem crs)

  constructor

  Parameters:
    `position` - existing position
    `crs` - spatial reference system of the point

Method Detail

### equals

    public boolean equals(Object other)

  checks if this point is completely equal to the submitted geometry

  Overrides:
    `equals` in class `GeometryImpl`
  Parameters:
    `other` - the Geometry to test for equality
  Returns:
    true if the objects are equal, else false

### getDimension

    public int getDimension()

  Description copied from interface: `Geometry`
  The operation "dimension" shall return the inherent dimension of this Geometry, which shall be less than or equal to the coordinate dimension. The dimension of a collection of geometric objects shall be the largest dimension of any of its pieces. Points are 0-dimensional, curves are 1-dimensional, surfaces are 2-dimensional, and solids are 3-dimensional.

  Specified by:
    `getDimension` in interface `Geometry`
  Returns:
    0

### getCoordinateDimension

    public int getCoordinateDimension()

  Description copied from interface: `Geometry`
  The operation "coordinateDimension" shall return the dimension of the coordinates that define this Geometry, which must be the same as the coordinate dimension of the coordinate reference system for this Geometry.

  Specified by:
    `getCoordinateDimension` in interface `Geometry`
  Returns:
    the number of ordinates contained in this point.

### clone

    public Object clone()

  Overrides:
    `clone` in class `GeometryImpl`

### getX

    public double getX()

  Specified by:
    `getX` in interface `Point`
  Returns:
    the x-value of the point

### getY

    public double getY()

  Specified by:
    `getY` in interface `Point`
  Returns:
    the y-value of the point

### getZ

    public double getZ()

  Specified by:
    `getZ` in interface `Point`
  Returns:
    the z-value of the point of Double.NaN if the dimension != 3

### getAsArray

    public double[] getAsArray()

  Specified by:
    `getAsArray` in interface `Point`
  Returns:
    the x- and y-value of the point as a two dimensional array the first field contains the x- the second field the y-value.

### translate

    public void translate(double[] d)

  translate the point by the submitted values. the `dz`- value will be ignored.

  Specified by:
    `translate` in interface `Geometry`
  Overrides:
    `translate` in class `GeometryImpl`
  Parameters:
    `d` - vector to translate the geometry with

### getPosition

    public Position getPosition()

  Specified by:
    `getPosition` in interface `Point`
  Returns:
    position

### intersects

    public boolean intersects(Geometry gmo)

  The Boolean valued operation "intersects" shall return TRUE if this Geometry intersects another Geometry. Within a Complex, the Primitives do not intersect one another. In general, topologically structured data uses shared geometric objects to capture intersection information.

  dummy implementation

  Specified by:
    `intersects` in interface `Geometry`
  Overrides:
    `intersects` in class `GeometryImpl`
  Parameters:
    `gmo` - the Geometry to intersect with
  Returns:
    true if the objects intersects, else false

### contains

    public boolean contains(Geometry gmo)

  The Boolean valued operation "contains" shall return TRUE if this Geometry contains another Geometry.

  Specified by:
    `contains` in interface `Geometry`
  Overrides:
    `contains` in class `GeometryImpl`
  Parameters:
    `gmo` - the Geometry to test (whether is is contained)
  Returns:
    true if the given object is contained, else false

### calculateParam

    protected void calculateParam()

  recalculates internal parameters

  Specified by:
    `calculateParam` in class `GeometryImpl`

### toString

    public String toString()

  Overrides:
    `toString` in class `GeometryImpl`

Overview | Package | Class | Use | Tree | Deprecated | Index | Help
| deegree 2.4 (2010/11/11 10:47 build-27-official)
PREV CLASS NEXT CLASS | FRAMES NO FRAMES
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD

an open source project founded by lat/lon, Bonn, Germany.
For more information visit: http://www.deegree.org