\phpDocumentor\Descriptor\BuilderAssemblerFactory

Attempts to retrieve an Assembler for the provided criteria.

Summary

Methods
Properties
Constants
register()
registerFallback()
get()
createDefault()
No public properties found
No constants found
No protected methods found
$assemblers
$fallbackAssemblers
N/A
No private methods found
No private properties found
N/A

Properties

$assemblers

$assemblers : \phpDocumentor\Descriptor\Builder\AssemblerMatcher[]

Type

AssemblerMatcher[]

$fallbackAssemblers

$fallbackAssemblers : \phpDocumentor\Descriptor\Builder\AssemblerMatcher[]

Type

AssemblerMatcher[]

Methods

register()

register(\phpDocumentor\Descriptor\Builder\Matcher<object>  $matcher, \phpDocumentor\Descriptor\Builder\AssemblerInterface<\phpDocumentor\Descriptor\Descriptor,object>  $assembler) : void

Registers an assembler instance to this factory.

Parameters

\phpDocumentor\Descriptor\Builder\Matcher $matcher

A callback function accepting the criteria as only parameter and which must return a boolean.

\phpDocumentor\Descriptor\Builder\AssemblerInterface<\phpDocumentor\Descriptor\Descriptor,object> $assembler

An instance of the Assembler that will be returned if the callback returns true with the provided criteria.

registerFallback()

registerFallback(\phpDocumentor\Descriptor\Builder\Matcher<object>  $matcher, \phpDocumentor\Descriptor\Builder\AssemblerInterface<\phpDocumentor\Descriptor\Descriptor,object>  $assembler) : void

Registers an assembler instance to this factory that is to be executed after all other assemblers have been checked.

Parameters

\phpDocumentor\Descriptor\Builder\Matcher $matcher

A callback function accepting the criteria as only parameter and which must return a boolean.

\phpDocumentor\Descriptor\Builder\AssemblerInterface<\phpDocumentor\Descriptor\Descriptor,object> $assembler

An instance of the Assembler that will be returned if the callback returns true with the provided criteria.

get()

get(\phpDocumentor\Descriptor\Builder\TParamInput  $criteria, class-string<\phpDocumentor\Descriptor\Builder\TParamDescriptor>  $type) : \phpDocumentor\Descriptor\Builder\AssemblerInterface<\phpDocumentor\Descriptor\Builder\TParamDescriptor,\phpDocumentor\Descriptor\Builder\TParamInput>|null

Retrieves a matching Assembler based on the provided criteria or null if none was found.

Parameters

\phpDocumentor\Descriptor\Builder\TParamInput $criteria
class-string<\phpDocumentor\Descriptor\Builder\TParamDescriptor> $type

Returns

\phpDocumentor\Descriptor\Builder\AssemblerInterface<\phpDocumentor\Descriptor\Builder\TParamDescriptor,\phpDocumentor\Descriptor\Builder\TParamInput>|null —

createDefault()

createDefault(\phpDocumentor\Reflection\DocBlock\ExampleFinder  $exampleFinder) : self

Parameters

\phpDocumentor\Reflection\DocBlock\ExampleFinder $exampleFinder

Returns

self —