Examples of XSModel


Examples of com.sun.org.apache.xerces.internal.xs.XSModel

                partvalid = true;
            }
        } else {
            Iterator ite = schemas.iterator();
            while (ite.hasNext()) {
                XSModel schema = (XSModel)ite.next();

                if (schema != null && isElement && schema.getElementDeclaration(name, namespace) != null) {
                    partvalid = true;
                    break;

                }
                if (schema != null && !isElement && schema.getTypeDefinition(name, namespace) != null) {
                    partvalid = true;
                    break;
                }
            }
        }
View Full Code Here

Examples of org.apache.xerces.impl.xs.psvi.XSModel

    }

    private void processPSVISchemaInformation(ElementPSVI elemPSVI) {
        if (elemPSVI == null)
            return;
        XSModel schemaInfo = elemPSVI.getSchemaInformation();
        XSNamespaceItemList schemaNamespaces =
            schemaInfo == null ? null : schemaInfo.getNamespaceItems();
        if (schemaNamespaces == null || schemaNamespaces.getLength() == 0) {
            sendElementEvent("psv:schemaInformation");
        }
        else {
            sendIndentedElement("psv:schemaInformation");
View Full Code Here

Examples of org.apache.xerces.xs.XSModel

      DefaultSchemaResolver resolver = new DefaultSchemaResolver();
      resolver.addClassBindingForLocation(xsdName, cls);
      SchemaBinding binding = resolver.resolve("", null, xsdName);

      XSModel xsModel = Util.loadSchema(xsdUrl.openStream(), null, resolver);

      assertEquivalent(xsModel, binding);
   }
View Full Code Here

Examples of org.apache.xerces.xs.XSModel

        schemaLoader.setEntityResolver(cr);

        LoggingXmlErrorHandler eh = new LoggingXmlErrorHandler(__log);
        schemaLoader.setErrorHandler(eh);

        XSModel model = schemaLoader.load(input);

        // The following mess is due to XMLSchemaLoaders funkyness in error
        // reporting: sometimes it throws an exception, sometime it returns
        // null, sometimes it just prints bs to the screen.
        if (model == null) {
View Full Code Here

Examples of org.apache.xerces.xs.XSModel

            public int getLength() {
                return uris.length;
            }
        };

        XSModel xsm = schemaLoader.loadInputList(list);
        return new SchemaModelImpl(xsm);
    }
View Full Code Here

Examples of org.apache.xerces.xs.XSModel

            public int getLength() {
                return uris.length;
            }
        };

        XSModel xsm = schemaLoader.loadInputList(list);
        return new SchemaModelImpl(xsm);
    }
View Full Code Here

Examples of org.apache.xerces.xs.XSModel

        schemaLoader.setFeature("http://apache.org/xml/features/honour-all-schemaLocations", true);

        LoggingXmlErrorHandler eh = new LoggingXmlErrorHandler(__log);
        schemaLoader.setErrorHandler(eh);

        XSModel model = schemaLoader.load(input);

        // The following mess is due to XMLSchemaLoaders funkyness in error
        // reporting: sometimes it throws an exception, sometime it returns
        // null, sometimes it just prints bs to the screen.
        if (model == null) {
View Full Code Here

Examples of org.apache.xerces.xs.XSModel

      }
    }
    // If the parser was able to create a schema model assign it for use.
    // If the schema is invalid we still want to make use of the model
    // where possible to avoid cascading error messages to message parts.
    XSModel xsModel = schemav.getXSModel();
    if(xsModel != null)
    {
      valInfo.addSchema(xsModel);
    }
  }
View Full Code Here

Examples of org.apache.xerces.xs.XSModel

    // Going through all schemas
    Iterator i = wsdlDocument.getSchemas().values().iterator();
    while (i.hasNext())
    {
      XSModel xsModel = (XSModel) i.next();
      // Retrieving the derived type definition
      XSTypeDefinition xsType = xsModel.getTypeDefinition(
        extType.getLocalPart(), extType.getNamespaceURI());
      // If it is found and derived from the base type, return true
      if (xsType != null && xsType.derivedFrom(type.getNamespaceURI(),
        type.getLocalPart(), XSConstants.DERIVATION_NONE))
      {
View Full Code Here

Examples of org.apache.xerces.xs.XSModel

          Map schemas = validator.getWSDLDocument().getSchemas();
          // Going through the schemas
          Iterator it = schemas.values().iterator();
          while (it.hasNext())
          {
            XSModel xsModel = (XSModel) it.next();
            XSTypeDefinition xsType = null;
            // Getting the corresponding part type
            if (type == XSConstants.ELEMENT_DECLARATION)
            {
              // Getting schema element
              XSElementDeclaration elem = xsModel.getElementDeclaration(
                ref.getLocalPart(), ref.getNamespaceURI());
              if (elem != null)
              {
                // Getting element's type
                xsType = elem.getTypeDefinition();
                // If it is ref:swaRef
                if (WSIConstants.NS_URI_SWA_REF.equals(xsType.getName())
                  && WSIConstants.SCHEMA_TYPE_SWA_REF.equals(
                    xsType.getNamespace()))
                {
                  // Adding the name of the element to the list
                  swaRefs.add(
                    new QName(elem.getNamespace(), elem.getName()));
                }
              }
            }
            else
            {
              xsType = xsModel.getTypeDefinition(
                ref.getLocalPart(), ref.getNamespaceURI());
            }
            // Collecting all the element names,adding element names to the list
            swaRefs.addAll(collectSwaRefs(xsType));
          }
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.