jxDBCon 0.9z

org.sourceforge.jxdbcon.postgresql
Class PGDateTimeTypes.PGabstime

java.lang.Object
  |
  +--org.sourceforge.jxutil.sql.type.AbstractType
        |
        +--org.sourceforge.jxutil.sql.type.AbstractTIMESTAMP
              |
              +--org.sourceforge.jxdbcon.postgresql.PGDateTimeTypes.PGabstime
Direct Known Subclasses:
PGDateTimeTypes.PGtimestampV6
Enclosing class:
PGDateTimeTypes

public static class PGDateTimeTypes.PGabstime
extends AbstractTIMESTAMP

TIMESTAMP type with low precision. This is the classic seconds since 1970-01-01 00:00:00 stored in an int4 value. Postgres knows about times sixty-eight years on either side of that. Minimum day value = -24856 (1901-12-13) Maximum day value = +24856 (2038-01-18) Investigation shows that the actual mininum day is 1931-12-14. FIXME: Should throw DataTruncation for out of range parameters.


Field Summary
static PGDateTimeTypes.PGabstime INSTANCE
           
 
Fields inherited from class org.sourceforge.jxutil.sql.type.AbstractType
BD_ONE, BD_ZERO, name
 
Constructor Summary
private PGDateTimeTypes.PGabstime()
           
protected PGDateTimeTypes.PGabstime(String name)
           
 
Method Summary
 byte[] getBytes(Object row, ConversionContext ctx)
           
 String getLiteralPrefix()
           
 String getLiteralSuffix()
           
 Timestamp getTimestamp(Object row, Calendar cal, ConversionContext ctx)
           
 void setInt(Object row, int val, ConversionContext ctx)
           
 void setNull(Object row, ConversionContext ctx)
           
 void setTimestamp(Object row, Timestamp val, Calendar cal, ConversionContext ctx)
           
 
Methods inherited from class org.sourceforge.jxutil.sql.type.AbstractTIMESTAMP
getDate, getJavaClass, getJavaType, getJDBCType, getObject, getString, getTime, setDate, setString
 
Methods inherited from class org.sourceforge.jxutil.sql.type.AbstractType
dataTruncationRead, dataTruncationWrite, deriveType, getArray, getAsciiStream, getAutoInc, getBigDecimal, getBinaryStream, getBlob, getBoolean, getByte, getCaseSensitive, getCharacterStream, getClob, getCreateParams, getCurrency, getDate, getDouble, getFloat, getInt, getLiteral, getLocalName, getLong, getMaxScale, getMinScale, getName, getNullable, getNumRadix, getObject, getPrecision, getRef, getScale, getSearchable, getShort, getTime, getTimestamp, getUnsigned, getURL, noConversion, noConversion, noConversion, setArray, setAsciiStream, setBigDecimal, setBinaryStream, setBlob, setBoolean, setByte, setBytes, setCharacterStream, setClob, setDate, setDouble, setFloat, setLong, setNull, setNull, setObject, setObject, setObject, setRef, setShort, setStruct, setTime, setTime, setTimestamp, setURL, toString
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

INSTANCE

public static final PGDateTimeTypes.PGabstime INSTANCE
Constructor Detail

PGDateTimeTypes.PGabstime

private PGDateTimeTypes.PGabstime()

PGDateTimeTypes.PGabstime

protected PGDateTimeTypes.PGabstime(String name)
Method Detail

getBytes

public byte[] getBytes(Object row,
                       ConversionContext ctx)
Overrides:
getBytes in class AbstractType

getLiteralPrefix

public String getLiteralPrefix()
Overrides:
getLiteralPrefix in class AbstractTIMESTAMP

getLiteralSuffix

public String getLiteralSuffix()
Overrides:
getLiteralSuffix in class AbstractTIMESTAMP

getTimestamp

public Timestamp getTimestamp(Object row,
                              Calendar cal,
                              ConversionContext ctx)
                       throws SQLException
Specified by:
getTimestamp in class AbstractTIMESTAMP
SQLException

setInt

public void setInt(Object row,
                   int val,
                   ConversionContext ctx)
            throws SQLException
Overrides:
setInt in class AbstractType
SQLException

setNull

public void setNull(Object row,
                    ConversionContext ctx)
             throws SQLException
Overrides:
setNull in class AbstractType
SQLException

setTimestamp

public void setTimestamp(Object row,
                         Timestamp val,
                         Calendar cal,
                         ConversionContext ctx)
                  throws SQLException
Specified by:
setTimestamp in class AbstractTIMESTAMP
SQLException

jxDBCon 0.9z

Copyright © 2001,2002 Keve Müller; see LICENSE file for details.