Search in sources :

Example 1 with SerializerContext

use of org.qi4j.library.rdf.serializer.SerializerContext in project qi4j-sdk by Qi4j.

the class ApplicationSerializer method serialize.

public Graph serialize(Application app) {
    Graph graph = new GraphImpl();
    SerializerContext context = new SerializerContext(graph);
    ApplicationVisitor applicationVisitor = new ApplicationVisitor(context);
    ((Application) app).descriptor().accept(applicationVisitor);
    return graph;
}
Also used : Graph(org.openrdf.model.Graph) GraphImpl(org.openrdf.model.impl.GraphImpl) SerializerContext(org.qi4j.library.rdf.serializer.SerializerContext)

Aggregations

Graph (org.openrdf.model.Graph)1 GraphImpl (org.openrdf.model.impl.GraphImpl)1 SerializerContext (org.qi4j.library.rdf.serializer.SerializerContext)1