trait CollectsResources (View source)

Methods

mixed
collectResource(mixed $resource)

Map the given collection resource into its individual resources.

string|null
collects()

Get the resource that this resource collects.

getIterator()

Get an iterator for the resource collection.

Details

protected mixed collectResource(mixed $resource)

Map the given collection resource into its individual resources.

Parameters

mixed $resource

Return Value

mixed

protected string|null collects()

Get the resource that this resource collects.

Return Value

string|null

ArrayIterator getIterator()

Get an iterator for the resource collection.

Return Value

ArrayIterator

Laravel Cloud is the best place to deploy Laravel, Nuxt, Express, Hono, Node.js, Bun, Go, Flask, Python, and more, with dedicated infrastructure available on AWS through Laravel Private Cloud.