Esensi\Model\Traits\RelatingModelTrait::getRelationship PHP Method

getRelationship() public method

Return the relationship configurations.
public getRelationship ( string $name ) : array
$name string of related model
return array
    public function getRelationship($name)
    {
        // If relationship does not exist throw an exception
        if (!$this->isRelationship($name)) {
            $exception = new ModelNotFoundException();
            $exception->setModel($name);
            throw $exception;
        }
        return $this->relationships[$name];
    }