--- a/server/src/app/Models/DocumentBase.php Fri Oct 07 02:07:34 2016 +0200
+++ b/server/src/app/Models/DocumentBase.php Sun Oct 09 11:44:18 2016 +0200
@@ -28,8 +28,9 @@
private $title = false;
private $lang = null;
private $langResolved = null;
- private $issued = null;
- private $modified = null;
+ private $issued = false;
+ private $modified = false;
+ private $created = false;
public function getProvidedCHO() {
@@ -44,8 +45,9 @@
$this->title = false;
$this->lang = null;
$this->langResolved = null;
- $this->issued = null;
- $this->modified = null;
+ $this->issued = false;
+ $this->modified = false;
+ $this->created = false;
}
public function getId() {
@@ -125,7 +127,7 @@
}
public function getIssued() {
- if(is_null($this->issued)) {
+ if($this->issued === false) {
try {
$this->issued = $this->getProvidedCHO()->getLiteral("<http://purl.org/dc/terms/issued>");
} catch(\Exception $e) {
@@ -140,8 +142,19 @@
return is_null($issued)?null:$issued->getValue();
}
+ public function getCreated() {
+ if($this->created === false) {
+ try {
+ $this->created = $this->getProvidedCHO()->getLiteral("<http://purl.org/dc/terms/created>");
+ } catch(\Exception $e) {
+ $this->created = null;
+ }
+ }
+ return $this->created;
+ }
+
public function getModified() {
- if(is_null($this->modified)) {
+ if($this->modified === false) {
try {
$this->modified = $this->getProvidedCHO()->getLiteral("<http://purl.org/dc/terms/modified>");
if(is_null($this->modified)) {