## com.bbn.openmap.layer.shape
Class ESRIPoly

    java.lang.Object
      com.bbn.openmap.layer.shape.ShapeUtils
          com.bbn.openmap.layer.shape.ESRIPoly

All Implemented Interfaces:
  ShapeConstants

Direct Known Subclasses:
  ESRIPoly.ESRIFloatPoly

public abstract class ESRIPoly
extends ShapeUtils

A representation of a shape file polygon, subordinate to an `ESRIPolygonRecord`. This is an abstract class, please use one of the fully derived internal classes to do your bidding.

### TODO

- Write double-floating point representation of an ESRIPoly.
- Make sure to abstract float point vs double float in other objects of the ShapeFile reading code.

Version:
  $Revision: 1.2.2.2 $ $Date: 2006/05/19 14:40:28 $
Author:
  Ray Tomlinson, Tom Mitchell <tmitchell@bbn.com>, HACK-author blame it on aculline

Nested Class Summary
`static class` `ESRIPoly.ESRIFloatPoly` Poly with data stored in floating point format.

Field Summary
`int` `nPoints` The number of (y,x) pairs of the ESRIPoly.

Fields inherited from interface com.bbn.openmap.dataAccess.shape.ShapeConstants

`DBF_ATTRIBUTE, DBF_CHARACTER, DBF_DATE, DBF_LOGICAL, DBF_MEMO, DBF_NUMERIC, DBF_TYPE_CHARACTER, DBF_TYPE_DATE, DBF_TYPE_LOGICAL, DBF_TYPE_MEMO, DBF_TYPE_NUMERIC, PARAM_DBF, PARAM_SHP, PARAM_SHX, SHAPE_BOUNDS_ATTRIBUTE, SHAPE_DBF_DASHPATTERN, SHAPE_DBF_DASHPHASE, SHAPE_DBF_DESCRIPTION, SHAPE_DBF_FILLCOLOR, SHAPE_DBF_INFO_ATTRIBUTE, SHAPE_DBF_LINECOLOR, SHAPE_DBF_LINEWIDTH, SHAPE_DBF_SELECTCOLOR, SHAPE_FILE_HEADER_LENGTH, SHAPE_FILE_RECORD_HEADER_LENGTH, SHAPE_INDEX_ATTRIBUTE, SHAPE_MAX_MEASURE_ATTRIBUTE, SHAPE_MAX_Z_ATTRIBUTE, SHAPE_MEASURE_ATTRIBUTE, SHAPE_MIN_MEASURE_ATTRIBUTE, SHAPE_MIN_Z_ATTRIBUTE, SHAPE_TYPE_ARC, SHAPE_TYPE_MULTIPATCH, SHAPE_TYPE_MULTIPOINT, SHAPE_TYPE_MULTIPOINTM, SHAPE_TYPE_MULTIPOINTZ, SHAPE_TYPE_NULL, SHAPE_TYPE_POINT, SHAPE_TYPE_POINTM, SHAPE_TYPE_POINTZ, SHAPE_TYPE_POLYGON, SHAPE_TYPE_POLYGONM, SHAPE_TYPE_POLYGONZ, SHAPE_TYPE_POLYLINE, SHAPE_TYPE_POLYLINEM, SHAPE_TYPE_POLYLINEZ, SHAPE_Z_ATTRIBUTE`

Constructor Summary
`ESRIPoly()`

Method Summary
`abstract int` `read(byte[] b, int off, boolean connect)` Reads a polygon from the given buffer starting at the given offset.

Methods inherited from class com.bbn.openmap.layer.shape.ShapeUtils
`readBEInt, readBox, readLEDouble, readLEInt, readLEInt, readLELong, readPoint, writeBEInt, writeBox, writeLEDouble, writeLEInt, writeLELong, writePoint`

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

Field Detail

### nPoints

    public int nPoints

  The number of (y,x) pairs of the ESRIPoly. This value should be the `points.length>>1`.

Constructor Detail

### ESRIPoly

    public ESRIPoly()

Method Detail

### read

    public abstract int read(byte[] b,
                             int off,
                             boolean connect)

  Reads a polygon from the given buffer starting at the given offset.

  Parameters:
    `b` - the buffer
    `off` - the offset
  Returns:
    the number of bytes read

Copyright (C) BBNT Solutions LLC; See http://openmap.bbn.com/ for details