public function parse($input, $context = '')
    {
        $pos = $this->findInitialTokenPosition($input);
        if ($pos === null) {
            return [];
        }

        $this->context = $context;

        $this->lexer->setInput(trim(substr($input, $pos), '* /'));
        $this->lexer->moveNext();

        return $this->Annotations();
    }
public function parse($input, $context = '')
    {
        $pos = $this->findInitialTokenPosition($input);
        if ($pos === null) {
            return [];
        }

        $this->context = $context;

        $this->lexer->setInput(trim(substr($input, $pos), '* /'));
        $this->lexer->moveNext();

        return $this->Annotations();
    }
public function parse ( $ input , $ context = '' ) { $ pos = $ this -> findInitialTokenPosition ( $ input ) ; if ( $ pos === null ) { return [ ] ; } $ this -> context = $ context ; $ this -> lexer -> setInput ( trim ( substr ( $ input , $ pos ) , '* /' ) ) ; $ this -> lexer -> moveNext ( ) ; return $ this -> Annotations ( ) ; }
Parses the given docblock string for annotations.

@param string $input   The docblock string to parse.
@param string $context The parsing context.

@return array Array of annotations. If no annotations are found, an empty array is returned.
Parses the given docblock string for annotations .