PHP Класс PhalconRest\Api\ApiResource

Наследование: extends ApiCollection, implements PhalconApi\Acl\MountableInterface, implements Phalcon\Mvc\Micro\CollectionInterface
Показать файл Открыть проект Примеры использования класса

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

Свойство Тип Описание
$_modelPrimaryKey
$collectionKey
$itemKey
$model
$transformer

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

Метод Описание
collectionKey ( string $collectionKey ) : static
crud ( string $prefix, string $name = null ) : static Returns resource with default values & all, find, create, update and delete endpoints pre-configured
factory ( string $prefix, string $name = null ) : static Returns resource with default values
getCollectionKey ( ) : string
getItemKey ( ) : string
getModel ( ) : string | null
getModelPrimaryKey ( ) : string | null
getMultipleKey ( ) : string
getSingleKey ( ) : string
getTransformer ( ) : string | null
itemKey ( string $itemKey ) : static
model ( string $model ) : static
multipleKey ( string $multipleKey ) : static
singleKey ( string $singleKey ) : static
transformer ( string $transformer ) : static

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

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

public collectionKey ( string $collectionKey ) : static
$collectionKey string Response key for multiple items
Результат static

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

Returns resource with default values & all, find, create, update and delete endpoints pre-configured
public static crud ( string $prefix, string $name = null ) : static
$prefix string Prefix for the resource (e.g. /user)
$name string Name for the resource (e.g. users) (optional)
Результат static

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

Returns resource with default values
public static factory ( string $prefix, string $name = null ) : static
$prefix string Prefix for the resource (e.g. /user)
$name string Name for the resource (e.g. users) (optional)
Результат static

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

public getCollectionKey ( ) : string
Результат string Response key for multiple items

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

public getItemKey ( ) : string
Результат string Response key for single item

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

public getModel ( ) : string | null
Результат string | null Classname of the model

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

public getModelPrimaryKey ( ) : string | null
Результат string | null Primary key of the model

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

Устаревший: Use getCollectionKey() instead
public getMultipleKey ( ) : string
Результат string Response key for multiple items

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

Устаревший: Use getItemKey() instead
public getSingleKey ( ) : string
Результат string Response key for single item

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

public getTransformer ( ) : string | null
Результат string | null Classname of the transformer

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

public itemKey ( string $itemKey ) : static
$itemKey string Response key for single item
Результат static

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

public model ( string $model ) : static
$model string Classname of the model
Результат static

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

Устаревший: Use collectionKey() instead
public multipleKey ( string $multipleKey ) : static
$multipleKey string Response key for multiple items
Результат static

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

Устаревший: Use itemKey() instead
public singleKey ( string $singleKey ) : static
$singleKey string Response key for single item
Результат static

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

public transformer ( string $transformer ) : static
$transformer string Classname of the transformer
Результат static

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

$_modelPrimaryKey защищенное свойство

protected $_modelPrimaryKey

$collectionKey защищенное свойство

protected $collectionKey

$itemKey защищенное свойство

protected $itemKey

$model защищенное свойство

protected $model

$transformer защищенное свойство

protected $transformer