daux.io/libs/Tree/Content.php

30 lines
487 B
PHP
Raw Normal View History

<?php namespace Todaymade\Daux\Tree;
2015-04-23 00:32:30 +02:00
class Content extends Entry
{
2015-07-17 23:38:06 +02:00
/**
* @var string
*/
protected $content;
2015-07-17 23:38:06 +02:00
/**
* @return string
*/
public function getContent()
{
if (!$this->content) {
$this->content = file_get_contents($this->getPath());
}
return $this->content;
}
/**
* @param string $content
*/
public function setContent($content)
{
$this->content = $content;
}
}