From: Olaf H. <ha...@in...> - 2009-06-23 15:18:24
|
On Friday 19 June 2009 17:53:25 Tim Pizey wrote: > Hi Olaf, Jennifer and all, > > I have started to bringNG4J inline with current Jena. > > Most changes are pretty trivial. However there appears to be a > hack where we treat List<NamedGraph> and List<Graph> > as covariant which will no longer work. Where does this "problem" surface - in the constructors of the UnionGraph class? It is strange because a NamedGraph is a Graph. For this reason the compiler should understand that a list of NamedGraph objects can be used as a list of Graph objects. > Do you have a plan, Not really a good one. We could use List<Graph> instead of List<NamedGraph> and since we add only NamedGraph objects to this list we can safely cast each member of the list to a NamedGraph. However, that's a hack. What do you (and the others) think? > are there other pitfalls? I don't know. Olaf |