ModelManifest
class ModelManifest implements ModelManifestInterface (View source)
Properties
protected | $models | The collection of models to register to this manifest. |
Methods
__construct()
The model manifest instance.
void
register(Collection $models)
Register models.
Model
getRegisteredModel(string $baseModelClass)
Get the registered model for a base model class.
void
removeModel(string $baseModelClass)
Removes model from manifest.
void
swapModel(string $currentModelClass, string $newModelClass)
Swap the model implementation.
string|null
getMorphClassBaseModel(string $morphClass)
Get the morph class base model.
Collection
getBaseModelClasses()
Get list of registered base model classes.
Collection
getRegisteredModels()
Get list of all registered models.
Details
__construct()
The model manifest instance.
void
register(Collection $models)
Register models.
Model
getRegisteredModel(string $baseModelClass)
Get the registered model for a base model class.
void
removeModel(string $baseModelClass)
Removes model from manifest.
void
swapModel(string $currentModelClass, string $newModelClass)
Swap the model implementation.
string|null
getMorphClassBaseModel(string $morphClass)
Get the morph class base model.
Collection
getBaseModelClasses()
Get list of registered base model classes.
Collection
getRegisteredModels()
Get list of all registered models.