(very partially) lombokify
i should have done it before but whatever
This commit is contained in:
parent
b0fb8c8c5f
commit
549eef6647
3 changed files with 13 additions and 38 deletions
2
lombok.config
Normal file
2
lombok.config
Normal file
|
@ -0,0 +1,2 @@
|
|||
config.stopBubbling = true
|
||||
lombok.accessors.fluent = true
|
7
pom.xml
7
pom.xml
|
@ -31,6 +31,13 @@
|
|||
<artifactId>gson</artifactId>
|
||||
<version>2.9.0</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>1.18.24</version>
|
||||
<scope>provided</scope>
|
||||
</dependency>
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
|
|
|
@ -4,9 +4,13 @@ import com.github.steveice10.mc.auth.data.GameProfile;
|
|||
import com.github.steveice10.mc.protocol.data.game.PlayerListEntry;
|
||||
import com.github.steveice10.mc.protocol.data.game.entity.player.GameMode;
|
||||
import net.kyori.adventure.text.Component;
|
||||
import lombok.Data;
|
||||
import lombok.AllArgsConstructor;
|
||||
|
||||
import java.security.PublicKey;
|
||||
|
||||
@Data
|
||||
@AllArgsConstructor
|
||||
public class MutablePlayerListEntry {
|
||||
private GameProfile profile;
|
||||
private GameMode gamemode;
|
||||
|
@ -16,45 +20,7 @@ public class MutablePlayerListEntry {
|
|||
private PublicKey publicKey;
|
||||
private byte[] keySignature;
|
||||
|
||||
public MutablePlayerListEntry (GameProfile profile, GameMode gamemode, int latency, Component displayName, long expiresAt, PublicKey publicKey, byte[] keySignature) {
|
||||
this.profile = profile;
|
||||
this.gamemode = gamemode;
|
||||
this.latency = latency;
|
||||
this.displayName = displayName;
|
||||
this.expiresAt = expiresAt;
|
||||
this.publicKey = publicKey;
|
||||
this.keySignature = keySignature;
|
||||
}
|
||||
|
||||
public MutablePlayerListEntry (PlayerListEntry entry) {
|
||||
this(entry.getProfile(), entry.getGameMode(), entry.getPing(), entry.getDisplayName(), entry.getExpiresAt(), entry.getPublicKey(), entry.getKeySignature());
|
||||
}
|
||||
|
||||
public GameProfile profile () { return this.profile; }
|
||||
|
||||
public void profile (GameProfile profile) { this.profile = profile; }
|
||||
|
||||
public GameMode gamemode () { return this.gamemode; }
|
||||
|
||||
public void gamemode (GameMode gamemode) { this.gamemode = gamemode; }
|
||||
|
||||
public int latency () { return this.latency; }
|
||||
|
||||
public void latency (int latency) { this.latency = latency; }
|
||||
|
||||
public Component displayName () { return this.displayName; }
|
||||
|
||||
public void displayName (Component displayName) { this.displayName = displayName; }
|
||||
|
||||
public long expiresAt () { return this.expiresAt; }
|
||||
|
||||
public void expiresAt (long expiresAt) { this.expiresAt = expiresAt; }
|
||||
|
||||
public PublicKey publicKey () { return this.publicKey; }
|
||||
|
||||
public void publicKey (PublicKey publicKey) { this.publicKey = publicKey; }
|
||||
|
||||
public byte[] keySignature () { return this.keySignature; }
|
||||
|
||||
public void keySignature (byte[] keySignature) { this.keySignature = keySignature; }
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue