xdi2.core.Graph.getStatement()方法的使用及代码示例

x33g5p2x  于2022-01-20 转载在 其他  
字(3.8k)|赞(0)|评价(0)|浏览(161)

本文整理了Java中xdi2.core.Graph.getStatement()方法的一些代码示例,展示了Graph.getStatement()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Graph.getStatement()方法的具体详情如下:
包路径:xdi2.core.Graph
类名称:Graph
方法名:getStatement

Graph.getStatement介绍

[英]Gets a statement in this graph.
[中]获取此图中的语句。

代码示例

代码示例来源:origin: projectdanube/xdi2

@Override
public Statement getStatement(XDIStatement XDIstatement) {
  return this.getGraph().getStatement(XDIstatement);
}

代码示例来源:origin: projectdanube/xdi2

Statement resolvedStatement = resolvedGraph.getStatement(resolvedStatementAddress);

代码示例来源:origin: projectdanube/xdi2

assertTrue(graph22.containsStatement(XDIStatement.create("=markus/#friend/=neustar=les")));
assertTrue(graph22.containsStatement(XDIStatement.create("=markus<#email>/&/\"markus@projectdanube.org\"")));
assertEquals(graph22.getStatement(XDIStatement.create("=neustar//=les")).getXDIStatement(), XDIStatement.create("=neustar//=les"));
assertEquals(graph22.getStatement(XDIStatement.create("=markus/#friend/=neustar=les")).getXDIStatement(), "=markus/#friend/=neustar=les");
assertEquals(graph22.getStatement(XDIStatement.create("=markus<#email>/&/\"markus@projectdanube.org\"")).getXDIStatement(), "=markus<#email>/&/\"markus@projectdanube.org\"");
assertTrue(graph22.getStatement(XDIStatement.create("=neustar//=les")) instanceof ContextNodeStatement);
assertTrue(graph22.getStatement(XDIStatement.create("=markus/#friend/=neustar=les")) instanceof RelationStatement);
assertTrue(graph22.getStatement(XDIStatement.create("=markus<#email>/&/\"markus@projectdanube.org\"")) instanceof LiteralStatement);
assertTrue(graph22.getStatement(XDIStatement.create("=neustar//=les")).getXDIStatement().isContextNodeStatement());
assertTrue(graph22.getStatement(XDIStatement.create("=markus/#friend/=neustar=les")).getXDIStatement().isRelationStatement());
assertTrue(graph22.getStatement(XDIStatement.create("=markus<#email>/&/\"markus@projectdanube.org\"")).getXDIStatement().isLiteralStatement());
assertTrue(graph23.containsStatement(XDIStatement.create("=markus/#friend/=neustar=les")));
assertTrue(graph23.containsStatement(XDIStatement.create("=markus<#email>/&/\"markus@projectdanube.org\"")));
assertEquals(graph23.getStatement(XDIStatement.create("=neustar//=les")).getXDIStatement(), XDIStatement.create("=neustar//=les"));
assertEquals(graph23.getStatement(XDIStatement.create("=markus/#friend/=neustar=les")).getXDIStatement(), "=markus/#friend/=neustar=les");
assertEquals(graph23.getStatement(XDIStatement.create("=markus<#email>/&/\"markus@projectdanube.org\"")).getXDIStatement(), "=markus<#email>/&/\"markus@projectdanube.org\"");
assertTrue(graph23.getStatement(XDIStatement.create("=neustar//=les")) instanceof ContextNodeStatement);
assertTrue(graph23.getStatement(XDIStatement.create("=markus/#friend/=neustar=les")) instanceof RelationStatement);
assertTrue(graph23.getStatement(XDIStatement.create("=markus<#email>/&/\"markus@projectdanube.org\"")) instanceof LiteralStatement);
assertTrue(graph23.getStatement(XDIStatement.create("=neustar//=les")).getXDIStatement().isContextNodeStatement());
assertTrue(graph23.getStatement(XDIStatement.create("=markus/#friend/=neustar=les")).getXDIStatement().isRelationStatement());
assertTrue(graph23.getStatement(XDIStatement.create("=markus<#email>/&/\"markus@projectdanube.org\"")).getXDIStatement().isLiteralStatement());

相关文章