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
ConstructorsConstructorDescriptionOpenApiProcessorConfig(Map<ComponentType, ComponentConfig> components) Creates an instance of aOpenApiProcessorConfigrecord class. -
Method Summary
Modifier and TypeMethodDescriptionReturns the value of thecomponentsrecord component.final booleanIndicates whether some other object is "equal to" this one.static OpenApiProcessorConfiggetPackageName(ComponentType componentType) getTemplate(ComponentType componentType) final inthashCode()Returns a hash code value for this object.final StringtoString()Returns a string representation of this record class.
-
Constructor Details
-
OpenApiProcessorConfig
Creates an instance of aOpenApiProcessorConfigrecord class.- Parameters:
components- the value for thecomponentsrecord 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 thecomponentsrecord component.- Returns:
- the value of the
componentsrecord component
-