Class PostgresIntervalExpr
java.lang.Object
org.apache.empire.db.DBObject
org.apache.empire.db.DBExpr
org.apache.empire.db.DBColumnExpr
org.apache.empire.dbms.postgresql.PostgresIntervalExpr
- All Implemented Interfaces:
ColumnExpr
-
Nested Class Summary
Nested Classes -
Field Summary
Fields inherited from class org.apache.empire.db.DBColumnExpr
attributes, beanPropertyName, optionsFields inherited from class org.apache.empire.db.DBExpr
CTX_ALIAS, CTX_ALL, CTX_DEFAULT, CTX_FULLNAME, CTX_NAME, CTX_NOPARENTHESIS, CTX_VALUE -
Constructor Summary
ConstructorsConstructorDescriptionPostgresIntervalExpr(DBDatabase db, int quantity, PostgresIntervalExpr.PostgresIntervalUnitField unit) -
Method Summary
Modifier and TypeMethodDescriptionadd(int quantity, PostgresIntervalExpr.PostgresIntervalUnitField unit) voidaddReferencedColumns(Set<DBColumn> list) Internal function to obtain all DBColumnExpr-objects used by this expression.voidaddSQL(DBSQLBuilder sql, long context) Used to build the SQL command.Add a description of this column with relevant metadata to the supplied parent XML Element.final DBDatabaseReturns the database object to which this object belongs to.Returns the data type of this column expression.Returns the enum type for this columngetName()Returns the column name for this column expression.Returns the underlying rowset containing this column For functions involving none or more than one physical column this function return the first oneReturns the underlying physical column.booleanIndicates whether this function is an aggregate (sum, min, max, avg, ...) or notMethods inherited from class org.apache.empire.db.DBColumnExpr
abs, aggregate, append, as, as, asc, avg, ceiling, cmp, coalesce, concat, concat, contains, convertTo, convertTo, count, countDistinct, day, decode, decode, decode, decode, decode, decode, decodeEnum, decodeSort, desc, divideBy, floor, format, function, getAttribute, getAttribute, getBeanPropertyName, getControlType, getDefaultSortOrder, getExprFromPhrase, getExprFromPhrase, getIgnoreCaseExpr, getJavaType, getNumberType, getOptions, getSourceColumn, getTitle, in, in, in, indexOf, indexOf, indexOf, is, isBetween, isCaseSensitive, isGreaterThan, isLessOrEqual, isLiteralValue, isMoreOrEqual, isNot, isNotBetween, isSmallerThan, length, like, like, likeLower, likeUpper, lower, max, min, minus, minus, modulo, month, multiplyWith, notContains, notIn, notIn, notIn, notLike, nvl, on, parenthesis, plus, plus, prepend, qualified, replace, reverse, round, setAttribute, setBeanPropertyName, setControlType, setDefaultSortOrder, setOptions, setTitle, stringAgg, stringAgg, substring, substring, substring, substring, substring, substring, sum, toChar, toChar, toString, trim, trimLeft, trimRight, trunc, upper, when, yearMethods inherited from class org.apache.empire.db.DBObject
checkParamNull
-
Constructor Details
-
PostgresIntervalExpr
public PostgresIntervalExpr(DBDatabase db, int quantity, PostgresIntervalExpr.PostgresIntervalUnitField unit)
-
-
Method Details
-
getDatabase
Description copied from class:DBObjectReturns the database object to which this object belongs to. For the database object itself this function will return the this pointer.- Specified by:
getDatabasein classDBObject- Returns:
- the database object
-
getDataType
Description copied from class:DBColumnExprReturns the data type of this column expression.- Specified by:
getDataTypein interfaceColumnExpr- Specified by:
getDataTypein classDBColumnExpr- Returns:
- the expressions data type
- See Also:
-
getEnumType
Description copied from interface:ColumnExprReturns the enum type for this column- Returns:
- the enum type
-
getName
Description copied from class:DBColumnExprReturns the column name for this column expression. The name must contain only alphanumeric characters and the underscore. For SQL functions this name may be generated. However subsequent calls to this function for the same object instance must return the same string.- Specified by:
getNamein interfaceColumnExpr- Specified by:
getNamein classDBColumnExpr- Returns:
- the column name
-
getRowSet
Description copied from class:DBColumnExprReturns the underlying rowset containing this column For functions involving none or more than one physical column this function return the first one- Specified by:
getRowSetin classDBColumnExpr- Returns:
- a column used for this expression
-
getUpdateColumn
Description copied from class:DBColumnExprReturns the underlying physical column. For functions involving none or more than one physical column this function returns null.- Specified by:
getUpdateColumnin interfaceColumnExpr- Specified by:
getUpdateColumnin classDBColumnExpr- Returns:
- the underlying column
-
isAggregate
public boolean isAggregate()Description copied from class:DBColumnExprIndicates whether this function is an aggregate (sum, min, max, avg, ...) or not- Specified by:
isAggregatein classDBColumnExpr- Returns:
- true if the column expression represents an aggregate
-
addXml
Description copied from class:DBColumnExprAdd a description of this column with relevant metadata to the supplied parent XML Element.- Specified by:
addXmlin classDBColumnExpr- Parameters:
parent- the parent element to which to append the column descriptionflags- currently not used- Returns:
- the newly created child element
-
addSQL
Description copied from class:DBExprUsed to build the SQL command. SQL for this expression must be appended to StringBuilder. -
add
-
addReferencedColumns
Description copied from class:DBExprInternal function to obtain all DBColumnExpr-objects used by this expression.- Specified by:
addReferencedColumnsin classDBExpr- Parameters:
list- list to which all used column expressions must be added
-