protected function validate()
    {
        $numberSymbols = $this->findSubtypes(Number::class);
        if (sizeof($numberSymbols) != 1) {
            throw new NotFoundException(
                'Error: Expected to contain one number class but found '.sizeof($numberSymbols)
            );
        }

        foreach ($this->symbols as $symbol) {
            if (sizeof($symbol->getIdentifiers()) == 0 and ! is_a($symbol, Number::class)) {
                throw new \LengthException('Error: AbstractSymbol does not have any identifiers');
            }
        }
    }