2 namespace TYPO3\CMS\Extbase\Reflection;
103 public function addProperty($name, $type, $lazy =
false, $cascade =
'')
106 $this->properties[$name] = array(
107 'type' => $type[
'type'],
108 'elementType' => $type[
'elementType'],
110 'cascade' => $cascade
123 return is_array($this->properties[$propertyName]) ? $this->properties[$propertyName] : array();
145 if ($modelType < self::MODELTYPE_ENTITY || $modelType > self::MODELTYPE_VALUEOBJECT) {
146 throw new \InvalidArgumentException(
'"' .
$modelType .
'" is an invalid model type.', 1212519195);
170 $this->aggregateRoot = $isRoot;
192 return array_key_exists($propertyName, $this->properties);
204 if (!array_key_exists($propertyName, $this->properties)) {
205 throw new \InvalidArgumentException(
'Property "' . $propertyName .
'" must be added to the class schema before it can be marked as UUID property.', 1233863842);
207 $this->uuidPropertyName = $propertyName;
231 if (!array_key_exists($propertyName, $this->properties)) {
232 throw new \InvalidArgumentException(
'Property "' . $propertyName .
'" must be added to the class schema before it can be marked as identity property.', 1233775407);
234 if ($this->properties[$propertyName][
'lazy'] ===
true) {
235 throw new \InvalidArgumentException(
'Property "' . $propertyName .
'" must not be makred for lazy loading to be marked as identity property.', 1239896904);
237 $this->identityProperties[$propertyName] = $this->properties[$propertyName][
'type'];