Package org.apache.xmlbeans

Examples of org.apache.xmlbeans.SchemaTypeLoader.findType()


    assertNotNull( schemaTypes );
    assertNotNull( definitionUrls );
    assertEquals( cnt, definitionUrls.size() );

    assertNotNull( schemaTypes.findType( new QName( "http://schemas.eviware.com/TestService/v1/", "PageReference" ) ) );

    return schemaTypes;
  }

  public void testWadlImport() throws Exception
View Full Code Here


   * @see TypeLookUpServices#Qname2Class(javax.xml.namespace.QName)
   */
  public Class qname2class(QName qname) {
    logger.debug("Get XMLBeans class for Qname: " + qname);
          SchemaTypeLoader stl = XmlBeans.getContextTypeLoader();
          SchemaType st = stl.findType(qname);
          if (st == null) {
              SchemaField sf = stl.findElement(qname);
              if (sf != null) {
                  st = sf.getType();
              }
View Full Code Here

     * @return null for classes that are not found, or if they are primitive types
     *     *
     */
    private Class q2UserClass(QName qname) {
        SchemaTypeLoader stl = XmlBeans.getContextTypeLoader();
        SchemaType st = stl.findType(qname);
        if (st == null) {
            SchemaField sf = stl.findElement(qname);
            if (sf != null)
                st = sf.getType();
        }
View Full Code Here

    }

    public Class q2Class(QName qType) {

        SchemaTypeLoader stl = XmlBeans.getContextTypeLoader();
        SchemaType st = stl.findType(qType);
        if (st == null) {
            SchemaField sf = stl.findElement(qType);
            if (sf != null) {
                st = sf.getType();
            }
View Full Code Here

        }
    }

    private Class q2UserClass(QName qname) {
        SchemaTypeLoader stl = XmlBeans.getContextTypeLoader();
        SchemaType st = stl.findType(qname);
        if (st == null) {
            SchemaField sf = stl.findElement(qname);
            if (sf != null)
                st = sf.getType();
        }
View Full Code Here

        c.removeXml();

        Assert.assertTrue( x.validate() );

        base.changeType( stl.findType( new QName( "derived" ) ) );

        c.insertElement( "bar" );

        Assert.assertTrue( x.validate() );
    }
View Full Code Here

        SchemaTypeLoader stl = makeSchemaTypeLoader( schemas );

        XmlOptions validate = new XmlOptions().setValidateOnSet();
        XmlOptions noValidate = new XmlOptions();

        SchemaType st = stl.findType(new QName("", "dec-restriction"));

        XmlDecimal dec = (XmlDecimal)stl.newInstance(st, validate);

        try {
            dec.set("200");
View Full Code Here

  @Test
  public void testHttpImport6() throws Exception
  {
    SchemaTypeLoader schemaTypes = validate( "http://localhost:" + getPort() + "/wsdls/test6/TestService.wsdl", 4 );
    assertNotNull( schemaTypes.findType( new QName( "http://schemas.eviware.com/TestService/v2/", "TestType" ) ) );

    schemaTypes = validatePath( "/wsdls/test6/TestService.wsdl", 4 );
    assertNotNull( schemaTypes.findType( new QName( "http://schemas.eviware.com/TestService/v2/", "TestType" ) ) );
  }
View Full Code Here

  {
    SchemaTypeLoader schemaTypes = validate( "http://localhost:" + getPort() + "/wsdls/test6/TestService.wsdl", 4 );
    assertNotNull( schemaTypes.findType( new QName( "http://schemas.eviware.com/TestService/v2/", "TestType" ) ) );

    schemaTypes = validatePath( "/wsdls/test6/TestService.wsdl", 4 );
    assertNotNull( schemaTypes.findType( new QName( "http://schemas.eviware.com/TestService/v2/", "TestType" ) ) );
  }

  @Test
  public void testHttpImport7() throws Exception
  {
View Full Code Here

  @Test
  public void testHttpImport7() throws Exception
  {
    SchemaTypeLoader schemaTypes = validate( "http://localhost:" + getPort() + "/wsdls/test7/TestService.wsdl", 4 );
    assertNotNull( schemaTypes.findType( new QName( "http://schemas.eviware.com/TestService/v2/", "TestType" ) ) );

    schemaTypes = validatePath( "/wsdls/test7/TestService.wsdl", 4 );
    assertNotNull( schemaTypes.findType( new QName( "http://schemas.eviware.com/TestService/v2/", "TestType" ) ) );
  }
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.