Méthode | Description | |
---|---|---|
getAttributes ( ) : array | The item’s attributes. | |
getCollection ( ) : string | Gets the collection of the item. e.g: "pages" or "posts". | |
getContent ( $snapshotName = '' ) : string | Get the compiled content. A snapshot is the compiled content at a specific point during the compilation process. "last" snapshot is the most recent compiled content. Binary content cannot have snapshots. | |
getId ( ) : string | A string that uniquely identifies an item. | |
getPath ( $snapshotName = '' ) : string | The item's relative path. e.g: "index.html" or "my-page/index.html". | |
getRelationshipCollection ( ) : Yosymfony\Spress\Core\DataSource\RelationshipCollection | Gets the RelationshipCollection instance associated with this item. | |
getType ( ) : string | Return the type of this item. Values: "item", "layout" or "include". | |
isBinary ( ) : boolean | True if the item is binary; false if it is not. | |
setAttributes ( array $values ) | Set the attributes of this item. | |
setCollection ( string $name ) | Sets the collection of the item. | |
setContent ( $content, $snapshotName ) | Set the compiled content. | |
setPath ( string $value, $snapshotName ) | Set the item's relative path. |
public getAttributes ( ) : array | ||
Résultat | array |
public getCollection ( ) : string | ||
Résultat | string | The name of the collection |
public getContent ( $snapshotName = '' ) : string | ||
$snapshotName | The name of the snapshot. "last" by default | |
Résultat | string | The content or empty-string If the snapshot does not exist |
public getRelationshipCollection ( ) : Yosymfony\Spress\Core\DataSource\RelationshipCollection | ||
Résultat | Yosymfony\Spress\Core\DataSource\RelationshipCollection | A RelationshipCollection instance |
public setAttributes ( array $values ) | ||
$values | array |
public setCollection ( string $name ) | ||
$name | string | The name of the collection |
public setContent ( $content, $snapshotName ) | ||
$content | Mixed The compiled content | |
$snapshotName | The name of the snapshot. The snapshot "last" is not valid |