Mercurial > hg > isophonics-drupal-site
annotate vendor/sebastian/diff/src/Line.php @ 12:7a779792577d
Update Drupal core to v8.4.5 (via Composer)
author | Chris Cannam |
---|---|
date | Fri, 23 Feb 2018 15:52:07 +0000 |
parents | 4c8ae668cc8c |
children | 1fec387a4317 |
rev | line source |
---|---|
Chris@0 | 1 <?php |
Chris@0 | 2 /* |
Chris@12 | 3 * This file is part of sebastian/diff. |
Chris@0 | 4 * |
Chris@0 | 5 * (c) Sebastian Bergmann <sebastian@phpunit.de> |
Chris@0 | 6 * |
Chris@0 | 7 * For the full copyright and license information, please view the LICENSE |
Chris@0 | 8 * file that was distributed with this source code. |
Chris@0 | 9 */ |
Chris@0 | 10 |
Chris@0 | 11 namespace SebastianBergmann\Diff; |
Chris@0 | 12 |
Chris@0 | 13 class Line |
Chris@0 | 14 { |
Chris@0 | 15 const ADDED = 1; |
Chris@0 | 16 const REMOVED = 2; |
Chris@0 | 17 const UNCHANGED = 3; |
Chris@0 | 18 |
Chris@0 | 19 /** |
Chris@0 | 20 * @var int |
Chris@0 | 21 */ |
Chris@0 | 22 private $type; |
Chris@0 | 23 |
Chris@0 | 24 /** |
Chris@0 | 25 * @var string |
Chris@0 | 26 */ |
Chris@0 | 27 private $content; |
Chris@0 | 28 |
Chris@0 | 29 /** |
Chris@0 | 30 * @param int $type |
Chris@0 | 31 * @param string $content |
Chris@0 | 32 */ |
Chris@0 | 33 public function __construct($type = self::UNCHANGED, $content = '') |
Chris@0 | 34 { |
Chris@0 | 35 $this->type = $type; |
Chris@0 | 36 $this->content = $content; |
Chris@0 | 37 } |
Chris@0 | 38 |
Chris@0 | 39 /** |
Chris@0 | 40 * @return string |
Chris@0 | 41 */ |
Chris@0 | 42 public function getContent() |
Chris@0 | 43 { |
Chris@0 | 44 return $this->content; |
Chris@0 | 45 } |
Chris@0 | 46 |
Chris@0 | 47 /** |
Chris@0 | 48 * @return int |
Chris@0 | 49 */ |
Chris@0 | 50 public function getType() |
Chris@0 | 51 { |
Chris@0 | 52 return $this->type; |
Chris@0 | 53 } |
Chris@0 | 54 } |