%dw 2.0
import * from dw::util::Coercions
output application/dw
---
{
a: toTime("23:57:59Z"),
b: toTime("13:44:12.283-08:00","HH:mm:ss.nxxx")
}
toTime
toTime(str: String, format: String | Null = null, locale: String | Null = null): Time
Transforms a String
value into a Time
value
and accepts a format and locale.
Introduced in DataWeave version 2.4.0.
Parameters
Name | Description |
---|---|
|
The |
|
The formatting to use on the |
|
Optional ISO 3166 country code to use, such as |