TagManager
extends PrototypeClassFactory
in package
This class is used in DocBlockGenerator and creates the needed Tag classes depending on the tag. So for example an @author tag will trigger the creation of an AuthorTag class.
If none of the classes is applicable, the GenericTag class will be created
Table of Contents
- $genericPrototype : PrototypeGenericInterface
- $prototypes : array<string|int, mixed>
- __construct() : mixed
- addPrototype() : mixed
- createTagFromReflection() : TagInterface
- getClonedPrototype() : PrototypeInterface
- hasPrototype() : bool
- initializeDefaultTags() : void
- setGenericPrototype() : mixed
- normalizeName() : string
Properties
$genericPrototype
protected
PrototypeGenericInterface
$genericPrototype
$prototypes
protected
array<string|int, mixed>
$prototypes
= []
Methods
__construct()
public
__construct([array<string|int, PrototypeInterface> $prototypes = [] ][, PrototypeGenericInterface $genericPrototype = null ]) : mixed
Parameters
- $prototypes : array<string|int, PrototypeInterface> = []
- $genericPrototype : PrototypeGenericInterface = null
Return values
mixed —addPrototype()
public
addPrototype(PrototypeInterface $prototype) : mixed
Parameters
- $prototype : PrototypeInterface
Tags
Return values
mixed —createTagFromReflection()
public
createTagFromReflection(TagInterface $reflectionTag) : TagInterface
Parameters
- $reflectionTag : TagInterface
Return values
TagInterface —getClonedPrototype()
public
getClonedPrototype(string $prototypeName) : PrototypeInterface
Parameters
- $prototypeName : string
Tags
Return values
PrototypeInterface —hasPrototype()
public
hasPrototype(string $name) : bool
Parameters
- $name : string
Return values
bool —initializeDefaultTags()
public
initializeDefaultTags() : void
Return values
void —setGenericPrototype()
public
setGenericPrototype(PrototypeGenericInterface $prototype) : mixed
Parameters
- $prototype : PrototypeGenericInterface
Tags
Return values
mixed —normalizeName()
protected
normalizeName(string $name) : string
Parameters
- $name : string