VertexDef contains only a single method lookup(Vertex) which returns the VertexDefTrait for a given Vertex. We want to be able to look up EdgeDefTraits from Edges in a similar fashion. The logic of lookup(Vertex) is agnostic. We should be able to write a unified method and a couple of thin wrapper methods.
[x] Create an ElementDef class, move lookup(Vertex) to it
VertexDef contains only a single method lookup(Vertex) which returns the VertexDefTrait for a given Vertex. We want to be able to look up EdgeDefTraits from Edges in a similar fashion. The logic of lookup(Vertex) is agnostic. We should be able to write a unified method and a couple of thin wrapper methods.