com.hp.hpl.jena.rdf.model.AnonId Java Examples

The following examples show how to use com.hp.hpl.jena.rdf.model.AnonId. You can vote up the ones you like or vote down the ones you don't like, and go to the original project or source file by following the links above each example. You may check out the related API usage on the sidebar.
Example #1
Source File: ModelImplJena.java    From semweb4j with BSD 2-Clause "Simplified" License 5 votes vote down vote up
@Override
public BlankNode createBlankNode(String id) {
	// this.modificationCount++;
	// should be unique across models
	AnonId anonid = AnonId.create(id);
	return new JenaBlankNode(com.hp.hpl.jena.graph.NodeFactory.createAnon(anonid));
}
 
Example #2
Source File: JenaNeoNode.java    From neo4jena with Apache License 2.0 5 votes vote down vote up
/**
* Get the id of blank node.
*/
@Override
public AnonId getBlankNodeId() {
 Transaction tx = graphDb.beginTx();
 //AnonId id = AnonId.create(String.valueOf(node.getId()));
 AnonId id = AnonId.create(delegate.getProperty(NeoGraph.PROPERTY_URI).toString());
 tx.success();
 return id;
}
 
Example #3
Source File: NTriples.java    From SolRDF with Apache License 2.0 2 votes vote down vote up
/**
 * Parses the given input as a blank node.
 * 
 * @param blankNodeAsString the blank node string value.
 * @return the {@link Node} Blank node representation of the given value.
 */
private static Node internalAsBlankNode(final String blankNodeAsString) {
	return NodeFactory.createAnon(AnonId.create(blankNodeAsString.substring(2)));	
}
 
Example #4
Source File: TypedNodeMaker.java    From GeoTriples with Apache License 2.0 votes vote down vote up
public Node makeNode(String value) { return Node.createAnon(new AnonId(value)); }