P
Piper707
Hi,
I need to generate an XML file for the result which differs based on
the value of a "status" attribute.
i.e for an error condition it would look something like this:
<result status="failure">
<errorBlock>
</result>
a success condition (an empty result block):
<result status="success">
</result>
I understand that XSD does not support conditional processing based on
the value of an attribute.
One way would be to have a tag called "failure" or "success" itself in
the body of the <result>, but then having an empty element seems
wasteful. I would like to have an atribute to do the same thing.
How does one deal with situations like these?
Thanks fo any help
Rohit.
I need to generate an XML file for the result which differs based on
the value of a "status" attribute.
i.e for an error condition it would look something like this:
<result status="failure">
<errorBlock>
</result>
a success condition (an empty result block):
<result status="success">
</result>
I understand that XSD does not support conditional processing based on
the value of an attribute.
One way would be to have a tag called "failure" or "success" itself in
the body of the <result>, but then having an empty element seems
wasteful. I would like to have an atribute to do the same thing.
How does one deal with situations like these?
Thanks fo any help
Rohit.