commons-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ansell <...@git.apache.org>
Subject [GitHub] commons-rdf pull request #43: COMMONSRDF-49: Make AbstractRDFParser serializ...
Date Wed, 15 Nov 2017 22:14:21 GMT
Github user ansell commented on a diff in the pull request:

    https://github.com/apache/commons-rdf/pull/43#discussion_r151267617
  
    --- Diff: commons-rdf-simple/src/main/java/org/apache/commons/rdf/simple/experimental/AbstractRDFParser.java
---
    @@ -200,19 +200,19 @@
          *         been set
          */
         public Optional<IRI> getSourceIri() {
    -        return sourceIri;
    +        return Optional.ofNullable(sourceIri);
         }
     
    -    private Optional<RDF> rdfTermFactory = Optional.empty();
    -    private Optional<RDFSyntax> contentTypeSyntax = Optional.empty();
    -    private Optional<String> contentType = Optional.empty();
    -    private Optional<IRI> base = Optional.empty();
    -    private Optional<InputStream> sourceInputStream = Optional.empty();
    -    private Optional<Path> sourceFile = Optional.empty();
    -    private Optional<IRI> sourceIri = Optional.empty();
    +    private RDF rdfTermFactory = null;
    +    private RDFSyntax contentTypeSyntax = null;
    +    private String contentType = null;
    +    private IRI base = null;
    +    private InputStream sourceInputStream = null;
    --- End diff --
    
    This may be a sticking point for actually enabling ``Serializable``, but the changes to
not use optional field values look good to me.


---

---------------------------------------------------------------------
To unsubscribe, e-mail: dev-unsubscribe@commons.apache.org
For additional commands, e-mail: dev-help@commons.apache.org


Mime
View raw message