Package org.apache.clerezza.rdf.utils

Examples of org.apache.clerezza.rdf.utils.GraphNode.addProperty()


  }

  @Override
  public GraphNode getExceptionGraphNode() {
    GraphNode result = new GraphNode(new BNode(), new SimpleMGraph());
    result.addProperty(RDF.type, TYPERENDERING.Exception);
    LiteralFactory factory = LiteralFactory.getInstance();
    result.addProperty(TYPERENDERING.errorSource, new UriRef(renderingSpecification.toString()));
    if (lineNumber != -1) {
      result.addProperty(TYPERENDERING.line, factory.createTypedLiteral(new Integer(lineNumber)));
    }
View Full Code Here


  @Override
  public GraphNode getExceptionGraphNode() {
    GraphNode result = new GraphNode(new BNode(), new SimpleMGraph());
    result.addProperty(RDF.type, TYPERENDERING.Exception);
    LiteralFactory factory = LiteralFactory.getInstance();
    result.addProperty(TYPERENDERING.errorSource, new UriRef(renderingSpecification.toString()));
    if (lineNumber != -1) {
      result.addProperty(TYPERENDERING.line, factory.createTypedLiteral(new Integer(lineNumber)));
    }
    if (columnNumber != -1) {
      result.addProperty(TYPERENDERING.column, factory.createTypedLiteral(Integer.valueOf(columnNumber)));
View Full Code Here

        String documentText = cas.getDocumentText();
        selectorNode.addProperty(new UriRef("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),
                AO.Selector);
        selectorNode.addProperty(new UriRef("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),
                AOSELECTORS.OffsetRangeTextSelector);
        selectorNode.addProperty(new UriRef("http://www.w3.org/1999/02/22-rdf-syntax-ns#type"),
                AOSELECTORS.PrefixPostfixTextSelector);
        selectorNode.addPropertyValue(AOSELECTORS.exact, getSpan(documentText, sel.start, sel.end));
        selectorNode.addPropertyValue(AOSELECTORS.prefix,
                getSpan(documentText, sel.start - 50, sel.start));
        selectorNode.addPropertyValue(AOSELECTORS.postfix,
View Full Code Here

    GraphNode result = new GraphNode(new BNode(), new SimpleMGraph());
    result.addProperty(RDF.type, TYPERENDERING.Exception);
    LiteralFactory factory = LiteralFactory.getInstance();
    result.addProperty(TYPERENDERING.errorSource, new UriRef(renderingSpecification.toString()));
    if (lineNumber != -1) {
      result.addProperty(TYPERENDERING.line, factory.createTypedLiteral(new Integer(lineNumber)));
    }
    if (columnNumber != -1) {
      result.addProperty(TYPERENDERING.column, factory.createTypedLiteral(Integer.valueOf(columnNumber)));
    }
    result.addProperty(TYPERENDERING.message, new PlainLiteralImpl(getMessage()));
View Full Code Here

    result.addProperty(TYPERENDERING.errorSource, new UriRef(renderingSpecification.toString()));
    if (lineNumber != -1) {
      result.addProperty(TYPERENDERING.line, factory.createTypedLiteral(new Integer(lineNumber)));
    }
    if (columnNumber != -1) {
      result.addProperty(TYPERENDERING.column, factory.createTypedLiteral(Integer.valueOf(columnNumber)));
    }
    result.addProperty(TYPERENDERING.message, new PlainLiteralImpl(getMessage()));
    return result;
  }
View Full Code Here

      result.addProperty(TYPERENDERING.line, factory.createTypedLiteral(new Integer(lineNumber)));
    }
    if (columnNumber != -1) {
      result.addProperty(TYPERENDERING.column, factory.createTypedLiteral(Integer.valueOf(columnNumber)));
    }
    result.addProperty(TYPERENDERING.message, new PlainLiteralImpl(getMessage()));
    return result;
  }

}
View Full Code Here

  @GET
  @Path("new")
  public GraphNode emptyPrefixBinding() {
    MGraph resultMGraph = new SimpleMGraph();
    GraphNode result = new GraphNode(new BNode(), resultMGraph);
    result.addProperty(RDF.type, CURIE.CuriePrefixBinding);
    result.addProperty(CURIE.prefix,
        literalFactory.createTypedLiteral("foaf"));
    result.addProperty(CURIE.binding,
        literalFactory.createTypedLiteral("http://xmlns.com/foaf/0.1/"));
    result.addProperty(RDF.type, PLATFORM.HeadedPage);
View Full Code Here

  @Path("new")
  public GraphNode emptyPrefixBinding() {
    MGraph resultMGraph = new SimpleMGraph();
    GraphNode result = new GraphNode(new BNode(), resultMGraph);
    result.addProperty(RDF.type, CURIE.CuriePrefixBinding);
    result.addProperty(CURIE.prefix,
        literalFactory.createTypedLiteral("foaf"));
    result.addProperty(CURIE.binding,
        literalFactory.createTypedLiteral("http://xmlns.com/foaf/0.1/"));
    result.addProperty(RDF.type, PLATFORM.HeadedPage);
    return result;
View Full Code Here

    MGraph resultMGraph = new SimpleMGraph();
    GraphNode result = new GraphNode(new BNode(), resultMGraph);
    result.addProperty(RDF.type, CURIE.CuriePrefixBinding);
    result.addProperty(CURIE.prefix,
        literalFactory.createTypedLiteral("foaf"));
    result.addProperty(CURIE.binding,
        literalFactory.createTypedLiteral("http://xmlns.com/foaf/0.1/"));
    result.addProperty(RDF.type, PLATFORM.HeadedPage);
    return result;
  }
View Full Code Here

    result.addProperty(RDF.type, CURIE.CuriePrefixBinding);
    result.addProperty(CURIE.prefix,
        literalFactory.createTypedLiteral("foaf"));
    result.addProperty(CURIE.binding,
        literalFactory.createTypedLiteral("http://xmlns.com/foaf/0.1/"));
    result.addProperty(RDF.type, PLATFORM.HeadedPage);
    return result;
  }

  /**
   * Saves a PrefixBiding, replacing an existing binding to the same value and
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.