Class CodegenOperation


  • public class CodegenOperation
    extends Object
    • Field Detail

      • hasAuthMethods

        public boolean hasAuthMethods
      • hasConsumes

        public boolean hasConsumes
      • hasProduces

        public boolean hasProduces
      • hasParams

        public boolean hasParams
      • hasOptionalParams

        public boolean hasOptionalParams
      • hasRequiredParams

        public boolean hasRequiredParams
      • returnTypeIsPrimitive

        public boolean returnTypeIsPrimitive
      • returnSimpleType

        public boolean returnSimpleType
      • subresourceOperation

        public boolean subresourceOperation
      • isMap

        public boolean isMap
      • isArray

        public boolean isArray
      • isMultipart

        public boolean isMultipart
      • isVoid

        public boolean isVoid
      • hasVersionHeaders

        public boolean hasVersionHeaders
      • hasVersionQueryParams

        public boolean hasVersionQueryParams
      • isResponseBinary

        public boolean isResponseBinary
      • isResponseFile

        public boolean isResponseFile
      • isResponseOptional

        public boolean isResponseOptional
      • hasReference

        public boolean hasReference
      • defaultReturnType

        public boolean defaultReturnType
      • isRestfulIndex

        public boolean isRestfulIndex
      • isRestfulShow

        public boolean isRestfulShow
      • isRestfulCreate

        public boolean isRestfulCreate
      • isRestfulUpdate

        public boolean isRestfulUpdate
      • isRestfulDestroy

        public boolean isRestfulDestroy
      • isRestful

        public boolean isRestful
      • isDeprecated

        public boolean isDeprecated
      • isCallbackRequest

        public boolean isCallbackRequest
      • uniqueItems

        public boolean uniqueItems
      • hasDefaultResponse

        public boolean hasDefaultResponse
      • hasErrorResponseObject

        public boolean hasErrorResponseObject
      • operationId

        public String operationId
      • returnType

        public String returnType
      • returnFormat

        public String returnFormat
      • httpMethod

        public String httpMethod
      • returnBaseType

        public String returnBaseType
      • returnContainer

        public String returnContainer
      • summary

        public String summary
      • unescapedNotes

        public String unescapedNotes
      • baseName

        public String baseName
      • defaultResponse

        public String defaultResponse
      • tags

        public List<io.swagger.v3.oas.models.tags.Tag> tags
      • externalDocs

        public io.swagger.v3.oas.models.ExternalDocumentation externalDocs
      • nickname

        public String nickname
      • operationIdOriginal

        public String operationIdOriginal
      • operationIdLowerCase

        public String operationIdLowerCase
      • operationIdCamelCase

        public String operationIdCamelCase
      • operationIdSnakeCase

        public String operationIdSnakeCase
    • Constructor Detail

      • CodegenOperation

        public CodegenOperation()
    • Method Detail

      • getHasBodyParam

        public boolean getHasBodyParam()
        Check if there's at least one body parameter
        Returns:
        true if body parameter exists, false otherwise
      • getHasQueryParams

        public boolean getHasQueryParams()
        Check if there's at least one query parameter
        Returns:
        true if query parameter exists, false otherwise
      • getHasQueryParamsOrAuth

        public boolean getHasQueryParamsOrAuth()
        Check if there's at least one query parameter or passing API keys in query
        Returns:
        true if query parameter exists or passing API keys in query, false otherwise
      • getHasHeaderParams

        public boolean getHasHeaderParams()
        Check if there's at least one header parameter
        Returns:
        true if header parameter exists, false otherwise
      • getHasPathParams

        public boolean getHasPathParams()
        Check if there's at least one path parameter
        Returns:
        true if path parameter exists, false otherwise
      • getHasFormParams

        public boolean getHasFormParams()
        Check if there's at least one form parameter
        Returns:
        true if any form parameter exists, false otherwise
      • getHasBodyOrFormParams

        public boolean getHasBodyOrFormParams()
        Check if there's at least one body parameter or at least one form parameter
        Returns:
        true if body or form parameter exists, false otherwise
      • getHasCookieParams

        public boolean getHasCookieParams()
        Check if there's at least one form parameter
        Returns:
        true if any cookie parameter exists, false otherwise
      • getHasOptionalParams

        public boolean getHasOptionalParams()
        Check if there's at least one optional parameter
        Returns:
        true if any optional parameter exists, false otherwise
      • getHasRequiredAndNotNullableParams

        public boolean getHasRequiredAndNotNullableParams()
      • getHasNotNullableParams

        public boolean getHasNotNullableParams()
      • getHasRequiredParams

        public boolean getHasRequiredParams()
        Check if there's at least one required parameter
        Returns:
        true if any optional parameter exists, false otherwise
      • getHasResponseHeaders

        public boolean getHasResponseHeaders()
        Check if there's at least one response header
        Returns:
        true if header response exists, false otherwise
      • getHasExamples

        public boolean getHasExamples()
        Check if there's at least one example parameter
        Returns:
        true if examples parameter exists, false otherwise
      • getHasDefaultResponse

        public boolean getHasDefaultResponse()
        Check if there's a default response
        Returns:
        true if responses contain a default response, false otherwise
      • getAllResponsesAreErrors

        public boolean getAllResponsesAreErrors()
      • contentTypeToOperation

        public Map<String,​CodegenOperation> contentTypeToOperation()
        Returns:
        contentTypeToOperation returns a map where the key is the request body content type and the value is the current CodegenOperation this is needed by templates when a different signature is needed for each request body content type
      • getHasVendorExtensions

        public boolean getHasVendorExtensions()
        Check if there's at least one vendor extension
        Returns:
        true if vendor extensions exists, false otherwise
      • isRestfulIndex

        public boolean isRestfulIndex()
        Check if act as Restful index method
        Returns:
        true if act as Restful index method, false otherwise
      • isRestfulShow

        public boolean isRestfulShow()
        Check if act as Restful show method
        Returns:
        true if act as Restful show method, false otherwise
      • isRestfulCreate

        public boolean isRestfulCreate()
        Check if act as Restful create method
        Returns:
        true if act as Restful create method, false otherwise
      • isRestfulUpdate

        public boolean isRestfulUpdate()
        Check if act as Restful update method
        Returns:
        true if act as Restful update method, false otherwise
      • isBodyAllowed

        public boolean isBodyAllowed()
        Check if body param is allowed for the request method
        Returns:
        true request method is PUT, PATCH or POST; false otherwise
      • isRestfulDestroy

        public boolean isRestfulDestroy()
        Check if act as Restful destroy method
        Returns:
        true if act as Restful destroy method, false otherwise
      • isRestful

        public boolean isRestful()
        Check if Restful-style
        Returns:
        true if Restful-style, false otherwise
      • hashCode

        public int hashCode()
        Overrides:
        hashCode in class Object