[XSL-LIST Mailing List Archive Home] [By Thread] [By Date] [Recent Entries] [Reply To This Message] RE: defining group of elemts for reference in xsd
Your question is off-topic for this list. Try xmlschema-dev@xxxxxxx But take a look at substitution groups. Michael Kay http://www.saxonica.com/ > -----Original Message----- > From: Karl [mailto:call14@xxxxxxxxx] > Sent: 31 July 2006 11:19 > To: xsl-list@xxxxxxxxxxxxxxxxxxxxxx > Subject: defining group of elemts for reference in xsd > > In my schema definition, I have certain element that are used > commonly in most of the place. > > For e.g > > <xsd:complexType name="TitleStructure" mixed="true"> > <xsd:choice minOccurs="0" maxOccurs="unbounded"> > <xsd:element ref="sub"/> > <xsd:element ref="sup"/> > <xsd:element ref="u"/> > <xsd:element ref="i"/> > <xsd:element ref="b"/> > <xsd:element ref="a"/> > <xsd:element ref="smallcaps"/> > </xsd:choice> > </xsd:complexType> > > > <xsd:complexType name="ParagraphStructure" mixed="true"> > <xsd:choice minOccurs="0" maxOccurs="unbounded"> > <xsd:element name="FootNote" > type="FootNoteStructure"/> > <xsd:element name="AuthorComment" > type="xsd:string"/> > ... > ... > <xsd:element name="InlineFigure" > type="InlineFigureStructure"/> > <xsd:element ref="b"/> > <xsd:element ref="i"/> > <xsd:element ref="u"/> > <xsd:element ref="sup"/> > <xsd:element ref="sub"/> > <xsd:element ref="a"/> > <xsd:element ref="smallcaps"/> > </xsd:choice> > </xsd:complexType> > > where you can see Iam refering "b", "i" etc in both > TitleStructure, ParagraphStructure. So, i prefer instead of > refering everytime these b, i, sup etc, can i put them as a > group under some name and ref that group > > i.e something like > > <suitable xsd tag> > <xsd:element ref="b"/> > <xsd:element ref="i"/> > ... > <xsd:element ref="smallcaps"/> > </suitable xsl tag> > > and then refering this in > <xsd:complexType name="TitleStructure" mixed="true"> > <xsd:choice minOccurs="0" maxOccurs="unbounded"> > <refering that pre-defined tag/> -- THIS WAY > </xsd:choice> > </xsd:complexType> > > I did look for similar thing in xsd, but could not find a > answer. But i believe there is an xsd answer. Anyone can you > pls suggest the pretty way. > > Thanks > karl > > > > > ___________________________________________________________ > Try the all-new Yahoo! Mail. "The New Version is radically > easier to use" - The Wall Street Journal > http://uk.docs.yahoo.com/nowyoucan.html
|
PURCHASE STYLUS STUDIO ONLINE TODAY!Purchasing Stylus Studio from our online shop is Easy, Secure and Value Priced! Download The World's Best XML IDE!Accelerate XML development with our award-winning XML IDE - Download a free trial today! Subscribe in XML format
|