mirror of
https://github.com/GravitLauncher/Launcher
synced 2024-11-15 11:39:11 +03:00
[FEATURE] feature support
This commit is contained in:
parent
eddfd61c06
commit
8875146be3
2 changed files with 24 additions and 0 deletions
|
@ -40,12 +40,29 @@ public enum AuthType
|
||||||
OTHER
|
OTHER
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
public enum ServerFeature
|
||||||
|
{
|
||||||
|
FEATURE_SUPPORT(1);
|
||||||
|
public final int val;
|
||||||
|
|
||||||
|
ServerFeature(int val) {
|
||||||
|
this.val = val;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
@LauncherNetworkAPI
|
@LauncherNetworkAPI
|
||||||
public final List<AuthAvailability> list;
|
public final List<AuthAvailability> list;
|
||||||
|
@LauncherNetworkAPI
|
||||||
|
public final long features;
|
||||||
|
|
||||||
public GetAvailabilityAuthRequestEvent(List<AuthAvailability> list) {
|
public GetAvailabilityAuthRequestEvent(List<AuthAvailability> list) {
|
||||||
this.list = list;
|
this.list = list;
|
||||||
|
this.features = ServerFeature.FEATURE_SUPPORT.val;
|
||||||
|
}
|
||||||
|
|
||||||
|
public GetAvailabilityAuthRequestEvent(List<AuthAvailability> list, long features) {
|
||||||
|
this.list = list;
|
||||||
|
this.features = features;
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
|
|
|
@ -49,6 +49,13 @@ public AuthRequest(String login, byte[] password) {
|
||||||
authType = ConnectTypes.CLIENT;
|
authType = ConnectTypes.CLIENT;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
public AuthRequest(String login, byte[] password, String auth_id) {
|
||||||
|
this.login = VerifyHelper.verify(login, VerifyHelper.NOT_EMPTY, "Login can't be empty");
|
||||||
|
this.password = new AuthECPassword(password.clone());
|
||||||
|
this.auth_id = auth_id;
|
||||||
|
getSession = true;
|
||||||
|
authType = ConnectTypes.CLIENT;
|
||||||
|
}
|
||||||
@Deprecated
|
@Deprecated
|
||||||
public AuthRequest(String login, byte[] password, HWID hwid, String auth_id) {
|
public AuthRequest(String login, byte[] password, HWID hwid, String auth_id) {
|
||||||
this.login = VerifyHelper.verify(login, VerifyHelper.NOT_EMPTY, "Login can't be empty");
|
this.login = VerifyHelper.verify(login, VerifyHelper.NOT_EMPTY, "Login can't be empty");
|
||||||
|
|
Loading…
Reference in a new issue