Some devices have multiple hardware pages, sometimes also called scenes or layers, between which one can swtch on the hardware itself. E.g. the korg nanokontrol has a switch for 4 scenes, which change the midicontrol numbers sent from sliders, knobs and channel buttons; the transport buttons stay the same in all scenes. This allows accessing many more actions than the number of hardware control elements on the device ( it is Modality in hardware ;-).
The Faderfox UC-4 is a nice example where one can show this support of hardware paging in code.
The Faderfox UC4 has a more complex notion of paging. For its 8 knobs with hat switches, 8 sliders, 8 buttons, and single crossfader, there are two paging groups:
For demonstration purposes, it has desc files for both kinds of hierarchical orders: element types on top and pages on top.
Here, one can show how to bring pages to the front for coding convenience: