Class Model
Base JSONAPI Model
Direct known subclasses
Indirect known subclasses
Phramework\JSONAPI\Model
,
Phramework\JSONAPI\Model\Directives
,
Phramework\JSONAPI\Model\Get
,
Phramework\JSONAPI\Model\Relationship
Namespace: Phramework\JSONAPI\Model
License: Apache-2.0
Author: Xenofon Spafaridis nohponex@gmail.com
Since: 0.0.0
Located at Model/Model.php
Methods summary
public static
array
|
|
public static
string
|
|
public static
string|null
|
|
public static
string|null
|
|
public static
string
|
|
public static
string
|
|
public static
string
|
Constants summary
string |
GET_RELATIONSHIP_BY_PREFIX
Model's method prefix, following by ucfirst(type of resource)
for example |
#
'getRelationshipBy'
|
string |
POST_RELATIONSHIP_BY_PREFIX
Model's method prefix, following by ucfirst(type of resource)
for example |
#
'postRelationshipBy'
|
string |
GET_BY_PREFIX
Model's method prefix |
#
'getBy'
|
Properties summary
protected static
string
|
$type
Resource's type, used to describe resource objects that share common attributes and relationships MUST be overwritten |
#
null
|
protected static
string|null
|
$table
Resource's table name MAY be overwritten, default is null (no database) |
#
null
|
protected static
string|null
|
$schema
Resource's table's schema name MAY be overwritten, default is null (no schema) |
#
null
|
protected static
string
|
$idAttribute
Resource's identification attribute (Primary key in database).
MAY be overwritten, default is |
#
'id'
|
protected static
string
|
$endpoint
Resource's endpoint, used for access by external request, usually it the same as type MUST be overwritten |
#
null
|
protected static
array|null
|
$cast
Records's type casting schema for database records MAY be overwritten Also it can be set to empty array to disable type casting for this resource. |
#
null
|