Examples of XmlParser


Examples of org.apache.uima.util.XMLParser

    File descriptorFile = JUnitExtension.getFile("CASTests/desc/casTestCaseDescriptor.xml");
    assertTrue("Descriptor must exist: " + descriptorFile.getAbsolutePath(), descriptorFile.exists());
   
    try {
      XMLParser parser = UIMAFramework.getXMLParser();
      ResourceSpecifier spec = (ResourceSpecifier) parser.parse(new XMLInputSource(descriptorFile));
      AnalysisEngine ae = UIMAFramework.produceAnalysisEngine(spec);
      this.cas = (CASImpl) ae.newCAS();
      assertTrue(this.cas != null);
      this.ts = this.cas.getTypeSystem();
      assertTrue(this.ts != null);
View Full Code Here

Examples of org.apache.vxquery.xmlparser.XMLParser

                    throw new SystemException(ErrorCode.FORG0006);
                }
                tvp.getValue(stringp);
                try {
                    // Only one document should be parsed so its ok to have a unique parser.
                    XMLParser parser = new XMLParser(false, nodeIdProvider);
                    FunctionHelper.readInDocFromPointable(stringp, in, bbis, di, abvs, parser);
                } catch (Exception e) {
                    throw new SystemException(ErrorCode.SYSE0001, e);
                }
                result.set(abvs);
View Full Code Here

Examples of org.auraframework.impl.root.parser.XMLParser

    public RegisterEventHandlerTest(String name) {
        super(name);
    }

    public void testSanity() throws Exception {
        XMLParser parser = XMLParser.getInstance();
        DefDescriptor<ComponentDef> descriptor = DefDescriptorImpl.getInstance("test:fakeparser", ComponentDef.class);
        StringSource<ComponentDef> source = new StringSource<>(
                descriptor,
                "<aura:component><aura:registerevent name='click' type='aura:click' description='The Description' access='global'/></aura:component>",
                "myID", Format.XML);
        ComponentDef def2 = parser.parse(descriptor, source);
        RegisterEventDef red = def2.getRegisterEventDefs().get("click");
        assertNotNull(red);
        assertEquals("click", red.getName());
        assertTrue(red.isGlobal());
    }
View Full Code Here

Examples of org.browsermob.proxy.jetty.xml.XmlParser

                }
            }
        }
       
        // Create a TLD parser
        XmlParser parser = new XmlParser(false);
       
        parser.redirectEntity("web-jsptaglibrary_1_1.dtd",WebApplicationContext.class.getResource("/javax/servlet/jsp/resources/web-jsptaglibrary_1_1.dtd"));
        parser.redirectEntity("web-jsptaglibrary_1_2.dtd",WebApplicationContext.class.getResource("/javax/servlet/jsp/resources/web-jsptaglibrary_1_2.dtd"));
        parser.redirectEntity("web-jsptaglibrary_2_0.xsd",WebApplicationContext.class.getResource("/javax/servlet/jsp/resources/web-jsptaglibrary_2_0.xsd"));
        parser.setXpath("/taglib/listener/listener-class");
        // Parse all the discovered TLDs
        Iterator iter = tlds.iterator();
        while (iter.hasNext())
        {
            try
            {
                Resource tld = (Resource)iter.next();
                if (log.isDebugEnabled()) log.debug("TLD="+tld);
               
                XmlParser.Node root = parser.parse(tld.getURL());
               
                for (int i=0;i<root.size();i++)
                {
                    Object o=root.get(i);
                    if (o instanceof XmlParser.Node)
View Full Code Here

Examples of org.concordion.internal.XMLParser

  public Concordion build() {
    if (target == null) {
      target = new FileTarget(getBaseOutputDir());
    }
    XMLParser xmlParser = new XMLParser();

//    specificationCommand.addSpecificationListener(new BreadcrumbRenderer(source, xmlParser));
//    specificationCommand.addSpecificationListener(new PageFooterRenderer(target));

    specificationReader = new XMLSpecificationReader(source, xmlParser, documentParser);
View Full Code Here

Examples of org.eclipse.jetty.xml.XmlParser

   
    public XmlParser newParser()
    throws ClassNotFoundException
    {
        XmlParser xmlParser = new WebDescriptor(null).newParser();
       
        URL jsp21xsd = Loader.getResource(Servlet.class, "javax/servlet/resources/jsp_2_1.xsd", true);
        redirect(xmlParser,"jsp_2_1.xsd",jsp21xsd);
       
        //set up cache of DTDs and schemas locally       
View Full Code Here

Examples of org.eclipse.jetty.xml.XmlParser

  }
 
  @Test
  public void testXml() throws Exception
  {
    XmlParser parser = getParser(true);
    try
    {
      parser.parse(getClass().getResource("/org/cipango/xml/sip.xml").toString());
      fail("expected SAXParseException");
    }
    catch (SAXParseException e)
    {
    }
   
    parser = getParser(false);
    parser.parse(getClass().getResource("/org/cipango/xml/sip.xml").toString());
  }
View Full Code Here

Examples of org.eclipse.jetty.xml.XmlParser

  }

  @Test
  public void testXmlDtd() throws Exception
  {
    XmlParser parser = getParser(true);
    parser.parse(getClass().getResource("/org/cipango/xml/sip-dtd.xml").toString());
  }
View Full Code Here

Examples of org.eclipse.jetty.xml.XmlParser

  @Test
  public void testXmlXsd() throws Exception
  {
    //System.out.println(WebAppContext.class.getResource("/javax/servlet/resources/javaee_5.xsd"));
    XmlParser parser = getParser(true);
    parser.parse(getClass().getResource("/org/cipango/xml/sip-xsd.xml").toString());
  }
View Full Code Here

Examples of org.eclipse.jetty.xml.XmlParser

  }

  @Test
  public void testWeb() throws Exception
  {
    XmlParser parser = getParser(true);
    parser.parse(getClass().getResource("/org/cipango/xml/web.xml").toString());
  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.