1
mirror of https://github.com/carm-outsource/TimeReward.git synced 2026-06-05 00:25:15 +08:00

feat(time): 尝试支持按日/周/月/总时长判别奖励。

This commit is contained in:
2023-09-02 17:14:00 +08:00
parent e1f4172a7f
commit dd80c5c9f7
24 changed files with 589 additions and 372 deletions
@@ -0,0 +1,37 @@
package cc.carm.plugin.timereward.user;
import cc.carm.plugin.timereward.data.IntervalType;
import cc.carm.plugin.timereward.data.RewardContents;
import cc.carm.plugin.timereward.data.TimeRecord;
import org.jetbrains.annotations.NotNull;
import java.time.Duration;
import java.util.Collections;
import java.util.UUID;
public class LockedRewardData extends UserRewardData {
public LockedRewardData(@NotNull UUID userUUID) {
super(userUUID, TimeRecord.empty(), Collections.emptyMap());
}
@Override
public Duration getOnlineDuration(@NotNull IntervalType type) {
return Duration.ZERO;
}
@Override
public boolean isClaimed(@NotNull RewardContents reward) {
return false;
}
@Override
public boolean isTimeEnough(RewardContents reward) {
return false;
}
@Override
public boolean addClaimedReward(@NotNull RewardContents reward) {
return false;
}
}