当前位置: 首页>>代码示例>>C++>>正文


C++ DocumentType::getEntities方法代码示例

本文整理汇总了C++中DocumentType::getEntities方法的典型用法代码示例。如果您正苦于以下问题:C++ DocumentType::getEntities方法的具体用法?C++ DocumentType::getEntities怎么用?C++ DocumentType::getEntities使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在DocumentType的用法示例。


在下文中一共展示了DocumentType::getEntities方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C++代码示例。

示例1: runTest

  /*
   * Runs the test case.
   */
  void runTest()
  {
     Document doc;
     DocumentType docType;
     NamedNodeMap entities;
     Node entityNode;
     String entityName;
     doc = (Document) baseT::load("staff", false);
     docType = doc.getDoctype();
     baseT::assertNotNull(docType, __LINE__, __FILE__);
     entities = docType.getEntities();
     baseT::assertNotNull(entities, __LINE__, __FILE__);
     entityNode = entities.getNamedItem(SA::construct_from_utf8("ent1"));
     baseT::assertNotNull(entityNode, __LINE__, __FILE__);
     entityName = entityNode.getNodeName();
     baseT::assertEquals("ent1", entityName, __LINE__, __FILE__);
 
  }
开发者ID:QuentinFiard,项目名称:arabica,代码行数:21,代码来源:nodeentitynodename.hpp

示例2: runTest

 /*
  * Runs the test case.
  */
 void runTest()
 {
    Document doc;
    DocumentType docType;
    NamedNodeMap entities;
    Node entityNode;
    String entityValue;
    doc = (Document) baseT::load("staff", true);
    docType = doc.getDoctype();
    baseT::assertNotNull(docType, __LINE__, __FILE__);
    entities = docType.getEntities();
    baseT::assertNotNull(entities, __LINE__, __FILE__);
    entityNode = entities.getNamedItem(SA::construct_from_utf8("ent1"));
    baseT::assertNotNull(entityNode, __LINE__, __FILE__);
    entityNode.setNodeValue(SA::construct_from_utf8("This should have no effect"));
    entityValue = entityNode.getNodeValue();
    baseT::assertNull(entityValue, __LINE__, __FILE__);
    
 }
开发者ID:QuentinFiard,项目名称:arabica,代码行数:22,代码来源:nodeentitysetnodevalue.hpp

示例3: runTest

 /*
  * Runs the test case.
  */
 void runTest()
 {
    Document doc;
    DocumentType docType;
    NamedNodeMap entityList;
    Node entity;
    doc = (Document) baseT::load("staff", false);
    docType = doc.getDoctype();
    baseT::assertNotNull(docType, __LINE__, __FILE__);
    entityList = docType.getEntities();
    baseT::assertNotNull(entityList, __LINE__, __FILE__);
    entity = entityList.getNamedItem(SA::construct_from_utf8("ent5"));
    baseT::skipIfNull(entity);
    
    if (("image/svg+xml" == baseT::getContentType())) {
        baseT::assertSize(7, entityList, __LINE__, __FILE__);
    } else {
        baseT::assertSize(5, entityList, __LINE__, __FILE__);
    }
      
  
 }
开发者ID:QuentinFiard,项目名称:arabica,代码行数:25,代码来源:documenttypegetentitieslength.hpp

示例4: runTest

   /*
    * Runs the test case.
    */
   void runTest()
   {
      Document doc;
      DocumentType docType;
      NamedNodeMap entityList;
      Entity entityNode;
      String publicId;
      String systemId;
      String notation;
      doc = (Document) baseT::load("staff", false);
      docType = doc.getDoctype();
      baseT::assertNotNull(docType, __LINE__, __FILE__);
      entityList = docType.getEntities();
      baseT::assertNotNull(entityList, __LINE__, __FILE__);
      entityNode = (Entity) entityList.getNamedItem(SA::construct_from_utf8("ent5"));
      baseT::skipIfNull(entityNode);
      publicId = entityNode.getPublicId();
      baseT::assertEquals("entityURI", publicId, __LINE__, __FILE__);
  systemId = entityNode.getSystemId();
      baseT::assertURIEquals("systemId", "", "", "", "entityFile", "", "", "", false, systemId);
notation = entityNode.getNotationName();
      baseT::assertEquals("notation1", notation, __LINE__, __FILE__);
  
   }
开发者ID:QuentinFiard,项目名称:arabica,代码行数:27,代码来源:entitygetpublicid.hpp


注:本文中的DocumentType::getEntities方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。