Skip to content

Commit

Permalink
Add CursorPager interface to pagination
Browse files Browse the repository at this point in the history
  • Loading branch information
RonnyLV committed May 20, 2024
1 parent f633987 commit 17997bb
Showing 1 changed file with 5 additions and 0 deletions.
5 changes: 5 additions & 0 deletions pagination.go
Original file line number Diff line number Diff line change
Expand Up @@ -18,6 +18,11 @@ type PageCounter interface {
CurrentPage() int64
}

type CursorPager interface {
HasNextCursor() bool
NextCursor() string
}

type Paged struct {
TotalCount int64 `json:"-"`
PageCount int64 `json:"-"`
Expand Down

0 comments on commit 17997bb

Please sign in to comment.