Package net.shibboleth.idp.module
Class AbstractIdPModule
java.lang.Object
net.shibboleth.idp.module.AbstractIdPModule
- All Implemented Interfaces:
IdPModule
,Component
,IdentifiedComponent
- Direct Known Subclasses:
PropertyDrivenIdPModule
IdPModule
base class implementing basic file management.- Since:
- 4.1.0
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescription(package private) class
Models a specific resource managed by a module.Nested classes/interfaces inherited from interface net.shibboleth.idp.module.IdPModule
IdPModule.ModuleResource, IdPModule.ResourceResult
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate org.slf4j.Logger
Class logger.Module resources. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptiondisable
(ModuleContext moduleContext, boolean clean) Disable the module.enable
(ModuleContext moduleContext) Enable the module.boolean
Gets resources managed by this module.int
hashCode()
boolean
isEnabled
(ModuleContext moduleContext) Gets whether the module is enabled.void
Sets the module resources to manage.toString()
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
Methods inherited from interface net.shibboleth.utilities.java.support.component.IdentifiedComponent
getId
Methods inherited from interface net.shibboleth.idp.module.IdPModule
getDescription, getName, getOwnerId, getURL, isHttpClientRequired
-
Field Details
-
log
@Nonnull private org.slf4j.Logger logClass logger. -
moduleResources
Module resources.
-
-
Constructor Details
-
AbstractIdPModule
public AbstractIdPModule()Constructor.
-
-
Method Details
-
getResources
@Nonnull @NonnullElements @NotLive @Unmodifiable public Collection<IdPModule.ModuleResource> getResources()Gets resources managed by this module.- Specified by:
getResources
in interfaceIdPModule
- Returns:
- resources managed by this module
-
setResources
public void setResources(@Nullable @NonnullElements Collection<AbstractIdPModule.BasicModuleResource> resources) Sets the module resources to manage.- Parameters:
resources
- resources to manage
-
isEnabled
Gets whether the module is enabled.The status of "enabled" is meant to reflect whether a deployer has previously or implicitly enabled the module, not necessarily whether the module is fully or properly configured or in use.
-
enable
@Nonnull @NonnullElements public Map<IdPModule.ModuleResource,IdPModule.ResourceResult> enable(@Nonnull ModuleContext moduleContext) throws ModuleException Enable the module.This operation MUST be idempotent.
- Specified by:
enable
in interfaceIdPModule
- Parameters:
moduleContext
- module context- Returns:
- summary of resource results
- Throws:
ModuleException
- if not successful
-
disable
@Nonnull @NonnullElements public Map<IdPModule.ModuleResource,IdPModule.ResourceResult> disable(@Nonnull ModuleContext moduleContext, boolean clean) throws ModuleException Disable the module.This operation MUST be idempotent with respect to the value of the input parameter.
- Specified by:
disable
in interfaceIdPModule
- Parameters:
moduleContext
- module contextclean
- if true, the module should attempt to fully remove traces of previous use in a potentially destructive fashion- Returns:
- summary of resource results
- Throws:
ModuleException
- if not successful
-
equals
-
hashCode
public int hashCode() -
toString
-