Class RegionFlagPagination
java.lang.Object
de.z0rdak.yawp.util.text.messages.pagination.BasePaginationMessage<IFlag>
de.z0rdak.yawp.util.text.messages.pagination.RegionFlagPagination
- All Implemented Interfaces:
MultiLineMessage<List<IFlag>>,PaginationMessage<IFlag>
-
Field Summary
Fields inherited from class de.z0rdak.yawp.util.text.messages.pagination.BasePaginationMessage
control, FIRST_PAGE_IDX, pageContent, paginationLines -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionList<net.minecraft.network.chat.Component>static List<net.minecraft.network.chat.MutableComponent>buildFlagEntriesForState(IProtectedRegion region, List<IFlag> selectedFlags, FlagState state) static net.minecraft.network.chat.MutableComponentbuildFlagQuickActionComponent(IProtectedRegion region, IFlag flag, net.minecraft.ChatFormatting flagLinkColor) Creates a TextComponent with a Link for displaying the flag info.static List<net.minecraft.network.chat.Component>static List<net.minecraft.network.chat.Component>buildRegionFlagEntries(IProtectedRegion region, List<IFlag> selectedFlags) static net.minecraft.network.chat.MutableComponentbuildRegionFlagInfoHeader(IProtectedRegion region, net.minecraft.network.chat.MutableComponent flagListLink) static net.minecraft.network.chat.MutableComponentbuildRemoveFlagEntry(IProtectedRegion region, IFlag flag, net.minecraft.ChatFormatting flagLinkColor, net.minecraft.ChatFormatting... ChatFormattings) Creates a TextComponent for flag removal, followed by the flag infosstatic net.minecraft.ChatFormattingcolorForState(FlagState state) net.minecraft.network.chat.Componentnet.minecraft.network.chat.Componentheader()net.minecraft.network.chat.ComponentMethods inherited from class de.z0rdak.yawp.util.text.messages.pagination.BasePaginationMessage
getContent, getLines, padEmptyEntriesMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface de.z0rdak.yawp.util.text.messages.multiline.MultiLineMessage
to
-
Constructor Details
-
RegionFlagPagination
public RegionFlagPagination(IProtectedRegion region, int pageNumber, int pageSize) throws InvalidPageNumberException - Throws:
InvalidPageNumberException
-
-
Method Details
-
buildRegionFlagInfoHeader
public static net.minecraft.network.chat.MutableComponent buildRegionFlagInfoHeader(IProtectedRegion region, net.minecraft.network.chat.MutableComponent flagListLink) -
buildRegionFlagEntries
public static List<net.minecraft.network.chat.Component> buildRegionFlagEntries(IProtectedRegion region) -
buildRegionFlagEntries
public static List<net.minecraft.network.chat.Component> buildRegionFlagEntries(IProtectedRegion region, List<IFlag> selectedFlags) -
buildFlagEntriesForState
public static List<net.minecraft.network.chat.MutableComponent> buildFlagEntriesForState(IProtectedRegion region, List<IFlag> selectedFlags, FlagState state) -
buildRemoveFlagEntry
public static net.minecraft.network.chat.MutableComponent buildRemoveFlagEntry(IProtectedRegion region, IFlag flag, net.minecraft.ChatFormatting flagLinkColor, net.minecraft.ChatFormatting... ChatFormattings) Creates a TextComponent for flag removal, followed by the flag infos -
colorForState
-
buildFlagQuickActionComponent
public static net.minecraft.network.chat.MutableComponent buildFlagQuickActionComponent(IProtectedRegion region, IFlag flag, net.minecraft.ChatFormatting flagLinkColor) Creates a TextComponent with a Link for displaying the flag info.
Text: [flagname] [regionTypeIdentifier] [s] [m] [o]
Where
- [s] is a suggest link to change the flag state,
- [m] is a quick link to toggle the flag mute state,
- [o] is a quick link to toggle the flag override state,- Parameters:
region-flag-- Returns:
- text component for quick flag actions [flagname] [regionTypeIdentifier] [s] [m] [o]
-
noContentMsg
public net.minecraft.network.chat.Component noContentMsg()- Specified by:
noContentMsgin classBasePaginationMessage<IFlag>
-
header
public net.minecraft.network.chat.Component header()- Specified by:
headerin classBasePaginationMessage<IFlag>
-
buildEntries
- Specified by:
buildEntriesin classBasePaginationMessage<IFlag>
-
emptyEntry
public net.minecraft.network.chat.Component emptyEntry()- Specified by:
emptyEntryin classBasePaginationMessage<IFlag>
-