Documentation

ExampleDataInterface

Table of Contents

Methods

build()  : void
Fill-in full details of the example.
getExamples()  : iterable<string|int, mixed>
Get list of examples (summary-info only).

Methods

build()

Fill-in full details of the example.

public build(array<string|int, mixed> &$example) : void
Parameters
$example : array<string|int, mixed>

We start with summary-info for this example (name, title, tags). We may expand upon the example record, filling in dynamic(ish) properties like $example['data'].

getExamples()

Get list of examples (summary-info only).

public getExamples() : iterable<string|int, mixed>

This data should be static and amenable to caching.

Return values
iterable<string|int, mixed>

        
On this page

Search results