Hi Dave,

> However, I have a question: Your sample element definition
> (MetaConstruct) can have no children (child elements).  Does
> it also guarantee that a MetaConstruct element in an
> instance document can have no character content?  For example,
> could we have the following:

[...]
> 
> What do you think?
> 
> I believe the relevant part of the specification is section 2.5.3
> "Empty Content" in "XML Schema Part 0" --
> http://www.w3.org/TR/xmlschema-0/

[...]
> 
> seems very similar to yours.  Am I right that the spec is saying
> that this element definition allows *no* character content?

Yes, the example is almost exactly the same. To test your assumption I've tried 
various combinations:

<MetaConstruct name="description" dataType="STR" ></MetaConstruct>
<MetaConstruct name="description" dataType="STR" >
        <!-- only comment -->
</MetaConstruct>
<MetaConstruct name="description" dataType="STR" >
        Character data
</MetaConstruct>

They all yield to the same error in my validator:

"cvc-complex-type.2.1: Element 'MetaConstruct' must have no character or 
element information item [children], because the type's content type is empty."

So, the above definition does not even allow a separate start and end element. 
It may only be rendered as <element />. Thus is can never contain any kind of 
child.

Regards,
Vincent

------------------------------------------------------------------------------
Open Source Business Conference (OSBC), March 24-25, 2009, San Francisco, CA
-OSBC tackles the biggest issue in open source: Open Sourcing the Enterprise
-Strategies to boost innovation and cut costs with open source participation
-Receive a $600 discount off the registration fee with the source code: SFAD
http://p.sf.net/sfu/XcvMzF8H
_______________________________________________
generateds-users mailing list
generateds-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/generateds-users

Reply via email to