Lists Home |
Date Index |
- To: "Marty Burns" <firstname.lastname@example.org>
- Subject: Re: [xml-dev] Naive question about binary encodings
- From: email@example.com (Henry S. Thompson)
- Date: 26 Mar 2003 13:22:59 +0000
- Cc: firstname.lastname@example.org
- In-reply-to: <OFEOICFLLBNNFJEENHNNKENCCIAA.email@example.com>
- References: <OFEOICFLLBNNFJEENHNNKENCCIAA.firstname.lastname@example.org>
- Sender: email@example.com
- User-agent: Gnus/5.0808 (Gnus v5.8.8) XEmacs/21.4 (Portable Code)
"Marty Burns" <firstname.lastname@example.org> writes:
> This is a beginners type question. Can your formulation
> xsi:type="xs:base64Binary" be used as an override of any element contents,
> or must it be provided for in the validating schema?
Also 'no' :-). That is, if there _is_ no validating schema, this will
work, since in the absence of appropriate components schema processors
may, and most do, traverse the document looking for things to do.
> If it needs to be
> accomodated in the schema, how would you do this to override all the nested
> contents in foo?
It would be odd to have an element which you wanted to allow to have
either encoded-binary _or_ proper XML content, wouldn't it?
But if you did, you'd have to define the element's type as mixed and
emptiable, that is, all element content optional. Best bet -- use an
abstract element of type anyType in your content model, then declare
two elements which name that as substitutionGroup head, one of type
base64Binary and the other of your preferred element content. Then
use the appropriate one for the appropriate content in your instances.
Henry S. Thompson, HCRC Language Technology Group, University of Edinburgh
Half-time member of W3C Team
2 Buccleuch Place, Edinburgh EH8 9LW, SCOTLAND -- (44) 131 650-4440
Fax: (44) 131 650-4587, e-mail: email@example.com
[mail really from me _always_ has this .sig -- mail without it is forged spam]