<?xml version="1.0" encoding="UTF-8"?>
<!--
  Licensed to the Apache Software Foundation (ASF) under one or more
  contributor license agreements.  See the NOTICE file distributed with
  this work for additional information regarding copyright ownership.
  The ASF licenses this file to You under the Apache License, Version 2.0
  (the "License"); you may not use this file except in compliance with
  the License.  You may obtain a copy of the License at

      http://www.apache.org/licenses/LICENSE-2.0

  Unless required by applicable law or agreed to in writing, software
  distributed under the License is distributed on an "AS IS" BASIS,
  WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  See the License for the specific language governing permissions and
  limitations under the License.
-->
<!DOCTYPE document PUBLIC "-//APACHE//DTD Documentation V2.0//EN" "http://forrest.apache.org/dtd/document-v20.dtd">
<document>
   <header>
      <title>Welcome to the org.apache.forrest.plugin.input.foaf Plugin</title>
   </header>
   <body>
      <section id="overview">
         <title>Apache Forrest - FOAF Plugin</title>
            <p>Renders a and aggregates <a href="http://xmlns.com/foaf/spec/">FOAF</a> documents into human readable form.</p>
   </section>
      <section id="samples">
         <title>Samples</title>
            <p>This section includes links to a number of samples using this plugin.
             The plugin is intended to be self documenting through these samples.
             If you require further help please ask on the user mailing list.
            </p>
         <section id="sample-1">
            <title>Sample FOAF data</title>
            <p>Details of the default FOAF file for this website is currently 
            supported in the following formats.</p>
            <ul>
               <li><a href="personDetails.source.xml">FOAF</a></li>
               <li><a href="personDetails.xml">XDoc</a></li>
               <li><a href="personDetails.html">HTML</a></li>
               <li><a href="personDetails.pdf">PDF</a></li>
            </ul>
            
            <p>It is also possible to process RDF files that use the rdf:seeAlso element to
            point at document providing more information. For example:</p>
            
            <ul>
               <li><a href="personDetails/rgardler.source.xml">FOAF</a></li>
               <li><a href="personDetails/rgardler.xml">XDoc</a></li>
               <li><a href="personDetails/rgardler.html">HTML</a></li>
               <li><a href="personDetails/rgardler.pdf">PDF</a></li>
            </ul>
         </section>
	  <section id="sample-2">
         <title>FOAF index</title>
         <p>This plugin can also be used to aggregate FOAF documents from various sources. 
         To index and view FOAF documents using this plugin, add the URIs of the FOAF documents in <code>samples/foafIndex.xml</code>. 
         Since the FOAF data can be obtained from anywhere you want, the FOAF data is assured to be kept up to date. 
         </p>
         
         <p>Add an "id" for the person and the locaction of that person's FOAF file as shown below. The "id" will be used in indexing the FOAF data.</p>
         <p>Example:</p>
         <source>
            <![CDATA[
   <people>
      <person id="johnDoe" location="http://example.org/john/foaf.rdf" />
      <person id="janeDoe" location="http://example.org/jane/foaf.rdf" />
   </people>
   ]]>
        </source>        
      <p>A working example for FOAF files indexing to explore the FOAF data
       can be found <a href="people/index.html">here</a>.</p>
	  </section>
	  
	  <section id="sample-3">
	     <title>Linking FOAF files</title>
	            <p>Tools such as the <a href="http://pingthesemanticweb.com/">PingTheSemanticWeb web service</a>
	            (which collects notifications about presence or updates to RDF data on the web), and 
	            <a href="http://sioc-project.org/firefox"> Semantic Radar extension for Firefox</a> (which lets users to 
	            discover RDF data on web pages while browsing), will be able to find the FOAF data associated with the 
	            website generated by this plugin.</p> 
	            <p>You simply have to add the following markup in the <code>head</code> of the HTML to link and make 
	            your FOAF data auto-discoverable.</p> 
	            <source>
	            <![CDATA[
   <link rel="meta" type="application/rdf+xml" title="FOAF" href="http://example.org/people/~you/foaf.rdf" />
	            ]]>
	            </source>
	            <p>
	            This can be done by using the <code>foaf-embedded</code> contract by passing the URL of the FOAF
	            file in the following manner:</p>
	            <source>
                <![CDATA[
   <forrest:contract name="foaf-embedded">
      <forrest:property name="foaf-embedded-links">
         <foaf url="http://example.org/people/~you/foaf.rdf"/>
      </forrest:property>
   </forrest:contract>
   ]]>
  </source>
  
	            
  </section>
	
      </section>
   </body>
   
</document>
