interface GridField_StateProvider implements GridFieldComponent (View source)

A GridField component that provides state, notably default state.

Implementation of this interface is optional; without it, no default state is assumed. The benefit of default state is that it won't be included in URLs, keeping URLs tidier.

Methods

public
void
initDefaultState(GridState_Data $data)

Initialise the default state in the given GridState_Data

Details

void initDefaultState(GridState_Data $data)

Initialise the default state in the given GridState_Data

We recommend that you call $data->initDefaults() to do this.

Parameters

GridState_Data $data

The top-level state object

Return Value

void