Class ChatPaginator<T>
java.lang.Object
com.stardevllc.starmclib.paginator.ChatPaginator<T>
-
Nested Class Summary
Nested ClassesModifier and TypeClassDescriptionstatic classstatic enumstatic interface -
Field Summary
FieldsModifier and TypeFieldDescriptionprotected final com.stardevllc.starlib.converter.string.StringConverter<T> protected final Collection<T> protected final intprotected final BiFunction<ChatPaginator<T>, Actor, String> protected final BiFunction<ChatPaginator<T>, Actor, String> protected final Stringprotected final Set<ChatPaginator.Vars> -
Constructor Summary
ConstructorsConstructorDescriptionChatPaginator(BiFunction<ChatPaginator<T>, Actor, String> header, BiFunction<ChatPaginator<T>, Actor, String> footer, String lineFormat, Collection<T> elements, int elementsPerPage, com.stardevllc.starlib.converter.string.StringConverter<T> converter, Set<ChatPaginator.Vars> supportedVars) -
Method Summary
Modifier and TypeMethodDescriptionvoidvoidcom.stardevllc.starlib.converter.string.StringConverter<T> intgetCurrentPage(Actor actor) intintprotected intvalidatePage(int page)
-
Field Details
-
header
-
lineFormat
-
elements
-
elementsPerPage
protected final int elementsPerPage -
converter
-
supportedVars
-
actorCurrentPages
-
-
Constructor Details
-
ChatPaginator
public ChatPaginator(BiFunction<ChatPaginator<T>, Actor, String> header, BiFunction<ChatPaginator<T>, Actor, String> footer, String lineFormat, Collection<T> elements, int elementsPerPage, com.stardevllc.starlib.converter.string.StringConverter<T> converter, Set<ChatPaginator.Vars> supportedVars)
-
-
Method Details
-
validatePage
protected int validatePage(int page) -
getCurrentPage
-
display
-
display
-
getHeader
-
getLineFormat
-
getElements
-
getElementsPerPage
public int getElementsPerPage() -
getConverter
-
getSupportedVars
-
getTotalPages
public int getTotalPages()
-