com.esri.arcgis.geometry
Interface IESRIShape

All Superinterfaces:
Serializable
All Known Subinterfaces:
IESRIShape2
All Known Implementing Classes:
IESRIShape2Proxy, IESRIShapeProxy

public interface IESRIShape
extends Serializable

Provides access to members that Import/Export ArcObjects geometries to ESRI shapefile format.

Superseded By

IESRIShape2

Remarks

Shape modifiers are used in certain methods of this interface. For instance they are used to define which geometry attributes to allow when exporting or importing a geometry.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux


Method Summary
 void attachToESRIShape(int[] byteCountInOut, byte[] byteBuffer)
          Takes ownership of the input ESRI shapefile format buffer.
 void exportToESRIShape(int[] byteCountInOut, byte[] byteBuffer)
          Writes an ESRI shapefile formatted version of this geometry to the specified buffer.
 void exportToESRIShapeEx(int modifiersToAllow, boolean useArcViewNaNs, int[] byteCountInOut, byte[] byteBuffer)
          Writes an ESRI shapefile formatted version of this geometry to the specified buffer.
 int getESRIShapeSize()
          The size of the buffer, in bytes, that will be required to hold the ESRI shapefile formatted version of the geometry.
 int getESRIShapeSizeEx(int modifiersToAllow)
          The size of the buffer (in bytes) that will be required to hold the ESRI shapefile version of the geometry.
 void getModifierOffset(int modifierType, int[] offset)
          Finds out the byte offsets within a shape buffer at which an exported attribute can be found.
 void importFromESRIShape(int[] byteCountInOut, byte[] byteBuffer)
          Defines this geometry from the input ESRI shapefile formatted buffer.
 void nonTrustedImportFromESRIShape(int[] byteCountInOut, byte[] byteBuffer)
          Defines this geometry from the contents of the input ESRI shapefile formatted buffer.
 void queryESRIShapeType(int basicShapeType, int[] shapeModifiers)
          Returns the basic type and modifiers (combination of esriShapeModifiers) that define the geometry's shape type, as it was last exported.
 

Method Detail

queryESRIShapeType

void queryESRIShapeType(int basicShapeType,
                        int[] shapeModifiers)
                        throws IOException,
                               AutomationException
Returns the basic type and modifiers (combination of esriShapeModifiers) that define the geometry's shape type, as it was last exported.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
basicShapeType - A com.esri.arcgis.geometry.esriShapeType constant (in)
shapeModifiers - The shapeModifiers (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getESRIShapeSize

int getESRIShapeSize()
                     throws IOException,
                            AutomationException
The size of the buffer, in bytes, that will be required to hold the ESRI shapefile formatted version of the geometry. The value may exceed the minimum required size.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Returns:
The cBytes
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getESRIShapeSizeEx

int getESRIShapeSizeEx(int modifiersToAllow)
                       throws IOException,
                              AutomationException
The size of the buffer (in bytes) that will be required to hold the ESRI shapefile version of the geometry. Only attributes specified by modifiers to allow will be exported. The value may exceed the minimum required size.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Parameters:
modifiersToAllow - The modifiersToAllow (in)
Returns:
The cBytes
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

importFromESRIShape

void importFromESRIShape(int[] byteCountInOut,
                         byte[] byteBuffer)
                         throws IOException,
                                AutomationException
Defines this geometry from the input ESRI shapefile formatted buffer. Assumes the buffer describes a topologically correct geometry. Returns the exact number of bytes read from the buffer.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
byteCountInOut - The byteCountInOut (in/out: use single element array)
byteBuffer - An unsigned byte (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

nonTrustedImportFromESRIShape

void nonTrustedImportFromESRIShape(int[] byteCountInOut,
                                   byte[] byteBuffer)
                                   throws IOException,
                                          AutomationException
Defines this geometry from the contents of the input ESRI shapefile formatted buffer. Does not assume that the buffer describes a topological correct geometry. Returns the exact number of bytes read from the buffer.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
byteCountInOut - The byteCountInOut (in/out: use single element array)
byteBuffer - An unsigned byte (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

attachToESRIShape

void attachToESRIShape(int[] byteCountInOut,
                       byte[] byteBuffer)
                       throws IOException,
                              AutomationException
Takes ownership of the input ESRI shapefile format buffer. The geometry must be deleted, set to empty, edited, or imported from/attached to a different buffer before the buffer can be re-used.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
byteCountInOut - The byteCountInOut (in/out: use single element array)
byteBuffer - An unsigned byte (in)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

exportToESRIShape

void exportToESRIShape(int[] byteCountInOut,
                       byte[] byteBuffer)
                       throws IOException,
                              AutomationException
Writes an ESRI shapefile formatted version of this geometry to the specified buffer. Returns the exact number of bytes written to the buffer.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
byteCountInOut - The byteCountInOut (in/out: use single element array)
byteBuffer - An unsigned byte (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

exportToESRIShapeEx

void exportToESRIShapeEx(int modifiersToAllow,
                         boolean useArcViewNaNs,
                         int[] byteCountInOut,
                         byte[] byteBuffer)
                         throws IOException,
                                AutomationException
Writes an ESRI shapefile formatted version of this geometry to the specified buffer. Only exports attributes specified by modifiersToAllow. Returns the exact number of bytes written to the buffer.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
modifiersToAllow - The modifiersToAllow (in)
useArcViewNaNs - The useArcViewNaNs (in)
byteCountInOut - The byteCountInOut (in/out: use single element array)
byteBuffer - An unsigned byte (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.

getModifierOffset

void getModifierOffset(int modifierType,
                       int[] offset)
                       throws IOException,
                              AutomationException
Finds out the byte offsets within a shape buffer at which an exported attribute can be found. Only works if the shape hasn't changed since the last call to ExportToESRIShape or ExportToESRIShapeEx.

Product Availability

Available with ArcGIS Engine, ArcGIS Desktop, and ArcGIS Server.

Supported Platforms

Windows, Solaris, Linux

Parameters:
modifierType - A com.esri.arcgis.geometry.esriShapeModifiers constant (in)
offset - The offset (out: use single element array)
Throws:
IOException - If there are interop problems.
AutomationException - If the ArcObject component throws an exception.