lt.monarch.chart.chart2D.engine
Class PlaneMapper2D

java.lang.Object
  extended by lt.monarch.chart.chart2D.engine.PlaneMapper2D
All Implemented Interfaces:
java.io.Serializable, PlaneMapper

public final class PlaneMapper2D
extends java.lang.Object
implements PlaneMapper, java.io.Serializable

Trivial plane mapper, which maps (x,y) coordinate pairs to Point2D objects.

See Also:
Serialized Form

Constructor Summary
Constructor and Description
PlaneMapper2D()
           
 
Method Summary
Modifier and Type Method and Description
 GeneralPoint map(double x, double y)
          Maps a 2-dimensional point for a specified 2D coordinate values.
 GeneralPoint map(double x, double y, GeneralPoint template)
          Creates a 2-dimensional point for a specified 2D coordinate values.
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

PlaneMapper2D

public PlaneMapper2D()
Method Detail

map

public GeneralPoint map(double x,
                        double y)
Maps a 2-dimensional point for a specified 2D coordinate values.

Specified by:
map in interface PlaneMapper
Parameters:
x - x coordinate value in range [0,1]
y - y coordinate value in range [0,1]
Returns:
creates and returns a Point2D

map

public GeneralPoint map(double x,
                        double y,
                        GeneralPoint template)
Creates a 2-dimensional point for a specified 2D coordinate values. The specified Point2D template is used, to avoid unnecessary object creation.

Specified by:
map in interface PlaneMapper
Parameters:
x - x coordinate value in range [0,1]
y - y coordinate value in range [0,1]
template - Point2D template
Returns:
n-dimensional point