Class TriggerServiceImpl
java.lang.Object
io.meeds.gamification.service.impl.TriggerServiceImpl
- All Implemented Interfaces:
TriggerService
-
Constructor Summary
ConstructorsConstructorDescriptionTriggerServiceImpl(org.exoplatform.commons.api.settings.SettingService settingService) -
Method Summary
Modifier and TypeMethodDescriptiongetTriggerProperties(String triggerName) Retrieves gamification trigger propertiesbooleanisTriggerEnabledForAccount(String triggerName, long accountId) Checks if a trigger is enabled for account or not.voidsetTriggerEnabledForAccount(String triggerName, long accountId, boolean enabled, String currentUser) Enables/disables organization trigger
-
Constructor Details
-
TriggerServiceImpl
public TriggerServiceImpl(org.exoplatform.commons.api.settings.SettingService settingService)
-
-
Method Details
-
getTriggerProperties
Description copied from interface:TriggerServiceRetrieves gamification trigger properties- Specified by:
getTriggerPropertiesin interfaceTriggerService- Parameters:
triggerName- trigger name- Returns:
TriggerProperties
-
setTriggerEnabledForAccount
public void setTriggerEnabledForAccount(String triggerName, long accountId, boolean enabled, String currentUser) throws IllegalAccessException Description copied from interface:TriggerServiceEnables/disables organization trigger- Specified by:
setTriggerEnabledForAccountin interfaceTriggerService- Parameters:
triggerName- trigger nameaccountId- account Idenabled- true to enabled, else falsecurrentUser- user name attempting to enables/disables trigger.- Throws:
IllegalAccessException- when user is not authorized enables/disables trigger
-
isTriggerEnabledForAccount
Description copied from interface:TriggerServiceChecks if a trigger is enabled for account or not.- Specified by:
isTriggerEnabledForAccountin interfaceTriggerService- Parameters:
triggerName- The trigger to be checked.accountId- The account Id.- Returns:
- true if the trigger enabled for account, false if not.
-