public function camera() { if (!is_null($this->camera)) { return $this->camera; } // check for valid exif data if (!is_array($this->data)) { return null; } // initialize and return it return $this->camera = new Exif\Camera($this->data); }