commons-issues mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Stian Soiland-Reyes (JIRA)" <>
Subject [jira] [Created] (COMMONSRDF-58) Refactor RDFParser fluent interface
Date Thu, 16 Feb 2017 12:07:42 GMT
Stian Soiland-Reyes created COMMONSRDF-58:

             Summary: Refactor RDFParser fluent interface
                 Key: COMMONSRDF-58
             Project: Apache Commons RDF
          Issue Type: Bug
          Components: parser, api
            Reporter: Stian Soiland-Reyes
            Assignee: Stian Soiland-Reyes
             Fix For: 1.0.0

Given [discussion on dev|]
I think we agreed on removing the always-clone-immutable feature, and several suggestions
for improvements of [RDFParser|].

Suggestions were: 

* Mutate directly on setters (builder does not need to be thread safe all the time)
* Add a {{freeze()}} to make a thread-safe clone -- it will return an unfreezed version on
any mutating setters
* Use names like {{withSource()}} etc instead of {{source()}}
* Bind {{RDFSyntax}} when getting a parser -- e.g. {{RDF.createParser(RDFSyntax.TURTLE)}}

* .. or new registry?
* Return a {{CompletableFuture}} rather than just a {{Future}} (so they can be easily composed)
* Allow direct synchronous calls without {{Future}}
* Short-cut calls like {{parser.parse(source, dest)}}
* Support streaming parsers
* Support arbitrary configuration options? e.g. {{parser.setOption(CustomOption5, "Fred"}}

This message was sent by Atlassian JIRA

View raw message