trait Illuminate / Http / Resources / CollectsResources

CollectsResources

Methods

protected

collectResource ( $resource ) : mixed

Map the given collection resource into its individual resources.

Parameters

  • $resource mixed
protected

collects ( ) : string|null

Get the resource that this resource collects.

public

jsonOptions ( ) : int

Get the JSON serialization options that should be applied to the resource response.

public

getIterator ( ) : ArrayIterator

Get an iterator for the resource collection.