Details
-
Improvement
-
Status: Resolved
-
Major
-
Resolution: Fixed
-
2.0.0-alpha-1
-
None
-
None
-
Reviewed
Description
The implementation of finding the first and last keys in the CellSet is as following:
public Cell first() { return this.delegatee.get(this.delegatee.firstKey()); } public Cell last() { return this.delegatee.get(this.delegatee.lastKey()); }
Recall we have Cell to Cell mapping, therefore the methods bringing the first/last key, which allready return Cell. Thus no need to waist time on the get() method for the same Cell.
Fix: return just the first/lastKey(), should be at least twice more effective.