Package io.manebot.database.model
Class Platform
- java.lang.Object
-
- io.manebot.database.model.TimedRow
-
- io.manebot.database.model.Platform
-
-
Nested Class Summary
-
Nested classes/interfaces inherited from interface io.manebot.platform.Platform
Platform.Builder
-
-
Method Summary
Modifier and Type Method Description GroupgetDefaultGroup()Gets the default group assignment for users registered on this platform.java.lang.StringgetId()Gets the platform's internal unique ID.intgetPlatformId()PlugingetPlugin()Gets the current plugin instance for this platform.PlatformRegistrationgetRegistration()Gets the runtime registration associated with this platform.UserAssociationgetUserAssocation(java.lang.String id)Gets a specific assocation for this platform.java.util.Collection<UserAssociation>getUserAssociations()Gets a list of user associations for this platform.java.util.Collection<UserAssociation>getUserAssociations(User user)Gets a set of user associations for the specified user.inthashCode()booleanisRegistrationAllowed()Finds if registration is allowed.voidsetDefaultGroup(UserGroup defaultGroup)Sets the default group assignment for users registered on this platform.voidsetRegistration(PlatformRegistration registration)voidsetRegistrationAllowed(boolean allowed)Sets if registration is allowed on this platform.-
Methods inherited from class io.manebot.database.model.TimedRow
getCreated, getCreatedDate, getUpdated, getUpdatedDate, setCreated, setCreated, setCreatedDate, setUpdated, setUpdated, setUpdatedDate
-
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, notify, notifyAll, toString, wait, wait, wait
-
Methods inherited from interface io.manebot.platform.Platform
getConnection, getUserAssocation, isConnected
-
-
-
-
Method Detail
-
getPlatformId
public int getPlatformId()
-
getRegistration
public PlatformRegistration getRegistration()
Description copied from interface:PlatformGets the runtime registration associated with this platform.- Specified by:
getRegistrationin interfacePlatform- Returns:
- Platform runtime registration.
-
getId
public java.lang.String getId()
Description copied from interface:PlatformGets the platform's internal unique ID.
-
isRegistrationAllowed
public boolean isRegistrationAllowed()
Description copied from interface:PlatformFinds if registration is allowed.- Specified by:
isRegistrationAllowedin interfacePlatform- Returns:
- true if registration is allowed, false otherwise.
-
setRegistrationAllowed
public void setRegistrationAllowed(boolean allowed)
Description copied from interface:PlatformSets if registration is allowed on this platform.- Specified by:
setRegistrationAllowedin interfacePlatform- Parameters:
allowed- true if registration is allowed, false otherwise.
-
getUserAssocation
public UserAssociation getUserAssocation(java.lang.String id)
Description copied from interface:PlatformGets a specific assocation for this platform.- Specified by:
getUserAssocationin interfacePlatform- Parameters:
id- Platform-specific user ID to search for.- Returns:
- user association if found on this platform, null otherwise.
-
getUserAssociations
public java.util.Collection<UserAssociation> getUserAssociations(User user)
Description copied from interface:PlatformGets a set of user associations for the specified user.- Specified by:
getUserAssociationsin interfacePlatform- Parameters:
user- User to search for.- Returns:
- collection of user associations for the specified uesr.
-
getUserAssociations
public java.util.Collection<UserAssociation> getUserAssociations()
Description copied from interface:PlatformGets a list of user associations for this platform.- Specified by:
getUserAssociationsin interfacePlatform- Returns:
- collection of user associations.
-
getPlugin
public Plugin getPlugin()
Description copied from interface:PlatformGets the current plugin instance for this platform.
-
setRegistration
public void setRegistration(PlatformRegistration registration)
-
hashCode
public int hashCode()
- Overrides:
hashCodein classjava.lang.Object
-
getDefaultGroup
public Group getDefaultGroup()
Description copied from interface:PlatformGets the default group assignment for users registered on this platform.- Specified by:
getDefaultGroupin interfacePlatform- Returns:
- Platform default user group, or null if no default is assigned.
-
setDefaultGroup
public void setDefaultGroup(UserGroup defaultGroup)
Description copied from interface:PlatformSets the default group assignment for users registered on this platform.- Specified by:
setDefaultGroupin interfacePlatform- Parameters:
defaultGroup- default user group for newly registered users.
-
-