Class GroupColorSettingsProvider
java.lang.Object
de.murmelmeister.murmelapi.group.settings.GroupColorSettingsProvider
- All Implemented Interfaces:
GroupColorSettings
-
Nested Class Summary
Nested Classes -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionvoidcreateGroup(int groupId, int creatorId) Creates a new group and checks if the group already exists.voidcreateGroup(int groupId, int creatorId, String chatPrefix, String chatSuffix, String chatColor, String tabPrefix, String tabSuffix, String tabColor, String tagPrefix, String tagSuffix, String tagColor) Creates a new group and checks if the group already exists.private voidcreateTable(String tableName) voiddeleteGroup(int groupId) Deletes a group.booleanexistsGroup(int groupId) Checks if a group exists.getColor(GroupColorType type, int groupId) Obtains the color of a group.intgetCreatorId(int groupId) Obtains the creator id of a group.getEditedDate(int groupId) Obtains the edited date of a group.longgetEditedTime(int groupId) Obtains the edited time of a group.getPrefix(GroupColorType type, int groupId) Obtains the prefix of a group.getSuffix(GroupColorType type, int groupId) Obtains the suffix of a group.voidsetColor(GroupColorType type, int groupId, int creatorId, String color) Sets the color of a group.voidsetPrefix(GroupColorType type, int groupId, int creatorId, String prefix) Sets the prefix of a group.voidsetSuffix(GroupColorType type, int groupId, int creatorId, String suffix) Sets the suffix of a group.
-
Constructor Details
-
GroupColorSettingsProvider
public GroupColorSettingsProvider()
-
-
Method Details
-
createTable
-
existsGroup
public boolean existsGroup(int groupId) Description copied from interface:GroupColorSettingsChecks if a group exists.- Specified by:
existsGroupin interfaceGroupColorSettings- Parameters:
groupId- The id of the group.- Returns:
- True if the group exists, otherwise false.
-
createGroup
public void createGroup(int groupId, int creatorId) Description copied from interface:GroupColorSettingsCreates a new group and checks if the group already exists. If the group already exists, the method will return without creating a new group.- Specified by:
createGroupin interfaceGroupColorSettings- Parameters:
groupId- The id of the group.creatorId- The creator id of the group.
-
createGroup
public void createGroup(int groupId, int creatorId, String chatPrefix, String chatSuffix, String chatColor, String tabPrefix, String tabSuffix, String tabColor, String tagPrefix, String tagSuffix, String tagColor) Description copied from interface:GroupColorSettingsCreates a new group and checks if the group already exists. If the group already exists, the method will return without creating a new group.- Specified by:
createGroupin interfaceGroupColorSettings- Parameters:
groupId- The id of the group.creatorId- The creator id of the group.chatPrefix- The chat prefix of the group.chatSuffix- The chat suffix of the group.chatColor- The chat color of the group.tabPrefix- The tab prefix of the group.tabSuffix- The tab suffix of the group.tabColor- The tab color of the group.tagPrefix- The tag prefix of the group.tagSuffix- The tag suffix of the group.tagColor- The tag color of the group.
-
deleteGroup
public void deleteGroup(int groupId) Description copied from interface:GroupColorSettingsDeletes a group.- Specified by:
deleteGroupin interfaceGroupColorSettings- Parameters:
groupId- The id of the group.
-
getCreatorId
public int getCreatorId(int groupId) Description copied from interface:GroupColorSettingsObtains the creator id of a group.- Specified by:
getCreatorIdin interfaceGroupColorSettings- Parameters:
groupId- The id of the group.- Returns:
- The creator id of the group.
-
getEditedTime
public long getEditedTime(int groupId) Description copied from interface:GroupColorSettingsObtains the edited time of a group.- Specified by:
getEditedTimein interfaceGroupColorSettings- Parameters:
groupId- The id of the group.- Returns:
- The edited time of the group.
-
getEditedDate
Description copied from interface:GroupColorSettingsObtains the edited date of a group.- Specified by:
getEditedDatein interfaceGroupColorSettings- Parameters:
groupId- The id of the group.- Returns:
- The edited date of the group.
-
getPrefix
Description copied from interface:GroupColorSettingsObtains the prefix of a group.- Specified by:
getPrefixin interfaceGroupColorSettings- Parameters:
type- The type of the group color.groupId- The id of the group.- Returns:
- The prefix of the group.
-
getSuffix
Description copied from interface:GroupColorSettingsObtains the suffix of a group.- Specified by:
getSuffixin interfaceGroupColorSettings- Parameters:
type- The type of the group color.groupId- The id of the group.- Returns:
- The suffix of the group.
-
getColor
Description copied from interface:GroupColorSettingsObtains the color of a group.- Specified by:
getColorin interfaceGroupColorSettings- Parameters:
type- The type of the group color.groupId- The id of the group.- Returns:
- The color of the group.
-
setPrefix
Description copied from interface:GroupColorSettingsSets the prefix of a group.- Specified by:
setPrefixin interfaceGroupColorSettings- Parameters:
type- The type of the group color.groupId- The id of the group.creatorId- The creator id of the group.prefix- The prefix of the group.
-
setSuffix
Description copied from interface:GroupColorSettingsSets the suffix of a group.- Specified by:
setSuffixin interfaceGroupColorSettings- Parameters:
type- The type of the group color.groupId- The id of the group.creatorId- The creator id of the group.suffix- The suffix of the group.
-
setColor
Description copied from interface:GroupColorSettingsSets the color of a group.- Specified by:
setColorin interfaceGroupColorSettings- Parameters:
type- The type of the group color.groupId- The id of the group.creatorId- The creator id of the group.color- The color of the group.
-