JolieDoc for Port Time
From file time.iol
| Port Name | Location | Protocol |
|---|---|---|
| Time |
List of the available interfaces
Interface TimeInterface
| Heading | Input type | Output type | Faults |
|---|---|---|---|
| cancelTimeout | long |
bool |
|
| getCurrentDateTime | CurrentDateTimeRequestType |
string |
|
| getCurrentDateValues | void |
DateValuesType |
|
| getCurrentTimeMillis | void |
long |
|
| getDateDiff | DiffDateRequestType |
int |
|
| getDateTime | GetDateTimeRequest |
GetDateTimeResponse |
|
| getDateTimeValues | GetTimestampFromStringRequest |
DateTimeType |
InvalidDate, |
| getDateValues | DateValuesRequestType |
DateValuesType |
InvalidDate, |
| getTimeDiff | GetTimeDiffRequest |
int |
|
| getTimeFromMilliSeconds | int |
TimeValuesType |
|
| getTimeValues | string |
TimeValuesType |
|
| getTimestampFromString | GetTimestampFromStringRequest |
long |
InvalidTimestamp, |
| scheduleTimeout | ScheduleTimeOutRequest |
long |
InvalidTimeUnit, |
| setNextTimeout | SetNextTimeOutRequest | ||
| setNextTimeoutByDateTime | undefined | ||
| setNextTimeoutByTime | undefined | ||
| sleep | undefined |
undefined |
Operation list
scheduleTimeout( ScheduleTimeOutRequest )( long ) throws InvalidTimeUnit
Schedules a timeout, which can be cancelled using #cancelTimeout from the returned string. Default .timeunit value is MILLISECONDS, .operation default is "timeout".
getDateValues( DateValuesRequestType )( DateValuesType ) throws InvalidDate
Converts an input string into a date expressed by means of
three elements: day, month and year. The request may specify the
date parsing format. See #DateValuesRequestType for details.
getDateTime( GetDateTimeRequest )( GetDateTimeResponse )
It returns a date time in a string format starting from a timestamp
getCurrentTimeMillis( void )( long )
Warning: this is temporary and subject to future change as soon as long is supported by Jolie.
getDateDiff( DiffDateRequestType )( int )
getTimeDiff( GetTimeDiffRequest )( int )
getTimestampFromString( GetTimestampFromStringRequest )( long ) throws InvalidTimestamp
cancelTimeout( long )( bool )
Cancels a timeout from a long-value created from #scheduleTimeout
setNextTimeoutByTime( undefined )
getCurrentDateTime( CurrentDateTimeRequestType )( string )
sleep( undefined )( undefined )
setNextTimeout( SetNextTimeOutRequest )
it sets a timeout whose duration is in milliseconds and it is represented by the root value of the message
When the alarm is triggered a message whose content is defined in .message is sent to operation defined in .operation
( default: timeout )
getTimeFromMilliSeconds( int )( TimeValuesType )
getDateTimeValues( GetTimestampFromStringRequest )( DateTimeType ) throws InvalidDate
setNextTimeoutByDateTime( undefined )
getCurrentDateValues( void )( DateValuesType )
Returns the current date split in three fields: day, month and year
getTimeValues( string )( TimeValuesType )
Message type list
ScheduleTimeOutRequest
type ScheduleTimeOutRequest: int {
.message?: undefined
.operation?: string
.timeunit?: string
}
DateValuesRequestType
type DateValuesRequestType: string {
.format?: string
}
DateValuesType
type DateValuesType: void {
.month: int
.year: int
.day: int
}
GetDateTimeRequest
type GetDateTimeRequest: long {
.format?: string
}
GetDateTimeResponse
type GetDateTimeResponse: string {
.month: int
.hour: int
.year: int
.day: int
.minute: int
.second: int
}
DiffDateRequestType
type DiffDateRequestType: void {
.format?: string
.date2: string
.date1: string
}
GetTimeDiffRequest
type GetTimeDiffRequest: void {
.time1: string
.time2: string
}
GetTimestampFromStringRequest
type GetTimestampFromStringRequest: string {
.format?: string
.language?: string
}
CurrentDateTimeRequestType
type CurrentDateTimeRequestType: void {
.format?: string
}
SetNextTimeOutRequest
type SetNextTimeOutRequest: int {
.message?: undefined
.operation?: string
}
TimeValuesType
type TimeValuesType: void {
.hour: int
.minute: int
.second: int
}
DateTimeType
type DateTimeType: void {
.month: int
.hour: int
.year: int
.day: int
.minute: int
.second: int
}
Type list
undefined
type undefined: undefined