You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Right now when limit() or sort() is called on an ArrayList, the action is completed immediately and the returned list already has the limit or sort applied.
This has two major drawbacks:
CPU cycles are wasted if the list is sorted again later
The limit and sort cannot be cancelled like they can with other lists by passing null into the method.
There may be other scenarios where ArrayList differs from other list implementations. We should seek to bring it in line with them so its behaviour is consistent and predictable.
Notes
A lot of work was put into making EagerLoadedList consistent with the way other relation lists work - a lot of its code can probably be reused for this.
Acceptance criteria
ArrayList behaves similarly to other lists - the result of its method calls is predictable based on what the result would be from calling those methods on other lists
Code duplication is avoided (e.g. instead of directly copying code from EagerLoadedList, see if it can be abstracted to a trait)
The text was updated successfully, but these errors were encountered:
Right now when
limit()
orsort()
is called on anArrayList
, the action is completed immediately and the returned list already has the limit or sort applied.This has two major drawbacks:
null
into the method.There may be other scenarios where
ArrayList
differs from other list implementations. We should seek to bring it in line with them so its behaviour is consistent and predictable.Notes
EagerLoadedList
consistent with the way other relation lists work - a lot of its code can probably be reused for this.Acceptance criteria
ArrayList
behaves similarly to other lists - the result of its method calls is predictable based on what the result would be from calling those methods on other listsEagerLoadedList
, see if it can be abstracted to a trait)The text was updated successfully, but these errors were encountered: