Tharos / LeanMapper

Lean Mapper is a tiny ORM based on powerful Dibi database abstraction library for PHP.
MIT License
87 stars 35 forks source link

Entity property with custom column name #91

Closed castamir closed 8 years ago

castamir commented 8 years ago

See space between property name and brackets

/**
 * @property int $foo(myfoo)
 * @property int $bar (mybar)
 */

//...

$reflection = $entity::getReflection($this);
$property = $reflection->getEntityProperty('foo')->getColumn(); // foo
$property = $reflection->getEntityProperty('bar')->getColumn(); // mybar