Class RewardPlugin
- java.lang.Object
-
- org.exoplatform.container.component.BaseComponentPlugin
-
- org.exoplatform.wallet.reward.api.RewardPlugin
-
- All Implemented Interfaces:
org.exoplatform.container.component.ComponentPlugin
public abstract class RewardPlugin extends org.exoplatform.container.component.BaseComponentPluginA reward plugin to manage rewarded points
-
-
Constructor Summary
Constructors Constructor Description RewardPlugin()
-
Method Summary
All Methods Instance Methods Abstract Methods Concrete Methods Modifier and Type Method Description abstract Map<Long,Double>getEarnedPoints(Set<Long> identityIds, long startDateInSeconds, long endDateInSeconds)Retrieves earned points for identities in a selected period of timeStringgetPluginId()get reward plugin unique identifierbooleanisEnabled()Checks is the plugin is enabled
-
-
-
Method Detail
-
getPluginId
public String getPluginId()
get reward plugin unique identifier- Returns:
- reward plugin ID
-
isEnabled
public boolean isEnabled()
Checks is the plugin is enabled- Returns:
- whether the plugin is enabled or not
-
getEarnedPoints
public abstract Map<Long,Double> getEarnedPoints(Set<Long> identityIds, long startDateInSeconds, long endDateInSeconds)
Retrieves earned points for identities in a selected period of time- Parameters:
identityIds- identity ids of wallets to consider in computationstartDateInSeconds- start timestamp in seconds of reward periodendDateInSeconds- end timestamp in seconds of reward period- Returns:
- a
Mapof identity ID with the sum of tokens to send as reward
-
-