Use overridable factory method for EOLQueryEngine graph node wrapping

GraphNodeWrapper allows us to hold weak references to nodes, to save memory.
However, when using time-aware queries, we cannot just recover the original
node from its ID: we need the timepoint as well. That means that we need to
wrap the node with a different class.

Until now, we basically had it done on a case-by-case basis, but that was
prone to slips: for instance, following a model element reference from a
time-aware node would give you a non-time-aware wrapper. This was OK until
you tried to run a large query, which resulted in GC'ing of the weak references:
from that point onwards, you'd start to see odd NullPointerExceptions in places.
34 files changed