Date Methods
Use Primavera Cloud supported date methods to manipulate date data.
Refer to the official Java documentation for more information on each method.
Notes:
- Primavera Cloud Expression Language automatically converts Doubles to Int types when calling methods that require Int arguments.
- Types are indicated in bold in each method signature.
Date Methods
Method Signature | Description | Parameters | Example |
---|---|---|---|
| Returns a Boolean value indicating whether the Date calling the after method occurs after the Date passed as an argument. | Date when - Date to compare against. |
|
| Returns a Boolean value indicating whether the Date calling the before method occurs before the Date passed as an argument. | Date when - Date to compare against. |
|
| Compares the value of the Date passed as an argument to the Date calling the compareTo method. Returns a 0 if the dates are equal, less than 0 if the Date calling the compareTo method occurs before the argument, and greater than 0 if the Date calling the compareTo method occurs after the argument. | Date anotherDate - Date to compare against. |
|
| Checks if the Date calling the equals method is equivalent to the Date passed as an argument. Dates are equivalent if they represent the same point in time to the millisecond. Returns true if the Dates are equal and returns false otherwise. | Date anotherDate - Date value to compare against. |
|
| Returns a value between 1 and 31 representing the day of the Date calling the getDate method. | No method parameters. |
|
| Returns the value of the Date calling the getTime method represented as the number of milliseconds since January 1, 1970, 00:00:00 GMT. | No method parameters. |
|
| Returns a hash code representing the Date calling the hashCode method. | No method parameters. |
|
Additional Date Methods
Method Signature | Description | Parameters | Example |
---|---|---|---|
| Returns a value between 0 and 23 representing the hours of the Date calling this method. | No method parameters. |
|
| Returns a value between 0 and 59 representing the minutes of the Date calling this method. | No method parameters. |
|
| Returns a value between 0 and 61 representing the minutes of the Date calling this method. | No method parameters. |
|
| Returns the offset between the Date calling this method and UTC represented in minutes. | No method parameters. |
|
| Returns the result of subtracting 1900 from the year contained in the Date calling this method. | No method parameters. |
|
| Returns the result of converting the String passed as an argument to a Date value. | String string - String representation of a date. |
|
| Returns a String representing the Date calling this method in GMT format. | No method parameters. |
|
| Returns a String representing the Date calling this method in an implementation independent form. | No method parameters. |
|
| Returns a String representing the Date calling this method in the form dow mon dd hh:mm:ss zzz yyyy. | No method parameters. |
|
Last Published Tuesday, May 21, 2024