public class DateTimeObject extends java.lang.Object implements IObject, IFunctionConstants
ABS, ACOS, ADD, ADDTIME, AM_PM, AND, ASIN, ATAN, ATAN2, AVERAGE, B_COL, BOOL, BOOL_FUNC, BOOL_NAME, CALENDAR_CONST, CEIL, COL, COS, COUNT, CURRDATE, CURRDATETIME, CURRTIME, D_COL, DATE, DATE_FUNC, DATE_NAME, DATETIME, DAY_OF_MONTH, DAY_OF_WEEK, DAY_OF_WEEK_IN_MONTH, DAY_OF_YEAR, DAYDIFF, DAYOFWEEK, DECL, DIVIDE, E, EQUALS, ERA, EXP, FACTORIAL, FALSE, FLOOR, GETAMPM, GETERA, GETMONTH, GREATER, GREATEREQUAL, HOUR, HOUR_OF_DAY, ID, IEEEREMAINDER, IFELSE_B, IFELSE_D, IFELSE_N, IFELSE_S, INDEXOF, INSERT, LASTINDEXOF, LESS, LESSEQUAL, LOG, MAX, MAXLENGTH, MEDIAN, MILLISECOND, MIN, MINUTE, MOD, MONTH, MULTIPLY, N_COL, NAND, NEW_DATE_NAME, NEW_NUM_NAME, NEW_STR_NAME, NOR, NOT, NUM, NUM_FUNC, NUM_NAME, OR, OTHER_FUNC_NAME, PAGE, PARAM, PI, POW, PRINTDATE, PRINTDATETIME, PRINTTIME, RANDOM, REPLACE, RINT, ROLLTIME, S_COL, SECOND, SIN, SQRT, STDDEV, STR, STR_FUNC, STR_NAME, STRCAT, STRLEN, SUBSTRING, SUBTRACT, SUMSQUARE, TAN, TD_FUNC_NAME, THIS, TODATE, TODEGREES, TOLOWERCASE, TONUMERIC, TORADIANS, TOSTRING, TOTALPAGES, TOTALSECTIONS, TOUPPERCASE, TRUE, VARIANCE, WEEK_OF_MONTH, WEEK_OF_YEAR, WITHIN, XNOR, XOR, YEAR
Modifier | Constructor and Description |
---|---|
|
DateTimeObject(java.util.Date date)
Creates a new DateTimeObject using specified Date
|
|
DateTimeObject(java.lang.String date)
Creates a new DateTimeObject using specified String
|
protected |
DateTimeObject(java.lang.String formula,
int sqlType)
Creates a new DateTimeObject using specified formula and SQL type
|
|
DateTimeObject(StringObject date)
Creates a new DateTimeObject using specified StringObject
|
Modifier and Type | Method and Description |
---|---|
static DateTimeObject |
add(DateTimeObject date,
short calendarField,
NumericObject amt)
Add amt to Calendar Field part of the Date
|
static StringObject |
getAmPm(DateTimeObject date)
Returns AM or PM depending on the time of the DateTimeObject
|
static DateTimeObject |
getColumnValue(int colInfoIndex)
Gets the column value at specified column
|
static DateTimeObject |
getColumnValue(int colInfoIndex,
int sqlType)
Gets the column value at specified column
|
static DateTimeObject |
getColumnValue(int colInfoIndex,
short aggregation)
Gets the column value at specified column after applying specified aggregation.
|
static DateTimeObject |
getColumnValue(int colInfoIndex,
short aggregation,
int sqlType)
Gets the column value at specified column after applying specified aggregation.
|
static DateTimeObject |
getColumnValue(NumericObject colInfoIndex,
int sqlType)
Gets the column value at specified column
|
static DateTimeObject |
getColumnValue(NumericObject colInfoIndex,
short aggregation,
int sqlType)
Gets the column value at specified column after applying specified aggregation.
|
static DateTimeObject |
getCurrentDate()
Returns the current date
|
static DateTimeObject |
getCurrentDateTime()
Returns the current date and time
|
static DateTimeObject |
getCurrentTime()
Returns the current time
|
static NumericObject |
getDateTime(DateTimeObject date,
short calendarField)
Gets the value of a specified field from the DateTimeObject
|
static NumericObject |
getDayDifference(DateTimeObject date1,
DateTimeObject date2)
Returns the difference in number of days between the two DateTimeObjects
|
static StringObject |
getDayOfWeek(DateTimeObject date)
Returns the day of the week
|
static StringObject |
getERA(DateTimeObject date)
Returns the ERA of the DateTimeObject
|
java.lang.String |
getFormula()
Returns the formula
|
static StringObject |
getMonth(DateTimeObject date)
Returns the month
|
int |
getSQLType()
Returns the SQL type
|
static StringObject |
printDate(DateTimeObject date)
Prints the date
|
static StringObject |
printDate(DateTimeObject date,
StringObject pattern)
Prints the date in the specified format
|
static StringObject |
printDateTime(DateTimeObject date)
Prints the date and time
|
static StringObject |
printDateTime(DateTimeObject date,
StringObject pattern)
Prints the date and time in the specified format
|
static StringObject |
printTime(DateTimeObject date)
Prints the time
|
static StringObject |
printTime(DateTimeObject date,
StringObject pattern)
Prints the time in the specified format
|
static DateTimeObject |
roll(DateTimeObject date,
short calendarField,
NumericObject amt)
Rolls amt to the Calendar Field part of Date.
|
public DateTimeObject(java.lang.String date)
public DateTimeObject(StringObject date)
public DateTimeObject(java.util.Date date)
protected DateTimeObject(java.lang.String formula, int sqlType)
public java.lang.String getFormula()
getFormula
in interface IObject
public int getSQLType()
getSQLType
in interface IObject
public static DateTimeObject getColumnValue(int colInfoIndex)
public static DateTimeObject getColumnValue(int colInfoIndex, int sqlType)
public static DateTimeObject getColumnValue(NumericObject colInfoIndex, int sqlType)
public static DateTimeObject getColumnValue(int colInfoIndex, short aggregation)
public static DateTimeObject getColumnValue(int colInfoIndex, short aggregation, int sqlType)
public static DateTimeObject getColumnValue(NumericObject colInfoIndex, short aggregation, int sqlType)
public static DateTimeObject getCurrentDateTime()
public static DateTimeObject getCurrentDate()
public static DateTimeObject getCurrentTime()
public static DateTimeObject add(DateTimeObject date, short calendarField, NumericObject amt)
Calendar Field : quadbase.reportdesigner.util.IFunctionConstants.ERA quadbase.reportdesigner.util.IFunctionConstants.YEAR quadbase.reportdesigner.util.IFunctionConstants.MONTH quadbase.reportdesigner.util.IFunctionConstants.WEEK_OF_YEAR quadbase.reportdesigner.util.IFunctionConstants.WEEK_OF_MONTH quadbase.reportdesigner.util.IFunctionConstants.DATE quadbase.reportdesigner.util.IFunctionConstants.DAY_OF_MONTH quadbase.reportdesigner.util.IFunctionConstants.DAY_OF_YEAR quadbase.reportdesigner.util.IFunctionConstants.DAY_OF_WEEK quadbase.reportdesigner.util.IFunctionConstants.DAY_OF_WEEK_IN_MONTH quadbase.reportdesigner.util.IFunctionConstants.AM_PM quadbase.reportdesigner.util.IFunctionConstants.HOUR quadbase.reportdesigner.util.IFunctionConstants.HOUR_OF_DAY quadbase.reportdesigner.util.IFunctionConstants.MINUTE quadbase.reportdesigner.util.IFunctionConstants.SECOND quadbase.reportdesigner.util.IFunctionConstants.MILLISECOND
IFunctionConstants
public static DateTimeObject roll(DateTimeObject date, short calendarField, NumericObject amt)
public static NumericObject getDateTime(DateTimeObject date, short calendarField)
public static NumericObject getDayDifference(DateTimeObject date1, DateTimeObject date2)
public static StringObject getDayOfWeek(DateTimeObject date)
public static StringObject getMonth(DateTimeObject date)
public static StringObject getAmPm(DateTimeObject date)
public static StringObject getERA(DateTimeObject date)
public static StringObject printDateTime(DateTimeObject date)
public static StringObject printDateTime(DateTimeObject date, StringObject pattern)
public static StringObject printTime(DateTimeObject date)
public static StringObject printTime(DateTimeObject date, StringObject pattern)
public static StringObject printDate(DateTimeObject date)
public static StringObject printDate(DateTimeObject date, StringObject pattern)