Package dev.plex.cache
Class SQLPlayerData
java.lang.Object
dev.plex.cache.SQLPlayerData
SQL fetching utilities for players
-
Field Summary
Fields -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanChecks if a player exists in the SQL databaseGets the player from cache or from the SQL databasevoidinsert(PlexPlayer player) Inserts the player's information in the databasevoidupdate(PlexPlayer player) Updates a player's information in the SQL database
-
Field Details
-
SELECT
- See Also:
-
UPDATE
- See Also:
-
INSERT
- See Also:
-
-
Constructor Details
-
SQLPlayerData
public SQLPlayerData()
-
-
Method Details
-
exists
Checks if a player exists in the SQL database- Parameters:
uuid- The unique ID of the player- Returns:
- true if the player was found in the database
-
getByUUID
Gets the player from cache or from the SQL database- Parameters:
uuid- The unique ID of the player- Returns:
- a PlexPlayer object
- See Also:
-
update
Updates a player's information in the SQL database- Parameters:
player- The PlexPlayer object- See Also:
-
insert
Inserts the player's information in the database- Parameters:
player- The PlexPlayer object- See Also:
-