Class ResourceMethodConfig

java.lang.Object
org.glassfish.jersey.model.internal.CommonConfig
org.glassfish.jersey.server.model.ResourceMethodConfig
All Implemented Interfaces:
javax.ws.rs.core.Configurable<javax.ws.rs.core.FeatureContext>, javax.ws.rs.core.Configuration, javax.ws.rs.core.FeatureContext, ExtendedConfig

class ResourceMethodConfig extends CommonConfig
Default configuration for resource methods. The only allowed contract types for this configuration are:
  • ContainerRequestFilter
  • ContainerResponseFilter
  • ReaderInterceptor
  • WriterInterceptor
  • Field Details

    • LOGGER

      private static final Logger LOGGER
    • allowedContracts

      private static final Set<Class<?>> allowedContracts
  • Constructor Details

    • ResourceMethodConfig

      ResourceMethodConfig(Map<String,Object> properties)
      Create new resource method runtime configuration.
      Parameters:
      properties - inherited properties.
  • Method Details

    • getModelEnhancer

      protected Inflector<ContractProvider.Builder,ContractProvider> getModelEnhancer(Class<?> providerClass)
      Description copied from class: CommonConfig
      An extension point that provides a way how to define a custom enhancement/update operation of a contract provider model registration being produced for a given component class. Default implementation return an enhancer just builds the model.

      Derived implementations may use this method to e.g. filter out all contracts not applicable in the given configuration context or change the model scope. The returned set of filtered contracts is then used for the actual provider registration.

      Overrides:
      getModelEnhancer in class CommonConfig
      Parameters:
      providerClass - class of the component being registered.
      Returns:
      filter for the contracts that being registered for a given component class.