Class AbstractAnnotationScanner
java.lang.Object
io.smallrye.openapi.runtime.scanner.spi.AbstractAnnotationScanner
- All Implemented Interfaces:
AnnotationScanner
Abstract base class for annotation scanners
- Author:
- Phillip Kruger ([email protected])
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected static String
createPathFromSegments
(String... segments) Make a path out of a number of path segments.String[]
getDefaultConsumes
(AnnotationScannerContext context, org.jboss.jandex.MethodInfo methodInfo, ResourceParameters params) String[]
getDefaultProduces
(AnnotationScannerContext context, org.jboss.jandex.MethodInfo methodInfo) protected String
protected static boolean
processProfiles
(OpenApiConfig config, org.eclipse.microprofile.openapi.models.Extensible<?> extensible) Checks if the given extensible contains profiles, and if the extensible should be included in the final openapi document.void
setContextRoot
(String path) Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
Methods inherited from interface io.smallrye.openapi.runtime.scanner.spi.AnnotationScanner
addApiReponseSchemaFromAnnotation, addResponses, clearJsonViewContext, containsScannerAnnotations, createResponseFromRestMethod, generateResponse, getConsumes, getConsumesForRequestBody, getDefaultStatus, getKotlinContinuationArgument, getName, getReasonPhrase, getRequestBodyParameterClassType, getResourceMethods, hasKotlinContinuation, isAsyncResponse, isDeleteMethod, isEmptySecurityRequirements, isFrameworkContextType, isKotlinContinuation, isMultipartInput, isMultipartOutput, isPathParameter, isPostMethod, isScannerInternalParameter, isScannerInternalResponse, isScannerInternalResponse, isVoidResponse, isVoidType, isWrapperType, kotlinContinuationToSchema, processCallback, processDefinitionAnnotation, processExtensions, processJavaSecurity, processOperation, processOperationTags, processRequestBody, processResponse, processScannerExtensions, processSecurityRequirementAnnotation, processSecuritySchemeAnnotation, processServerAnnotation, processServerAnnotation, processTags, scan, setJsonViewContext, setRequestBodyConstraints, unwrapType
-
Field Details
-
context
-
currentAppPath
-
-
Constructor Details
-
AbstractAnnotationScanner
public AbstractAnnotationScanner()
-
-
Method Details
-
setContextRoot
- Specified by:
setContextRoot
in interfaceAnnotationScanner
-
makePaths
-
makePath
-
createPathFromSegments
Make a path out of a number of path segments.- Parameters:
segments
- String paths- Returns:
- Path built from the segments
-
processProfiles
protected static boolean processProfiles(OpenApiConfig config, org.eclipse.microprofile.openapi.models.Extensible<?> extensible) Checks if the given extensible contains profiles, and if the extensible should be included in the final openapi document. Any extension containing a profile is removed from the extensible. inclusion is then calculated based on all collected profiles.- Parameters:
config
- current configextensible
- the extensible to check for profiles- Returns:
- true, if the given extensible should be included in the final openapi document, otherwise false
-
getDefaultConsumes
public String[] getDefaultConsumes(AnnotationScannerContext context, org.jboss.jandex.MethodInfo methodInfo, ResourceParameters params) - Specified by:
getDefaultConsumes
in interfaceAnnotationScanner
-
getDefaultProduces
public String[] getDefaultProduces(AnnotationScannerContext context, org.jboss.jandex.MethodInfo methodInfo) - Specified by:
getDefaultProduces
in interfaceAnnotationScanner
-