com.tensegrity.composite.geometry
Interface GeometryItemCoordinates

All Known Implementing Classes:
DefaultGeometryItemCoordinates

public interface GeometryItemCoordinates

Instances of classes implementing this interface manage and store coordinates for GeometryItems.

Version:
$Id: GeometryItemCoordinates.java,v 1.4 2004/01/27 16:49:22 AndreasEbbert Exp $
Author:
MichaelKegel
See Also:
GeometryItem

Method Summary
 int[] getComponentsX()
          Returns a copy of all stored x-coordinates in an int-array.
 int[] getComponentsY()
          Returns a copy of all stored y-coordinates in an int-array.
 int[] getCoordinate(int index)
          Returns the (x,y)-coordinate-pair stored at the given index.
 int getCoordinateCount()
          Returns the number of coordinate-pairs stored.
 int[] getReferenceComponentsX()
          Returns a copy of all stored reference x-coordinates.
 int[] getReferenceComponentsY()
          Returns a copy of all stored reference y-coordinates.
 int[] getSegmentTypes()
          Returns a copy of the int-array containing all segment-types.
 boolean hasSegmentTypes()
          Returns true, if segment-types are stored.
 

Method Detail

getCoordinateCount

public int getCoordinateCount()
Returns the number of coordinate-pairs stored.

Returns:
the number of coordinate-pairs stored.

hasSegmentTypes

public boolean hasSegmentTypes()
Returns true, if segment-types are stored.

Returns:
true, if segment-types are stored.

getCoordinate

public int[] getCoordinate(int index)
Returns the (x,y)-coordinate-pair stored at the given index. result[0] -> x, result[1] -> y.

Parameters:
index - the index for which to retrieve th coordinate-pair.
Returns:
the coordinate-pair at the given index.

getComponentsX

public int[] getComponentsX()
Returns a copy of all stored x-coordinates in an int-array.

Returns:
a copy of all stored x-coordinates.

getComponentsY

public int[] getComponentsY()
Returns a copy of all stored y-coordinates in an int-array.

Returns:
a copy of all stored y-coordinates.

getReferenceComponentsX

public int[] getReferenceComponentsX()
Returns a copy of all stored reference x-coordinates.

Returns:
a copy of all stored reference x-coordinates.

getReferenceComponentsY

public int[] getReferenceComponentsY()
Returns a copy of all stored reference y-coordinates.

Returns:
a copy of all stored reference y-coordinates.

getSegmentTypes

public int[] getSegmentTypes()
Returns a copy of the int-array containing all segment-types.

Returns:
a copy of the int-array containing all segment-types.


Copyright © 2005 Tensegrity Software GmbH. All Rights Reserved. Date of creation: 09.06.2006.