Velocity Reviews - Computer Hardware Reviews

Velocity Reviews > Newsgroups > Programming > XML > Variable sequence of element tags in a XML document.

Reply
Thread Tools

Variable sequence of element tags in a XML document.

 
 
debicool_98@yahoo.com
Guest
Posts: n/a
 
      10-28-2004
I'm working on an XML document we want to process into our backend
system.
The author of the definition (Schema) wants to allow variable sequence
of different element tags (blocks) in a specific part of that document.


Example:
This is the general structure of that XML document.
You can see different Loan Types as part of the student block
<School>
<Student>
<LoanInformation>
<LoanTypeA>
<LoanTypeB>
<LoanTypeC>
</Student>
</School>

The author wants to allow that the LoanTypes could come in in any
sequence like

<School>
<Student>
<LoanInformation>
<LoanTypeC>
<LoanTypeA>
<LoanTypeB>
</Student>
</School>

or

<School>
<Student>
<LoanInformation>
<LoanTypeB>
<LoanTypeA>
<LoanTypeC>
</Student>
</School>

etc.

the LoanTypes are also Looping elements so multiple entries of those
could occure like

<School>
<Student>
<LoanInformation>
<LoanTypeB>
<LoanTypeA>
<LoanTypeB>
<LoanTypeB>
<LoanTypeC>
<LoanTypeA>
</Student>
</School>

Are there any rules (documented) which either allow this or do not
allow this in any XML document.
Any Information are highly appreciated.

 
Reply With Quote
 
 
 
 
Martin Honnen
Guest
Posts: n/a
 
      10-28-2004


http://www.velocityreviews.com/forums/(E-Mail Removed) wrote:

> I'm working on an XML document we want to process into our backend
> system.
> The author of the definition (Schema) wants to allow variable sequence
> of different element tags (blocks) in a specific part of that document.
>
>
> Example:
> This is the general structure of that XML document.
> You can see different Loan Types as part of the student block
> <School>
> <Student>
> <LoanInformation>
> <LoanTypeA>
> <LoanTypeB>
> <LoanTypeC>
> </Student>
> </School>
>
> The author wants to allow that the LoanTypes could come in in any
> sequence like
>
> <School>
> <Student>
> <LoanInformation>
> <LoanTypeC>
> <LoanTypeA>
> <LoanTypeB>
> </Student>
> </School>
>
> or
>
> <School>
> <Student>
> <LoanInformation>
> <LoanTypeB>
> <LoanTypeA>
> <LoanTypeC>
> </Student>
> </School>
>
> etc.
>
> the LoanTypes are also Looping elements so multiple entries of those
> could occure like
>
> <School>
> <Student>
> <LoanInformation>
> <LoanTypeB>
> <LoanTypeA>
> <LoanTypeB>
> <LoanTypeB>
> <LoanTypeC>
> <LoanTypeA>
> </Student>
> </School>
>
> Are there any rules (documented) which either allow this or do not
> allow this in any XML document.


You need to make sure those tags are closed properly e.g.
<LoanTypeB />
but besides that the XML specification allows what you have.

--

Martin Honnen
http://JavaScript.FAQTs.com/
 
Reply With Quote
 
 
 
Reply

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are Off


Similar Threads
Thread Thread Starter Forum Replies Last Post
How can I construct an XML file to contain HTML tags in the data for a Literal element? AAaron123 ASP .Net 5 09-28-2009 05:44 PM
how to Update/insert an xml element's text----> (<element>text</element>) HANM XML 2 01-29-2008 03:31 PM
how to iterate over sequence and non-sequence ? stef mientki Python 13 10-20-2007 10:21 AM
BOOT SEQUENCE (how to change boot sequence) bird Computer Support 13 12-24-2003 02:20 AM
Element sequence in XML (using CWM and XMI) Nick Java 0 10-07-2003 06:21 AM



Advertisments