org.geotools.data.teradata
Class WKBAttributeIO

Object
  extended by WKBAttributeIO

public class WKBAttributeIO
extends Object

An attribute IO implementation that can manage the WKB

Since:
2.4.1
Author:
Andrea Aime

Constructor Summary
WKBAttributeIO()
           
WKBAttributeIO(GeometryFactory gf)
           
 
Method Summary
static byte getFromChar(char c)
          Turns a char that encodes four bits in hexadecimal notation into a byte
 Geometry read(ResultSet rs, int columnIndex)
           
 Geometry read(ResultSet rs, String columnName)
           
 Geometry wkb2Geometry(byte[] wkbBytes)
          This method will convert a Well Known Binary representation to a JTS Geometry object.
 Geometry wkb2Geometry(InputStream inputStream)
           
 void write(PreparedStatement ps, int position, Object value)
           
 
Methods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

WKBAttributeIO

public WKBAttributeIO()

WKBAttributeIO

public WKBAttributeIO(GeometryFactory gf)
Method Detail

wkb2Geometry

public Geometry wkb2Geometry(byte[] wkbBytes)
                      throws IOException
This method will convert a Well Known Binary representation to a JTS Geometry object.

Returns:
a JTS Geometry object that is equivalent to the WTB representation passed in by param wkb
Throws:
IOException - if more than one geometry object was found in the WTB representation, or if the parser could not parse the WKB representation.

wkb2Geometry

public Geometry wkb2Geometry(InputStream inputStream)
                      throws IOException
Throws:
IOException

read

public Geometry read(ResultSet rs,
                     String columnName)
              throws IOException
Throws:
IOException
See Also:
org.geotools.data.jdbc.attributeio.AttributeIO#read(java.sql.ResultSet, int)

read

public Geometry read(ResultSet rs,
                     int columnIndex)
              throws IOException
Throws:
IOException
See Also:
org.geotools.data.jdbc.attributeio.AttributeIO#read(java.sql.ResultSet, int)

write

public void write(PreparedStatement ps,
                  int position,
                  Object value)
           throws IOException
Throws:
IOException
See Also:
org.geotools.data.jdbc.attributeio.AttributeIO#write(java.sql.PreparedStatement, int, java.lang.Object)

getFromChar

public static byte getFromChar(char c)
Turns a char that encodes four bits in hexadecimal notation into a byte

Parameters:
c -


Copyright © 1996-2014 Geotools. All Rights Reserved.