|
Enumerations for validation and display: msg#00015windows.devel.soap.general
Enumerations for Validation and Display Within a schema I use a enumeration facet to allow schema validation against the set of required values for a given type. The enum defines the codified values for this type. However, there is another requirement where the textual description for a each of the allowable values is required and it would be nice to be able to design a schema which could accomodate both of these. As an example, say I have the following schema type :- <xs:simpleType name="Size"> <xs:restriction base="xs:string" > <xs:enumeration value="S" /> <xs:enumeration value="M" /> <xs:enumeration value="L" /> <xs:enumeration value="XL" /> <xs:enumeration value="XXL" /> </xs:restriction> </xs:simpleType> In my web service request message a consumer uses one of the codified values to indicate the required size. However, say I also want to build a browser based application (perhaps XForms) which will provide a 'drop down' list box control which displays the descriptions for each size (Small, Medium, Large, etc..) as well as supply the code when the form is submitted. I would like to use my schema as the single source of codelists for both purposes. Can anyone help me find a workable solution ? _________________________________________________________________ MSN Photos is the easiest way to share and print your photos: http://photos.msn.com/support/worldwide.aspx You can read messages from the SOAP archive, unsubscribe from SOAP, or subscribe to other DevelopMentor lists at http://discuss.develop.com. |
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Re: ANN: Web Services DevCon Filling Fast: 00015, Kevin Hector |
|---|---|
| Next by Date: | (unknown): 00015, Tom |
| Previous by Thread: | ANN: Web Services DevCon Filling Fasti: 00015, Chris Sells |
| Next by Thread: | (unknown): 00015, Tom |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
| News | FAQ | advertise |