PHP Class Yosymfony\Spress\Core\Plugin\Event\ContentEvent

Used with events: - "spress.before_convert". - "spress.after_convert".
Author: Victor Puertas ([email protected])
Inheritance: extends Symfony\Component\EventDispatcher\Event
Mostrar archivo Open project: spress/spress Class Usage Examples

Protected Properties

Property Type Description
$defaultSnapshotContent
$defaultSnapshotPath
$item

Public Methods

Method Description
__construct ( Yosymfony\Spress\Core\DataSource\ItemInterface $item, string $defaultSnapshotContent, string $defaultSnapshotPath ) Constructor.
getAttributes ( ) : array Gets the attributes of the item.
getContent ( ) : string Gets the content.
getId ( ) : string Gets the item identifier.
getItem ( ) : Yosymfony\Spress\Core\DataSource\ItemInterface Gets the item.
setAttributes ( array $attributes ) Sets the attributes of the item.
setContent ( string $content ) Sets the content (without Front-matter).

Method Details

__construct() public method

Constructor.
public __construct ( Yosymfony\Spress\Core\DataSource\ItemInterface $item, string $defaultSnapshotContent, string $defaultSnapshotPath )
$item Yosymfony\Spress\Core\DataSource\ItemInterface
$defaultSnapshotContent string The name of the defatul snapshot for content
$defaultSnapshotPath string The name of the defatul snapshot for path

getAttributes() public method

Gets the attributes of the item.
public getAttributes ( ) : array
return array

getContent() public method

Gets the content.
public getContent ( ) : string
return string

getId() public method

Gets the item identifier.
public getId ( ) : string
return string

getItem() public method

Gets the item.
public getItem ( ) : Yosymfony\Spress\Core\DataSource\ItemInterface
return Yosymfony\Spress\Core\DataSource\ItemInterface

setAttributes() public method

Sets the attributes of the item.
public setAttributes ( array $attributes )
$attributes array

setContent() public method

Sets the content (without Front-matter).
public setContent ( string $content )
$content string

Property Details

$defaultSnapshotContent protected_oe property

protected $defaultSnapshotContent

$defaultSnapshotPath protected_oe property

protected $defaultSnapshotPath

$item protected_oe property

protected $item