Laravel - Eloquent - Dynamically defined relationship
<p>Is it possible to set a model's relationship dynamically? For example, I have model <code>Page</code>, and I want to add relationship <code>banners()</code> to it without actually changing its file? So does something like this exist:</p>

<pre><code>Page::createRelationship('banners', function(){
    $this-&gt;hasMany('banners');
});
</code></pre>

<p>Or something similar? As they are fetched using the magic methods anyway, perhaps I can add the relationship dynamically?</p>

<p>Thanks!</p>