feat: 魔改网易登录接口
Some checks failed
Java CI with Gradle / build (push) Has been cancelled
Some checks failed
Java CI with Gradle / build (push) Has been cancelled
This commit is contained in:
@@ -5,7 +5,7 @@ plugins {
|
||||
}
|
||||
|
||||
java {
|
||||
withJavadocJar()
|
||||
// withJavadocJar()
|
||||
withSourcesJar()
|
||||
|
||||
sourceSets["main"].java {
|
||||
|
@@ -148,4 +148,8 @@ public interface ProxyConfig {
|
||||
* @return read timeout (in milliseconds)
|
||||
*/
|
||||
int getReadTimeout();
|
||||
|
||||
String getNeteaseAuthUrl();
|
||||
|
||||
String getNeteaseGameId();
|
||||
}
|
||||
|
@@ -19,7 +19,7 @@ public final class GameProfile {
|
||||
|
||||
private final UUID id;
|
||||
private final String undashedId;
|
||||
private final String name;
|
||||
private String name;
|
||||
private final List<Property> properties;
|
||||
|
||||
/**
|
||||
@@ -80,6 +80,10 @@ public final class GameProfile {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
/**
|
||||
* Returns an immutable list of profile properties associated with this profile.
|
||||
*
|
||||
@@ -221,4 +225,116 @@ public final class GameProfile {
|
||||
+ '}';
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* netease auth response.
|
||||
*/
|
||||
public static class Response {
|
||||
private Integer code = 0;
|
||||
private String message;
|
||||
private String details;
|
||||
private ResponseEntity entity;
|
||||
|
||||
/**
|
||||
* default constructor.
|
||||
*
|
||||
* @param code -
|
||||
* @param message -
|
||||
* @param details -
|
||||
* @param entity the game profile
|
||||
*/
|
||||
public Response(Integer code, String message, String details, ResponseEntity entity) {
|
||||
this.code = code;
|
||||
this.message = message;
|
||||
this.details = details;
|
||||
this.entity = entity;
|
||||
}
|
||||
|
||||
public Integer getCode() {
|
||||
return code;
|
||||
}
|
||||
|
||||
public void setCode(Integer code) {
|
||||
this.code = code;
|
||||
}
|
||||
|
||||
public String getMessage() {
|
||||
return message;
|
||||
}
|
||||
|
||||
public void setMessage(String message) {
|
||||
this.message = message;
|
||||
}
|
||||
|
||||
public String getDetails() {
|
||||
return details;
|
||||
}
|
||||
|
||||
public void setDetails(String details) {
|
||||
this.details = details;
|
||||
}
|
||||
|
||||
public ResponseEntity getEntity() {
|
||||
return entity;
|
||||
}
|
||||
|
||||
public void setEntity(ResponseEntity entity) {
|
||||
this.entity = entity;
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* netease auth response entity.
|
||||
*/
|
||||
public static class ResponseEntity {
|
||||
private String id;
|
||||
private String name;
|
||||
private List<Property> properties;
|
||||
|
||||
/**
|
||||
* default constructor.
|
||||
*
|
||||
* @param id -
|
||||
* @param name -
|
||||
* @param properties -
|
||||
*/
|
||||
public ResponseEntity(String id, String name, List<Property> properties) {
|
||||
this.id = id;
|
||||
this.name = name;
|
||||
this.properties = properties;
|
||||
}
|
||||
|
||||
public String getId() {
|
||||
return id;
|
||||
}
|
||||
|
||||
public void setId(String id) {
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
public String getName() {
|
||||
return name;
|
||||
}
|
||||
|
||||
public void setName(String name) {
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
public List<Property> getProperties() {
|
||||
return properties;
|
||||
}
|
||||
|
||||
public void setProperties(List<Property> properties) {
|
||||
this.properties = properties;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return "ResponseEntity{"
|
||||
+ "id='" + id + '\''
|
||||
+ ", name='" + name + '\''
|
||||
+ ", properties=" + properties
|
||||
+ '}';
|
||||
}
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user