Open Journal Systems
3.3.0
|
Static Public Member Functions | |
static | format ($format, $value) |
static | formatBooleanAsString ($value) |
static | formatDate ($value) |
static | formatDateTime ($value) |
static | formatDateTimeHttp ($value) |
static | formatTime ($value) |
static | formatTimestamp ($value) |
Static Protected Member Functions | |
static | dateFormatter ($dateTime, $format) |
static | getUtcTimeZone () |
Static Protected Attributes | |
static | $utcTimeZone |
JSON Schema formatter class
Definition at line 10 of file SchemaFormatter.php.
|
staticprotected |
Perform the actual DateTime formatting
int | string | \DateTime | $dateTime | Date time value |
string | $format | Format of the result |
InvalidArgumentException |
Definition at line 140 of file SchemaFormatter.php.
Referenced by Guzzle\Service\Description\SchemaFormatter\formatDate(), Guzzle\Service\Description\SchemaFormatter\formatDateTime(), Guzzle\Service\Description\SchemaFormatter\formatDateTimeHttp(), Guzzle\Service\Description\SchemaFormatter\formatTime(), and Guzzle\Service\Description\SchemaFormatter\formatTimestamp().
|
static |
Format a value by a registered format name
string | $format | Registered format used to format the value |
mixed | $value | Value being formatted |
Definition at line 23 of file SchemaFormatter.php.
References Guzzle\Service\Description\SchemaFormatter\formatBooleanAsString(), Guzzle\Service\Description\SchemaFormatter\formatDate(), Guzzle\Service\Description\SchemaFormatter\formatDateTime(), Guzzle\Service\Description\SchemaFormatter\formatDateTimeHttp(), Guzzle\Service\Description\SchemaFormatter\formatTime(), and Guzzle\Service\Description\SchemaFormatter\formatTimestamp().
Referenced by Guzzle\Service\Description\Parameter\filter(), Guzzle\Tests\Service\Description\SchemaFormatterTest\testEnsuresTimestampsAreIntegers(), Guzzle\Tests\Service\Description\SchemaFormatterTest\testFilters(), and Guzzle\Tests\Service\Description\SchemaFormatterTest\testValidatesDateTimeInput().
|
static |
Formats a boolean value as a string
string | integer | bool | $value | Value to convert to a boolean 'true' / 'false' value |
Definition at line 98 of file SchemaFormatter.php.
Referenced by Guzzle\Service\Description\SchemaFormatter\format().
|
static |
Create a YYYY-MM-DD formatted string
string | integer | \DateTime | $value | Date time value |
Definition at line 74 of file SchemaFormatter.php.
References Guzzle\Service\Description\SchemaFormatter\dateFormatter().
Referenced by Guzzle\Service\Description\SchemaFormatter\format().
|
static |
Create a ISO 8601 (YYYY-MM-DDThh:mm:ssZ) formatted date time value in UTC time
string | integer | \DateTime | $value | Date time value |
Definition at line 50 of file SchemaFormatter.php.
References Guzzle\Service\Description\SchemaFormatter\dateFormatter().
Referenced by Guzzle\Service\Description\SchemaFormatter\format().
|
static |
Create an HTTP date (RFC 1123 / RFC 822) formatted UTC date-time string
string | integer | \DateTime | $value | Date time value |
Definition at line 62 of file SchemaFormatter.php.
References Guzzle\Service\Description\SchemaFormatter\dateFormatter().
Referenced by Guzzle\Service\Description\SchemaFormatter\format().
|
static |
Create a hh:mm:ss formatted string
string | integer | \DateTime | $value | Date time value |
Definition at line 86 of file SchemaFormatter.php.
References Guzzle\Service\Description\SchemaFormatter\dateFormatter().
Referenced by Guzzle\Service\Description\SchemaFormatter\format().
|
static |
Return a UNIX timestamp in the UTC timezone
string | integer | \DateTime | $value | Time value |
Definition at line 110 of file SchemaFormatter.php.
References Guzzle\Service\Description\SchemaFormatter\dateFormatter().
Referenced by Guzzle\Service\Description\SchemaFormatter\format().
|
staticprotected |
Get a UTC DateTimeZone object
Definition at line 120 of file SchemaFormatter.php.
References Guzzle\Service\Description\SchemaFormatter\$utcTimeZone.
|
staticprotected |
Definition at line 13 of file SchemaFormatter.php.
Referenced by Guzzle\Service\Description\SchemaFormatter\getUtcTimeZone().