Class ShapeFileHeader2
java.lang.Object
org.gvsig.fmap.dal.store.shp.utils.ShapeFileHeader2
Class to represent the header in the shape file.
-
Field Summary
FieldsModifier and TypeFieldDescriptionintFile Code, must be the value 9994intFile Length;doubleBoundingBox ZmaxdoubleBoundingBox ZminintintUnused 1;intUnused 2;intUnused 3;intUnused 4;intUnused 5;intVersion of the file.doubleBoundingBox XmaxdoubleBoundingBox XmindoubleBoundingBox YmaxdoubleBoundingBox YmindoubleBoundingBox ZmaxdoubleBoundingBox Zminstatic final intstatic final intstatic final intstatic final intstatic final intShape Type Value Shape Type 0 Null Shape 1 Point 3 PolyLine 5 Polygon 8 MultiPoint 11 PointZ 13 PolyLineZ 15 PolygonZ 18 MultiPointZ 21 PointM 23 PolyLineM 25 PolygonM 28 MultiPointM 31 MultiPatchstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final intstatic final int -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionintReturn the file code.Get the extents of the shape file.intReturn the number of 16 bit words in the shape file as recorded in the headerintReturn the length of the header in 16 bit words..intReturn the version of the file.voidreadHeader(org.gvsig.utils.bigfile.BigByteBuffer2 in) Read the header from the shape file.voidsetWarnings(boolean inWarning) Print warnings to system.out.voidwrite(ByteBuffer out, int type, int numGeoms, int length, double minX, double minY, double maxX, double maxY, double minZ, double maxZ, double minM, double maxM)
-
Field Details
-
SHAPE_NULL
public static final int SHAPE_NULLShape Type Value Shape Type 0 Null Shape 1 Point 3 PolyLine 5 Polygon 8 MultiPoint 11 PointZ 13 PolyLineZ 15 PolygonZ 18 MultiPointZ 21 PointM 23 PolyLineM 25 PolygonM 28 MultiPointM 31 MultiPatch- See Also:
-
SHAPE_POINT
public static final int SHAPE_POINT- See Also:
-
SHAPE_POLYLINE
public static final int SHAPE_POLYLINE- See Also:
-
SHAPE_POLYGON
public static final int SHAPE_POLYGON- See Also:
-
SHAPE_MULTIPOINT
public static final int SHAPE_MULTIPOINT- See Also:
-
SHAPE_POINTZ
public static final int SHAPE_POINTZ- See Also:
-
SHAPE_POLYLINEZ
public static final int SHAPE_POLYLINEZ- See Also:
-
SHAPE_POLYGONZ
public static final int SHAPE_POLYGONZ- See Also:
-
SHAPE_MULTIPOINTZ
public static final int SHAPE_MULTIPOINTZ- See Also:
-
SHAPE_POINTM
public static final int SHAPE_POINTM- See Also:
-
SHAPE_POLYLINEM
public static final int SHAPE_POLYLINEM- See Also:
-
SHAPE_POLYGONM
public static final int SHAPE_POLYGONM- See Also:
-
SHAPE_MULTIPOINTM
public static final int SHAPE_MULTIPOINTM- See Also:
-
SHAPE_MULTIPATCH
public static final int SHAPE_MULTIPATCH- See Also:
-
myFileCode
public int myFileCodeFile Code, must be the value 9994 -
myUnused1
public int myUnused1Unused 1; -
myUnused2
public int myUnused2Unused 2; -
myUnused3
public int myUnused3Unused 3; -
myUnused4
public int myUnused4Unused 4; -
myUnused5
public int myUnused5Unused 5; -
myFileLength
public int myFileLengthFile Length; -
myVersion
public int myVersionVersion of the file. -
myShapeType
public int myShapeType -
myXmin
public double myXminBoundingBox Xmin -
myYmin
public double myYminBoundingBox Ymin -
myXmax
public double myXmaxBoundingBox Xmax -
myYmax
public double myYmaxBoundingBox Ymax -
myZmin
public double myZminBoundingBox Zmin -
myZmax
public double myZmaxBoundingBox Zmax -
myMmin
public double myMminBoundingBox Zmin -
myMmax
public double myMmaxBoundingBox Zmax
-
-
Constructor Details
-
ShapeFileHeader2
public ShapeFileHeader2()ShapeFileHeader constructor comment.
-
-
Method Details
-
getFileCode
public int getFileCode()Return the file code.- Returns:
- Entero.
-
getVersion
public int getVersion()Return the version of the file.- Returns:
- Versión.
-
getFileExtents
Get the extents of the shape file.- Returns:
- FullExtent.
-
setWarnings
public void setWarnings(boolean inWarning) Print warnings to system.out.- Parameters:
inWarning- boolean.
-
getHeaderLength
public int getHeaderLength()Return the length of the header in 16 bit words..- Returns:
- Longitud de la cabecera.
-
getFileLength
public int getFileLength()Return the number of 16 bit words in the shape file as recorded in the header- Returns:
- Longitud del fichero.
-
readHeader
public void readHeader(org.gvsig.utils.bigfile.BigByteBuffer2 in) Read the header from the shape file.- Parameters:
in- ByteBuffer.
-
write
public void write(ByteBuffer out, int type, int numGeoms, int length, double minX, double minY, double maxX, double maxY, double minZ, double maxZ, double minM, double maxM)
-