An example of some XML that could be sent:
<hours-of-operation>
<monday hourType="custom">
<open unit="AM">9:00</open> <!-- open/close or closed or 24hour -->
<close unit="PM">5:00</close>
</monday>
<tuesday hourType="closed" />
<wednesday hourType="24hour" />
<thursday hourType="custom">
<open unit="AM">9:00</open> <!-- open/close or closed or 24hour -->
<close unit="PM">5:00</close>
</thursday>
<friday hourType="custom">
<open unit="AM">9:00</open> <!-- open/close or closed or 24hour -->
<close unit="PM">5:00</close>
</friday>
<saturday hourType="closed" />
<sunday hourType="closed" />
</hours-of-operation>
I want an XSD that defines the hours of operations element. If it makes things simpler, feel free to make the hourType
an element as opposed to an attribute.
So basically, I need a day for each week, and it can EITHER have open and close hours, be closed, or be open 24 hours. Also, the requirements here are not lenient, I require all days of the week.
If it weren't clear, I don't want to know how you'd approach this problem in practice. I want XSD definitions for the XML that I posted, if you have a source that attempts to tackle this problem I want the specific XSD portion that applies exactly to this XML. I don't know much about XML schemas, and while I'm learning best I can quickly, the best thing I can get for this is the actual XSD code for this use case.