jxDBCon 0.9z

org.sourceforge.jxdbcon.postgresql
Class PGDateTimeTypes

java.lang.Object
  |
  +--org.sourceforge.jxdbcon.postgresql.PGTypes
        |
        +--org.sourceforge.jxdbcon.postgresql.PGDateTimeTypes

public class PGDateTimeTypes
extends PGTypes

The date and time types used in the PostgreSQL database system.

Version:
$Revision: 1.6 $
Author:
Keve Müller, Peter Brant

Nested Class Summary
static class PGDateTimeTypes.PGabstime
          TIMESTAMP type with low precision.
static class PGDateTimeTypes.PGdate
          DATE type.
static class PGDateTimeTypes.PGtime
          TIME type.
static class PGDateTimeTypes.PGtimestamp
          TIMESTAMP (with time zone) for versions prior to 7.2.
static class PGDateTimeTypes.PGtimestampBase
          The base class for timestamp implementations.
static class PGDateTimeTypes.PGtimestamptz
          TIMESTAMP [WITH TIME ZONE] type as introduced with 7.2.
static class PGDateTimeTypes.PGtimestampV6
          In PG 6.5.3 timestamp is merely a wrapper for abstime.
static class PGDateTimeTypes.PGtimestampV72
          TIMESTAMP WITHOUT TIME ZONE as introduced with 7.2.
 
Nested classes inherited from class org.sourceforge.jxdbcon.postgresql.PGTypes
PGTypes.DefaultParamType, PGTypes.PGaclitem, PGTypes.PGbit, PGTypes.PGbool, PGTypes.PGbytea, PGTypes.PGmacaddr, PGTypes.PGoid, PGTypes.PGunknown, PGTypes.PGvarbit
 
Field Summary
private static int E1970
           
private static int EPOCH
           
 
Fields inherited from class org.sourceforge.jxdbcon.postgresql.PGTypes
be, defKnownTypes, le
 
Constructor Summary
PGDateTimeTypes()
           
 
Method Summary
private static int date2j(int y, int m, int d)
          Convert year/month/day to Julian date.
private static Timestamp j2date_dt2time(int jd, double jt)
           
private static Date j2date(int jd)
          Conversion routine copied from datetime.c.
static Timestamp textToTimestamp(String val)
           
private static double time2t(int hour, int min, double sec)
          Conversion routine copied from datetime.c.
 
Methods inherited from class org.sourceforge.jxdbcon.postgresql.PGTypes
doEscape, genericGetBytes, genericSetBytes, genericSetNull
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

E1970

private static final int E1970

EPOCH

private static final int EPOCH
Constructor Detail

PGDateTimeTypes

public PGDateTimeTypes()
Method Detail

date2j

private static int date2j(int y,
                          int m,
                          int d)
Convert year/month/day to Julian date. Conversion routine copied from datetime.c.


j2date_dt2time

private static Timestamp j2date_dt2time(int jd,
                                        double jt)

j2date

private static Date j2date(int jd)
Conversion routine copied from datetime.c.


textToTimestamp

public static final Timestamp textToTimestamp(String val)
                                       throws IllegalArgumentException
IllegalArgumentException

time2t

private static double time2t(int hour,
                             int min,
                             double sec)
Conversion routine copied from datetime.c.


jxDBCon 0.9z

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