1 <?php
2 /**
3  * Exception thrown if a parse error occurs
4  *
5  * @license http://www.opensource.org/licenses/mit-license.php The MIT License
6  * @copyright Copyright 2010-2014 PhpCss Team
7  */
8 
9 namespace PhpCss\Exception {
10 
11   use Exception;
12   use PhpCss;
13 
14   /**
15    * Exception thrown if a parse error occurs
16    *
17    * A parse error occurs if certain tokens are expected for further parsing, but
18    * none of them are found on the token stream
19    */
20   abstract class ParserException extends Exception implements PhpCssException {
21 
22     /**
23      * An array of tokens which would have been expected to be found.
24      *
25      * @var array(PhpCss\Scanner\Token)
26      */
27     protected $_expectedTokens = [];
28 
29     public function getExpected(): array {
30       return $this->_expectedTokens;
31     }
32   }
33 }
34