PHP Class Asvae\ApiTester\Entities\BaseEntity

Inheritance: implements Illuminate\Contracts\Support\Arrayable, implements Illuminate\Contracts\Support\Jsonable, implements ArrayAcces\ArrayAccess, implements JsonSerializabl\JsonSerializable
Afficher le fichier Open project: asvae/laravel-api-tester

Protected Properties

Свойство Type Description
$attributes Entity attributes.
$fillable Names of attributes that can be filled.

Méthodes publiques

Méthode Description
__construct ( array $data = [] ) BaseEntity constructor.
fill ( array $data ) : void Fill attributes that can be filled.
jsonSerialize ( ) : mixed Specify data which should be serialized to JSON
offsetExists ( mixed $offset ) : boolean Whether a offset exists.
offsetGet ( mixed $offset ) : mixed Offset to retrieve.
offsetSet ( mixed $offset, mixed $value ) : void Offset to set.
offsetUnset ( mixed $offset ) : void Offset to unset.
toArray ( ) : array Get the instance as an array.
toJson ( integer $options ) : string Convert the object to its JSON representation.

Méthodes protégées

Méthode Description
filterFillable ( array $data ) : array Return array with with key that can be filled.

Method Details

__construct() public méthode

BaseEntity constructor.
public __construct ( array $data = [] )
$data array

fill() public méthode

Fill attributes that can be filled.
public fill ( array $data ) : void
$data array
Résultat void

filterFillable() protected méthode

Return array with with key that can be filled.
protected filterFillable ( array $data ) : array
$data array
Résultat array

jsonSerialize() public méthode

Specify data which should be serialized to JSON
public jsonSerialize ( ) : mixed
Résultat mixed data which can be serialized by json_encode, which is a value of any type other than a resource.

offsetExists() public méthode

Whether a offset exists.
public offsetExists ( mixed $offset ) : boolean
$offset mixed An offset to check for.
Résultat boolean true on success or false on failure.

offsetGet() public méthode

Offset to retrieve.
public offsetGet ( mixed $offset ) : mixed
$offset mixed The offset to retrieve.
Résultat mixed Can return all value types.

offsetSet() public méthode

Offset to set.
public offsetSet ( mixed $offset, mixed $value ) : void
$offset mixed The offset to assign the value to.
$value mixed The value to set.
Résultat void

offsetUnset() public méthode

Offset to unset.
public offsetUnset ( mixed $offset ) : void
$offset mixed The offset to unset.
Résultat void

toArray() public méthode

Get the instance as an array.
public toArray ( ) : array
Résultat array return array representation of object.

toJson() public méthode

Convert the object to its JSON representation.
public toJson ( integer $options ) : string
$options integer
Résultat string

Property Details

$attributes protected_oe property

Entity attributes.
protected $attributes

$fillable protected_oe property

Names of attributes that can be filled.
protected $fillable