I would like to know how can I override indexOf()
method in a subclass of ArrayList
. I need to use the same accessing that super to the private transient elementData
var.
How can I solve my design?
EDIT: Could it be a valid solution changing the call to elementData[i] to a similar this.get(i) (which is actually allowed?). Would it corrupt or break the logic someway?