Record Class OpenApiProcessorConfig
java.lang.Object
java.lang.Record
com.mohamnag.jstatic.plugins.openapi_processor.OpenApiProcessorConfig
Will parse config with root key "open-api-processor".
To override defaults for each component type, define a sub-key with name of that component type as used in OpenAPI
spec. For each component type a
"template"
and a "package"
key might be configured.
See OpenApiProcessor
docs to find out how these values are used.
For example use following to configure template and package for request bodies only:
"open-api-processor":
requestBodies:
template: openapi/req_body
package: dtos.request_bodies
-
Constructor Summary
ConstructorDescriptionOpenApiProcessorConfig
(Map<ComponentType, ComponentConfig> components) Creates an instance of aOpenApiProcessorConfig
record class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecomponents
record component.final boolean
Indicates whether some other object is "equal to" this one.static OpenApiProcessorConfig
getPackageName
(ComponentType componentType) getTemplate
(ComponentType componentType) final int
hashCode()
Returns a hash code value for this object.final String
toString()
Returns a string representation of this record class.
-
Constructor Details
-
OpenApiProcessorConfig
Creates an instance of aOpenApiProcessorConfig
record class.- Parameters:
components
- the value for thecomponents
record component
-
-
Method Details
-
extract
-
getPackageName
-
getTemplate
-
toString
Returns a string representation of this record class. The representation contains the name of the class, followed by the name and value of each of the record components. -
hashCode
public final int hashCode()Returns a hash code value for this object. The value is derived from the hash code of each of the record components. -
equals
Indicates whether some other object is "equal to" this one. The objects are equal if the other object is of the same class and if all the record components are equal. All components in this record class are compared withObjects::equals(Object,Object)
. -
components
Returns the value of thecomponents
record component.- Returns:
- the value of the
components
record component
-