H
hal
I have a HashMap containing references to rather large value objects (
Vector objects containing > 1000 other objects each )
I rarely need to actually access these values -> and performance in
accessing them is not an issue.
Therefore I have made my own implementation of the HashMap where I
overwrite get and put and instead of putting in a reference to the
objects I serialize the values and store a String with a path to the
serialized object ( get reads the object - so the implementation is
somewhat transparent though any object stored now is immutable ).
Now in rare cases I need to loop through the entire Map using the
Map.Entity collection.
How do I control when the objects are deserialized in the loop in a way
that is transparent to the user of the HashMap? What implementing method
is called when calling getValue() on a Map.Entity object?
Regards
Hans Lund
Vector objects containing > 1000 other objects each )
I rarely need to actually access these values -> and performance in
accessing them is not an issue.
Therefore I have made my own implementation of the HashMap where I
overwrite get and put and instead of putting in a reference to the
objects I serialize the values and store a String with a path to the
serialized object ( get reads the object - so the implementation is
somewhat transparent though any object stored now is immutable ).
Now in rare cases I need to loop through the entire Map using the
Map.Entity collection.
How do I control when the objects are deserialized in the loop in a way
that is transparent to the user of the HashMap? What implementing method
is called when calling getValue() on a Map.Entity object?
Regards
Hans Lund