interface Parser (View source)

Parser interface for converting reflection/stub data into domain models

Methods

bool
canParse(T $object)

Check if this parser can handle the given object

mixed
parse(T $object)

Parse an object into a domain model

Details

bool canParse(T $object)

Check if this parser can handle the given object

Parameters

T $object

The object to check

Return Value

bool

True if this parser can parse the object

mixed parse(T $object)

Parse an object into a domain model

Parameters

T $object

The object to parse

Return Value

mixed

The parsed domain model (PHPClass, PHPMethod, PHPFunction, etc.)