You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@jena.apache.org by "Claude Warren (JIRA)" <ji...@apache.org> on 2013/01/12 11:48:12 UTC

[jira] [Created] (JENA-381) Composed graphs do no generate listener event for deletion on iterator.

Claude Warren created JENA-381:
----------------------------------

             Summary: Composed graphs do no generate listener event for deletion on iterator.
                 Key: JENA-381
                 URL: https://issues.apache.org/jira/browse/JENA-381
             Project: Apache Jena
          Issue Type: Bug
          Components: Jena
    Affects Versions: Jena 2.7.4, Jena 2.10.0
            Reporter: Claude Warren


Composed graphs do no generate listener event for deletion on iterator as indicated by failure of testEventDeleteByFind() in AbstractTestGraph

Analysis:

returned iterator is a composite of the iterators on the base graph. e.g. AIter.andThen( BIter ).  When remove is called it is executed against the base graph.  The composed graph does not listen to the base graphs and thus does not broadcast the subgraph deletion to its listeners.

Potential Solution:

Have the composite graph register as a listener to the base graphs and rebroadcast all events to its listeners.  I expect that this will cause duplicate notification for currently broadcast events and that several methods that modify the graph and broadcast the change will have to be modified so as not to announce the change but let the underlying graph announce it.

Alternative Solution:

Modify the iterator so that it wraps the currently returned iterator trap the delete method and announces the deletion to its listeners after calling the delete on the wrapped iterator.

The alternative solution is probably easier to implement.


--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators
For more information on JIRA, see: http://www.atlassian.com/software/jira