SimpleComponentPagination class Null safety

Paginator where each page is message content

Inheritance

Constructors

SimpleComponentPagination(Interactions interactions, List<String> contentPages)
Creates instance of SimpleComponentPagination

Properties

builder ComponentMessageBuilder
Message builder used to create paginated messages
read / write, inherited
contentPages List<String>
List of string to paginate with
final
currentPage int
Current page that paginator is on
read / write, inherited
customPreId String
Custom id for this instance of paginator that different paginators could be recognized.
late, final, inherited
hashCode int
The hash code for this object. [...]
read-only, inherited
interactions Interactions
Reference to Interactions
final, inherited
maxPage int
Number of pages
read-only, override
runtimeType Type
A representation of the runtime type of the object.
read-only, inherited

Methods

getMessageBuilderForPage(int page, ComponentMessageBuilder currentBuilder) ComponentMessageBuilder
Returns MessageBuilder for page number. Always modify builder passed in currentBuilder argument.
override
initHook(ComponentMessageBuilder builder) ComponentMessageBuilder
Called after initializing basic components.
inherited
initMessageBuilder() ComponentMessageBuilder
Inits ComponentMessageBuilder with buttons needed for pagination. And hooks needed events.
inherited
noSuchMethod(Invocation invocation) → dynamic
Invoked when a non-existent method or property is accessed. [...]
inherited
onFirstPageButtonClicked() → void
Invoked on first page button click
inherited
onLastPageButtonClicked() → void
Invoked when last page button is clicked.
inherited
onNextPageButtonClicked() → void
Invoked when next page button is clicked.
inherited
onPreviousPageButtonClicked() → void
Invoked when previous page button is clicked.
inherited
toString() String
A string representation of this object. [...]
inherited
updatePage(int page, ComponentMessageBuilder currentBuilder, ButtonInteractionEvent target) FutureOr<void>
Invoked on each page update. Current page number is passed in page argument. Builder that message should be edited with is passed in currentBuilder argument. target parameter is generic and allows customization of how message will be modified.
inherited

Operators

operator ==(Object other) bool
The equality operator. [...]
inherited