Possible changes 

Possibilities for discussion.

1. Quads are not extended Triples (useful if the default graph is a union of named graphs but this isn't always the case) but share a common supertype.
1.  Add a CONTRIBUTING file
1.  3 parts of a Literal
1.  getObject is a Resource, not a Literal
On Tue, Jun 10, 2014 at 9:27 AM, Andy Seaborne <notifications@github.com>
wrote:

> In src/main/java/org/apache/commons/rdf/Quad.java:
>
> >
> >      IRI getGraph();
> >
> > +    /** View as a Triple */
> > +    Triple asTriple() ;
>
> Maybe we have a bit of a terminolgy problem.
>
> Triple and Quad would have separate equality conditions.
>

Because of the equality issue, banana-rdf has to remove the context/graph
information in many occasion in order to be able to compare.

So I would prefer if libraries were not relying on .equals() for the
equality.  Why not providing several equalities through different
Comparator-s?

>
> asTriple is a conversion operation and produces a new object if
> necessary. It's a view but a view object is distinct from the underlying
> object.
>
Converting quads to triples does seem to happen a reasonable amount so some
> compact way to do is advantageous but not a strict requirement. The
> converse Triple.asQuad(graph) could be provided.
>

It should not be necessary.


> TermTuple does not then create a value-equality problem - each of Triple
> and Quad will need to provide its own hashCode and equality operations.
>
Would I be able to compare TermTuple-s from Jena and Sesame?


> If the operations on TermTuple are confusing (and repeating lower down
> does hint they are) and if we don't want get(index) operations common to
> Triple and Quad (not in patch - I have found them useful in some low
> level storage code and not very useful in an API).
>
> Proposal : Drop TermTuple as common subclass for now.
>
> —
> Reply to this email directly or view it on GitHub
> <https://github.com/wikier/commons-rdf/pull/3/files#r13580720>.
>