start("mvn:org.apache.clerezza/rdf.stable.serializer")start("mvn:org.apache.clerezza/rdf.file.storage")Smart Content Binding (SCB) is an open source framework developed by clerezza.org aiming primarily at providing a java implementation of the graph data model specified by W3C RDF and functionalities to operate on that data model. SCB offers a service interface to access multiple named graphs and it can use various providers to manage RDF graphs in a technology specific manner, e.g., using Jena (TBD) or Sesame . It also provides façades that allow an application to use Jena or Sesame (TBD) APIs to process RDF graphs (note that the choice of a façade is independent of the chosen backend; you can for example use the Jena façade to write your code against the Jena API while using the Sesame provider to store your data in a Sesame store). Furthermore, SCB offers a serialization and a parsing service to convert a graph into a certain representation (format) and vice versa. In order to support ontologies usage, SCB provides a tool to convert ontologies defined in various formats including RDF/XML into Java classes.
SCB comprises the following architectural components as depicted in Fig. 1:
Figure 1: SCB Architecture
The Core contains interface definitions of the RDF graph data model and its
implementation. The three main classes are Graph, MGraph,
and TripleCollection. The class Graph represents an
immutable RDF Graph, as such its identity criterion is defined in terms of
graph-isomorphism. The class MGraph represents a mutable RDF Graph,
which enables triples to be added to or removed from a graph. The class
TripleCollection is the super class of both the class Graph
and MGraph.
SCB Core provides three services: TcManager [4] allows access to
the various TripleCollections, Parser [5] and
Serializer [6] to allow reading and writing graphs from and to
various formats. In an OSGi environment these services are accessed using the
service registry or injected using OSGi Declarative Services. In a non OSGi environment
static factory methods are used to return an instance.
The TcManager delegates actual processing tasks to a specific Storage Provider
chosen from a set of Storage Providers based on their priority number (weight).
Storage Providers can be dynamically bound to or unbound from the Core.
The functionality required by the Parser and Serializer is delegated to registered
Parsing and Serializing Providers respectively, according to their capability
(supported formats). Later registered providers shadow previous ones for the same format.
The current implementation of SCB includes a Jena Façade. The Jena Façade allows an application to use Jena API to manipulate a TC.
In order to ease operations on a resource in a TC, the Utilities component provides a class with a set of useful methods, e.g., to delete all triples (statements) with the resource as subject and a specified predicate.
Finally, the Ontologies Tool contains a standalone application called SchemaGen to generate the Java source code with constants from an ontology description.
Each architectural component described above comprises one or more artifacts as
listed in Table 1.
Table 1: Artifacts of each architectural components
| Architectural Component | Artifact | Artifact Type |
|---|---|---|
| Core | org.apache.clerezza.rdf.core | Jar and OSGi bundle |
| org.apache.clerezza.rdf.core.test | Jar and OSGi bundle | |
| Façades | org.apache.clerezza.rdf.jena.facade | Jar and OSGi bundle |
| Utilities | org.apache.clerezza.rdf.utils | Jar and OSGi bundle |
| Storage Providers | org.apache.clerezza.rdf.sesame.storage | Jar and OSGi bundle |
| org.apache.clerezza.rdf.jena.storage | Jar and OSGi bundle | |
| Parsing Providers | org.apache.clerezza.rdf.jena.parser | Jar and OSGi bundle |
| Serializing Providers | org.apache.clerezza.rdf.jena.serializer | Jar and OSGi bundle |
| Ontologies Tool | org.apache.clerezza.rdf.tool.schemagen | Executable jar |
If you want to build SCB from its sources, you need JDK version 1.6 to compile. Maven version 2.0.9 has been used to build SCB.
To develop an application on top of SCB, you need to have the Core and optionally Utilities and Façades.
To deploy an application which uses SCB, Java(TM) SE Runtime Environment 6 or higher is needed. If the application does not use OSGi, then the SCB Core, the jars required for compilation, as well as the needed implementations (typically one provider for storage, serialization, and parsing) must be in the classpath. If the application uses OSGi, these jars are loaded as bundles, and to run in OSGi, Declarative Services must be enabled (see the documentation of your OSGi container).
The use of SCB in an OSGi environment has been tested with Apache Felix [7] and Eclipse Equinox [8].
For your convenience you may access a web-form at the Uri-Path /graph/upload-form.
ModificationStatus is a global object with a field isModified indicating if some saveable information has been changed on the page.
isModified is set to true), or alternatively elements that fire change events can be registered for being monitored using watchElements (the following example adds listeners to all input fields).watchElements takes a jquery selector string to specify the elements to be watched.StatusMessage allows to add/remove status messages (e.g. saving) to an overlay (absolut positioned div) which follows the mouse pointer. During a ajax request a status message can be added and after the response the message can be removed. Each message is added to an array.
Overlay behave similarly to an OS window. Unlike true browser popup windows, the overlay is floating DHTML elements embedded directly within the page context. The Overlay is positioned above the flow of a page and is draggable, resizable and has a close button. The Overlay has a method show with arguments body, header, width and height, which renders the overlay. The body and the header can be html elements or text. The width (default value: 46em) and height (default value: 37em) can be defined absolutely or relatively.
Smart Content Binding (SCB) is an open source framework developed by clerezza.org aiming primarily at providing a java implementation of the graph data model specified by W3C RDF and functionalities to operate on that data model. SCB offers a service interface to access multiple named graphs and it can use various providers to manage RDF graphs in a technology specific manner, e.g., using Jena (TBD) or Sesame . It also provides façades that allow an application to use Jena or Sesame (TBD) APIs to process RDF graphs (note that the choice of a façade is independent of the chosen backend; you can for example use the Jena façade to write your code against the Jena API while using the Sesame provider to store your data in a Sesame store). Furthermore, SCB offers a serialization and a parsing service to convert a graph into a certain representation (format) and vice versa. In order to support ontologies usage, SCB provides a tool to convert ontologies defined in various formats including RDF/XML into Java classes.
The platform provides a web service to check whether the current user owns a certain permission. This service is invoked with a GET-request specifying the resource path /security/check and the query parameter permission. The parameter has the format:
'(' <permission class name> <double-quoted name> <double-quoted actions> ')'.
An example of a valid URL would be: http://localhost:8282/security/check?permission=(java.io.FilePermission "/tmp/*" "read")
As a result of this check the platform returns a response with the code 204, if the user has this permission.
<scr:component enabled="true" name="org.example.html.BookFormRenderlet"> <implementation class="org.example.html.BookFormRenderlet"/> <service servicefactory="false"> <provide interface="org.apache.clerezza.platform.typerendering.Renderlet"/> </service> <property name="service.pid" value="org.example.html.BookFormRenderlet"/> <reference name="renderletManager" interface="org.apache.clerezza.platform.typerendering.RenderletManager" cardinality="1..1" policy="static" bind="bindRenderletManager" unbind="unbindRenderletManager"/> </scr:component>