class BooleanTypeUtil
extends java.lang.Object
Helper class to handle boolean type of PostgreSQL.
Based on values accepted by the PostgreSQL server: https://www.postgresql.org/docs/current/static/datatype-boolean.html
| Modifier and Type | Field and Description |
|---|---|
private static java.util.logging.Logger |
LOGGER |
| Modifier | Constructor and Description |
|---|---|
private |
BooleanTypeUtil() |
| Modifier and Type | Method and Description |
|---|---|
private static PSQLException |
cannotCoerceException(java.lang.Object value) |
(package private) static boolean |
castToBoolean(java.lang.Object in)
Cast an Object value to the corresponding boolean value.
|
private static boolean |
fromCharacter(java.lang.Character charval) |
private static boolean |
fromNumber(java.lang.Number numval) |
private static boolean |
fromString(java.lang.String strval) |
static boolean castToBoolean(java.lang.Object in)
throws PSQLException
in - Object to cast into booleanPSQLException - PSQLState.CANNOT_COERCEprivate static boolean fromString(java.lang.String strval)
throws PSQLException
PSQLExceptionprivate static boolean fromCharacter(java.lang.Character charval)
throws PSQLException
PSQLExceptionprivate static boolean fromNumber(java.lang.Number numval)
throws PSQLException
PSQLExceptionprivate static PSQLException cannotCoerceException(java.lang.Object value)