Class PropertyDrivenModule

java.lang.Object
net.shibboleth.profile.module.AbstractModule
net.shibboleth.profile.module.PropertyDrivenModule
All Implemented Interfaces:
Module, Component, IdentifiedComponent

public abstract class PropertyDrivenModule extends AbstractModule implements Module
Implementation of Module relying on Java Properties.
Since:
9.0.0
  • Field Details

    • DEFAULT_RESOURCE

      @Nonnull @NotEmpty public static final String DEFAULT_RESOURCE
      Default name of module properties resource.
      See Also:
    • MODULE_NAME_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_NAME_PROPERTY
      Suffix of property for module name.
      See Also:
    • MODULE_DESC_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_DESC_PROPERTY
      Suffix of property for module description.
      See Also:
    • MODULE_URL_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_URL_PROPERTY
      Suffix of property for module URL.
      See Also:
    • MODULE_PLUGIN_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_PLUGIN_PROPERTY
      Suffix of property for module plugin owner.
      See Also:
    • MODULE_SRC_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_SRC_PROPERTY
      Suffix of property for resource source.
      See Also:
    • MODULE_DEST_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_DEST_PROPERTY
      Suffix of property for resource destination.
      See Also:
    • MODULE_REPLACE_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_REPLACE_PROPERTY
      Suffix of property for resource replacement.
      See Also:
    • MODULE_OPTIONAL_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_OPTIONAL_PROPERTY
      Suffix of property for resource optionality.
      See Also:
    • MODULE_EXEC_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_EXEC_PROPERTY
      Suffix of property for resource executability.
      See Also:
    • MODULE_WINDOWS_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_WINDOWS_PROPERTY
      Suffix of property for resource Windows applicability.
      See Also:
    • MODULE_NONWINDOWS_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_NONWINDOWS_PROPERTY
      Suffix of property for resource non-Windows applicability.
      See Also:
    • MODULE_POSTENABLE_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_POSTENABLE_PROPERTY
      Suffix of property for module post-enable message.
      See Also:
    • MODULE_POSTDISABLE_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_POSTDISABLE_PROPERTY
      Suffix of property for module post-disable message.
      See Also:
    • MODULE_LANGS_PROPERTY

      @Nonnull @NotEmpty public static final String MODULE_LANGS_PROPERTY
      Suffix of property for module languages.
      See Also:
    • log

      @Nonnull private org.slf4j.Logger log
      Class logger.
    • moduleProperties

      @Nonnull private final Properties moduleProperties
      Properties describing module.
    • moduleId

      @Nonnull @NotEmpty private String moduleId
      Module ID.
    • moduleName

      @Nonnull @NotEmpty private String moduleName
      Module name.
    • moduleURL

      @Nullable @NotEmpty private String moduleURL
      Module URL.
    • pluginId

      @Nullable @NotEmpty private String pluginId
      Plugin ID.
    • locales

      @Nonnull private List<String> locales
      Available message locales.
    • requireHttpClient

      private boolean requireHttpClient
      Whether to require an HTTP client.
  • Constructor Details

    • PropertyDrivenModule

      public PropertyDrivenModule(@Nullable String version, @Nonnull Class<? extends Module> claz) throws IOException, ModuleException
      Constructor.
      Parameters:
      claz - type of object used to locate default module.properties resource
      version - version of the containing application (or null if none available)
      Throws:
      IOException - if unable to read file
      ModuleException - if the module is not in a valid state
    • PropertyDrivenModule

      public PropertyDrivenModule(@Nullable String version, @Nonnull InputStream inputStream) throws IOException, ModuleException
      Constructor.
      Parameters:
      inputStream - property stream
      version - version of the containing application (or null if none available)
      Throws:
      IOException - if unable to read file
      ModuleException - if the module is not in a valid state
    • PropertyDrivenModule

      public PropertyDrivenModule(@Nullable String version, @Nonnull Properties properties) throws ModuleException
      Constructor.
      Parameters:
      properties - property set
      version - version of the containing application (or null if none available)
      Throws:
      ModuleException - if the module is not in a valid state
  • Method Details