| 1 | <?php |
||
| 14 | class Statement |
||
| 15 | { |
||
| 16 | |||
| 17 | private $command; |
||
| 18 | private $data; |
||
| 19 | private $file; |
||
| 20 | private $line; |
||
| 21 | |||
| 22 | public function __construct($command, $data = null, $file = null, $line = null) |
||
| 29 | |||
| 30 | public function __toString() |
||
| 37 | |||
| 38 | /** |
||
| 39 | * Get the command part of this statement |
||
| 40 | * @return string single word, without spaces |
||
| 41 | */ |
||
| 42 | public function getCommand() |
||
| 46 | |||
| 47 | /** |
||
| 48 | * Get the data of this statement |
||
| 49 | * @return string may contain spaces |
||
| 50 | */ |
||
| 51 | public function getData() |
||
| 55 | |||
| 56 | /** |
||
| 57 | * Get the file (if available) where this statement was parsed from |
||
| 58 | * @return string|null the full filename or null of from static text |
||
| 59 | */ |
||
| 60 | public function getFile() |
||
| 64 | |||
| 65 | /** |
||
| 66 | * Get the line number where this statement was found |
||
| 67 | * @return int|null the line number |
||
| 68 | */ |
||
| 69 | public function getLine() |
||
| 73 | |||
| 74 | } |
||
| 75 |