Class ServletReaderExtension

    • Constructor Detail

      • ServletReaderExtension

        public ServletReaderExtension()
    • Method Detail

      • getPriority

        public int getPriority()
        Description copied from interface: ReaderExtension
        Returns this extension's priority. Note: Extension will be executed first with lowest priority.
        Specified by:
        getPriority in interface ReaderExtension
        Returns:
        this extension's priority
      • isReadable

        public boolean isReadable​(ReaderContext context)
        Description copied from interface: ReaderExtension
        Checks that a resource should be scanned.
        Specified by:
        isReadable in interface ReaderExtension
        Parameters:
        context - is the resource context
        Returns:
        true if the resource needs to be scanned, otherwise false
      • applyConsumes

        public void applyConsumes​(ReaderContext context,
                                  io.swagger.models.Operation operation,
                                  Method method)
        Description copied from interface: ReaderExtension
        Reads the consumes from the method's annotations and applies these to the operation.
        Specified by:
        applyConsumes in interface ReaderExtension
        Parameters:
        context - is the resource context
        operation - is the container for the operation data
        method - is the method for reading annotations
      • applyProduces

        public void applyProduces​(ReaderContext context,
                                  io.swagger.models.Operation operation,
                                  Method method)
        Description copied from interface: ReaderExtension
        Reads the produces from the method's annotations and applies these to the operation.
        Specified by:
        applyProduces in interface ReaderExtension
        Parameters:
        context - is the resource context
        operation - is the container for the operation data
        method - is the method for reading annotations
      • getPath

        public String getPath​(ReaderContext context,
                              Method method)
        Description copied from interface: ReaderExtension
        Returns operation's path.
        Specified by:
        getPath in interface ReaderExtension
        Parameters:
        context - is the resource context
        method - is the method for reading annotations
        Returns:
        operation's path
      • applyOperationId

        public void applyOperationId​(io.swagger.models.Operation operation,
                                     Method method)
        Description copied from interface: ReaderExtension
        Reads the operation id from the method's annotations and applies it to the operation.
        Specified by:
        applyOperationId in interface ReaderExtension
        Parameters:
        operation - is the container for the operation data
        method - is the method for reading annotations
      • applySummary

        public void applySummary​(io.swagger.models.Operation operation,
                                 Method method)
        Description copied from interface: ReaderExtension
        Reads the summary from the method's annotations and applies it to the operation.
        Specified by:
        applySummary in interface ReaderExtension
        Parameters:
        operation - is the container for the operation data
        method - is the method for reading annotations
      • applyDescription

        public void applyDescription​(io.swagger.models.Operation operation,
                                     Method method)
        Description copied from interface: ReaderExtension
        Reads the description from the method's annotations and applies it to the operation.
        Specified by:
        applyDescription in interface ReaderExtension
        Parameters:
        operation - is the container for the operation data
        method - is the method for reading annotations
      • applySchemes

        public void applySchemes​(ReaderContext context,
                                 io.swagger.models.Operation operation,
                                 Method method)
        Description copied from interface: ReaderExtension
        Reads the schemes from the method's annotations and applies these to the operation.
        Specified by:
        applySchemes in interface ReaderExtension
        Parameters:
        context - is the resource context
        operation - is the container for the operation data
        method - is the method for reading annotations
      • setDeprecated

        public void setDeprecated​(io.swagger.models.Operation operation,
                                  Method method)
        Description copied from interface: ReaderExtension
        Sets the deprecated flag to the operation.
        Specified by:
        setDeprecated in interface ReaderExtension
        Parameters:
        operation - is the container for the operation data
        method - is the method for reading annotations
      • applySecurityRequirements

        public void applySecurityRequirements​(ReaderContext context,
                                              io.swagger.models.Operation operation,
                                              Method method)
        Description copied from interface: ReaderExtension
        Reads the security requirement from the method's annotations and applies these to the operation.
        Specified by:
        applySecurityRequirements in interface ReaderExtension
        Parameters:
        context - is the resource context
        operation - is the container for the operation data
        method - is the method for reading annotations
      • applyTags

        public void applyTags​(ReaderContext context,
                              io.swagger.models.Operation operation,
                              Method method)
        Description copied from interface: ReaderExtension
        Reads the tags from the method's annotations and applies these to the operation.
        Specified by:
        applyTags in interface ReaderExtension
        Parameters:
        context - is the resource context
        operation - is the container for the operation data
        method - is the method for reading annotations
      • applyResponses

        public void applyResponses​(ReaderContext context,
                                   io.swagger.models.Operation operation,
                                   Method method)
        Description copied from interface: ReaderExtension
        Reads the responses from the method's annotations and applies these to the operation.
        Specified by:
        applyResponses in interface ReaderExtension
        Parameters:
        context - is the resource context
        operation - is the container for the operation data
        method - is the method for reading annotations
      • applyParameters

        public void applyParameters​(ReaderContext context,
                                    io.swagger.models.Operation operation,
                                    Type type,
                                    Annotation[] annotations)
        Description copied from interface: ReaderExtension
        Reads the parameters from the method's annotations and applies these to the operation.
        Specified by:
        applyParameters in interface ReaderExtension
        Parameters:
        context - is the resource context
        operation - is the container for the operation data
        type - is the type of parameter
        annotations - are the method's annotations
      • applyImplicitParameters

        public void applyImplicitParameters​(ReaderContext context,
                                            io.swagger.models.Operation operation,
                                            Method method)
        Description copied from interface: ReaderExtension
        Reads the implicit parameters from the method's annotations and applies these to the operation.
        Specified by:
        applyImplicitParameters in interface ReaderExtension
        Parameters:
        context - is the resource context
        operation - is the container for the operation data
        method - is the method for reading annotations
      • applyExtensions

        public void applyExtensions​(ReaderContext context,
                                    io.swagger.models.Operation operation,
                                    Method method)
        Description copied from interface: ReaderExtension
        Reads the extensions from the method's annotations and applies these to the operation.
        Specified by:
        applyExtensions in interface ReaderExtension
        Parameters:
        context - is the resource context
        operation - is the container for the operation data
        method - is the method for reading annotations