PHP Class ZF\Apigility\Admin\Model\RestServiceResource

Inheritance: extends ZF\Rest\AbstractResourceListener
Afficher le fichier Open project: zfcampus/zf-apigility-admin Class Usage Examples

Protected Properties

Свойство Type Description
$documentationModel DocumentationModel
$inputFilterModel InputFilterModel
$model RestServiceModel
$moduleName string
$restFactory RestServiceModelFactory

Méthodes publiques

Méthode Description
__construct ( RestServiceModelFactory $restFactory, InputFilterModel $inputFilterModel, DocumentationModel $documentationModel )
create ( array | object $data ) : RestServiceEntity | ZF\ApiProblem\ApiProblem Create a new REST service
delete ( mixed $id ) : boolean Delete a service
fetch ( string $id ) : RestServiceEntity | ZF\ApiProblem\ApiProblem Fetch REST metadata
fetchAll ( array $params = [] ) : RestServiceEntity[] Fetch metadata for all REST services
getModel ( string $type = RestServiceModelFactory::TYPE_DEFAULT ) : RestServiceModel
getModuleName ( ) : string
patch ( string $id, object | array $data ) : ZF\ApiProblem\ApiProblem | RestServiceEntity Update an existing REST service

Méthodes protégées

Méthode Description
injectDocumentation ( RestServiceEntity $service )
injectInputFilters ( RestServiceEntity $service ) Inject the input filters collection, if any, as an embedded collection

Method Details

__construct() public méthode

public __construct ( RestServiceModelFactory $restFactory, InputFilterModel $inputFilterModel, DocumentationModel $documentationModel )
$restFactory RestServiceModelFactory
$inputFilterModel InputFilterModel
$documentationModel DocumentationModel

create() public méthode

Create a new REST service
public create ( array | object $data ) : RestServiceEntity | ZF\ApiProblem\ApiProblem
$data array | object
Résultat RestServiceEntity | ZF\ApiProblem\ApiProblem

delete() public méthode

Delete a service
public delete ( mixed $id ) : boolean
$id mixed
Résultat boolean

fetch() public méthode

Fetch REST metadata
public fetch ( string $id ) : RestServiceEntity | ZF\ApiProblem\ApiProblem
$id string
Résultat RestServiceEntity | ZF\ApiProblem\ApiProblem

fetchAll() public méthode

Fetch metadata for all REST services
public fetchAll ( array $params = [] ) : RestServiceEntity[]
$params array
Résultat RestServiceEntity[]

getModel() public méthode

public getModel ( string $type = RestServiceModelFactory::TYPE_DEFAULT ) : RestServiceModel
$type string One of the RestServiceModelFactory::TYPE_* constants; defaults to RestServiceModelFactory::TYPE_DEFAULT.
Résultat RestServiceModel

getModuleName() public méthode

public getModuleName ( ) : string
Résultat string

injectDocumentation() protected méthode

protected injectDocumentation ( RestServiceEntity $service )
$service RestServiceEntity

injectInputFilters() protected méthode

Inject the input filters collection, if any, as an embedded collection
protected injectInputFilters ( RestServiceEntity $service )
$service RestServiceEntity

patch() public méthode

Update an existing REST service
public patch ( string $id, object | array $data ) : ZF\ApiProblem\ApiProblem | RestServiceEntity
$id string
$data object | array
Résultat ZF\ApiProblem\ApiProblem | RestServiceEntity

Property Details

$documentationModel protected_oe property

protected DocumentationModel,ZF\Apigility\Admin\Model $documentationModel
Résultat DocumentationModel

$inputFilterModel protected_oe property

protected InputFilterModel,ZF\Apigility\Admin\Model $inputFilterModel
Résultat InputFilterModel

$model protected_oe property

protected RestServiceModel,ZF\Apigility\Admin\Model $model
Résultat RestServiceModel

$moduleName protected_oe property

protected string $moduleName
Résultat string

$restFactory protected_oe property

protected RestServiceModelFactory,ZF\Apigility\Admin\Model $restFactory
Résultat RestServiceModelFactory