Package emu.grasscutter.database
Class DatabaseHelper
java.lang.Object
emu.grasscutter.database.DatabaseHelper
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionstatic booleancheckPlayerExists(int id) static AccountcreateAccount(String username) static AccountcreateAccountWithId(String username, int reservedId) static AccountcreateAccountWithPassword(String username, String password) Deprecated.static PlayercreatePlayer(Player character, int reservedId) static booleandeleteAccount(String username) static voiddeleteFriendship(Friendship friendship) static booleandeleteItem(GameItem item) static booleandeleteMail(Mail mail) static AccountgetAccountById(String uid) static AccountgetAccountByName(String username) static AccountgetAccountByPlayerId(int playerId) static AccountgetAccountBySessionKey(String sessionKey) static AccountgetAccountByToken(String token) getAllMail(Player player) getAvatars(Player player) static List<Friendship>getFriends(Player player) static List<GachaRecord>getGachaRecords(int ownerId, int page, int gachaType) static List<GachaRecord>getGachaRecords(int ownerId, int page, int gachaType, int pageSize) static longgetGachaRecordsMaxPage(int ownerId, int page, int gachaType) static longgetGachaRecordsMaxPage(int ownerId, int page, int gachaType, int pageSize) getInventoryItems(Player player) static intgetNextPlayerId(int reservedId) static PlayergetPlayerById(int id) static List<Friendship>getReverseFriends(Player player) static FriendshipgetReverseFriendship(Friendship friendship) static voidsaveAccount(Account account) static voidsaveAvatar(Avatar avatar) static voidsaveFriendship(Friendship friendship) static voidsaveGachaRecord(GachaRecord gachaRecord) static voidstatic voidstatic voidsavePlayer(Player character)
-
Field Details
-
AWJVN
public static char AWJVN
-
-
Constructor Details
-
DatabaseHelper
public DatabaseHelper()
-
-
Method Details
-
createAccount
-
createAccountWithId
-
createAccountWithPassword
Deprecated. -
saveAccount
-
getAccountByName
-
getAccountByToken
-
getAccountBySessionKey
-
getAccountById
-
getAccountByPlayerId
-
deleteAccount
-
getAllPlayers
-
getPlayerById
-
checkPlayerExists
public static boolean checkPlayerExists(int id) -
createPlayer
-
getNextPlayerId
public static int getNextPlayerId(int reservedId) -
savePlayer
-
saveAvatar
-
getAvatars
-
saveItem
-
deleteItem
-
getInventoryItems
-
getFriends
-
getReverseFriends
-
saveFriendship
-
deleteFriendship
-
getReverseFriendship
-
getGachaRecords
-
getGachaRecords
-
getGachaRecordsMaxPage
public static long getGachaRecordsMaxPage(int ownerId, int page, int gachaType) -
getGachaRecordsMaxPage
public static long getGachaRecordsMaxPage(int ownerId, int page, int gachaType, int pageSize) -
saveGachaRecord
-
getAllMail
-
saveMail
-
deleteMail
-