| @@ 188-197 (lines=10) @@ | ||
| 185 | * |
|
| 186 | * @throws NodeException If row with specified index does not exist |
|
| 187 | */ |
|
| 188 | public function getRow($index) |
|
| 189 | { |
|
| 190 | $rows = $this->getRows(); |
|
| 191 | ||
| 192 | if (!isset($rows[$index])) { |
|
| 193 | throw new NodeException(sprintf('Rows #%d does not exist in table.', $index)); |
|
| 194 | } |
|
| 195 | ||
| 196 | return $rows[$index]; |
|
| 197 | } |
|
| 198 | ||
| 199 | /** |
|
| 200 | * Returns specific column in a table. |
|
| @@ 233-242 (lines=10) @@ | ||
| 230 | * |
|
| 231 | * @throws NodeException If row with specified index does not exist |
|
| 232 | */ |
|
| 233 | public function getRowLine($index) |
|
| 234 | { |
|
| 235 | $lines = array_keys($this->table); |
|
| 236 | ||
| 237 | if (!isset($lines[$index])) { |
|
| 238 | throw new NodeException(sprintf('Rows #%d does not exist in table.', $index)); |
|
| 239 | } |
|
| 240 | ||
| 241 | return $lines[$index]; |
|
| 242 | } |
|
| 243 | ||
| 244 | /** |
|
| 245 | * Converts row into delimited string. |
|