Subject: another schema issue

From: Martin Bjorklund <[email-masked]>
Date: Thu, 30 Mar 2006 19:17:14 +0200 (CEST)

I didn't quite understand all implications of configInlineType:

     <!--
       Type for <config> element
       -->
     <xs:complexType name="configInlineType">
       <xs:complexContent>
         <xs:restriction base="xs:anyType"/>
       </xs:complexContent>
     </xs:complexType>

     <xs:element name="config" type="configInlineType"/>

so I tried to validate an edit-config message with the schema in the
draft and xmllint.

It complained and said that the <config> element's type is empty,
which makes sense I suppose.  There's a restriction on anyType which
restricts it to nothing.

Shouldn't the "config" element (all all others alike) be defined as:

         <xs:element name="config" type="xs:anyType"/>

What do I miss?

/martin

--
to unsubscribe send a message to [email-masked] with
the word 'unsubscribe' in a single line as the message text body.
archive: <http://ops.ietf.org/lists/netconf/>

---

From: Cridlig Vincent <[email-masked]>
Date: Fri, 31 Mar 2006 08:28:17 +0200

> which makes sense I suppose.  There's a restriction on anyType which
Same for me. I validates in Java but not in libxml2 (C). I suspect Java 
is wrong but not sure.
This is the same problem as filter previously.
Add something like this solve the problem, instead of xs:complexContent:
<xs:sequence>
         <xs:any processContents="skip"/>
       </xs:sequence>
Also, if I remember well the xpath attribute of filter is not set to 
optional. I think it should.
Vincent

>          <xs:element name="config" type="xs:anyType"/>

		
___________________________________________________________________________ 
Nouveau : téléphonez moins cher avec Yahoo! Messenger ! Découvez les tarifs exceptionnels pour appeler la France et l'international.
Téléchargez sur http://fr.messenger.yahoo.com

---

From: Martin Bjorklund <[email-masked]>
Date: Fri, 31 Mar 2006 09:53:06 +0200 (CEST)

>          <xs:any processContents="skip"/>

You have to do

   <xs:sequence>
          <xs:any processContents="skip" maxOccurs="unbounded"/>
   </xs:sequence>

To support e.g. this as a reply to get-config:

<rpc-reply>
  <data>
    <interfaces xmlns="urn:ifMib:...">
      ...
    </interfaces>
    <system xmlns="....">
      ...
    </system>
  </data>
</rpc-reply>

> optional. I think it should.

It has a default value, so maybe 'use' is not required.  The XSD spec
isn't very easy to understand...  xmllint doesn't complain anyway.

/martin