com.esri.sde.sdk.client
Class SeShape

java.lang.Object
  extended by com.esri.sde.sdk.client.SeShape
All Implemented Interfaces:
java.lang.Cloneable

public class SeShape
extends java.lang.Object
implements java.lang.Cloneable

The ESRI representation of a geometric shape. Shapes represent geometric objects in two-dimensional planar space that are useful for GIS applications. Shapes can be 0-dimensional points, 1-dimensional lines, and 2-dimensional areas. The available shape types are nil, points, lines, simple lines, and areas. Each shape has a spatial reference system which describes the coordinate space in which the shape is defined. ArcSDE functions that compare or combine two shapes use `Clementini` operators. Eliseo Clementini and colleagues have formalized the possible relationships that can exist between shapes. The Clementini operators differentiate between a shape`s boundary and interior. A point is considered to be all interior and has no boundary. The endpoints of a line constitutes its boundary, while the rest of the line is considered the interior. The lines that form the edge of a polygon are the boundary, while the rest of the polygon is the interior.

Shape Predicates

Methods that perform boolean shape comparisons. isEqual, isTouching, isWithin, isContaining, isCrossing, isOverlapping, isDisjoint

Shape transformations

The overlay method combines two shapes. It returns two shapes, primaryRemainder and secondaryRemainder, which contain any pieces that are unique to the primary or secondary shape only. Shapes that are common to both shapes are returned in a list of shapes. ArcSDE also has methods that return specific relationships of the overlay. For instance, method intersect returns shapes that are common to both shapes. Method difference returns the shapes which are part of the primary shape only, while method symmetricalDifference returns two lists: primary only and secondary only. Method union returns the logical OR of space between the two shapes and method clip returns the intersection of the shape and a rectangular envelope. There are two methods of the SeShape class that return a partOffset array and a subpartOffset array. They are getAllPoints and getPoints (returns the points of a part). Here is an explaination of how the offset arrays are used: The partOffsets array contains integer indexes into the subpartOffsets array that indicate the first subpart of a part. The subpartOffsets array contains integer indexes into the point array that indicate the first point of a subpart. If the subpart_offsets array is null, the partOffsets array contains integer indexes directly into the points array. Shapes other than polygons will always have a single subpart offset for each part. An SeShape contains an object that represents an SeGeometry.


Field Summary
static int RM_AREA_INTERSECT
          AREA_INTERSECTION Shape Relationship returned in findRelation.
static int RM_BOUNDARY_INTERSECT
          BOUNDARY INTERSECTION Shape Relationship returned in findRelation.
static int RM_CBOUND_DIFF
          COMMON EDGE OPPOSITE DIRECTION Shape Relationship returned in findRelation.
static int RM_CBOUND_SAME
          COMMON EDGE SAME DIRECTION Shape Relationship returned in findRelation.
static int RM_COMMON_POINT
          COMMON_POINT Shape Relationship returned in findRelation.
static int RM_EMBEDDED_POINT
          VERTICE EMBEDDED IN LINE Shape Relationship returned in findRelation.
static int RM_IDENTICAL
          PRIMARY == SECONDARY Shape Relationship returned in findRelation.
static int RM_INTERIOR_INTERSECT
          INTERIOR INTERSECTION Shape Relationship returned in findRelation.
static int RM_LINE_CROSS
          LINE CROSS Shape Relationship returned in findRelation.
static int RM_PARALLEL_OVERLAPPING
          PARALLEL OVERLAPPING LINES Shape Relationship returned in findRelation.
static int RM_PRIM_CONTAINED
          PRIMARY CONTAINED BY SECONDARY Shape Relationship returned in findRelation.
static int RM_PRIM_LEP_INTERIOR
          PRIMARY ENDPOINT TOUCHES INTERIOR Shape Relationship returned in findRelation.
static int RM_SEC_CONTAINED
          SECONDARY CONTAINED BY PRIMARY Shape Relationship returned in findRelation.
static int RM_SEC_LEP_INTERIOR
          SECONDARY ENDPOINT TOUCHES INTERIOR Shape Relationship returned in findRelation.
static int RM_TESTS_PERFORMED
          Bit mask used to determine if any shape relationship tests were performed.
static int SE_BUILD_POLYGONS_FROM_ALL_RINGS
          Uses all segments in the shape to create a polygon.
static int SE_BUILD_POLYGONS_FROM_CLOCKWISE_RINGS
          Uses only the clockwise lines in the shape to create a polygon.
static int SE_BUILD_POLYGONS_FROM_COUNTERCLOCKWISE_RINGS
          Uses only the counterclockwise lines in the shape to create a polygon.
static int SE_BUILD_SIMPLELINES
          Converts a set of spagetti lines into a multipart simple line shape.
static int SE_MATCH_MEASURES
          Match the measure values when connecting line segments in build when build mode is SE_BUILD_SIMPLELINES
static int SE_MATCH_ZEDS
          Match the Z coordinate values when connecting line segments in build when build mode is SE_BUILD_SIMPLELINES
static int SE_MATCH_ZEDS_AND_MEASURES
          Match the z coordinate and measure values when connecting line segments in build when build mode is SE_BUILD_SIMPLELINES
static int TURN_DEFAULT
           
static int TURN_LEFT
          Left hand rotation - Polygon interior is on the Left
static int TURN_RIGHT
          Right hand rotation - Polygon interior is on the right.
static int TYPE_LINE
           
static int TYPE_MULTI_LINE
           
static int TYPE_MULTI_POINT
           
static int TYPE_MULTI_POLYGON
           
static int TYPE_MULTI_SIMPLE_LINE
           
static int TYPE_NIL
           
static int TYPE_POINT
           
static int TYPE_POLYGON
           
static int TYPE_SIMPLE_LINE
           
 
Constructor Summary
SeShape()
          Creates a Nil Shape.
SeShape(SeCoordinateReference cRef)
          Creates a Nil shape with the specified coordinate reference.
 
Method Summary
 void addIsland(SDEPoint[] pts)
          Adds and island ring (donut hole) to an area shape.
 void addPart(SeShape srcShape)
          Adds a new part to the shape.
 java.util.ArrayList asBinary(int allocSize)
          Returns ESRI binary shape representation.
 SeShape asLine()
          Returns a shape of type line, using a shape of any type.
 SeShape asPoint()
          Returns a shape of type point, using a shape of any type.
 SeShape asPolygon()
          Returns a shape of type polygon, using a shape of any type.
 SeShape asSimpleLine()
          Returns a shape of simple line type, using a shape of any type.
 java.lang.String asText(int maxStringLength)
          Returns a textual representation of a shape object.
 java.util.ArrayList asWKB(int allocSize)
          Returns WKB representation of this shape object.
 SeShape build(int mode, boolean dissolve, int match)
          Assembles a linestring or area shape from the calling shape, which must be a (spagetti) line shape.
 double calculateDistance(SeShape secShape, boolean insideTest)
          Returns the closest distance between two shapes.
 SeShape changeCoordRef(SeCoordinateReference coordref, PeGeogTransformations geogtran)
          Projects a shape to a new coordinate system.
 void changePath(SDEPoint firstPoint, SDEPoint midPoint, SDEPoint lastPoint, SDEPoint[] pointList)
          Replaces a path in the source shape with a new path.
 SeShape clip(SeExtent env)
          Returns the intersection (logical AND of space) of the shape and a supplied rectangular envelope.
 java.lang.Object clone()
          Returns a copy of the shape.
 void deleteIsland(SDEPoint point)
          Deletes the island ring that contains the specified point from the source shape.
 void deletePart(int partNumber)
          Deletes the specified part of a multipart shape.
 void deletePath(SDEPoint firstPoint, SDEPoint midPoint, SDEPoint lastPoint)
          Deletes a path from the calling shape.
 void deletePoint(SDEPoint point)
          Deletes all occurrences of the specified point in the shape.
 SeShape difference(SeShape secondaryShape)
          The difference function returns the portion of this shape that is not intersected by the secondary shape.
 void extendLine(SDEPoint endpoint, SDEPoint[] points)
          Extends a linear shape by adding a specified string of points to the beginning or end of the shape.
 SeShape filterCoordinates(double distance)
          Applies a Douglas_Poiker line generalization to a shape.
 SeShape[] findAlong(double measure)
          Returns the points or lines along a shape as defined by the shape's measures and the supplied measured value.
 SeShape[] findBetween(double fromMeasure, double toMeasure)
          Returns the points or lines along a shape as defined by the shape's measures between the given from- and to- values.
 long findRelation(SeShape secondaryShape)
          Returns a mask defining all the relationships between the calling shape and the supplied shape.
 void fromSeGeometry(SeGeometry geom)
          Sets this object's shape from an SeGeometry object.
 SeShape generateBuffer(double distance, int maxPts)
          Generates a buffer around the source shape, and returns the resulting new shape.
 SeShape generateCircle(SDEPoint center, double radius, int numPts)
          Generates a polygon shape in the form of a circle based on the supplied center, radius and number of points.
 SeShape generateConvexHull()
          Computes the convex hull polygon for a shape's points.
 void generateEllipse(SDEPoint center, double semiMajorAxis, double semiMinorAxis, double angle, int numPts)
          Generates an area shape that approximates an ellipse.
 void generateFromBinary(byte[] binaryShape)
           
 SeShape generateFromPart(int partNumber)
          Generates a new shape from the specified part number of a multi-part shape.
 int generateFromText(java.lang.String textShape)
          Returns a shape object from its textual representaion.
 void generateFromWKB(byte[] wkbShape)
          Constructs shape from WKB representation.
 SDEPoint generateLabelPoint()
          Generates a label point for a shape.
 void generateLine(int numPts, int numParts, int[] partOffsets, SDEPoint[] ptArray)
          Generates a line shape from an array of points.
 void generatePoint(int numPts, SDEPoint[] ptArray)
          Generates a point shape from an array of points.
 void generatePolygon(int numPts, int numParts, int[] partOffsets, SDEPoint[] ptArray)
          Turns this shape into a polygon shape from an array of points.
 void generateRectangle(SeExtent ext)
          Generates a polygon shape in the form of a rectangle, based on the supplied lower-left and upper-right points.
 void generateSimpleLine(int numPts, int numParts, int[] partOffsets, SDEPoint[] ptArray)
          Generates a simple line shape from an array of points.
 double get3DLength()
          Returns the three-dimensional length of a shape.
 double get3DLength(int partNumber)
          Returns the three-dimensional length of a shape part.
 double[][][] getAllCoords()
          Returns the world coordinates as an array of parts/subparts/coordinates.
 double[][][] getAllCoords(int turn)
          Returns the world coordinates as an array of parts/subparts/coordinates.
 java.util.ArrayList getAllPoints(int rotation, boolean wantSubpartOffsets)
          Retrieves all the points as well as part offsets and subpart offsets of the shape.
 SeShapeAnno getAnno()
          Returns the shape's annotation.
 double getArea()
          Returns the area of a shape.
 double getArea(int partNum)
          Returns the area of a shape.
 int getBinarySize()
          Returns the size of a ESRI binary representation.
 com.esri.sde.sdk.client.SeShapeCad getCad()
          Returns the shape's cad.
 SeCoordinateReference getCoordRef()
          Returns the coordinate reference of a shape.
 SeExtent getExtent()
          Returns the extent of a shape.
 SeExtent getExtent(int partNum)
          Returns the extent of a shape or a shape part.
 SeObjectId getFeatureId()
          Returns the shape's unique id.
 double getLength()
          Returns the length of a shape.
 int getMaxM()
          Deprecated. at ArcSDE 9.0, replaced by getMaxMValue() .
 long getMaxMValue()
          Returns the maximum measure value.
 int getMaxZ()
          Deprecated. at ArcSDE 9.0, replaced by getMaxZValue() .
 long getMaxZValue()
          Returns the maximum z coordinate value.
 int getMinM()
          Deprecated. at ArcSDE 9.0, replaced by getMinMValue() .
 long getMinMValue()
          Returns the minimum measure value.
 int getMinZ()
          Deprecated. at ArcSDE 9.0, replaced by getMinZValue() .
 long getMinZValue()
          Returns the minimum z coordinate value.
 double[] getMRange()
          Returns the range of measure values of a shape.
 double[] getMRange(int partNumber)
          Returns the range of measure values of a shape part.
 int getNumOfPoints()
          Returns the number of points of the shape.
 int getNumParts()
          Returns the number of parts in a shape.
 int getNumPoints(int partNum, int subPartNum)
          Returns the number of points in a shape or a shape part.
 int getNumSubParts(int partNum)
          Returns the number of subparts of a part in a multi-part shape.
 java.util.ArrayList getPoints(int rotation, int partNumber)
          Returns the point array of the specified part, and the subpart offsets, if there are any.
 int getTextSize()
          Returns the maximum size for the text.
 int getType()
           
 int getWKBSize()
          Returns the size of WKB representation.
 double[] getZRange()
          Returns the range of elevation values of a shape.
 double[] getZRange(int partNumber)
          Returns the range of elevation values of a shape part.
 boolean hasAnno()
          Returns TRUE if the supplied shape has annotation.
 boolean hasCad()
          Returns TRUE if the supplied shape has cad.
 void insertPart(int partNum, SeShape srcShape)
          Inserts all of the parts of a given shape into the calling shape at the specified part index.
 void interpolateByMeasures(double delta)
          Interpolates the shape by adding points based on measure deltas.
 SeShape[] intersect(SeShape secondaryShape)
          Returns the intersection (logical AND NOT of space) of two shapes.
 boolean is3D()
          Returns TRUE if the supplied shape has an elevation array.
 boolean isContaining(SeShape secondaryShape)
          Returns TRUE if the primary shape wholly contains the secondary shape.
 boolean isCrossing(SeShape secondaryShape)
          Returns TRUE if the intersection of the interiors is a lower dimension than the maximum dimension of the two shapes.
 boolean isDisjoint(SeShape secondaryShape)
          Returns TRUE if the intersection of two shapes is empty.
 boolean isEqual(SeShape secondaryShape)
          Returns TRUE if the two supplied shapes are identical.
 boolean isLine()
          Returns TRUE if the supplied shape is type line.
 boolean isMeasured()
          Returns TRUE if the supplied shape has a measure array.
 boolean isMultiPart()
          Returns TRUE if the supplied shape has multiple parts.
 boolean isNil()
          Returns TRUE if the supplied shape is nil(empty).
 boolean isOverlapping(SeShape secondaryShape)
          Returns TRUE if the intersection of two shapes results in an object of the same geometric dimension.
 boolean isPoint()
          Returns TRUE if the supplied shape is type point.
 boolean isPolygon()
          Returns TRUE if the supplied shape is type polygon.
 boolean isSimpleLine()
          Returns TRUE if the supplied shape is type simple line.
 boolean isTouching(SeShape secondaryShape)
          Returns TRUE if the two supplied shapes hsare a common boundary.
 boolean isWithin(SeShape secondaryShape)
          Returns TRUE if this shape is wholly contained within secondaryShape.
 void makeNil()
          Makes this shape a nil shape.
 void movePoint(SDEPoint fromPoint, SDEPoint toPoint)
          Moves all occurrences of a single point to a new location.
 SeShape[] overlay(SeShape secondaryShape)
          Overlays two shapes.
 void replacePart(int partNum, SeShape srcShape)
          Replaces a shape part with another shape.
 void replacePathWithArc(SDEPoint firstPoint, SDEPoint midPoint, SDEPoint lastPoint, double radius, int arcSegs)
          Replaces a line or path with a circular arc represented as a series of vectors.
 void setAnno(SeShapeAnno anno)
          Sets the shape's annotation.
 void setCad(com.esri.sde.sdk.client.SeShapeCad cad)
          Sets the shape's cad.
 void setCoordRef(SeCoordinateReference cRef)
          Sets the coordinate reference of the shape.
 SeShape symmetricalDifference(SeShape secondaryShape)
          Returns the symmetrical difference (logical XOR of space) of two shapes.
 java.awt.geom.GeneralPath toGeneralPath()
          Returns a shape as a Java path object for Java graphics.
 java.awt.geom.GeneralPath toGeneralPath(int rotation)
          Returns a shape as a Java path object for Java graphics with a specified rotation.
 SeGeometry toSeGeometry()
          Convert this shape into an SeGeometry object.
 java.lang.String toString()
          Returns a string description of the shape.
 SeShape union(SeShape secondaryShape)
          Returns the union (logical OR of space) of two shapes.
 
Methods inherited from class java.lang.Object
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

TYPE_NIL

public static final int TYPE_NIL
See Also:
Constant Field Values

TYPE_POINT

public static final int TYPE_POINT
See Also:
Constant Field Values

TYPE_LINE

public static final int TYPE_LINE
See Also:
Constant Field Values

TYPE_SIMPLE_LINE

public static final int TYPE_SIMPLE_LINE
See Also:
Constant Field Values

TYPE_POLYGON

public static final int TYPE_POLYGON
See Also:
Constant Field Values

TYPE_MULTI_POINT

public static final int TYPE_MULTI_POINT
See Also:
Constant Field Values

TYPE_MULTI_LINE

public static final int TYPE_MULTI_LINE
See Also:
Constant Field Values

TYPE_MULTI_SIMPLE_LINE

public static final int TYPE_MULTI_SIMPLE_LINE
See Also:
Constant Field Values

TYPE_MULTI_POLYGON

public static final int TYPE_MULTI_POLYGON
See Also:
Constant Field Values

TURN_DEFAULT

public static final int TURN_DEFAULT
See Also:
Constant Field Values

TURN_LEFT

public static final int TURN_LEFT
Left hand rotation - Polygon interior is on the Left

See Also:
Constant Field Values

TURN_RIGHT

public static final int TURN_RIGHT
Right hand rotation - Polygon interior is on the right.

See Also:
Constant Field Values

SE_BUILD_POLYGONS_FROM_ALL_RINGS

public static final int SE_BUILD_POLYGONS_FROM_ALL_RINGS
Uses all segments in the shape to create a polygon.

See Also:
Constant Field Values

SE_BUILD_POLYGONS_FROM_COUNTERCLOCKWISE_RINGS

public static final int SE_BUILD_POLYGONS_FROM_COUNTERCLOCKWISE_RINGS
Uses only the counterclockwise lines in the shape to create a polygon.

See Also:
Constant Field Values

SE_BUILD_POLYGONS_FROM_CLOCKWISE_RINGS

public static final int SE_BUILD_POLYGONS_FROM_CLOCKWISE_RINGS
Uses only the clockwise lines in the shape to create a polygon.

See Also:
Constant Field Values

SE_BUILD_SIMPLELINES

public static final int SE_BUILD_SIMPLELINES
Converts a set of spagetti lines into a multipart simple line shape.

See Also:
Constant Field Values

SE_MATCH_ZEDS

public static final int SE_MATCH_ZEDS
Match the Z coordinate values when connecting line segments in build when build mode is SE_BUILD_SIMPLELINES

See Also:
Constant Field Values

SE_MATCH_MEASURES

public static final int SE_MATCH_MEASURES
Match the measure values when connecting line segments in build when build mode is SE_BUILD_SIMPLELINES

See Also:
Constant Field Values

SE_MATCH_ZEDS_AND_MEASURES

public static final int SE_MATCH_ZEDS_AND_MEASURES
Match the z coordinate and measure values when connecting line segments in build when build mode is SE_BUILD_SIMPLELINES

See Also:
Constant Field Values

RM_LINE_CROSS

public static final int RM_LINE_CROSS
LINE CROSS Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_COMMON_POINT

public static final int RM_COMMON_POINT
COMMON_POINT Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_EMBEDDED_POINT

public static final int RM_EMBEDDED_POINT
VERTICE EMBEDDED IN LINE Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_CBOUND_SAME

public static final int RM_CBOUND_SAME
COMMON EDGE SAME DIRECTION Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_CBOUND_DIFF

public static final int RM_CBOUND_DIFF
COMMON EDGE OPPOSITE DIRECTION Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_PARALLEL_OVERLAPPING

public static final int RM_PARALLEL_OVERLAPPING
PARALLEL OVERLAPPING LINES Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_IDENTICAL

public static final int RM_IDENTICAL
PRIMARY == SECONDARY Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_AREA_INTERSECT

public static final int RM_AREA_INTERSECT
AREA_INTERSECTION Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_INTERIOR_INTERSECT

public static final int RM_INTERIOR_INTERSECT
INTERIOR INTERSECTION Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_BOUNDARY_INTERSECT

public static final int RM_BOUNDARY_INTERSECT
BOUNDARY INTERSECTION Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_PRIM_LEP_INTERIOR

public static final int RM_PRIM_LEP_INTERIOR
PRIMARY ENDPOINT TOUCHES INTERIOR Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_SEC_LEP_INTERIOR

public static final int RM_SEC_LEP_INTERIOR
SECONDARY ENDPOINT TOUCHES INTERIOR Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_PRIM_CONTAINED

public static final int RM_PRIM_CONTAINED
PRIMARY CONTAINED BY SECONDARY Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_SEC_CONTAINED

public static final int RM_SEC_CONTAINED
SECONDARY CONTAINED BY PRIMARY Shape Relationship returned in findRelation.

See Also:
Constant Field Values

RM_TESTS_PERFORMED

public static final int RM_TESTS_PERFORMED
Bit mask used to determine if any shape relationship tests were performed. Used to anaylse the result returned by findRelation(com.esri.sde.sdk.client.SeShape).

See Also:
Constant Field Values
Constructor Detail

SeShape

public SeShape()
        throws SeException
Creates a Nil Shape.

Throws:
SeException

SeShape

public SeShape(SeCoordinateReference cRef)
        throws SeException
Creates a Nil shape with the specified coordinate reference.

Throws:
SeException
Method Detail

getArea

public double getArea()
               throws SeException
Returns the area of a shape. This method calls native code in the Geometry package.

Throws:
SeException

getArea

public double getArea(int partNum)
               throws SeException
Returns the area of a shape. This method calls native code in the Geometry package.

Throws:
SeException

getExtent

public SeExtent getExtent()
                   throws SeException
Returns the extent of a shape.

Throws:
SeException

getExtent

public SeExtent getExtent(int partNum)
                   throws SeException
Returns the extent of a shape or a shape part.

Throws:
SeException

getLength

public double getLength()
                 throws SeException
Returns the length of a shape. This method calls native code in the Geometry package.

Throws:
SeException

getMRange

public double[] getMRange()
                   throws SeException
Returns the range of measure values of a shape. The minimum M and maximum M values are returned in an array of 2 doubles. The first entry [0] is the min value and the second [1] is the max value. If the shape has no measures, an array of -1.0,-1.0 will be returned.

Throws:
SeException

getMRange

public double[] getMRange(int partNumber)
                   throws SeException
Returns the range of measure values of a shape part. The minimum M and maximum M values are returned in an array of 2 doubles. The first entry [0] is the min value and the second [1] is the max value. If the shape has no measures, an array of -1.0,-1.0 will be returned.

Parameters:
partNumber - The number of the part to return the M range for.
Throws:
SeException

getNumParts

public int getNumParts()
                throws SeException
Returns the number of parts in a shape.

Throws:
SeException

getNumSubParts

public int getNumSubParts(int partNum)
                   throws SeException
Returns the number of subparts of a part in a multi-part shape. The n parts are numbered 1, 2, ..., n.

Parameters:
partNum - The number of the part to get the subpart count for.
Throws:
SeException

getNumPoints

public int getNumPoints(int partNum,
                        int subPartNum)
                 throws SeException
Returns the number of points in a shape or a shape part.

Throws:
SeException

getAllPoints

public java.util.ArrayList getAllPoints(int rotation,
                                        boolean wantSubpartOffsets)
                                 throws SeException
Retrieves all the points as well as part offsets and subpart offsets of the shape. The ArrayList returned holds the points, partOffsets, and optional subpartOffsets, in that order.

Parameters:
rotation - The winding-rule used to determine the order of the points returned for an area shape.
wantSubpartOffsets - do you want the subpart offsets for an area shape?
Returns:
ArrayList list of points, partOffsets, and optionally, the subpartOffsets ArrayList.get(0) - Points. Array of SDEpoint objects. ArrayList.get(1) - Part offsets. Integer array of part offset values. ArrayList.get(2) - Optional sub part offsets. This element is present only when wantPartOffsets is true;
Throws:
SeException

getPoints

public java.util.ArrayList getPoints(int rotation,
                                     int partNumber)
                              throws SeException
Returns the point array of the specified part, and the subpart offsets, if there are any. The ArrayList returned holds the points as the first element and subpartOffsets as the second. If there are no subpart offsets, the ArrayList will only have one element - the array of points.

Parameters:
rotation - The winding-rule used to determine the order of the points returned for an area shape.
Throws:
SeException

get3DLength

public double get3DLength()
                   throws SeException
Returns the three-dimensional length of a shape. If the shape is a Nil shape, a point shape, or a shape with no z-coordinates, 0.0 is returned.

Returns:
double The 3D of the entire shape.
Throws:
SeException

get3DLength

public double get3DLength(int partNumber)
                   throws SeException
Returns the three-dimensional length of a shape part. If the shape is a Nil shape, a point shape, or a shape with no z-coordinates, 0.0 is returned.

Parameters:
partNumber - The number of the part to return the length of.
Throws:
SeException

getZRange

public double[] getZRange()
                   throws SeException
Returns the range of elevation values of a shape. The minimum Z and maximum z values are returned in an array of 2 doubles. The first entry [0] is the min value and the second [1] is the max value. If the shape has no z coordinates, an array of 0.0,0.0 will be returned.

Throws:
SeException

getZRange

public double[] getZRange(int partNumber)
                   throws SeException
Returns the range of elevation values of a shape part. The minimum Z and maximum z values are returned in an array of 2 doubles. The first entry [0] is the min value and the second [1] is the max value. If the shape has no z coordinates, an array of 0.0,0.0 will be returned.

Parameters:
partNumber - The number of the part to return the Z range for.
Throws:
SeException

addIsland

public void addIsland(SDEPoint[] pts)
               throws SeException
Adds and island ring (donut hole) to an area shape. The points representing the island must be arranged in clockwise order.

Parameters:
pts - An array of SDEPoints defining the island.
Throws:
SeException

addPart

public void addPart(SeShape srcShape)
             throws SeException
Adds a new part to the shape.

Throws:
SeException

build

public SeShape build(int mode,
                     boolean dissolve,
                     int match)
              throws SeException
Assembles a linestring or area shape from the calling shape, which must be a (spagetti) line shape. build mode options:

SE_BUILD_POLYGONS_FROM_CLOCKWISE_RINGS - Uses only the clockwise lines in the shape to create a polygon.

SE_BUILD_POLYGONS_FROM_COUNTERCLOCKWISE_RINGS - Uses only the counterclockwise lines in the shape to create a polygon.

SE_BUILD_POLYGONS_FROM_ALL_RINGS - Uses all lines in the shape to create a polygon.

SE_BUILD_SIMPLELINES - Converts a set of spagetti lines into a multipart simple line shape

If the dissolve flag is TRUE, then all duplicate line segments are eliminated.

Match values: Used when build mode is SE_BUILD_SIMPLELINES

SE_MATCH_ZEDS - Match the z coordinate values when connecting line segments

SE_MATCH_MEASURES - Match the measure values when connecting line segments

SE_MATCH_ZEDS_AND_MEASURES - Match the z coordinate and measure values

Parameters:
mode - the type of shape to build.
dissolve - indicates whether or not duplicate line segments should be removed.
match - determines if matches are to be made including zed and/or measure values.
Throws:
SeException

changeCoordRef

public SeShape changeCoordRef(SeCoordinateReference coordref,
                              PeGeogTransformations geogtran)
                       throws SeException
Projects a shape to a new coordinate system.

If geogtran is null, the two coordinate systems are assumed to be based on the same datum. If the two coordinate systems are on different datums, you must create a geographic transformation object which specifies how to convert the datums. Consider using the predefined transformations with the PeFactory functions.

For example, you can using following code to create a geographic transformation object that converts between NAD27 and WGS84 in the contiguous United States.

PeGeogTransformations geotran=PeFactory.geogtran(PeGeogtranDefs.PE_GT_NAD_1927_TO_WGS_1984_4);

Parameters:
coordref - the new coordinate system for result shape
geogtran - a geographic (datum) transformation object. Can be null.
Returns:
the result shape
Throws:
SeException

changePath

public void changePath(SDEPoint firstPoint,
                       SDEPoint midPoint,
                       SDEPoint lastPoint,
                       SDEPoint[] pointList)
                throws SeException
Replaces a path in the source shape with a new path. T The start and end points of the original path are maintained. If the new path described by the pointList argument is null, the points between the firstPoint and the lastPoint will be eliminated. The midPoint parameter is important when working with area shapes. The midPoint identifies which section of the polygon to change, since there is more than one path between the firstPoint and lastPoint.

Parameters:
firstPoint - The first point in the path to change.
midPoint - The midpoint of the path to change. (optional)
lastPoint - The last point in the path to change.
pointList - The points of the new path.
Throws:
SeException

deleteIsland

public void deleteIsland(SDEPoint point)
                  throws SeException
Deletes the island ring that contains the specified point from the source shape. The calling shape must be an area shape.

Parameters:
point - The point identifying the island to delete from the area shape.
Throws:
SeException

deletePart

public void deletePart(int partNumber)
                throws SeException
Deletes the specified part of a multipart shape. Any remaining parts in the shape are shifted to replace the deleted part. If the shape contains a single part that was deleted, the shape becomes a nil shape.

Parameters:
partNumber - The number of the part to delete.
Throws:
SeException

deletePath

public void deletePath(SDEPoint firstPoint,
                       SDEPoint midPoint,
                       SDEPoint lastPoint)
                throws SeException
Deletes a path from the calling shape. The path is specified by a starting point, a midpoint, and an end point. The firstPoint and lastPoint are not removed.

Parameters:
firstPoint - Start point coordinates
midPoint - Coordinates of any point along the path
lastPoint - End point coordinates
Throws:
SeException

deletePoint

public void deletePoint(SDEPoint point)
                 throws SeException
Deletes all occurrences of the specified point in the shape.

Parameters:
point - Coordinates of the point to remove
Throws:
SeException

extendLine

public void extendLine(SDEPoint endpoint,
                       SDEPoint[] points)
                throws SeException
Extends a linear shape by adding a specified string of points to the beginning or end of the shape.

Parameters:
endpoint - The point at which to extend the linear shape.
points - The list of points to add to the linear shape.
Throws:
SeException

filterCoordinates

public SeShape filterCoordinates(double distance)
                          throws SeException
Applies a Douglas_Poiker line generalization to a shape.

Throws:
SeException

insertPart

public void insertPart(int partNum,
                       SeShape srcShape)
                throws SeException
Inserts all of the parts of a given shape into the calling shape at the specified part index. Existing parts in the target shape at or following the specified part number will be shifted to accomodate the newly inserted parts. partNum must be a value between 1 and one greater than the current part count of the callng shape. The srcShape will be added to the end of the calling shape if the partNum is one greater than the part count. If the target shape has two or more parts, the source and target shapes must be of the same shape type. If the operation fails, the target shape is unchanged. Both shapes must have the same coordinate reference.

Parameters:
partNum - The part number of the target shape at which to insert the parts of srcShape.
srcShape - The shape containing the parts to insert into the calling shape.
Throws:
SeException

movePoint

public void movePoint(SDEPoint fromPoint,
                      SDEPoint toPoint)
               throws SeException
Moves all occurrences of a single point to a new location. This method verifies that the new point location does not cause the shape to violate any entity integrity rules.

Parameters:
fromPoint - The point within the shape to move.
toPoint - The point to move the fromPoint to.
Throws:
SeException

replacePart

public void replacePart(int partNum,
                        SeShape srcShape)
                 throws SeException
Replaces a shape part with another shape. If the target shape has two or more parts, the source and target shapes must be of the same shape type. If the operation fails, the target shape is unchanged. Both shapes must have the same coordinate reference.

Parameters:
partNum - The part number of the target shape to replace with the parts of srcShape.
srcShape - The shape containing the parts to replace the part in the calling shape with.
Throws:
SeException

replacePathWithArc

public void replacePathWithArc(SDEPoint firstPoint,
                               SDEPoint midPoint,
                               SDEPoint lastPoint,
                               double radius,
                               int arcSegs)
                        throws SeException
Replaces a line or path with a circular arc represented as a series of vectors. Replaces one or more line segments of a shape with a circular arc whose radius you specify. The arc begins at the firstPoint of the line or path to be replaced and ends at the lastPoint. The arcSegs parameter specifies the number of line segments in a full circle. An arcSegs value of 360 makes lines a `degree` long. The center of the circle made by the radius can be on either side of the line you`re replacing. The two sides of the line are called left and right, determined by the direction of the line. For a line defined as (firstPoint, lastPoint), right and left are defined from firstPoint looking toward lastPoint. If the radius value is positive, the center point of the circle is to the left of a line drawn from the firstPoint to the lastPoint; if negative, the center point is to the right of the line. The absolute value of the radius must be more than one-half the distance between firstPoint and lastPoint. Once you`ve chosen a radius, you still have two arcs to choose from. Imagine a line originating at the center of the circle and sweeping from firstPoint to the lastPoint. There are actually two arcs. One travels clockwise from firstPoint to lastPoint, while the other travels counterclockwise. A positive arcSegs value rotates counterclockwise from the firstPoint. A negative arcSegs value travels clockwise from the firstPoint.

Parameters:
firstPoint - Starting point on the path to replace.
midPoint - The midpoint of the path to replace.
lastPoint - Ending point on the path to replace.
radius - The radius of the arc to replace the identified path with.
arcSegs - Number of segements in a full circle (16-400).
Throws:
SeException

asLine

public SeShape asLine()
               throws SeException
Returns a shape of type line, using a shape of any type.

Throws:
SeException

asPoint

public SeShape asPoint()
                throws SeException
Returns a shape of type point, using a shape of any type.

Throws:
SeException

asPolygon

public SeShape asPolygon()
                  throws SeException
Returns a shape of type polygon, using a shape of any type.

Throws:
SeException

asSimpleLine

public SeShape asSimpleLine()
                     throws SeException
Returns a shape of simple line type, using a shape of any type.

Throws:
SeException

calculateDistance

public double calculateDistance(SeShape secShape,
                                boolean insideTest)
                         throws SeException
Returns the closest distance between two shapes. If the inside test is used, if any part of one of the shapes is inside the other (area) shape, the distance returned is 0.0. If insideness is not tested, the distance calculated will be the closest boundary -to-boundary distance.

Parameters:
secShape - The secondary shape to use in the calculation.
insideTest - if true, the inside test is used.
Throws:
SeException

getFeatureId

public SeObjectId getFeatureId()
                        throws SeException
Returns the shape's unique id.

Throws:
SeException

getType

public int getType()
            throws SeException
Throws:
SeException

getNumOfPoints

public int getNumOfPoints()
                   throws SeException
Returns the number of points of the shape.

Throws:
SeException

getMinZ

public int getMinZ()
            throws SeException
Deprecated. at ArcSDE 9.0, replaced by getMinZValue() .

Returns the minimum z coordinate value.

Throws:
SeException

getMinZValue

public long getMinZValue()
                  throws SeException
Returns the minimum z coordinate value.

Throws:
SeException

getMaxZ

public int getMaxZ()
            throws SeException
Deprecated. at ArcSDE 9.0, replaced by getMaxZValue() .

Returns the maximum z coordinate value.

Throws:
SeException

getMaxZValue

public long getMaxZValue()
                  throws SeException
Returns the maximum z coordinate value.

Throws:
SeException

getMinM

public int getMinM()
            throws SeException
Deprecated. at ArcSDE 9.0, replaced by getMinMValue() .

Returns the minimum measure value.

Throws:
SeException

getMinMValue

public long getMinMValue()
                  throws SeException
Returns the minimum measure value.

Throws:
SeException

getMaxM

public int getMaxM()
            throws SeException
Deprecated. at ArcSDE 9.0, replaced by getMaxMValue() .

Returns the maximum measure value.

Throws:
SeException

getMaxMValue

public long getMaxMValue()
                  throws SeException
Returns the maximum measure value.

Throws:
SeException

getCoordRef

public SeCoordinateReference getCoordRef()
                                  throws SeException
Returns the coordinate reference of a shape.

Throws:
SeException

setCoordRef

public void setCoordRef(SeCoordinateReference cRef)
                 throws SeException
Sets the coordinate reference of the shape.

Throws:
SeException

getAnno

public SeShapeAnno getAnno()
                    throws SeException
Returns the shape's annotation.

Throws:
SeException

setAnno

public void setAnno(SeShapeAnno anno)
             throws SeException
Sets the shape's annotation.

Throws:
SeException

getCad

public com.esri.sde.sdk.client.SeShapeCad getCad()
                                          throws SeException
Returns the shape's cad. For ESRI internal use only.

Throws:
SeException

setCad

public void setCad(com.esri.sde.sdk.client.SeShapeCad cad)
            throws SeException
Sets the shape's cad. For ESRI internal use only.

Throws:
SeException

hasAnno

public boolean hasAnno()
Returns TRUE if the supplied shape has annotation.


hasCad

public boolean hasCad()
Returns TRUE if the supplied shape has cad. For ESRI internal use only.


generateBuffer

public SeShape generateBuffer(double distance,
                              int maxPts)
                       throws SeException
Generates a buffer around the source shape, and returns the resulting new shape.

Throws:
SeException

generateConvexHull

public SeShape generateConvexHull()
                           throws SeException
Computes the convex hull polygon for a shape's points.

Throws:
SeException

generateFromPart

public SeShape generateFromPart(int partNumber)
                         throws SeException
Generates a new shape from the specified part number of a multi-part shape. The n parts of a multi-part shape are numbered 1, 2, ..., n.

Parameters:
partNumber - The part number.
Throws:
SeException

generateLabelPoint

public SDEPoint generateLabelPoint()
                            throws SeException
Generates a label point for a shape.

Returns:
SDEPoint the generated label point.
Throws:
SeException

generateLine

public void generateLine(int numPts,
                         int numParts,
                         int[] partOffsets,
                         SDEPoint[] ptArray)
                  throws SeException
Generates a line shape from an array of points.

Throws:
SeException

generatePoint

public void generatePoint(int numPts,
                          SDEPoint[] ptArray)
                   throws SeException
Generates a point shape from an array of points.

Throws:
SeException

generatePolygon

public void generatePolygon(int numPts,
                            int numParts,
                            int[] partOffsets,
                            SDEPoint[] ptArray)
                     throws SeException
Turns this shape into a polygon shape from an array of points.

Throws:
SeException

generateRectangle

public void generateRectangle(SeExtent ext)
                       throws SeException
Generates a polygon shape in the form of a rectangle, based on the supplied lower-left and upper-right points.

Throws:
SeException

generateEllipse

public void generateEllipse(SDEPoint center,
                            double semiMajorAxis,
                            double semiMinorAxis,
                            double angle,
                            int numPts)
                     throws SeException
Generates an area shape that approximates an ellipse.

Throws:
SeException

generateSimpleLine

public void generateSimpleLine(int numPts,
                               int numParts,
                               int[] partOffsets,
                               SDEPoint[] ptArray)
                        throws SeException
Generates a simple line shape from an array of points.

Throws:
SeException

interpolateByMeasures

public void interpolateByMeasures(double delta)
                           throws SeException
Interpolates the shape by adding points based on measure deltas. First, the difference between the start and end points are interpolated based on a specified measure. Then, points are added to the shape using the the measure as an offset. No densification is done on a segement incident on a vertex with an undefined measure value.

Parameters:
delta - The maximum delta of measure values between any two points in the resulting shape.
Throws:
SeException

toGeneralPath

public java.awt.geom.GeneralPath toGeneralPath()
                                        throws SeException
Returns a shape as a Java path object for Java graphics.

Throws:
SeException

toGeneralPath

public java.awt.geom.GeneralPath toGeneralPath(int rotation)
                                        throws SeException
Returns a shape as a Java path object for Java graphics with a specified rotation.

Throws:
SeException

getAllCoords

public double[][][] getAllCoords()
                          throws SeException
Returns the world coordinates as an array of parts/subparts/coordinates. Each part of the shape holds an array of subparts, each of which holds the x and y values of each point in the subpart.

Throws:
SeException

getAllCoords

public double[][][] getAllCoords(int turn)
                          throws SeException
Returns the world coordinates as an array of parts/subparts/coordinates. Each part of the shape holds an array of subparts, each of which holds the x and y values of each point in the subpart.

Parameters:
turn - Can be TURN_DEFAULT, TURN_LEFT, or TURN_RIGHT
Throws:
SeException

toString

public java.lang.String toString()
Returns a string description of the shape.

Overrides:
toString in class java.lang.Object

clone

public java.lang.Object clone()
                       throws java.lang.CloneNotSupportedException
Returns a copy of the shape.

Overrides:
clone in class java.lang.Object
Throws:
java.lang.CloneNotSupportedException

findAlong

public SeShape[] findAlong(double measure)
                    throws SeException
Returns the points or lines along a shape as defined by the shape's measures and the supplied measured value. Returns null if no such points or lines exist.

Throws:
SeException

findBetween

public SeShape[] findBetween(double fromMeasure,
                             double toMeasure)
                      throws SeException
Returns the points or lines along a shape as defined by the shape's measures between the given from- and to- values. Returns null if no such points or lines exist.

Throws:
SeException

isContaining

public boolean isContaining(SeShape secondaryShape)
                     throws SeException
Returns TRUE if the primary shape wholly contains the secondary shape.

Throws:
SeException

isCrossing

public boolean isCrossing(SeShape secondaryShape)
                   throws SeException
Returns TRUE if the intersection of the interiors is a lower dimension than the maximum dimension of the two shapes.

Throws:
SeException

isDisjoint

public boolean isDisjoint(SeShape secondaryShape)
                   throws SeException
Returns TRUE if the intersection of two shapes is empty.

Throws:
SeException

isEqual

public boolean isEqual(SeShape secondaryShape)
                throws SeException
Returns TRUE if the two supplied shapes are identical.

Throws:
SeException

isLine

public boolean isLine()
               throws SeException
Returns TRUE if the supplied shape is type line.

Throws:
SeException

isMeasured

public boolean isMeasured()
                   throws SeException
Returns TRUE if the supplied shape has a measure array.

Throws:
SeException

isMultiPart

public boolean isMultiPart()
                    throws SeException
Returns TRUE if the supplied shape has multiple parts.

Throws:
SeException

isNil

public boolean isNil()
              throws SeException
Returns TRUE if the supplied shape is nil(empty).

Throws:
SeException

isOverlapping

public boolean isOverlapping(SeShape secondaryShape)
                      throws SeException
Returns TRUE if the intersection of two shapes results in an object of the same geometric dimension.

Throws:
SeException

isPoint

public boolean isPoint()
                throws SeException
Returns TRUE if the supplied shape is type point.

Throws:
SeException

isPolygon

public boolean isPolygon()
                  throws SeException
Returns TRUE if the supplied shape is type polygon.

Throws:
SeException

isSimpleLine

public boolean isSimpleLine()
                     throws SeException
Returns TRUE if the supplied shape is type simple line.

Throws:
SeException

is3D

public boolean is3D()
             throws SeException
Returns TRUE if the supplied shape has an elevation array.

Throws:
SeException

isTouching

public boolean isTouching(SeShape secondaryShape)
                   throws SeException
Returns TRUE if the two supplied shapes hsare a common boundary.

Throws:
SeException

isWithin

public boolean isWithin(SeShape secondaryShape)
                 throws SeException
Returns TRUE if this shape is wholly contained within secondaryShape.

Throws:
SeException

makeNil

public void makeNil()
             throws SeException
Makes this shape a nil shape.

Throws:
SeException

findRelation

public long findRelation(SeShape secondaryShape)
                  throws SeException
Returns a mask defining all the relationships between the calling shape and the supplied shape. The mask returns a flag for each of the relation types that is satisfied: equal, touch, cross, intersect, disjoint, and overlap.

RM_LINE_CROSS - Line intersection. The boundaries of shapes intersect. The point of intersection is not a contained vertex for at least one of the shapes.

RM_COMMON_PT - The primary and secondary shapes have at least one point in common.

RM_EMBEDDED_PT - A vertex is embedded in a line.

RM_CBOUND_SAME - A common boundary exists between the primary and secondary shapes. The direction of flow (point storage order) of the common boundary is the same in both shapes.

RM_CBOUND_DIFF - A common boundary exists between the primary and secondary shapes. The direction of flow (point storage order) of the common boundary is opposite in the shapes.

RM_PARALLEL_OVERLAPPING - Similar to the common boundary masks but one of the shapes has a common boundary with the interior of the other shape.

RM_IDENTICAL - The primary and secondary shapes are identical in terms of shape type and coordinate description.

RM_AREA_INTERSECT - An area intersection exists. At least one of the shapes is an area shape and the other shape is at least partially inside it. Adjacency is not an area intersect.

RM_INTERIOR_INTERSECT - Same as RM_AREA_INTERSECT but applicable to all entity types. The interiors of both shapes must intersect.

RM_BOUNDARY_INTERSECT - The endpoint of a linestring intersects the endpoint of another linestring or the boundary of an area feature.

RM_PRIM_LEP_INTERIOR - The endpoint of the primary feature intersects the interior of the secondary feature. Occurs when a linear feature`s endpoint (primary) intersects a point feature.

RM_SEC_LEP_INTERIOR - The primary feature intersects the endpoint of the secondary feature. Occurs when a point feature (primary) intersects a linear feature`s endpoint.

RM_PRIM_CONTAINED - The primary shape is wholly contained by the secondary shape. If the secondary shape is an area shape, the primary shape is wholly inside the secondary shape`s boundary. If both shapes are linear, the primary shape`s path is wholly included in the secondary shape`s path. If the primary shape is a point shape, the primary shape is one of the secondary shape`s vertices.

RM_SEC_CONTAINED - The secondary shape is wholly contained by the primary shape. If the primary shape is an area shape, the secondary shape is wholly inside the primary shape`s boundary. If both shapes are linear, the secondary shape`s path is wholly included in the primary shape`s path. If the secondary shape is a point shape, the secondary shape is one of the primary shape`s vertices.

Both shapes must have the same coordinate reference.

Parameters:
secondaryShape - The shape to compare with this one.
Returns:
long mask containing the spatial relationships
Throws:
SeException

overlay

public SeShape[] overlay(SeShape secondaryShape)
                  throws SeException
Overlays two shapes. Both shapes must have the same coordinate reference. An Array of SeShapes is returned with the following contents: element [0] - primary remainder, the portions of the calling shape that do not intersect the secondaryShape. element [1] - secondary remainder, the portions of secondaryShape that do not intersect the calling shape. elements [2]-[?] the portions of the two shapes that are common. If no portion of the two shapes are common, the returned SeShape array will not have more than 2 elements, so check the size of the array to to determine if there are any common shapes.

Parameters:
secondaryShape - The shape to overlay with the calling shape.
Throws:
SeException

intersect

public SeShape[] intersect(SeShape secondaryShape)
                    throws SeException
Returns the intersection (logical AND NOT of space) of two shapes. Both shapes must have the same coordinate reference.

Parameters:
secondaryShape - The shape to intersect with the calling shape.
Throws:
SeException

difference

public SeShape difference(SeShape secondaryShape)
                   throws SeException
The difference function returns the portion of this shape that is not intersected by the secondary shape. This is the logical AND NOT of space. The difference function only operates on shapes of like dimension and returns a collection that has the same dimension as the source shapes. In the event that the source shapes are equal, a NIL shape is returned. Both the calling shape and the given shape must have the same coordinate reference.

Parameters:
secondaryShape - Shape object to take the difference of with calling shape.
Throws:
SeException

symmetricalDifference

public SeShape symmetricalDifference(SeShape secondaryShape)
                              throws SeException
Returns the symmetrical difference (logical XOR of space) of two shapes. Both shapes must have the same coordinate reference.

Parameters:
secondaryShape - Shape object to take the symmetrical difference of with the calling shape.
Throws:
SeException

union

public SeShape union(SeShape secondaryShape)
              throws SeException
Returns the union (logical OR of space) of two shapes. Both shapes must have the same coordinate reference and be of the same type (point/point, line/line, simple line/simple line, polygon/polygon.

Parameters:
secondaryShape - The shape to union with the calling shape.
Returns:
SeShape The result of the union.
Throws:
SeException

clip

public SeShape clip(SeExtent env)
             throws SeException
Returns the intersection (logical AND of space) of the shape and a supplied rectangular envelope. The resulting shape has the same dimension of the calling shape, or may be a Nil shape if the shape does not intersect the envelope.

Parameters:
env - The envelope to intersect with the shape.
Returns:
SeShape The result of the clip operation.
Throws:
SeException

asText

public java.lang.String asText(int maxStringLength)
                        throws SeException
Returns a textual representation of a shape object.

Parameters:
maxStringLength -
Returns:
Shape in text format.
Throws:
SeException

generateFromText

public int generateFromText(java.lang.String textShape)
                     throws SeException
Returns a shape object from its textual representaion.

Parameters:
textShape - Shape in text format.
Returns:
int Sql type.
Throws:
SeException

getTextSize

public int getTextSize()
                throws SeException
Returns the maximum size for the text.

Throws:
SeException

asWKB

public java.util.ArrayList asWKB(int allocSize)
                          throws SeException
Returns WKB representation of this shape object.

Parameters:
allocSize - Size of the binary shape.
Returns:
ArrayList [0] Integer Size of the actual WKBGeometry. [1] byte[] The resulting WKBGeometry.
Throws:
SeException

generateFromWKB

public void generateFromWKB(byte[] wkbShape)
                     throws SeException
Constructs shape from WKB representation.

Parameters:
wkbShape - WKB representation.
Throws:
SeException

getWKBSize

public int getWKBSize()
               throws SeException
Returns the size of WKB representation.

Returns:
Size of the shape's WKB representation.
Throws:
SeException

asBinary

public java.util.ArrayList asBinary(int allocSize)
                             throws SeException
Returns ESRI binary shape representation.

Parameters:
allocSize - Size of the pre-allocated binary shape.
Returns:
ArrayList [1] Integer Size of the actual ESRIGeometry [2] byte[] The output ESRIGeometry.
Throws:
SeException

generateFromBinary

public void generateFromBinary(byte[] binaryShape)
                        throws SeException
Throws:
SeException

getBinarySize

public int getBinarySize()
                  throws SeException
Returns the size of a ESRI binary representation.

Returns:
int Size of ESRI binary representation.
Throws:
SeException

toSeGeometry

public SeGeometry toSeGeometry()
                        throws SeException
Convert this shape into an SeGeometry object.

Returns:
SeGeometry The geometry object.
Throws:
SeException

fromSeGeometry

public void fromSeGeometry(SeGeometry geom)
                    throws SeException
Sets this object's shape from an SeGeometry object.

Parameters:
geom - The SeGeometry object to set this shape to.
Throws:
SeException

generateCircle

public SeShape generateCircle(SDEPoint center,
                              double radius,
                              int numPts)
                       throws SeException
Generates a polygon shape in the form of a circle based on the supplied center, radius and number of points.

Throws:
SeException