This question pertains to both WSIF and AXIS.

Using wrapped document literal style operations, the following XML Schema
fragment results in an error stating that the <sequence> <element> does not
have type information:

                  <xsd:element name="zooService">
                        <xsd:complexType>
                              <xsd:annotation>
                                    <xsd:appinfo>
                                          <xsd:has-property name="uniqueId"
value="a1bz"/>
                                          <xsd:has-property
name="internalElementType" value="page"/>
                                    </xsd:appinfo>
                              </xsd:annotation>
                              <xsd:sequence>
                                    <xsd:element
ref="xsd1:zootSummaryHeader" maxOccurs="1" minOccurs="1"/>
                              </xsd:sequence>
                        </xsd:complexType>
                  </xsd:element>

The WSIF code from WSIFUtils.java throwing the exception is as follows:

            ArrayList unWrappedParts = new ArrayList();
            for (int i=0; i< se.length; i++) {
               PartImpl np = new PartImpl();
               QName type = se[i].getTypeName();
               if (type==null) {
                    throw new WSIFException("sequence element has no type
name: " + se[i]);
               }
               np.setName(type.getLocalPart());
               np.setElementName(se[i].getElementType());
               unWrappedParts.add(np);
            }

1)  Is the XML Schema fragment valid, that is, should a <sequence> be able
to contain an <element> that uses a reference with no type information?
2)  Is the WSIF code incorrrect in maintaining that a type name must exist
for any <sequence>'s <element> tag?

Thanks in advance.

Reply via email to