Elgg  Version 5.1
Data.php
Go to the documentation of this file.
1 <?php
2 
3 namespace Elgg\Export;
4 
5 use ArrayObject;
6 use DateTime;
7 
13 abstract class Data extends ArrayObject {
14 
18  public function __construct($input = [], int $flags = ArrayObject::ARRAY_AS_PROPS, string $iterator_class = 'ArrayIterator') {
19  parent::__construct($input, $flags, $iterator_class);
20  }
21 
26  public function getTimeCreated() {
27  if (!$this->time_created) {
28  return null;
29  }
30 
31  return new DateTime($this->time_created);
32  }
33 }
getTimeCreated()
Get time created.
Definition: Data.php:26
$input
Form field view.
Definition: field.php:13
__construct($input=[], int $flags=ArrayObject::ARRAY_AS_PROPS, string $iterator_class= 'ArrayIterator')
{}
Definition: Data.php:18