private function CerHandler::filled in Corresponding Entity References 7.2
Check if a field can support any more values. Formerly known as "reference overloading".
Parameters
array $references: The values in the field.
$field: Field definition (i.e., from field_info_field).
Return value
boolean
2 calls to CerHandler::filled()
- CerHandler::addReferenceFrom in ./
handler.inc - Creates a reference to the local entity on the remote entity. Throws CerException if the local entity is already referenced by the remote entity, or if the remote field cannot hold any more values.
- CerHandler::addReferenceTo in ./
handler.inc - Creates a reference to the remote entity on the local entity. Throws CerException if the local entity already references the remote entity, or if the field cannot hold any more values.
File
- ./
handler.inc, line 428 - Contains base code for CER handlers, which are objects responsible for creating, updating and deleting corresponding references between entities.
Class
- CerHandler
- @class Generic CER handler with rudimentary language handling.
Code
private function filled($references, $field) {
return $field['cardinality'] != FIELD_CARDINALITY_UNLIMITED && sizeof($references) >= $field['cardinality'];
}