API / Minn\Rest / Context

Context enum

Minn\Rest\Context · public/minn/src/Minn/Rest/Context.php · 18 lines

The view a REST caller asked for. View is the public shape, edit adds the raw halves and the caller's own action links, embed is the reduced shape a linked resource carries when it rides inside another response.

Cases

caseView = 'view'
caseEdit = 'edit'
caseEmbed = 'embed'

Public

staticof(Minn\Http\Request $request): self#

The context a request names, view when it names none or names one the route does not serve.

methodisEdit(): bool#

Whether this is the edit context.