35 private ?
string $url = null;
57 public function __construct(
string $url,
int $width = null,
int $height = null)
71 $image = new \stdClass();
73 if (!is_null($this->width)) {
76 if (!is_null($this->height)) {
90 $image = new \stdClass();
92 if (!is_null($this->width)) {
95 if (!is_null($this->height)) {
112 if (is_object($item)) {
114 foreach (get_object_vars($item) as
$name => $value) {
This file is part of ILIAS, a powerful learning management system published by ILIAS open source e-Le...
Class to represent a content-item image object.
int $width
Width of image.
__construct(string $url, int $width=null, int $height=null)
Class constructor.
toJsonObject()
Generate the JSON object representation of the image.
toJsonldObject()
Generate the JSON-LD object representation of the image.
static fromJsonObject(object $item)
Generate an Image object from its JSON or JSON-LD representation.
int $height
Height of image.