PHP Класс Flarum\Api\Controller\AbstractSerializeController

Наследование: implements Flarum\Http\Controller\ControllerInterface
Показать файл Открыть проект Примеры использования класса

Открытые свойства

Свойство Тип Описание
$include array The relationships that are included by default.
$limit integer The number of records included by default.
$maxLimit integer The maximum number of records that can be requested.
$optionalInclude array The relationships that are available to be included.
$serializer string The name of the serializer class to output results with.
$sort array | null The default sort field and order to user.
$sortFields array The fields that are available to be sorted by.

Защищенные свойства (Protected)

Свойство Тип Описание
$container Illuminate\Contracts\Container\Container
$events Illuminate\Contracts\Events\Dispatcher

Открытые методы

Метод Описание
getContainer ( ) : Illuminate\Contracts\Container\Container
getEventDispatcher ( ) : Illuminate\Contracts\Events\Dispatcher
handle ( Psr\Http\Message\ServerRequestInterface $request )
setContainer ( Illuminate\Contracts\Container\Container $container )
setEventDispatcher ( Illuminate\Contracts\Events\Dispatcher $events )

Защищенные методы

Метод Описание
buildParameters ( Psr\Http\Message\ServerRequestInterface $request ) : Parameters
createElement ( mixed $data, Tobscure\JsonApi\SerializerInterface $serializer ) : Tobscure\JsonApi\ElementInterface Create a PHP JSON-API Element for output in the document.
data ( Psr\Http\Message\ServerRequestInterface $request, Document $document ) : mixed Get the data to be serialized and assigned to the response document.
extractFields ( Psr\Http\Message\ServerRequestInterface $request ) : array
extractFilter ( Psr\Http\Message\ServerRequestInterface $request ) : array
extractInclude ( Psr\Http\Message\ServerRequestInterface $request ) : array
extractLimit ( Psr\Http\Message\ServerRequestInterface $request ) : integer
extractOffset ( Psr\Http\Message\ServerRequestInterface $request ) : integer
extractSort ( Psr\Http\Message\ServerRequestInterface $request ) : array | null

Описание методов

buildParameters() защищенный Метод

protected buildParameters ( Psr\Http\Message\ServerRequestInterface $request ) : Parameters
$request Psr\Http\Message\ServerRequestInterface
Результат Tobscure\JsonApi\Parameters

createElement() абстрактный защищенный Метод

Create a PHP JSON-API Element for output in the document.
abstract protected createElement ( mixed $data, Tobscure\JsonApi\SerializerInterface $serializer ) : Tobscure\JsonApi\ElementInterface
$data mixed
$serializer Tobscure\JsonApi\SerializerInterface
Результат Tobscure\JsonApi\ElementInterface

data() абстрактный защищенный Метод

Get the data to be serialized and assigned to the response document.
abstract protected data ( Psr\Http\Message\ServerRequestInterface $request, Document $document ) : mixed
$request Psr\Http\Message\ServerRequestInterface
$document Tobscure\JsonApi\Document
Результат mixed

extractFields() защищенный Метод

protected extractFields ( Psr\Http\Message\ServerRequestInterface $request ) : array
$request Psr\Http\Message\ServerRequestInterface
Результат array

extractFilter() защищенный Метод

protected extractFilter ( Psr\Http\Message\ServerRequestInterface $request ) : array
$request Psr\Http\Message\ServerRequestInterface
Результат array

extractInclude() защищенный Метод

protected extractInclude ( Psr\Http\Message\ServerRequestInterface $request ) : array
$request Psr\Http\Message\ServerRequestInterface
Результат array

extractLimit() защищенный Метод

protected extractLimit ( Psr\Http\Message\ServerRequestInterface $request ) : integer
$request Psr\Http\Message\ServerRequestInterface
Результат integer

extractOffset() защищенный Метод

protected extractOffset ( Psr\Http\Message\ServerRequestInterface $request ) : integer
$request Psr\Http\Message\ServerRequestInterface
Результат integer

extractSort() защищенный Метод

protected extractSort ( Psr\Http\Message\ServerRequestInterface $request ) : array | null
$request Psr\Http\Message\ServerRequestInterface
Результат array | null

getContainer() публичный статический Метод

public static getContainer ( ) : Illuminate\Contracts\Container\Container
Результат Illuminate\Contracts\Container\Container

getEventDispatcher() публичный статический Метод

public static getEventDispatcher ( ) : Illuminate\Contracts\Events\Dispatcher
Результат Illuminate\Contracts\Events\Dispatcher

handle() публичный Метод

public handle ( Psr\Http\Message\ServerRequestInterface $request )
$request Psr\Http\Message\ServerRequestInterface

setContainer() публичный статический Метод

public static setContainer ( Illuminate\Contracts\Container\Container $container )
$container Illuminate\Contracts\Container\Container

setEventDispatcher() публичный статический Метод

public static setEventDispatcher ( Illuminate\Contracts\Events\Dispatcher $events )
$events Illuminate\Contracts\Events\Dispatcher

Описание свойств

$container защищенное статическое свойство

protected static Container,Illuminate\Contracts\Container $container
Результат Illuminate\Contracts\Container\Container

$events защищенное статическое свойство

protected static Dispatcher,Illuminate\Contracts\Events $events
Результат Illuminate\Contracts\Events\Dispatcher

$include публичное свойство

The relationships that are included by default.
public array $include
Результат array

$limit публичное свойство

The number of records included by default.
public int $limit
Результат integer

$maxLimit публичное свойство

The maximum number of records that can be requested.
public int $maxLimit
Результат integer

$optionalInclude публичное свойство

The relationships that are available to be included.
public array $optionalInclude
Результат array

$serializer публичное свойство

The name of the serializer class to output results with.
public string $serializer
Результат string

$sort публичное свойство

The default sort field and order to user.
public array|null $sort
Результат array | null

$sortFields публичное свойство

The fields that are available to be sorted by.
public array $sortFields
Результат array