org.w3c.dom.Entity.getNotationName()方法的使用及代码示例

x33g5p2x  于2022-01-19 转载在 其他  
字(7.5k)|赞(0)|评价(0)|浏览(128)

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

Entity.getNotationName介绍

[英]For unparsed entities, the name of the notation for the entity. For parsed entities, this is null.
[中]对于未分析的实体,实体符号的名称。对于已解析的实体,这是null

代码示例

代码示例来源:origin: robovm/robovm

return url;
String notationName = entity.getNotationName();

代码示例来源:origin: xalan/xalan

return url;
String notationName = entity.getNotationName();

代码示例来源:origin: xalan/xalan

String notationName = entity.getNotationName();
if (notationName != null) {
  uri = entity.getSystemId();

代码示例来源:origin: robovm/robovm

return url;
String notationName = entity.getNotationName();

代码示例来源:origin: xalan/xalan

return url;
String notationName = entity.getNotationName();

代码示例来源:origin: plutext/docx4j

&& entName.equals(nodeName)) {
if (ent.getNotationName() != null) {
  String msg =
    Utils.messages.createMessage(
  || ent.getNotationName() != null) {
  String msg =
    Utils.messages.createMessage(

代码示例来源:origin: robovm/robovm

&& entName.equals(nodeName)) {
if (ent.getNotationName() != null) {
  String msg =
    Utils.messages.createMessage(
  || ent.getNotationName() != null) {
  String msg =
    Utils.messages.createMessage(

代码示例来源:origin: com.sun.xml.parsers/jaxp-ri

public boolean isEntityUnparsed(String name) {
  if (fEntities != null) {
    Entity entity = (Entity) fEntities.getNamedItem(name);
    if (entity != null) {
      return (entity.getNotationName() != null);
    }
  }
  return false;
}

代码示例来源:origin: com.rackspace.apache/xerces2-xsd11

public boolean isEntityUnparsed(String name) {
  if (fEntities != null) {
    Entity entity = (Entity) fEntities.getNamedItem(name);
    if (entity != null) {
      return (entity.getNotationName() != null);
    }
  }
  return false;
}

代码示例来源:origin: org.apache.servicemix.bundles/org.apache.servicemix.bundles.jaxp-ri

public boolean isEntityUnparsed(String name) {
  if (fEntities != null) {
    Entity entity = (Entity) fEntities.getNamedItem(name);
    if (entity != null) {
      return (entity.getNotationName() != null);
    }
  }
  return false;
}

代码示例来源:origin: com.helger/ph-isorelax

public boolean enter (final Entity entity)
{
 final String name = entity.getNodeName ();
 final String pid = entity.getPublicId ();
 final String sid = entity.getSystemId ();
 final String notation = entity.getNotationName ();
 buffer_.append ("<!ENTITY ").append (name);
 if (sid != null)
 {
  if (pid != null)
   buffer_.append (" PUBLIC \"").append (pid).append ("\" \"").append (UXML.escapeSystemQuot (sid)).append ("\">");
  else
   buffer_.append (" SYSTEM \"").append (UXML.escapeSystemQuot (sid)).append ("\">");
  if (notation != null)
   buffer_.append (" NDATA ").append (notation).append (">");
 }
 else
 {
  buffer_.append (" \"");
  final XMLMaker entityMaker = new XMLMaker ();
  UDOMVisitor.traverseChildren (entity, entityMaker);
  buffer_.append (UXML.escapeEntityQuot (entityMaker.getText ())).append ("\"").append (">");
 }
 return false;
}

代码示例来源:origin: com.sun.xml.bind/jaxb-extra-osgi

public boolean isParsedEntity(EntityReference entityreference) {
  String s = entityreference.getNodeName();
  Document document = entityreference.getOwnerDocument();
  DocumentType documenttype = document.getDoctype();
  if(documenttype == null)
    return false;
  NamedNodeMap namednodemap = documenttype.getEntities();
  Entity entity = (Entity)namednodemap.getNamedItem(s);
  if(entity == null)
    return false;
  else
    return entity.getNotationName() == null;
}

代码示例来源:origin: com.helger/ph-isorelax

public boolean isParsedEntity (final EntityReference entityRef)
 {
  final String name = entityRef.getNodeName ();
  final Document doc = entityRef.getOwnerDocument ();
  final DocumentType doctype = doc.getDoctype ();
  if (doctype == null)
   return false;

  final NamedNodeMap entities = doctype.getEntities ();
  final Entity entity = (Entity) entities.getNamedItem (name);
  if (entity == null)
   return false;

  return entity.getNotationName () == null;
 }
}

代码示例来源:origin: org.wicketstuff.htmlvalidator/wicketstuff-isorelax

public boolean isParsedEntity(EntityReference entityRef) {
  String name = entityRef.getNodeName();
  Document doc = entityRef.getOwnerDocument();
  DocumentType doctype = doc.getDoctype();
  if (doctype == null) {
    return (false);
  }
  NamedNodeMap entities = doctype.getEntities();
  Entity entity = (Entity)entities.getNamedItem(name);
  if (entity == null) {
    return (false);
  }
  return (entity.getNotationName() == null);
  }
}

代码示例来源:origin: com.phloc/isorelax

public boolean isParsedEntity (final EntityReference entityRef)
 {
  final String name = entityRef.getNodeName ();
  final Document doc = entityRef.getOwnerDocument ();
  final DocumentType doctype = doc.getDoctype ();
  if (doctype == null)
  {
   return (false);
  }
  final NamedNodeMap entities = doctype.getEntities ();
  final Entity entity = (Entity) entities.getNamedItem (name);
  if (entity == null)
  {
   return (false);
  }
  return (entity.getNotationName () == null);
 }
}

代码示例来源:origin: net.sf.saxon/Saxon-HE

for (int i = 0; i < map.getLength(); i++) {
  Entity e = (Entity) map.item(i);
  if (e.getNotationName() != null) {

代码示例来源:origin: com.sun.xml.bind/jaxb-extra-osgi

private void _handleEntities(DocumentType documenttype) {
  try {
    NamedNodeMap namednodemap = documenttype.getEntities();
    int i = namednodemap.getLength();
    for(int j = 0; j < i; j++) {
      Entity entity = (Entity)namednodemap.item(j);
      String s = entity.getPublicId();
      String s1 = entity.getSystemId();
      String s2 = entity.getNotationName();
      if(s != null || s1 != null)
        _handleExternalEntity(entity.getNodeName(), s, s1, s2);
      else
        _handleInternalEntity(entity);
    }
    NamedNodeMap namednodemap1 = documenttype.getNotations();
    int k = namednodemap1.getLength();
    for(int l = 0; l < k; l++) {
      Notation notation = (Notation)namednodemap1.item(l);
      String s3 = notation.getPublicId();
      String s4 = notation.getSystemId();
      dtd_.notationDecl(notation.getNodeName(), s3, s4);
    }
  }
  catch(SAXException saxexception) {
    _errorReport(saxexception);
  }
}

代码示例来源:origin: com.sun.xml.bind/jaxb-extra-osgi

private void _handleEntities(DocumentType documenttype) {
  try {
    NamedNodeMap namednodemap = documenttype.getEntities();
    int i = namednodemap.getLength();
    for(int j = 0; j < i; j++) {
      Entity entity = (Entity)namednodemap.item(j);
      String s = entity.getPublicId();
      String s1 = entity.getSystemId();
      String s2 = entity.getNotationName();
      if(s != null || s1 != null)
        _handleExternalEntity(entity.getNodeName(), s, s1, s2);
      else
        _handleInternalEntity(entity);
    }
    NamedNodeMap namednodemap1 = documenttype.getNotations();
    int k = namednodemap1.getLength();
    for(int l = 0; l < k; l++) {
      Notation notation = (Notation)namednodemap1.item(l);
      String s3 = notation.getPublicId();
      String s4 = notation.getSystemId();
      dtd_.notationDecl(notation.getNodeName(), s3, s4);
    }
  }
  catch(SAXException saxexception) {
    _errorReport(saxexception);
  }
}

代码示例来源:origin: org.wicketstuff.htmlvalidator/wicketstuff-isorelax

String publicID = entity.getPublicId();
String systemID = entity.getSystemId();
String notationName = entity.getNotationName();
if (publicID != null || systemID != null) {
  _handleExternalEntity(

代码示例来源:origin: org.apache.ws.commons.axiom/dom-testsuite

/**
  * Runs the test case.
  * @throws Throwable Any uncaught exception causes test to fail
  */
  public void runTest() throws Throwable {
   Document doc;
   DocumentType docType;
   NamedNodeMap entityList;
   Entity entityNode;
   String publicId;
   String systemId;
   String notation;
   doc = (Document) load("staff", false);
   docType = doc.getDoctype();
   assertNotNull("docTypeNotNull", docType);
   entityList = docType.getEntities();
   assertNotNull("entitiesNotNull", entityList);
   entityNode = (Entity) entityList.getNamedItem("ent5");
   publicId = entityNode.getPublicId();
   assertEquals("publicId", "entityURI", publicId);
   systemId = entityNode.getSystemId();
   assertURIEquals("systemId", null, null, null, "entityFile", null, null, null, null, systemId);
notation = entityNode.getNotationName();
   assertEquals("notation", "notation1", notation);
   }
  /**

相关文章