| 1 | <?php | ||
| 5 | trait Indexable | ||
| 6 | { | ||
| 7 | /** | ||
| 8 | * @param string $index | ||
| 9 | * | ||
| 10 | * @return $this | ||
| 11 | */ | ||
| 12 | 2 | public function indexBy($index) | |
| 13 |     { | ||
| 14 | 2 | $this->getAssociation()->setIndexBy($index); | |
| 15 | |||
| 16 | 2 | return $this; | |
| 17 | } | ||
| 18 | |||
| 19 | /** | ||
| 20 | * @return \Doctrine\ORM\Mapping\Builder\OneToManyAssociationBuilder | ||
| 21 | */ | ||
| 22 | abstract public function getAssociation(); | ||
| 23 | } | ||
| 24 |