W3C home > Mailing lists > Public > www-talk@w3.org > November to December 2001

Abstract Schema DOM (for DTD)

From: Sigurd Lerstad <sigler@bredband.no>
Date: Wed, 7 Nov 2001 22:46:36 +0100
Message-ID: <066c01c167d5$ad0e6020$270573d5@MMSTUDIOPROJ>
To: <www-talk@w3.org>
Hello,

If there's a more appropriate list for this question, please tell me..

I'm trying to implement the Abstract Schema DOM API (for DTD), but I've
encountered a problem

for example:

<!ELEMENT z (a+,b*)
>

now there's an interface ASElementDeclaration which is used for z, it
contains an
ASContentModel for (a+,b*)

Is is stated that ASContentModel::subModels is :Pointers to ASObjects such
as ASElementDeclarations and further ASContentModels.

ASContentModel::subModels (which would contain a and b) as
ASElementDeclaration?

the problem is then that what happens to the + after a, since there's no
thing like this in ASElementDeclaration

shouldn't there be defined some interfaces like this:

ASContentModel
{
    int minOccurs;
    int maxOccurs;
    int listoperator;
}

ASContentModelGroup : ASContentModel
{
    subModels;
}

ASContentModelElement : ASContentModel
{
    ASElementDeclaration* elementRef;
}

or am I missing something?

thanks,

--
Sigurd Lerstad
Received on Wednesday, 7 November 2001 16:42:45 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Wednesday, 27 October 2010 18:14:26 GMT