|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jooq.util.postgres.PGIntervalConverter
public class PGIntervalConverter
A converter for org.postgresql.util.PGInterval
Postgres returns an undisclosed internal type for intervals. This converter
takes care of converting the internal type to jOOQ's interval data types
DayToSecond
and YearToMonth
Note, that Postgres uses some non-standard ways of describing negative intervals. Negative intervals have a sign before every date part!
Constructor Summary | |
---|---|
PGIntervalConverter()
|
Method Summary | |
---|---|
static DayToSecond |
toDayToSecond(Object pgInterval)
Convert a Postgres interval to a jOOQ DAY TO SECOND interval |
static Object |
toPGInterval(DayToSecond interval)
Convert a jOOQ DAY TO SECOND interval to a Postgres representation |
static Object |
toPGInterval(YearToMonth interval)
Convert a jOOQ YEAR TO MONTH interval to a Postgres representation |
static YearToMonth |
toYearToMonth(Object pgInterval)
Convert a Postgres interval to a jOOQ YEAR TO MONTH interval |
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Constructor Detail |
---|
public PGIntervalConverter()
Method Detail |
---|
public static Object toPGInterval(DayToSecond interval)
DAY TO SECOND
interval to a Postgres representation
public static Object toPGInterval(YearToMonth interval)
YEAR TO MONTH
interval to a Postgres representation
public static DayToSecond toDayToSecond(Object pgInterval)
DAY TO SECOND
interval
public static YearToMonth toYearToMonth(Object pgInterval)
YEAR TO MONTH
interval
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |