Jarves\ORM\Builder\Propel::addRelation PHP Method

addRelation() protected method

protected addRelation ( Object $object, Jarves\Admin\FieldTypes\RelationDefinitionInterface $relation, &$xmlTable )
$object Jarves\Configuration\Object
$relation Jarves\Admin\FieldTypes\RelationDefinitionInterface
    protected function addRelation(Object $object, RelationDefinitionInterface $relation, &$xmlTable)
    {
        $possibleRelations = [AbstractStorage::MANY_TO_ONE, AbstractStorage::ONE_TO_ONE];
        if (in_array($relation->getType(), $possibleRelations)) {
            $this->addForeignKey($object, $relation, $xmlTable);
        }
    }