Processors
Interfaces, Classes, Traits and Enums
- AugmentParameters
- Use the parameter->name as keyfield (parameter->parameter) when used as reusable component (openapi->components->parameters).
- AugmentProperties
- Use the property context to extract useful information and inject that into the annotation.
- AugmentSchemas
- Use the Schema context to extract useful information and inject that into the annotation.
- BuildPaths
- Build the openapi->paths using the detected @OA\PathItem and @OA\Operations (like @OA\Get, @OA\Post, etc).
- CleanUnmerged
- DocBlockDescriptions
- This would be detected as summary.
- ExpandClasses
- Iterate over the chain of anchestors of a schema and:
- merge anchestor annotations/methods/properties into the schema if the anchestor doesn't have a schema itself
- inherit from the anchestor if it has a schema (allOf) and stop.
- ExpandInterfaces
- Look at all (direct) interfaces for a schema and:
- merge interfaces annotations/methods into the schema if the interface does not have a schema itself
- inherit from the interface if it has a schema (allOf).
- ExpandTraits
- Look at all (direct) traits for a schema and:
- merge trait annotations/methods/properties into the schema if the trait does not have a schema itself
- inherit from the trait if it has a schema (allOf).
- InheritProperties
- Copy the annotated properties from parent classes;.
- InheritTraits
- MergeIntoComponents
- Merge reusable annotation into @OA\Schemas.
- MergeIntoOpenApi
- Merge all @OA\OpenApi annotations into one.
- MergeJsonContent
- Split JsonContent into Schema and MediaType.
- MergeTraits
- MergeXmlContent
- Split XmlContent into Schema and MediaType.
- OperationId
- Generate the OperationId based on the context of the OpenApi annotation.
- MergeTrait
- Steps:
1. Determine direct parent / interfaces / traits
2. With each:
- traverse up inheritance tree
- inherit from first with schema; all other with scheme can be ignored
- merge from all without schema
=> update all $ref that might reference a property merged.