src
main/java
cc.fascinated
common
model/player
service/skin
cc/fascinated
Main.java
common
ColorUtils.javaDNSUtils.javaEnumUtils.javaExpiringSet.javaIPUtils.javaImageUtils.javaJavaMinecraftVersion.javaPlayerUtils.javaServerUtils.javaTuple.javaUUIDUtils.javaWebRequest.java
packet
renderer
config
controller
exception
log
model
cache
dns
mojang
player
response
server
skin
token
repository
MinecraftServerCacheRepository.javaPlayerCacheRepository.javaPlayerNameCacheRepository.javaPlayerSkinPartCacheRepository.java
service
test/java/cc/fascinated/tests
27
src/main/java/cc/fascinated/model/cache/CachedPlayerName.java
vendored
Normal file
27
src/main/java/cc/fascinated/model/cache/CachedPlayerName.java
vendored
Normal file
@ -0,0 +1,27 @@
|
||||
package cc.fascinated.model.cache;
|
||||
|
||||
import lombok.*;
|
||||
import org.springframework.data.annotation.Id;
|
||||
import org.springframework.data.redis.core.RedisHash;
|
||||
|
||||
import java.util.UUID;
|
||||
|
||||
/**
|
||||
* @author Braydon
|
||||
*/
|
||||
@AllArgsConstructor
|
||||
@Getter
|
||||
@EqualsAndHashCode(onlyExplicitlyIncluded = true)
|
||||
@ToString
|
||||
@RedisHash(value = "playerName", timeToLive = 60L * 60L) // 1 hour (in seconds)
|
||||
public final class CachedPlayerName {
|
||||
/**
|
||||
* The username of the player.
|
||||
*/
|
||||
@Id @NonNull private String username;
|
||||
|
||||
/**
|
||||
* The unique id of the player.
|
||||
*/
|
||||
@NonNull private UUID uniqueId;
|
||||
}
|
Reference in New Issue
Block a user