You are here

public function ClassMetadata::getPropertyMetadata in Zircon Profile 8

Same name and namespace in other branches
  1. 8.0 vendor/symfony/validator/Mapping/ClassMetadata.php \Symfony\Component\Validator\Mapping\ClassMetadata::getPropertyMetadata()

Returns all metadata instances for the given named property.

If your implementation does not support properties, simply throw an exception in this method (for example a <tt>BadMethodCallException</tt>).

Parameters

string $property The property name.:

Return value

PropertyMetadataInterface[] A list of metadata instances. Empty if no metadata exists for the property.

Overrides PropertyMetadataContainerInterface::getPropertyMetadata

2 calls to ClassMetadata::getPropertyMetadata()
ClassMetadata::accept in vendor/symfony/validator/Mapping/ClassMetadata.php
ClassMetadata::getMemberMetadatas in vendor/symfony/validator/Mapping/ClassMetadata.php
Returns all metadatas of members describing the given property.

File

vendor/symfony/validator/Mapping/ClassMetadata.php, line 428

Class

ClassMetadata
Default implementation of {@link ClassMetadataInterface}.

Namespace

Symfony\Component\Validator\Mapping

Code

public function getPropertyMetadata($property) {
  if (!isset($this->members[$property])) {
    return array();
  }
  return $this->members[$property];
}