如何在不使用查询生成器的情况下,在Laravel 4中创建一个新的Eloquent 的集合?
There is a newCollection()
method which can be overridden by that doesn't really do job because that is only being used when we are querying a set result.
I was thinking of building an empty Collection, then fill it with Eloquent objects. The reason I'm not using array is because I like Eloquent Collections methods such as contains
.
If there are other alternatives, I would love to hear them out.