ClassMetadataFactory::getMetadataFor()

ClassMetadataInterface getMetadataFor(string|object $value) If the method was called with the same class name (or an object of that class) before, the same metadata instance is returned. If the factory was configured with a cache, this method will first look for an existing metadata instance in the cache. If an existing instance is found, it will be returned without further ado. Otherwise, a new metadata instance is created. If the factory was configured with a loader, the metad

ClassMetadataFactory deprecated

class ClassMetadataFactory extends LazyLoadingMetadataFactory deprecated since version 2.5, to be removed in 3.0. Use {@link LazyLoadingMetadataFactory} instead. Alias of {@link LazyLoadingMetadataFactory}. Methods __construct(LoaderInterface $loader = null, CacheInterface $cache = null) Creates a new metadata factory. from LazyLoadingMetadataFactory MetadataInterface getMetadataFor(mixed $value) Returns the metadata for the given value. from LazyLoadingMetadataFactory bool h

ClassMetadataFactory

class ClassMetadataFactory implements ClassMetadataFactoryInterface Returns a {@link ClassMetadata}. Traits ClassResolverTrait Resolves a class name. Methods __construct(LoaderInterface $loader, Cache $cache = null) ClassMetadataInterface getMetadataFor(string|object $value) If the method was called with the same class name (or an object of that class) before, the same metadata instance is returned. bool hasMetadataFor(mixed $value) Checks if class has metadata. Deta

ClassMetadata::setGroupSequenceProvider()

setGroupSequenceProvider(bool $active) Sets whether a group sequence provider should be used. Parameters bool $active Exceptions GroupDefinitionException

ClassMetadata::setGroupSequence()

ClassMetadata setGroupSequence(array $groupSequence) Sets the default group sequence for this class. Parameters array $groupSequence An array of group names Return Value ClassMetadata Exceptions GroupDefinitionException

ClassMetadata::mergeConstraints()

mergeConstraints(ClassMetadata $source) Merges the constraints of the given metadata into this object. Parameters ClassMetadata $source The source metadata

ClassMetadata::merge()

merge(ClassMetadataInterface $classMetadata) Merges a {@link ClassMetadataInterface} in the current one. Parameters ClassMetadataInterface $classMetadata

ClassMetadata::isGroupSequenceProvider()

bool isGroupSequenceProvider() Returns whether the "Default" group is overridden by a dynamic group sequence obtained by the validated objects. If this method returns true, the class must implement {@link \Symfony\Component\Validator\GroupSequenceProviderInterface}. This interface will be used to obtain the group sequence when an object of this class is validated. Return Value bool Returns true if the "Default" group is overridden by a dynamic group sequence

ClassMetadata::hasPropertyMetadata()

bool hasPropertyMetadata(string $property) Check if there's any metadata attached to the given named property. Parameters string $property The property name Return Value bool

ClassMetadata::hasGroupSequence()

bool hasGroupSequence() Returns whether the "Default" group is overridden by a group sequence. If it is, you can access the group sequence with {@link getGroupSequence()}. Return Value bool Returns true if the "Default" group is overridden