Class CustomProvidersFeature

  • All Implemented Interfaces:
    javax.ws.rs.core.Feature

    public class CustomProvidersFeature
    extends java.lang.Object
    implements javax.ws.rs.core.Feature
    Feature to provide the single-line registration of custom providers.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      private java.util.Collection<java.lang.Class<?>> providers  
    • Constructor Summary

      Constructors 
      Constructor Description
      CustomProvidersFeature​(java.util.Collection<java.lang.Class<?>> providers)
      Constructs Feature which is used to register providers as providers in Configuration.
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      boolean configure​(javax.ws.rs.core.FeatureContext context)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • providers

        private final java.util.Collection<java.lang.Class<?>> providers
    • Constructor Detail

      • CustomProvidersFeature

        public CustomProvidersFeature​(java.util.Collection<java.lang.Class<?>> providers)
        Constructs Feature which is used to register providers as providers in Configuration.
        Parameters:
        providers - collection of providers which are going to be registered
    • Method Detail

      • configure

        public boolean configure​(javax.ws.rs.core.FeatureContext context)
        Specified by:
        configure in interface javax.ws.rs.core.Feature