This is the mail archive of the docbook-apps@lists.oasis-open.org mailing list .


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[docbook-apps] Re: Context Based Rules?


/ Naomi Gronson <naomi_gronson@yahoo.com> was heard to say:
| I'm looking at adding a few tags to docbook (or
| altering existing ones) to match a content model I've
| been given.  Some of the changes require a new element
| to allow specific children based on it's context.  For
| example, can rules dictate that a new element can
| contain a mediaobject element unless the new element
| is contained in a listitem?

You can do this with RELAX NG (and XML Schema for that matter), but
not with DTDs.

| Has anyone done this, know if it can be done, or dealt
| with a similar problem?  I appreciate the help.

It may be easier to allow the element but add additional constraints
with something like Schematron.

                                        Be seeing you,
                                          norm

-- 
Norman Walsh <ndw@nwalsh.com>      | The human race consists of the
http://www.oasis-open.org/docbook/ | dangerously insane and such as are
Chair, DocBook Technical Committee | not.--Mark Twain

Attachment: pgp00000.pgp
Description: PGP signature


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]