Date Type of CFPropertyList Note: CFDate uses Unix timestamp (epoch) to store dates internally.
More...
|
static | dateValue ($val) |
| Create a UNIX timestamp from a PList date string.
|
|
|
const | DATE_DIFF_APPLE_UNIX = 978307200 |
|
const | TIMESTAMP_APPLE = 0 |
|
const | TIMESTAMP_UNIX = 1 |
|
Date Type of CFPropertyList Note: CFDate uses Unix timestamp (epoch) to store dates internally.
◆ __construct()
CFDate::__construct |
( |
| $value, |
|
|
| $format = CFDate::TIMESTAMP_UNIX ) |
◆ dateValue()
static CFDate::dateValue |
( |
| $val | ) |
|
|
static |
Create a UNIX timestamp from a PList date string.
- Parameters
-
string | $val | The date string (e.g. "2009-05-13T20:23:43Z") |
- Return values
-
integer | The UNIX timestamp |
- Exceptions
-
◆ getValue()
CFDate::getValue |
( |
| $format = CFDate::TIMESTAMP_UNIX | ) |
|
Get the Date CFType's value.
- Parameters
-
- Return values
-
integer | Unix timestamp @uses TIMESTAMP_APPLE to determine timestamp type @uses TIMESTAMP_UNIX to determine timestamp type @uses DATE_DIFF_APPLE_UNIX to convert Unix-timestamp to Apple-timestamp |
◆ setValue()
CFDate::setValue |
( |
| $value, |
|
|
| $format = CFDate::TIMESTAMP_UNIX ) |
Set the Date CFType's value.
- Parameters
-
- Return values
-
void | @uses TIMESTAMP_APPLE to determine timestamp type @uses TIMESTAMP_UNIX to determine timestamp type @uses DATE_DIFF_APPLE_UNIX to convert Apple-timestamp to Unix-timestamp |
◆ toBinary()
convert value to binary representation
- Parameters
-
- Return values
-
The | offset in the object table |
◆ toXML()
CFDate::toXML |
( |
DOMDocument | $doc, |
|
|
| $nodeName = "" ) |
Get XML-Node.
- Parameters
-
DOMDocument | $doc | DOMDocument to create DOMNode in |
string | $nodeName | For compatibility reasons; just ignore it |
- Return values
-
The documentation for this class was generated from the following file:
- lib/plist/classes/CFPropertyList/CFDate.php