DMS\Filter\Mapping\ClassMetadataInterface::mergeRules PHP Method

mergeRules() public method

Merges rules from another metadata object into this one
public mergeRules ( DMS\Filter\Mapping\ClassMetadataInterface $metadata )
$metadata DMS\Filter\Mapping\ClassMetadataInterface
    public function mergeRules(ClassMetadataInterface $metadata);

Usage Example

 /**
  * Checks if the object has interfaces and cascades parsing of annotatiosn
  * to all the interfaces
  *
  * @param ClassMetadataInterface $metadata
  */
 protected function loadInterfaceMetadata(ClassMetadataInterface $metadata)
 {
     foreach ($metadata->getReflectionClass()->getInterfaces() as $interface) {
         $metadata->mergeRules($this->getClassMetadata($interface->getName()));
     }
 }