-
-
Notifications
You must be signed in to change notification settings - Fork 2
Expand file tree
/
Copy pathSuperAuthAPIEvent.java
More file actions
35 lines (27 loc) · 1008 Bytes
/
SuperAuthAPIEvent.java
File metadata and controls
35 lines (27 loc) · 1008 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
package xyz.theprogramsrc.superauth_v3.api;
import xyz.theprogramsrc.superauth_v3.global.hashing.HashingMethod;
import xyz.theprogramsrc.superauth_v3.global.users.User;
import xyz.theprogramsrc.superauth_v3.global.users.UserStorage;
import xyz.theprogramsrc.superauth_v3.spigot.storage.AuthSettings;
public class SuperAuthAPIEvent {
private final UserStorage userStorage;
private final AuthSettings authSettings;
private User user;
public SuperAuthAPIEvent(AuthSettings authSettings, UserStorage userStorage, String user) {
this.authSettings = authSettings;
this.userStorage = userStorage;
userStorage.get(user, u -> this.user = u);
}
public AuthSettings getAuthSettings() {
return authSettings;
}
public HashingMethod getHashingMethod(){
return this.getAuthSettings().getHashingMethod();
}
public UserStorage getUserStorage() {
return userStorage;
}
public User getUser() {
return user;
}
}