The custom C1Date object
The C1Date object is defined only for Oracle Clinical One Platform and supports both full and partial dates.
Since this is a custom class, you need to know specific details about
its constructors and methods. This information allows you to use
C1Date objects to properly handle partial dates.
Constructors
The
C1Date object has two possible
constructors:C1Date(date, day, month, year)C1Date (date, day, month, year, hour, minute, second)These two possible constructors use the following object parameters:
| Parameter | Description |
|---|---|
date |
Takes a JavaScript Date object
(full date).
Note: When adate is provided, following
parameters are not needed.
|
day |
Takes a numeric value for the day of the date. |
month |
Takes a numeric value for the month of the date. |
year |
Takes a 4-digit numeric value for the year of the date (yyyy). |
hour |
Takes a numeric value for the hours time element. |
minute |
Takes a numeric value for the minutes time elemnt. |
second |
Takes a numeric value for the seconds time element. |
Methods
The
C1Date class has the following methods:
| Method | Description |
|---|---|
isPartialDate() |
Returns true for partial dates
or false for full dates.
|
getDate() |
Returns a JavaScript Date
object, or null.
|
getDay() |
Returns the numeric value of the day,
null or UNK.
|
getMonth() |
Returns the numeric value of the month,
null or UNK.
|
getYear() |
Returns the 4-digit value of the year,
null or UNK.
|
getHour() |
Returns the numeric value of the hours time
element, null or UNK.
|
getMinute() |
Returns the numeric value of the minutes time
element, null or UNK.
|
getSecond() |
Returns the numeric value of the seconds time
element, null or UNK.
|
Parent topic: Handle partial dates in custom rules