Author: hasan
Date: Thu Nov 9 21:48:45 2017
New Revision: 1814794
URL: http://svn.apache.org/viewvc?rev=1814794&view=rev
Log:
CLEREZZA-1017: Add discussion text to Tutorial 01
Modified:
clerezza/site/production/getting-started/tutorial/tutorial-01/index.html
Modified:
clerezza/site/production/getting-started/tutorial/tutorial-01/index.html
URL:
http://svn.apache.org/viewvc/clerezza/site/production/getting-started/tutorial/tutorial-01/index.html?rev=1814794&r1=1814793&r2=1814794&view=diff
==============================================================================
--- clerezza/site/production/getting-started/tutorial/tutorial-01/index.html
(original)
+++ clerezza/site/production/getting-started/tutorial/tutorial-01/index.html
Thu Nov 9 21:48:45 2017
@@ -146,7 +146,15 @@ org.apache.clerezza.commons.rdf.BlankNod
"Hasan"
</div>
<h2>Discussion</h2>
- <p></p>
+ <p>
+ The subject of the two triples is a blank node
as defined at line 15. The predicate 'hasFirstName' in the first triple is
represented by a specific IRI
'http://clerezza.apache.org/2017/01/example#hasFirstName', whereas the object
is a plain literal having the value 'Hasan'. The second triple has the
predicate 'isA' which is defined as the IRI
'http://clerezza.apache.org/2017/01/example#isA', and its object is of type IRI
as well, namely the IRI
'http://clerezza.apache.org/2017/01/example#ClerezzaUser'.
+ </p>
+ <p>
+ Both triples are instantiated using TripleImpl
as shown at line 23 and 24. The triples are then added to a SimpleGraph which
is an in-memory implementation of a graph based on java.util.AbstractCollection.
+ </p>
+ <p>
+ Line 30 is an important statement to retrieve
triples from a graph. The method 'filter' has the function to restrict triples
to be retrieved. It takes three arguments: subject, predicate, and object for
each triple in the graph to match against. A null argument matches any value.
Triples which match the given filter arguments are returned by the method in
form of an iterator.
+ </p>
<p>
Note: Any comments and suggestions for improvements
are welcome. Please send your feedback to <a
href="mailto:[email protected]">[email protected]</a>
</p>