•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the XML, XSLT and XPATH section within the Software Development category of DaniWeb, a massive community of 330,205 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 3,936 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our XML, XSLT and XPATH advertiser:
Views: 269 | Replies: 0
![]() |
•
•
Join Date: Mar 2008
Posts: 2
Reputation:
Rep Power: 0
Solved Threads: 0
Anyone solved this one? - Suppose I have a Person complex type defined in an xsd. And it has an element, eg age, that is declared as minOccurs=0. ie, age is optional for the creation/existence of the complexType.
Now suppose I want to pass that Person as the argument on 5 different SOAP requests (operations) that are defined in a WSDL. And suppose that I want to enforce and declare to the caller that on 3 of those operations age is a required element, and on 2 of them age is not required.
Is there a best way to do this? Should I create new complex types such as Op1Person, Op2Person etc that each have the appropriate setting for minOccurs for that operation? ("Op1Person" would probably only include the Person elements that were required for Operation op1).
So, "Person" is the real domain object, what would be the best way to specify what elements of Person are required for particular operations? And to specify it declaratively so it's known at build time, rather than relying on assertion exceptions being thrown at runtime?
-gr
Now suppose I want to pass that Person as the argument on 5 different SOAP requests (operations) that are defined in a WSDL. And suppose that I want to enforce and declare to the caller that on 3 of those operations age is a required element, and on 2 of them age is not required.
Is there a best way to do this? Should I create new complex types such as Op1Person, Op2Person etc that each have the appropriate setting for minOccurs for that operation? ("Op1Person" would probably only include the Person elements that were required for Operation op1).
So, "Person" is the real domain object, what would be the best way to specify what elements of Person are required for particular operations? And to specify it declaratively so it's known at build time, rather than relying on assertion exceptions being thrown at runtime?
-gr
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
DaniWeb Marketplace (Sponsored Links)
Other Threads in the XML, XSLT and XPATH Forum
- Previous Thread: XSLT and DB2 data
- Next Thread: appending a new node to am existing xml file


Linear Mode