PHP Интерфейс Tebru\Retrofit\Adapter\SerializerAdapter

Автор: Nate Brunette ([email protected])
Показать файл Открыть проект

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

Метод Описание
serialize ( mixed $data, array $context = [] ) : string Serialize an object to a string
setDefaultSerializationContext ( array $context ) Set the default serialization context
setSerializeTo ( string $serializeTo ) Set the format that data should be serialized to
toArray ( mixed $data, array $context = [] ) : array Serialize an object to an array

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

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

Serialize an object to a string
public serialize ( mixed $data, array $context = [] ) : string
$data mixed The data that should be serialized
$context array Serializer specific context
Результат string

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

Set the default serialization context
public setDefaultSerializationContext ( array $context )
$context array

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

Set the format that data should be serialized to
public setSerializeTo ( string $serializeTo )
$serializeTo string

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

Serialize an object to an array
public toArray ( mixed $data, array $context = [] ) : array
$data mixed The data that should be serialized
$context array Serializer specific context
Результат array