class
Illuminate
/
Contracts
/
Database
/
ModelIdentifier
ModelIdentifier
Properties
public
$class string
The class name of the model.
Default: null
public
$id mixed
The unique identifier of the model.
This may be either a single ID or an array of IDs.
Default: null
public
$relations array
The relationships loaded on the model.
Default: null
public
$connection string|null
The connection name of the model.
Default: null
public
$collectionClass string|null
The class name of the model collection.
Default: null
Methods
public
__construct ( $class , $id , array $relations , $connection ) : void
Create a new model identifier.
Parameters
- $class string
- $id mixed
- $relations array
- $connection mixed
public
useCollectionClass ( string $collectionClass ) : $this
Specify the collection class that should be used when serializing / restoring collections.
Parameters
- $collectionClass string|null