class CSSSnippet in Picture Background Formatter 8
Hierarchy
- class \Drupal\picture_background_formatter\Component\Render\CSSSnippet implements MarkupInterface
Expanded class hierarchy of CSSSnippet
1 file declares its use of CSSSnippet
- PictureBackgroundFormatter.php in src/
Plugin/ Field/ FieldFormatter/ PictureBackgroundFormatter.php
File
- src/
Component/ Render/ CSSSnippet.php, line 7
Namespace
Drupal\picture_background_formatter\Component\RenderView source
class CSSSnippet implements MarkupInterface {
/**
* The string to escape.
*
* @var string
*/
protected $string;
/**
* Constructs an HtmlEscapedText object.
*
* @param $string
* The string to escape. This value will be cast to a string.
*/
public function __construct($string) {
$this->string = (string) $string;
}
/**
* {@inheritdoc}
*/
public function __toString() {
return $this->string;
}
/**
* {@inheritdoc}
*/
public function jsonSerialize() {
return $this
->__toString();
}
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
CSSSnippet:: |
protected | property | The string to escape. | |
CSSSnippet:: |
public | function | ||
CSSSnippet:: |
public | function | Constructs an HtmlEscapedText object. | |
CSSSnippet:: |
public | function |
Returns markup. Overrides MarkupInterface:: |