Updated models
This commit is contained in:
parent
3183c56d78
commit
9593bd988e
@ -10,34 +10,32 @@ import java.util.UUID;
|
||||
*
|
||||
* @author Braydon
|
||||
*/
|
||||
@NoArgsConstructor
|
||||
@AllArgsConstructor
|
||||
@Setter @Getter
|
||||
@AllArgsConstructor @Getter
|
||||
@EqualsAndHashCode(onlyExplicitlyIncluded = true)
|
||||
@ToString
|
||||
public class Player {
|
||||
/**
|
||||
* The unique id of this player.
|
||||
*/
|
||||
@Id @EqualsAndHashCode.Include @NonNull private UUID uniqueId;
|
||||
@Id @EqualsAndHashCode.Include @NonNull private final UUID uniqueId;
|
||||
|
||||
/**
|
||||
* The username of this player.
|
||||
*/
|
||||
@NonNull private String username;
|
||||
@NonNull private final String username;
|
||||
|
||||
/**
|
||||
* The skin of this player.
|
||||
*/
|
||||
@NonNull private Skin skin;
|
||||
@NonNull private final Skin skin;
|
||||
|
||||
/**
|
||||
* The cape of this player, null if none.
|
||||
*/
|
||||
private Cape cape;
|
||||
private final Cape cape;
|
||||
|
||||
/**
|
||||
* The profile actions this player has, null if none.
|
||||
*/
|
||||
private ProfileAction[] profileActions;
|
||||
private final ProfileAction[] profileActions;
|
||||
}
|
@ -16,27 +16,27 @@ import java.util.Base64;
|
||||
* @author Braydon
|
||||
* @see <a href="https://wiki.vg/Mojang_API#UUID_to_Profile_and_Skin.2FCape">Mojang API</a>
|
||||
*/
|
||||
@NoArgsConstructor @Setter @Getter @EqualsAndHashCode(onlyExplicitlyIncluded = true) @ToString
|
||||
@AllArgsConstructor @Getter @EqualsAndHashCode(onlyExplicitlyIncluded = true) @ToString
|
||||
public final class MojangProfileToken {
|
||||
/**
|
||||
* The id of the profile.
|
||||
*/
|
||||
@EqualsAndHashCode.Include @NonNull private String id;
|
||||
@EqualsAndHashCode.Include @NonNull private final String id;
|
||||
|
||||
/**
|
||||
* The name of the profile.
|
||||
*/
|
||||
@NonNull private String name;
|
||||
@NonNull private final String name;
|
||||
|
||||
/**
|
||||
* The properties of the profile.
|
||||
*/
|
||||
@NonNull private ProfileProperty[] properties;
|
||||
@NonNull private final ProfileProperty[] properties;
|
||||
|
||||
/**
|
||||
* The actions this profile has.
|
||||
*/
|
||||
@NonNull private ProfileAction[] profileActions;
|
||||
@NonNull private final ProfileAction[] profileActions;
|
||||
|
||||
public Tuple<Skin, Cape> getSkinAndCape() {
|
||||
ProfileProperty textures = getPropertyByName("textures"); // Get the profile textures
|
||||
|
@ -1,8 +1,8 @@
|
||||
package me.braydon.mc.model.token;
|
||||
|
||||
import lombok.AllArgsConstructor;
|
||||
import lombok.Getter;
|
||||
import lombok.NoArgsConstructor;
|
||||
import lombok.Setter;
|
||||
import lombok.NonNull;
|
||||
import lombok.ToString;
|
||||
|
||||
/**
|
||||
@ -11,10 +11,10 @@ import lombok.ToString;
|
||||
* @author Braydon
|
||||
* @see <a href="https://wiki.vg/Mojang_API#Username_to_UUID">Mojang API</a>
|
||||
*/
|
||||
@NoArgsConstructor @Setter @Getter @ToString
|
||||
@AllArgsConstructor @Getter @ToString
|
||||
public final class MojangUsernameToUUIDToken {
|
||||
/**
|
||||
* The id of the username.
|
||||
*/
|
||||
private String id;
|
||||
@NonNull private final String id;
|
||||
}
|
Loading…
Reference in New Issue
Block a user