ControllerTagGenerator
extends AbstractTagGenerator
in package
AbstractTagGenerator
Table of Contents
Properties
- $className : string
- The current class we are working with
- $existingTags : array<string|int, Tag>
- The existing tags of the class we are working with
- $pageClassesCache : mixed
- $reflector : ReflectionClass
- $tagFactory : StandardTagFactory
- $tags : array<string|int, Tag>
- List all the generated tags form the various generateSomeORMProperies methods
Methods
- __construct() : mixed
- ControllerTagGenerator constructor.
- getExistingTagCommentByTagString() : string
- getExistingTags() : array<string|int, Tag>
- getSupportedTagTypes() : array<string|int, mixed>
- List of supported tags.
- getTags() : array<string|int, Tag>
- generateControllerObjectTags() : mixed
- Generate the controller tags, these differ slightly from the standard ORM tags
- generateExtensionsTags() : mixed
- Generate the mixins for DataExtensions.
- generateOwnerTags() : mixed
- Generate the Owner-properties for extensions.
- generateTags() : void
- getAnnotationClassName() : string
- Check if we need to use the short name for a class
- getClassConfig() : mixed
- getOwnerClasses() : array<string|int, string>|Generator
- Get all owner classes of the given extension class
- isContentController() : bool
- mapPageTypesToControllerName() : mixed
- Generates the cache of Page types to Controllers when the controller_name config is used
- pushMethodTag() : mixed
- pushMixinTag() : mixed
- pushPropertyTag() : mixed
- pushTagWithExistingComment() : Tag
Properties
$className
The current class we are working with
protected
string
$className
= ''
$existingTags
The existing tags of the class we are working with
protected
array<string|int, Tag>
$existingTags
= []
$pageClassesCache
protected
static mixed
$pageClassesCache
= []
$reflector
protected
ReflectionClass
$reflector
$tagFactory
protected
StandardTagFactory
$tagFactory
$tags
List all the generated tags form the various generateSomeORMProperies methods
protected
array<string|int, Tag>
$tags
= []
Tags
Methods
__construct()
ControllerTagGenerator constructor.
public
__construct(string $className, $existingTags) : mixed
Parameters
Tags
getExistingTagCommentByTagString()
public
getExistingTagCommentByTagString(string $tagString) : string
Parameters
- $tagString : string
Return values
stringgetExistingTags()
public
getExistingTags() : array<string|int, Tag>
Return values
array<string|int, Tag>getSupportedTagTypes()
List of supported tags.
public
getSupportedTagTypes() : array<string|int, mixed>
Each tag type can hold many tags, so we keep them grouped. Also used to reset the tag list after each run
Return values
array<string|int, mixed>getTags()
public
getTags() : array<string|int, Tag>
Return values
array<string|int, Tag>generateControllerObjectTags()
Generate the controller tags, these differ slightly from the standard ORM tags
protected
generateControllerObjectTags() : mixed
Tags
generateExtensionsTags()
Generate the mixins for DataExtensions.
protected
generateExtensionsTags() : mixed
generateOwnerTags()
Generate the Owner-properties for extensions.
protected
generateOwnerTags() : mixed
Tags
generateTags()
protected
generateTags() : void
Tags
getAnnotationClassName()
Check if we need to use the short name for a class
protected
getAnnotationClassName(string $class) : string
Parameters
- $class : string
Return values
stringgetClassConfig()
protected
getClassConfig( $key) : mixed
Parameters
getOwnerClasses()
Get all owner classes of the given extension class
protected
getOwnerClasses(string $extensionClass) : array<string|int, string>|Generator
Parameters
- $extensionClass : string
-
Class name of the extension
Return values
array<string|int, string>|Generator —List of all direct owners of this extension
isContentController()
protected
isContentController(string $className) : bool
Parameters
- $className : string
Tags
Return values
boolmapPageTypesToControllerName()
Generates the cache of Page types to Controllers when the controller_name config is used
protected
mapPageTypesToControllerName() : mixed
pushMethodTag()
protected
pushMethodTag(string $methodName, string $tagString) : mixed
Parameters
- $methodName : string
- $tagString : string
pushMixinTag()
protected
pushMixinTag( $tagString) : mixed
Parameters
pushPropertyTag()
protected
pushPropertyTag(string $tagString) : mixed
Parameters
- $tagString : string
pushTagWithExistingComment()
protected
pushTagWithExistingComment( $type, $tagString) : Tag