> ## Documentation Index
> Fetch the complete documentation index at: https://docs.bijection.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Class: PageFillController<Result>

> Reactive segmented pagination with custody bound to the exact query and arguments.

[browser](/api/modules/browser).PageFillController

Reactive segmented pagination with custody bound to the exact query and arguments.
Hosts subscribe to `segments`, call `read` with those answers, and commit the
returned transition after rendering. Query changes fence old transitions and
release every held answer and cursor. No network or UI runtime is owned here.

## Type parameters

| Name | Type |
| :- | :- |
| `Result` | extends `AppPage` = `AppPage` |

## Constructors

### constructor

• **new PageFillController**\<`Result`>()

#### Type parameters

| Name | Type |
| :- | :- |
| `Result` | extends `AppPage` = `AppPage` |

## Properties

### key

• **key**: `string` = `""`

***

### segments

• **segments**: [`PageSegment`](/api/modules/browser#pagesegment)\[] = `[]`

## Methods

### configure

▸ **configure**(`query`, `args`, `start`, `pageSize`): `void`

#### Parameters

| Name | Type |
| :- | :- |
| `query` | [`FunctionReference`](/api/modules/server#functionreference)\<`"query"`> |
| `args` | `Record`\<`string`, `undefined` \| [`Value`](/api/modules/values#value)> |
| `start` | `null` \| `string` |
| `pageSize` | `number` |

#### Returns

`void`

***

### read

▸ **read**(`answers`, `canRestart?`): `Object`

#### Parameters

| Name | Type | Default value |
| :- | :- | :- |
| `answers` | readonly (`undefined` \| `Error` \| `Result`)\[] | `undefined` |
| `canRestart` | `boolean` | `false` |

#### Returns

`Object`

| Name | Type |
| :- | :- |
| `page` | `undefined` \| `AppPage` & \{ `segments`: `number` ; `filling`: `boolean` ; `stalled`: `boolean`  } & `Omit`\<`Result`, keyof `AppPage`> |
| `transition` | `string` |
| `restartCaller` | `boolean` |
| `commit` | () => `boolean` |
| `continueFilling` | () => `boolean` |


This documentation is built and hosted on [Mintlify](https://mintlify.com), a developer documentation platform.