org.openprovenance.prov.model.Namespace.qualifiedNameToString()方法的使用及代码示例

x33g5p2x  于2022-01-25 转载在 其他  
字(7.0k)|赞(0)|评价(0)|浏览(194)

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

Namespace.qualifiedNameToString介绍

暂无

代码示例

代码示例来源:origin: org.openprovenance.prov/prov-json

  1. @Override
  2. public Bundle newNamedBundle(QualifiedName id, Namespace namespaces,
  3. Collection<Statement> statements) {
  4. Object bundle = getJSONStructure(currentRecords, currentNamespace);
  5. documentBundles.put(currentNamespace.qualifiedNameToString(id), bundle);
  6. // Reset to document-level records and namespaces
  7. currentRecords = documentRecords;
  8. currentNamespace = documentNamespace;
  9. return null;
  10. }

代码示例来源:origin: lucmoreau/ProvToolbox

  1. @Override
  2. public Bundle newNamedBundle(QualifiedName id, Namespace namespaces,
  3. Collection<Statement> statements) {
  4. Object bundle = getJSONStructure(currentRecords, currentNamespace);
  5. documentBundles.put(currentNamespace.qualifiedNameToString(id), bundle);
  6. // Reset to document-level records and namespaces
  7. currentRecords = documentRecords;
  8. currentNamespace = documentNamespace;
  9. return null;
  10. }

代码示例来源:origin: org.openprovenance.prov/prov-model

  1. static public String qualifiedNameToString(QualifiedName name) {
  2. Namespace ns=Namespace.getThreadNamespace();
  3. return ns.qualifiedNameToString(name);
  4. }

代码示例来源:origin: org.openprovenance.prov/prov-model

  1. static public String qualifiedNameToString(javax.xml.namespace.QName name) {
  2. Namespace ns=Namespace.getThreadNamespace();
  3. return ns.qualifiedNameToString(name);
  4. }

代码示例来源:origin: lucmoreau/ProvToolbox

  1. static public String qualifiedNameToString(QualifiedName name) {
  2. Namespace ns=Namespace.getThreadNamespace();
  3. return ns.qualifiedNameToString(name);
  4. }

代码示例来源:origin: org.openprovenance.prov/prov-model

  1. static public String qualifiedNameToStringWithNamespace(QualifiedName name) {
  2. Namespace ns=Namespace.getThreadNamespace();
  3. return ns.qualifiedNameToString(name);
  4. }

代码示例来源:origin: org.openprovenance.prov/prov-n

  1. public String idOrMarker(QualifiedName qn) {
  2. return ((qn == null) ? MARKER : Namespace.getThreadNamespace().qualifiedNameToString(qn));
  3. }

代码示例来源:origin: lucmoreau/ProvToolbox

  1. static public String qualifiedNameToString(javax.xml.namespace.QName name) {
  2. Namespace ns=Namespace.getThreadNamespace();
  3. return ns.qualifiedNameToString(name);
  4. }

代码示例来源:origin: org.openprovenance.prov/prov-json

  1. @Override
  2. public Entity newEntity(QualifiedName id, Collection<Attribute> attributes) {
  3. List<Object[]> attrs = convertAttributes(attributes);
  4. JsonProvRecord record = new JsonProvRecord("entity",
  5. currentNamespace.qualifiedNameToString(id),
  6. attrs);
  7. this.currentRecords.add(record);
  8. return null;
  9. }

代码示例来源:origin: org.openprovenance.prov/prov-json

  1. @Override
  2. public AlternateOf newAlternateOf(QualifiedName e2, QualifiedName e1) {
  3. List<Object[]> attrs = new ArrayList<Object[]>();
  4. if (e2 != null)
  5. attrs.add(tuple("prov:alternate2", currentNamespace.qualifiedNameToString(e2)));
  6. if (e1 != null)
  7. attrs.add(tuple("prov:alternate1", currentNamespace.qualifiedNameToString(e1)));
  8. String recordID = getBlankID("aO");
  9. JsonProvRecord record = new JsonProvRecord("alternateOf", recordID,
  10. attrs);
  11. this.currentRecords.add(record);
  12. return null;
  13. }

代码示例来源:origin: org.openprovenance.prov/prov-json

  1. @Override
  2. public SpecializationOf newSpecializationOf(QualifiedName e2, QualifiedName e1) {
  3. List<Object[]> attrs = new ArrayList<Object[]>();
  4. if (e2 != null)
  5. attrs.add(tuple("prov:specificEntity", currentNamespace.qualifiedNameToString(e2)));
  6. if (e1 != null)
  7. attrs.add(tuple("prov:generalEntity", currentNamespace.qualifiedNameToString(e1)));
  8. String recordID = getBlankID("sO");
  9. JsonProvRecord record = new JsonProvRecord("specializationOf",
  10. recordID, attrs);
  11. this.currentRecords.add(record);
  12. return null;
  13. }

代码示例来源:origin: org.openprovenance.prov/prov-json

  1. @Override
  2. public Agent newAgent(QualifiedName id, Collection<Attribute> attributes) {
  3. List<Object[]> attrs = convertAttributes(attributes);
  4. JsonProvRecord record = new JsonProvRecord("agent",
  5. currentNamespace.qualifiedNameToString(id),
  6. attrs);
  7. this.currentRecords.add(record);
  8. return null;
  9. }

代码示例来源:origin: lucmoreau/ProvToolbox

  1. @Override
  2. public SpecializationOf newSpecializationOf(QualifiedName e2, QualifiedName e1) {
  3. List<Object[]> attrs = new ArrayList<Object[]>();
  4. if (e2 != null)
  5. attrs.add(tuple("prov:specificEntity", currentNamespace.qualifiedNameToString(e2)));
  6. if (e1 != null)
  7. attrs.add(tuple("prov:generalEntity", currentNamespace.qualifiedNameToString(e1)));
  8. String recordID = getBlankID("sO");
  9. JsonProvRecord record = new JsonProvRecord("specializationOf",
  10. recordID, attrs);
  11. this.currentRecords.add(record);
  12. return null;
  13. }

代码示例来源:origin: lucmoreau/ProvToolbox

  1. @Override
  2. public AlternateOf newAlternateOf(QualifiedName e2, QualifiedName e1) {
  3. List<Object[]> attrs = new ArrayList<Object[]>();
  4. if (e2 != null)
  5. attrs.add(tuple("prov:alternate2", currentNamespace.qualifiedNameToString(e2)));
  6. if (e1 != null)
  7. attrs.add(tuple("prov:alternate1", currentNamespace.qualifiedNameToString(e1)));
  8. String recordID = getBlankID("aO");
  9. JsonProvRecord record = new JsonProvRecord("alternateOf", recordID,
  10. attrs);
  11. this.currentRecords.add(record);
  12. return null;
  13. }

代码示例来源:origin: lucmoreau/ProvToolbox

  1. @Override
  2. public Entity newEntity(QualifiedName id, Collection<Attribute> attributes) {
  3. List<Object[]> attrs = convertAttributes(attributes);
  4. JsonProvRecord record = new JsonProvRecord("entity",
  5. currentNamespace.qualifiedNameToString(id),
  6. attrs);
  7. this.currentRecords.add(record);
  8. return null;
  9. }

代码示例来源:origin: lucmoreau/ProvToolbox

  1. @Override
  2. public Agent newAgent(QualifiedName id, Collection<Attribute> attributes) {
  3. List<Object[]> attrs = convertAttributes(attributes);
  4. JsonProvRecord record = new JsonProvRecord("agent",
  5. currentNamespace.qualifiedNameToString(id),
  6. attrs);
  7. this.currentRecords.add(record);
  8. return null;
  9. }

代码示例来源:origin: org.openprovenance.prov/prov-n

  1. @Override
  2. public void startBundle(QualifiedName bundleId, Namespace namespaces) {
  3. String s = keyword("bundle") + " " + namespaces.qualifiedNameToString(bundleId)
  4. + breakline();
  5. s = s + processNamespaces(namespaces);
  6. writeln(s);
  7. }

代码示例来源:origin: lucmoreau/ProvToolbox

  1. @Override
  2. public void startBundle(QualifiedName bundleId, Namespace namespaces) {
  3. String s = keyword("bundle") + " " + namespaces.qualifiedNameToString(bundleId)
  4. + breakline();
  5. s = s + processNamespaces(namespaces);
  6. writeln(s);
  7. }

代码示例来源:origin: org.openprovenance.prov/prov-json

  1. private Object[] convertAttribute(Attribute attr) {
  2. String attrName = currentNamespace.qualifiedNameToString(attr.getElementName());
  3. Object value = attr.getValue();
  4. QualifiedName type = attr.getType();
  5. Object attrValue = convertTypedValue(value, type);
  6. return tuple(attrName, attrValue);
  7. }

代码示例来源:origin: lucmoreau/ProvToolbox

  1. private Object[] convertAttribute(Attribute attr) {
  2. String attrName = currentNamespace.qualifiedNameToString(attr.getElementName());
  3. Object value = attr.getValue();
  4. QualifiedName type = attr.getType();
  5. Object attrValue = convertTypedValue(value, type);
  6. return tuple(attrName, attrValue);
  7. }

相关文章