Class DocumentationRestResourceClasses

java.lang.Object
org.graylog2.shared.plugins.DocumentationRestResourceClasses

public class DocumentationRestResourceClasses extends Object
This class provides access to the system and plugin API resources that are available through the Guice multi-binder. We need this wrapper class to be able to inject the Set<Class<? extends PluginRestResource>> and the named system resources into a Jersey REST resource. HK2 does not allow to inject this directly into the resource class.
  • Constructor Details

    • DocumentationRestResourceClasses

      @Inject public DocumentationRestResourceClasses(Map<String,Set<Class<? extends PluginRestResource>>> pluginRestResources, @Named("systemRestResources") Set<Class<?>> systemResources)
  • Method Details

    • getPluginResourcesMap

      public Map<String,Set<Class<? extends PluginRestResource>>> getPluginResourcesMap()
      Returns a map of plugin package names to Sets of PluginRestResource classes.
      Returns:
      the map
    • getSystemResources

      public Set<Class<?>> getSystemResources()
      Returns all system resources.
      Returns:
      the set of system resource classes