Maslosoft Mangan API
Class DbRefArrayAnnotation
DB reference array annotation is used to create reference to other or same collection items.
All parameters are optional. However it is recommended to set first parameter - default class for referenced objects.
It takes first parameter as class name or class literal, and second parameter to indicate if it should be updated along with parent model.
Most simple example - will allow many of any object types to be referenced: ```
- Maslosoft\Addendum\Collections\MetaAnnotation
- Maslosoft\Mangan\Meta\ManganAnnotation
- Maslosoft\Mangan\Meta\ManganPropertyAnnotation
- Maslosoft\Mangan\Annotations\DbRefAnnotation
- Maslosoft\Mangan\Annotations\DbRefArrayAnnotation
Dbrefarray: Example of updatable DB reference:
Dbrefarray(classliteral,:
true) ```
Template: DbRefArray(${class}, ${updatable})
Conflicts('embedded')
Conflicts('embeddedarray')
Conflicts('dbref')
Conflicts('related')
Conflicts('relatedarray')
Target('property')
Author: Piotr Maselkowski
Located at Annotations/DbRefArrayAnnotation.php
Methods inherited from Maslosoft\Mangan\Meta\ManganPropertyAnnotation
Methods inherited from Maslosoft\Mangan\Meta\ManganAnnotation
Properties summary
public
array
|
$value
|
#
[]
|
public
string|array
|
$key
Comparing key. This is used to update db ref instances from external sources. |
#
null
|