public function contributeToInverseClass(
        Model $relatedModel,
        ForeignObjectRel $relation
    ) {
        if (!$this->relation->isHidden()) {
            $inverseAccessor = $this->getInverseDescriptor();
            $relatedModel->getMeta()->getConcreteModel()->addToClass(
                $relation->getAccessorName(),
                $inverseAccessor
            );
        }
    }
public function contributeToInverseClass(
        Model $relatedModel,
        ForeignObjectRel $relation
    ) {
        if (!$this->relation->isHidden()) {
            $inverseAccessor = $this->getInverseDescriptor();
            $relatedModel->getMeta()->getConcreteModel()->addToClass(
                $relation->getAccessorName(),
                $inverseAccessor
            );
        }
    }
public function contributeToInverseClass ( Model $ relatedModel , ForeignObjectRel $ relation ) { if ( ! $ this -> relation -> isHidden ( ) ) { $ inverseAccessor = $ this -> getInverseDescriptor ( ) ; $ relatedModel -> getMeta ( ) -> getConcreteModel ( ) -> addToClass ( $ relation -> getAccessorName ( ) , $ inverseAccessor ) ; } }
We add some properties to the related model class i.e. the inverse model
of the relationship initiated by this field.

e.g. we add the inverse field to use to query when starting on the
inverse side.

@param Model|string     $relatedModel
@param ForeignObjectRel $relation
@author: Eddilbert Macharia (http://eddmash.com)<edd.cowan@gmail.com>
We add some properties to the related model class i . e . the inverse model of the relationship initiated by this field .