Class AbstractUserManager<T extends User>
java.lang.Object
me.lucko.luckperms.common.model.manager.AbstractManager<UUID,User,T>
me.lucko.luckperms.common.model.manager.user.AbstractUserManager<T>
- Direct Known Subclasses:
StandardUserManager
public abstract class AbstractUserManager<T extends User>
extends AbstractManager<UUID,User,T>
implements UserManager<T>
-
Constructor Summary
ConstructorsConstructorDescriptionAbstractUserManager(LuckPermsPlugin plugin, UserHousekeeper.TimeoutSettings timeoutSettings) -
Method Summary
Modifier and TypeMethodDescriptiongetByUsername(String name) Get a user object by nameGets the instance responsible for unloading unneeded users.booleangiveDefaultIfNeeded(User user) Gives the user the default group if necessary.voidInvalidates thePermissionCalculators for *loaded* users.voidInvalidates the cached data for *loaded* users.booleanisDefaultNode(net.luckperms.api.node.Node node) Gets whether the given node is a default node given byUserManager.giveDefaultIfNeeded(User).booleanisNonDefaultUser(User user) Check whether the user's state indicates that they should be persisted to storage.Reloads the data of all *online* usersMethods inherited from class me.lucko.luckperms.common.model.manager.AbstractManager
getAll, getIfLoaded, getOrMake, isLoaded, retainAll, sanitizeIdentifier, unload
-
Constructor Details
-
AbstractUserManager
-
-
Method Details
-
getOrMake
- Specified by:
getOrMakein interfaceUserManager<T extends User>
-
getByUsername
Description copied from interface:UserManagerGet a user object by name- Specified by:
getByUsernamein interfaceUserManager<T extends User>- Parameters:
name- The name to search by- Returns:
- a
Userobject if the user is loaded, returns null if the user is not loaded
-
giveDefaultIfNeeded
Description copied from interface:UserManagerGives the user the default group if necessary.- Specified by:
giveDefaultIfNeededin interfaceUserManager<T extends User>- Parameters:
user- the user to give to
-
isNonDefaultUser
Description copied from interface:UserManagerCheck whether the user's state indicates that they should be persisted to storage.- Specified by:
isNonDefaultUserin interfaceUserManager<T extends User>- Parameters:
user- the user to check- Returns:
- true if the user should be saved
-
isDefaultNode
public boolean isDefaultNode(net.luckperms.api.node.Node node) Description copied from interface:UserManagerGets whether the given node is a default node given byUserManager.giveDefaultIfNeeded(User).- Specified by:
isDefaultNodein interfaceUserManager<T extends User>- Parameters:
node- the node- Returns:
- true if it is the default node
-
getHouseKeeper
Description copied from interface:UserManagerGets the instance responsible for unloading unneeded users.- Specified by:
getHouseKeeperin interfaceUserManager<T extends User>- Returns:
- the housekeeper
-
loadAllUsers
Description copied from interface:UserManagerReloads the data of all *online* users- Specified by:
loadAllUsersin interfaceUserManager<T extends User>
-
invalidateAllUserCaches
public void invalidateAllUserCaches()Description copied from interface:UserManagerInvalidates the cached data for *loaded* users.- Specified by:
invalidateAllUserCachesin interfaceUserManager<T extends User>
-
invalidateAllPermissionCalculators
public void invalidateAllPermissionCalculators()Description copied from interface:UserManagerInvalidates thePermissionCalculators for *loaded* users.- Specified by:
invalidateAllPermissionCalculatorsin interfaceUserManager<T extends User>
-