| 1 | <?php |
||
| 7 | class Description |
||
| 8 | { |
||
| 9 | use HasLimit; |
||
| 10 | |||
| 11 | /** |
||
| 12 | * @var string |
||
| 13 | */ |
||
| 14 | protected $content; |
||
| 15 | |||
| 16 | /** |
||
| 17 | * @var int |
||
| 18 | */ |
||
| 19 | protected $maxSize; |
||
| 20 | |||
| 21 | /** |
||
| 22 | * Create a new description instance. |
||
| 23 | * |
||
| 24 | * @param array $config |
||
| 25 | */ |
||
| 26 | public function __construct(array $config = []) |
||
| 30 | |||
| 31 | /** |
||
| 32 | * Init config. |
||
| 33 | * |
||
| 34 | * @param array $config |
||
| 35 | * @return void |
||
| 36 | */ |
||
| 37 | protected function initConfig(array $config) |
||
| 45 | |||
| 46 | public function setMaxSize($size) |
||
| 52 | |||
| 53 | public function getMaxSize() |
||
| 57 | |||
| 58 | public function set($content) |
||
| 64 | |||
| 65 | public function get() |
||
| 73 | |||
| 74 | public function toString() |
||
| 78 | |||
| 79 | public function __toString() |
||
| 83 | } |
||
| 84 |