interface AmpPrepareMetadataJsonInterface in Accelerated Mobile Pages (AMP) 8
Provides an interface for preparing AMP Metadata JSON.
Hierarchy
- interface \Drupal\amp\AmpPrepareMetadataJsonInterface
Expanded class hierarchy of AmpPrepareMetadataJsonInterface
All classes that implement AmpPrepareMetadataJsonInterface
1 file declares its use of AmpPrepareMetadataJsonInterface
- AmpPrepareMetadataJson.php in src/
Utility/ AmpPrepareMetadataJson.php
File
- src/
AmpPrepareMetadataJsonInterface.php, line 10
Namespace
Drupal\ampView source
interface AmpPrepareMetadataJsonInterface {
/**
* Gets the encoded AMP metadata JSON.
*
* @param array $amp_metadata_settings
* The array containing AMP metadata settings.
* @param string $canonical_url
* The canonical url for this node.
* @param NodeInterface $node
* The node object.
*
* @return string
* A JSON encoded string on success or FALSE on failure.
*/
public function getJson(array $amp_metadata_settings, $canonical_url, NodeInterface $node);
/**
* Gets the array containing metadata ready to be converted to JSON.
*/
public function getPreparedMetadataJson();
/**
* Allows additions or changes to metadata ready to be converted to JSON.
*
* @param array $prepared_metadata
*/
public function setPreparedMetadataJson($prepared_metadata);
/**
* Get the list of metadata items.
*/
public function getAmpMetadataList();
/**
* Sets the list of metadata items.
*/
public function setAmpMetadataList();
}
Members
Name | Modifiers | Type | Description | Overrides |
---|---|---|---|---|
AmpPrepareMetadataJsonInterface:: |
public | function | Get the list of metadata items. | 1 |
AmpPrepareMetadataJsonInterface:: |
public | function | Gets the encoded AMP metadata JSON. | 1 |
AmpPrepareMetadataJsonInterface:: |
public | function | Gets the array containing metadata ready to be converted to JSON. | 1 |
AmpPrepareMetadataJsonInterface:: |
public | function | Sets the list of metadata items. | 1 |
AmpPrepareMetadataJsonInterface:: |
public | function | Allows additions or changes to metadata ready to be converted to JSON. | 1 |