Class ModulePresentUtil
java.lang.Object
org.broadleafcommerce.common.module.ModulePresentUtil
Utility class that checks for the presence of registered Broadleaf modules.
- Author:
- Nathan Moore (nathanmoore)., Phillip Verheyden (phillipuniverse), Philip Baggett (pbaggett)
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic boolean
allPresent
(List<String> modulesInQuestion) Checks that every module in the list is registered.static boolean
This version takes a String instead of aBroadleafModuleRegistration.BroadleafModuleEnum
but operates in the same way by checking to see if a particular Broadleaf module has registered itselfstatic boolean
isPresent
(BroadleafModuleRegistration.BroadleafModuleEnum moduleInQuestion) Checks if the given module is registered
-
Field Details
-
MODULE_REGISTRATIONS
-
-
Constructor Details
-
ModulePresentUtil
public ModulePresentUtil()
-
-
Method Details
-
isPresent
public static boolean isPresent(@Nonnull BroadleafModuleRegistration.BroadleafModuleEnum moduleInQuestion) Checks if the given module is registered- Parameters:
moduleInQuestion
- the module that should be checked- Returns:
- whether the module in question has registered itself at runtime
-
allPresent
Checks that every module in the list is registered.- Parameters:
modulesInQuestion
- list of modules that should be checked- Returns:
- true if all modules in the list are present, false otherwise
- See Also:
-
isPresent
This version takes a String instead of aBroadleafModuleRegistration.BroadleafModuleEnum
but operates in the same way by checking to see if a particular Broadleaf module has registered itself- Parameters:
moduleInQuestion
- a String that maps toModuleLifecycleLoggingBean.getModuleName()
-