ObjectIdentityInterface

interface ObjectIdentityInterface Represents the identity of an individual domain object instance. Methods bool equals(ObjectIdentityInterface $identity) We specifically require this method so we can check for object equality explicitly, and do not have to rely on referencial equality instead. string getIdentifier() Obtains a unique identifier for this object. The identifier must not be re-used for other objects with the same type. string getType() Returns a type for the domain

ObjectIdentity::getType()

string getType() Returns a type for the domain object. Typically, this is the PHP class name. Return Value string cannot return null

ObjectIdentity::getIdentifier()

string getIdentifier() Obtains a unique identifier for this object. The identifier must not be re-used for other objects with the same type. Return Value string cannot return null

ObjectIdentity::fromDomainObject()

static ObjectIdentity fromDomainObject(object $domainObject) Constructs an ObjectIdentity for the given domain object Parameters object $domainObject Return Value ObjectIdentity Exceptions InvalidDomainObjectException

ObjectIdentity::equals()

bool equals(ObjectIdentityInterface $identity) We specifically require this method so we can check for object equality explicitly, and do not have to rely on referencial equality instead. Though in most cases, both checks should result in the same outcome. Referential Equality: $object1 === $object2 Example for Object Equality: $object1->getId() === $object2->getId() Parameters ObjectIdentityInterface $identity Return Value bool

ObjectIdentity

class ObjectIdentity implements ObjectIdentityInterface ObjectIdentity implementation Methods __construct(string $identifier, string $type) Constructor. static ObjectIdentity fromDomainObject(object $domainObject) Constructs an ObjectIdentity for the given domain object string getIdentifier() Obtains a unique identifier for this object. The identifier must not be re-used for other objects with the same type. string getType() Returns a type for the domain object. Typically,

ObjectChoiceList deprecated::getValuesForChoices()

array getValuesForChoices(array $choices) Returns the values corresponding to the given choices. The values must be strings. The values must be returned with the same keys and in the same order as the corresponding choices in the given array. Parameters array $choices An array of choices. Not existing choices in this array are ignored Return Value array An array of choice values with ascending, 0-based numeric keys

ObjectChoiceList deprecated::getIndicesForChoices()

array getIndicesForChoices(array $choices) deprecated deprecated since version 2.4, to be removed in 3.0. Returns the indices corresponding to the given choices. The indices must be positive integers or strings accepted by {@link \Symfony\Component\Form\FormConfigBuilder::validateName()}. The index "placeholder" is internally reserved. The indices must be returned with the same keys and in the same order as the corresponding choices in the given array. Parameters array $choi

ObjectChoiceList deprecated

class ObjectChoiceList extends ChoiceList deprecated since Symfony 2.7, to be removed in version 3.0. Use {@link \Symfony\Component\Form\ChoiceList\ArrayChoiceList} instead. A choice list for object choices. Supports generation of choice labels, choice groups and choice values by calling getters of the object (or associated objects). $choices = array($user1, $user2); // call getName() to determine the choice labels $choiceList = new ObjectChoiceList($choices, 'name'); Methods __con

NumericNodeDefinition::min()

NumericNodeDefinition min(mixed $min) Ensures that the value is bigger than the given reference. Parameters mixed $min Return Value NumericNodeDefinition Exceptions InvalidArgumentException when the constraint is inconsistent