interface Illuminate / Contracts / Pagination / CursorPaginator
You are viewing an older version of the documentation. For the latest, please visit master documentation.

CursorPaginator

Methods

public

url ( $cursor ) : string

Get the URL for a given cursor.

Parameters

public

appends ( $key , $value ) : $this

Add a set of query string values to the paginator.

Parameters

  • $key array|string|null
  • $value string|null
public

fragment ( $fragment ) : $this|string|null

Get / set the URL fragment to be appended to URLs.

Parameters

  • $fragment string|null
public

previousPageUrl ( ) : string|null

Get the URL for the previous page, or null.

public

nextPageUrl ( ) : string|null

The URL for the next page, or null.

public

items ( ) : array

Get all of the items being paginated.

public

previousCursor ( ) : Cursor |null

Get the "cursor" of the previous set of items.

public

nextCursor ( ) : Cursor |null

Get the "cursor" of the next set of items.

public

perPage ( ) : int

Determine how many items are being shown per page.

public

cursor ( ) : Cursor |null

Get the current cursor being paginated.

public

hasPages ( ) : bool

Determine if there are enough items to split into multiple pages.

public

path ( ) : string|null

Get the base path for paginator generated URLs.

public

isEmpty ( ) : bool

Determine if the list of items is empty or not.

public

isNotEmpty ( ) : bool

Determine if the list of items is not empty.

public

render ( $view , $data ) : string

Render the paginator using a given view.

Parameters

  • $view string|null
  • $data array