Nexus API Reference

FromServiceResolver
in package
implements ParamResolver

Read onlyYes
FinalYes
Tags
psalm-api

Recognises #[FromService(Id::class)] and resolves via the PSR-11 container. The service id is captured in the payload at compile time; at request time we look it up in the container present on InvocationContext::$services.

When the attribute id is null (#[FromService] alone), the parameter's type-hint is used as the container id.

Throws at resolve time if no container is wired.

Table of Contents

Interfaces

ParamResolver

Methods

compile()  : ParamMetadata|null
resolve()  : mixed

Methods


        
On this page

Search results