getEntityMetadata() public method

Get the Entity metadata object
public getEntityMetadata ( boolean $shallow = false ) : Entity
$shallow boolean
return Bravo3\Orm\Mappers\Metadata\Entity
Example #1
0
 /**
  * Get the metadata for an entity, including column information
  *
  * @param string|object $entity Entity or class name of the entity
  * @return Entity
  */
 public function getEntityMetadata($entity)
 {
     $class_name = Reader::getEntityClassName($entity);
     if (!isset($this->metadata_cache[$class_name])) {
         $parser = new AnnotationMetadataParser($class_name);
         $this->metadata_cache[$class_name] = $parser->getEntityMetadata();
     }
     return $this->metadata_cache[$class_name];
 }