On 23/11/12 10:49, Reto Bachmann-Gmür wrote:
In clerezza we put a strong emphasis on identity criteria. This is also a
reason why no factories are part of the API. Two nodes are identical and
can be used interchangeably iff the are equals according to the relevant
specs, so it shall not matter if you got your instance from a factory or
implemented the interface yourself, the two instances behave the same in
all contexts.

Same debate for Jena Graph SPI a long time ago.

The obvious follow-through to me is that there should be classes (final even), not interfaces, because they have strong equality rules.

Only if the interfaces are to be implemented directly, and not via a copy transformation, do interfaces seem to have a real reason for being there.

Identity was also the reason for having the distinction
between immutable and mutable graphs. The RDF specification define when two
graphs are equals (they are if they are isomorphic) but this criterion can
only be matched to the Object.equals if the graph aren't mutable (as you
otherwise run into big problems).

Slight confusion between identity and equivalence. Two graph are equivalent by bNode-isomorphism; they are still different.

Equivalence is context sensitive. There may be other information, now or later, that breaks that equivalence. But if two things have the same identity, that can't happen.

RDF 1.1 is (probably) going to spell this more clearly.

Work-in-progress:
http://www.w3.org/2011/rdf-wg/wiki/User:Rcygania2/B-Scopes

        Andy

Reply via email to