Module Interface XML:DTD

SUMMARY: MODULE | CLASS | TYPE | PROC | VAR | CONST | DETAIL: TYPE | PROC | VAR | CONST

# XML:DTD

This module implements the mechanisms to store, maintain, and query the data gathered from an XML document's DTD. An instance of Builder is created by the parser XML:Parser.Parser to hold a document's DTD information.

### Import List

        URI
        XML:UnicodeBuffer
        XML:UnicodeCodec

Class List
AttValue |
AttrDecl |
Builder |
CP |
Characters |
ChoiceCP |
Declaration |
ElementDecl |
Entity |
EntityRef |
Enumeration |
ExternalEntity |
Fragment |
InternalEntity |
NameCP |
NameNode |
Namespace |
NamespaceDeclaration |
Notation |
RegexpInfo |
SeqCP |

Class Summary: AttValue [Detail]
      +--XML:DTD.AttValue
Field Summary
fragmentList-: Fragment
Constructor Summary
InitAttValue(AttValue)
Method Summary
Append(Fragment)
Clear()
Flatten(AttrDecl): String Returns the string representation of the attribute value attrDecl.
FlattenNorm(AttrDecl, VAR BOOLEAN): String Like AttValue.Flatten, but reports if normalization has been done.
FlattenValue(BOOLEAN, VAR BOOLEAN): String Returns the string representation of the attribute value attValue.
Length(): LONGINT Calculates the length of the attribute value, as if it were of type CDATA.

Class Summary: AttrDecl [Detail]
      +---XML:DTD.Declaration
           |
           +--XML:DTD.AttrDecl
Field Summary
default-: DefaultType
defaultValue-: AttValue
elementName-: String
enumeration-: Enumeration
externalMarkupDecl-: BOOLEAN
type-: AttributeType
Inherited Fields
From XML:DTD.Declaration: name, next
Constructor Summary
InitAttrDecl(AttrDecl, String, String, AttributeType, Enumeration, DefaultType, AttValue, BOOLEAN)

Class Summary: Builder [Detail]
      +--XML:DTD.Builder
Field Summary
attributeList-: Declaration
elementNamespace-: Namespace Namespace with element declarations.
geNamespace-: Namespace Namespace with general entity declarations.
peNamespace-: Namespace Namespace with parameter entity declarations.
rootName-: String Name of the root name, as given in the DTD.
Constructor Summary
Init(Builder) Initializes the DTD builder.
New(): Builder
Method Summary
AddAttribute(AttrDecl)
AttachAttributes() Attaches all attribute declarations in the DTD to the declarations of their element.
IsValidEntityDecl(String, String): BOOLEAN Tests if the internal entity declaration is legal.
NewAttValue(): AttValue
NewAttrDecl(String, String, AttributeType, Enumeration, DefaultType, AttValue, BOOLEAN): AttrDecl
NewCharacters(String, CharPos, CharPos, BOOLEAN): Characters
NewChoiceCP(CPModeType, CP): ChoiceCP
NewDocumentEntity(URI): ExternalEntity
NewElementDecl(String, CP, BOOLEAN): ElementDecl
NewEntityRef(String, Entity): EntityRef
NewEnumeration(): Enumeration
NewExternalDTD(String, String, URI): ExternalEntity
NewExternalEntity(String, EntityType, String, String, String, URI, BOOLEAN): ExternalEntity
NewInternalEntity(String, EntityType, String, BOOLEAN): InternalEntity
NewNameCP(CPModeType, String): NameCP
NewNotation(String, String, String, URI): Notation
NewSeqCP(CPModeType, CP): SeqCP
SetRootName(String)

Class Summary: CP [Detail]
      +--XML:DTD.CP
Field Summary
cpMode-: SHORTINT
next-: CP
Method Summary
SetMode(SHORTINT)
SetNext(CP)

Class Summary: Characters [Detail]
      +---XML:DTD.Fragment
           |
           +--XML:DTD.Characters
Field Summary
source-: String The array slice ``source[sourceStart, sourceEnd[`' holds the fragment's character data.
sourceEnd-: CharPos
sourceStart-: CharPos
Inherited Fields
From XML:DTD.Fragment: next
Constructor Summary
InitCharacters(Characters, String, CharPos, CharPos)

Class Summary: ChoiceCP [Detail]
      +---XML:DTD.CP
           |
           +--XML:DTD.ChoiceCP
Field Summary
list-: CP
Inherited Fields
From XML:DTD.CP: cpMode, next
Constructor Summary
InitChoiceCP(ChoiceCP, CPModeType, CP)
Inherited Methods
From XML:DTD.CP: SetMode, SetNext

Class Summary: Declaration [Detail]
      +--XML:DTD.Declaration
Field Summary
name-: String Name of the declared object.
next-: Declaration Next declaration in namespace.
Constructor Summary
InitDeclaration(Declaration, String)

Class Summary: ElementDecl [Detail]
      +---XML:DTD.Declaration
           |
           +--XML:DTD.ElementDecl
Field Summary
attrNamespace-: Namespace The attribute namespace of the element.
contentModel-: CP The content model of the element.
contentType-: ContentType Type of the content model.
externalMarkupDecl-: BOOLEAN Set if the entity is declared in an external markup declaration.
idAttr-: AttrDecl If the element has an ID attribute, then this field refers to its attribute declaration after Builder.AttachAttributes has been called.
multipleDecl-: BOOLEAN Set to TRUE, if more than one declaration of this element type appears in the DTD.
notationAttr-: AttrDecl If the element has a NOTATION attribute, then this field refers to its attribute declaration after Builder.AttachAttributes has been called.
regexp-: RegexpInfo Regular expression contructed for ``children`' element content.
Inherited Fields
From XML:DTD.Declaration: name, next
Constructor Summary
InitElementDecl(ElementDecl, String, CP, Namespace, BOOLEAN)
Method Summary
IsElementContent(): BOOLEAN
IsEmpty(): BOOLEAN
SetMultipleDecl()
SetRegexp(RegexpInfo)

Class Summary: Entity [Detail]
      +---XML:DTD.Declaration
           |
           +--XML:DTD.Entity
Field Summary
attValue: AttValue This field is used internally by the parser.
entityValue-: String This is either the value of an internal entity, or the internalized version of an external entity.
expanding: BOOLEAN This field is used internally by the parser.
externalMarkupDecl-: BOOLEAN Set if the entity is declared in an external markup declaration.
type-: EntityType This field indicates the kind of entity.
Inherited Fields
From XML:DTD.Declaration: name, next
Method Summary
IsDocumentEntity(): BOOLEAN
LengthValue(): LONGINT Returns the length of the entity's value.
SetEntityValue(String)

Class Summary: EntityRef [Detail]
      +---XML:DTD.Fragment
           |
           +--XML:DTD.EntityRef
Field Summary
entity: Entity After the name has been resolved successfully, this field refers to the internal entity declaration that is being referenced.
name-: String The name of the reference.
Inherited Fields
From XML:DTD.Fragment: next
Constructor Summary
InitEntityRef(EntityRef, String, Entity)

Class Summary: Enumeration [Detail]
      +--XML:DTD.Enumeration
Field Summary
nameList-: NameNode
Method Summary
Append(String)
Matches(VAR StringVar): BOOLEAN Returns TRUE, if one of the names listed in the enumeration matches the string name.

Class Summary: ExternalEntity [Detail]
      +---XML:DTD.Declaration
           |
           +---XML:DTD.Entity
                |
                +--XML:DTD.ExternalEntity
Field Summary
baseURI-: URI The base URI of the external entity.
codecFactory-: Factory The factory object that produced the Unicode decoder that is used to access the files contents.
encoding-: String The encoding string from the XML or text declaration.
ndata-: String For a parsed entity declaration, this field is NIL.
public-: String Public identifier of the external entity.
standalone-: StandaloneType The standalone declaration.
system-: String System identifier of the external entity.
version-: String The version string from the XML or text declaration.
Inherited Fields
From XML:DTD.Declaration: name, next From XML:DTD.Entity: attValue, entityValue, expanding, externalMarkupDecl, type
Method Summary
IsDocumentEntity(): BOOLEAN
SetCodecFactory(Factory)
SetEncoding(String)
SetStandalone(StandaloneType)
SetVersion(String)
Inherited Methods
From XML:DTD.Entity: IsDocumentEntity, LengthValue, SetEntityValue

Class Summary: Fragment [Detail]
      +--XML:DTD.Fragment
Field Summary
next-: Fragment Refers to the next fragment in the list AttValue.fragmentList.
Constructor Summary
InitFragment(Fragment)

Class Summary: InternalEntity [Detail]
      +---XML:DTD.Declaration
           |
           +---XML:DTD.Entity
                |
                +--XML:DTD.InternalEntity
Inherited Fields
From XML:DTD.Declaration: name, next From XML:DTD.Entity: attValue, entityValue, expanding, externalMarkupDecl, type
Inherited Methods
From XML:DTD.Entity: IsDocumentEntity, LengthValue, SetEntityValue

Class Summary: NameCP [Detail]
      +---XML:DTD.CP
           |
           +--XML:DTD.NameCP
Field Summary
name-: String
Inherited Fields
From XML:DTD.CP: cpMode, next
Constructor Summary
InitNameCP(NameCP, CPModeType, String)
Inherited Methods
From XML:DTD.CP: SetMode, SetNext

Class Summary: NameNode [Detail]
      +--XML:DTD.NameNode
Field Summary
name-: String
next-: NameNode

Class Summary: Namespace [Detail]
      +--XML:DTD.Namespace
Field Summary
declList-: Declaration Refers to the first element of the list of declarations.
Constructor Summary
NewNamespace(): Namespace
Method Summary
Add(Declaration): BOOLEAN Adds the declaration decl to the namespace ns.
Get(String): Declaration

Class Summary: NamespaceDeclaration [Detail]
      +--XML:DTD.NamespaceDeclaration
Field Summary
prefix-: String The prefix being declared.
uri-: StringURI The absolute URI (plus optional fragment identifier) of the namespace being declared.
Constructor Summary
NewNamespaceDeclaration(String, StringURI): NamespaceDeclaration

Class Summary: Notation [Detail]
      +---XML:DTD.Declaration
           |
           +--XML:DTD.Notation
Field Summary
baseURI-: URI The base URI of the external entity.
public-: String Public identifier.
system-: String System identifier.
Inherited Fields
From XML:DTD.Declaration: name, next

Class Summary: RegexpInfo [Detail]
      +--XML:DTD.RegexpInfo

Class Summary: SeqCP [Detail]
      +---XML:DTD.CP
           |
           +--XML:DTD.SeqCP
Field Summary
list-: CP
Inherited Fields
From XML:DTD.CP: cpMode, next
Constructor Summary
InitSeqCP(SeqCP, CPModeType, CP)
Inherited Methods
From XML:DTD.CP: SetMode, SetNext

Type Summary
AttributeType = SHORTINT Indicates the type of an attribute.
CPModeType = SHORTINT
Char = Char Character type used to store names and character data from an XML document.
CharPos = CharPos This integer type is used to store the position of a character in the input buffer or in a string.
ContentType = SHORTINT
DefaultType = SHORTINT Indicates the defaulting mode of an attribute declaration.
ElementWhitespaceType = SHORTINT
EntityType = SHORTINT Values of this type indicate the type of an entity.
StandaloneType = SHORTINT Used to store information about the ``standalone`' of an XML declaration.
String = CharArray A pointer to an array of Char.
StringURI = POINTER TO ARRAY OF CHAR
StringVar = ARRAY OF Char An open array with Char as element type.

Procedure Summary
GetString(VAR ARRAY OF Char, LONGINT, LONGINT): String
GetStringURI(VAR ARRAY OF CHAR, LONGINT, LONGINT): StringURI
GetStringValue(ARRAY OF Char): String

Variable Summary
undefAttr-: AttrDecl

Constant Summary
attrCDATA
attrDefault
attrENTITIES
attrENTITY
attrENUMERATED
attrFixed
attrID
attrIDREF
attrIDREFS
attrImplied
attrNMTOKEN
attrNMTOKENS
attrNOTATION
attrRequired
contentANY
contentChildren
contentEMPTY
contentMixed
cpOnce
cpOptional
cpRepeat0
cpRepeat1
elementWhitespaceNo If the document source for a character sequence does not match the S production (for example, because it includes a non-whitespace character, a character reference, or is a CDATA section), then XML:Builder.Characters.elementWhitespace is elementWhitespaceNo.
elementWhitespaceUnknown If the document source matches the production S, but the parser does not know if the current element permits only element content, then the character data is flagged as elementWhitespaceUnknown.
elementWhitespaceYes This flag is used if the document source matches the production S, the parser is validating, and the current element only permits element content.
entityDocument Document entity.
entityExternalDTDSubset Entity representing the external DTD subset.
entityExternalGeneral External general entity.
entityExternalParameter External parameter entity.
entityInternalGeneral Internal general entity.
entityInternalParameter Internal parameter entity.
entityUnparsed Unparsed external general entity.
standaloneNo
standaloneNotApplicable
standaloneNotPresent
standaloneYes

Class Detail: AttValue

Field Detail

### fragmentList

    FIELD fragmentList-: Fragment

Constructor Detail

### InitAttValue

    PROCEDURE InitAttValue(attValue: AttValue)

Method Detail

### Append

    PROCEDURE (attValue: AttValue) Append(fragment: Fragment)

### Clear

    PROCEDURE (attValue: AttValue) Clear()

### Flatten

    PROCEDURE (attValue: AttValue) Flatten(attrDecl: AttrDecl): String

> Returns the string representation of the attribute value attrDecl. If attrDecl is not NIL, and the attribute's type is not attrCDATA, then sequences of spaces are collapsed into a single space, and leading and trailing whitespace is removed from the string.

### FlattenNorm

    PROCEDURE (attValue: AttValue) FlattenNorm(attrDecl: AttrDecl;
                          VAR didNormalization: BOOLEAN): String

> Like AttValue.Flatten, but reports if normalization has been done. On completion, didNormalization is TRUE if, and only if, the value was modified by normalizing whitespace.

### FlattenValue

    PROCEDURE (attValue: AttValue) FlattenValue(normalizeWhitespace: BOOLEAN;
                           VAR didNormalization: BOOLEAN): String

> Returns the string representation of the attribute value attValue. If normalizeWhitespace is TRUE, then sequences of spaces are collapsed into a single space, and leading and trailing whitespace is removed from the string. On completion, didNormalization is TRUE if, and only if, the value was modified by normalizing whitespace.

### Length

    PROCEDURE (attValue: AttValue) Length(): LONGINT

> Calculates the length of the attribute value, as if it were of type CDATA.

Class Detail: AttrDecl

Field Detail

### default

    FIELD default-: DefaultType

### defaultValue

    FIELD defaultValue-: AttValue

### elementName

    FIELD elementName-: String

### enumeration

    FIELD enumeration-: Enumeration

### externalMarkupDecl

    FIELD externalMarkupDecl-: BOOLEAN

### type

    FIELD type-: AttributeType

Constructor Detail

### InitAttrDecl

    PROCEDURE InitAttrDecl(attrDecl: AttrDecl;
                           elementName: String;
                           name: String;
                           type: AttributeType;
                           enum: Enumeration;
                           default: DefaultType;
                           defaultValue: AttValue;
                           externalMarkupDecl: BOOLEAN)

Class Detail: Builder

Field Detail

### attributeList

    FIELD attributeList-: Declaration

### elementNamespace

    FIELD elementNamespace-: Namespace

> Namespace with element declarations.

### geNamespace

    FIELD geNamespace-: Namespace

> Namespace with general entity declarations.

### peNamespace

    FIELD peNamespace-: Namespace

> Namespace with parameter entity declarations.

### rootName

    FIELD rootName-: String

> Name of the root name, as given in the DTD.

Constructor Detail

### Init

    PROCEDURE Init(b: Builder)

> Initializes the DTD builder. Also registers the predefined general entities ``lt`', ``gt`', ``amp`', ``apos`', and ``quot`'.

### New

    PROCEDURE New(): Builder

Method Detail

### AddAttribute

    PROCEDURE (b: Builder) AddAttribute(attrDecl: AttrDecl)

### AttachAttributes

    PROCEDURE (b: Builder) AttachAttributes()

> Attaches all attribute declarations in the DTD to the declarations of their element.

### IsValidEntityDecl

    PROCEDURE (b: Builder) IsValidEntityDecl(name: String;
                                entityValue: String): BOOLEAN

> Tests if the internal entity declaration is legal. If the name name refers to a predefined entity, but entityValue is no legal replacement text for the entity, then this function returns FALSE. Otherwise, it returns TRUE.

### NewAttValue

    PROCEDURE (b: Builder) NewAttValue(): AttValue

### NewAttrDecl

    PROCEDURE (b: Builder) NewAttrDecl(elementName: String;
                          name: String;
                          type: AttributeType;
                          enum: Enumeration;
                          default: DefaultType;
                          defaultValue: AttValue;
                          externalMarkupDecl: BOOLEAN): AttrDecl

### NewCharacters

    PROCEDURE (b: Builder) NewCharacters(source: String;
                            start: CharPos;
                            end: CharPos;
                            createCopy: BOOLEAN): Characters

### NewChoiceCP

    PROCEDURE (b: Builder) NewChoiceCP(cpMode: CPModeType;
                          list: CP): ChoiceCP

### NewDocumentEntity

    PROCEDURE (b: Builder) NewDocumentEntity(baseURI: URI): ExternalEntity

### NewElementDecl

    PROCEDURE (b: Builder) NewElementDecl(name: String;
                             contentModel: CP;
                             externalMarkupDecl: BOOLEAN): ElementDecl

### NewEntityRef

    PROCEDURE (b: Builder) NewEntityRef(name: String;
                           entity: Entity): EntityRef

### NewEnumeration

    PROCEDURE (b: Builder) NewEnumeration(): Enumeration

### NewExternalDTD

    PROCEDURE (b: Builder) NewExternalDTD(public: String;
                             system: String;
                             baseURI: URI): ExternalEntity

### NewExternalEntity

    PROCEDURE (b: Builder) NewExternalEntity(name: String;
                                type: EntityType;
                                public: String;
                                system: String;
                                ndata: String;
                                baseURI: URI;
                                externalMarkupDecl: BOOLEAN): ExternalEntity

### NewInternalEntity

    PROCEDURE (b: Builder) NewInternalEntity(name: String;
                                type: EntityType;
                                entityValue: String;
                                externalMarkupDecl: BOOLEAN): InternalEntity

### NewNameCP

    PROCEDURE (b: Builder) NewNameCP(cpMode: CPModeType;
                        name: String): NameCP

### NewNotation

    PROCEDURE (b: Builder) NewNotation(name: String;
                          public: String;
                          system: String;
                          baseURI: URI): Notation

### NewSeqCP

    PROCEDURE (b: Builder) NewSeqCP(cpMode: CPModeType;
                       list: CP): SeqCP

### SetRootName

    PROCEDURE (b: Builder) SetRootName(name: String)

Class Detail: CP

Field Detail

### cpMode

    FIELD cpMode-: SHORTINT

### next

    FIELD next-: CP

Method Detail

### SetMode

    PROCEDURE (cp: CP) SetMode(cpMode: SHORTINT)

### SetNext

    PROCEDURE (cp: CP) SetNext(next: CP)

Class Detail: Characters

Field Detail

### source

    FIELD source-: String

> The array slice ``source[sourceStart, sourceEnd[`' holds the fragment's character data.

### sourceEnd

    FIELD sourceEnd-: CharPos

### sourceStart

    FIELD sourceStart-: CharPos

Constructor Detail

### InitCharacters

    PROCEDURE InitCharacters(chars: Characters;
                             source: String;
                             start: CharPos;
                             end: CharPos)

Class Detail: ChoiceCP

Field Detail

### list

    FIELD list-: CP

Constructor Detail

### InitChoiceCP

    PROCEDURE InitChoiceCP(choiceCP: ChoiceCP;
                           cpMode: CPModeType;
                           list: CP)

Class Detail: Declaration

Field Detail

### name

    FIELD name-: String

> Name of the declared object.

### next

    FIELD next-: Declaration

> Next declaration in namespace.

Constructor Detail

### InitDeclaration

    PROCEDURE InitDeclaration(decl: Declaration;
                              name: String)

Class Detail: ElementDecl

Field Detail

### attrNamespace

    FIELD attrNamespace-: Namespace

> The attribute namespace of the element.

### contentModel

    FIELD contentModel-: CP

> The content model of the element.

### contentType

    FIELD contentType-: ContentType

> Type of the content model.

### externalMarkupDecl

    FIELD externalMarkupDecl-: BOOLEAN

> Set if the entity is declared in an external markup declaration.

### idAttr

    FIELD idAttr-: AttrDecl

> If the element has an ID attribute, then this field refers to its attribute declaration after Builder.AttachAttributes has been called. If the element has no ID attribute, then this field is NIL. If it has multiple ID attributes, it has the value undefAttr.

### multipleDecl

    FIELD multipleDecl-: BOOLEAN

> Set to TRUE, if more than one declaration of this element type appears in the DTD.

### notationAttr

    FIELD notationAttr-: AttrDecl

> If the element has a NOTATION attribute, then this field refers to its attribute declaration after Builder.AttachAttributes has been called. If the element has no NOTATION attribute, then this field is NIL. If it has multiple NOTATION attributes, it has the value undefAttr.

### regexp

    FIELD regexp-: RegexpInfo

> Regular expression contructed for ``children`' element content.

Constructor Detail

### InitElementDecl

    PROCEDURE InitElementDecl(elemDecl: ElementDecl;
                              name: String;
                              contentModel: CP;
                              attrNamespace: Namespace;
                              externalMarkupDecl: BOOLEAN)

Method Detail

### IsElementContent

    PROCEDURE (elemDecl: ElementDecl) IsElementContent(): BOOLEAN

### IsEmpty

    PROCEDURE (elemDecl: ElementDecl) IsEmpty(): BOOLEAN

### SetMultipleDecl

    PROCEDURE (elemDecl: ElementDecl) SetMultipleDecl()

### SetRegexp

    PROCEDURE (elemDecl: ElementDecl) SetRegexp(regexp: RegexpInfo)

Class Detail: Entity

Field Detail

### attValue

    FIELD attValue: AttValue

> This field is used internally by the parser. If an entity is ever expanded within an attribute value, this field holds the expanded text before non-CDATA normalization.

### entityValue

    FIELD entityValue-: String

> This is either the value of an internal entity, or the internalized version of an external entity. For an internal entity, this field is never NIL. This string is not terminated with an 0X, use Entity.LengthValue to determine its length.

### expanding

    FIELD expanding: BOOLEAN

> This field is used internally by the parser. While expanding the entity, it is set to TRUE.

### externalMarkupDecl

    FIELD externalMarkupDecl-: BOOLEAN

> Set if the entity is declared in an external markup declaration.

### type

    FIELD type-: EntityType

> This field indicates the kind of entity. It distinguishes between general/parameter, internal/external, and parsed/unparsed.

Method Detail

### IsDocumentEntity

    PROCEDURE (entity: Entity) IsDocumentEntity(): BOOLEAN

### LengthValue

    PROCEDURE (entity: Entity) LengthValue(): LONGINT

> Returns the length of the entity's value.

### SetEntityValue

    PROCEDURE (entity: Entity) SetEntityValue(entityValue: String)

Class Detail: EntityRef

Field Detail

### entity

    FIELD entity: Entity

> After the name has been resolved successfully, this field refers to the internal entity declaration that is being referenced.

### name

    FIELD name-: String

> The name of the reference.

Constructor Detail

### InitEntityRef

    PROCEDURE InitEntityRef(entRef: EntityRef;
                            name: String;
                            entity: Entity)

Class Detail: Enumeration

Field Detail

### nameList

    FIELD nameList-: NameNode

Method Detail

### Append

    PROCEDURE (enum: Enumeration) Append(name: String)

### Matches

    PROCEDURE (enum: Enumeration) Matches(VAR name: StringVar): BOOLEAN

> Returns TRUE, if one of the names listed in the enumeration matches the string name.

Class Detail: ExternalEntity

Field Detail

### baseURI

    FIELD baseURI-: URI

> The base URI of the external entity. For a document entity, this is the URI passed to XML:Parser.NewChannel, and therefore may be NIL. For other entities, it is either derived from the public or system identifier, and always present.

### codecFactory

    FIELD codecFactory-: Factory

> The factory object that produced the Unicode decoder that is used to access the files contents. If encoding is NIL, the factory is derived by auto detection. Otherwise, the encoding declaration encoding is used to retrieve it.

### encoding

    FIELD encoding-: String

> The encoding string from the XML or text declaration. NIL, if no encoding is given.

### ndata

    FIELD ndata-: String

> For a parsed entity declaration, this field is NIL. For an unparsed entity, it holds the name of the NDATA.

### public

    FIELD public-: String

> Public identifier of the external entity. May be NIL.

### standalone

    FIELD standalone-: StandaloneType

> The standalone declaration. Only applicable to the document entity.

### system

    FIELD system-: String

> System identifier of the external entity. This field is never NIL.

### version

    FIELD version-: String

> The version string from the XML or text declaration. NIL, if the version is omitted.

Method Detail

### IsDocumentEntity

    PROCEDURE (entity: ExternalEntity) IsDocumentEntity(): BOOLEAN

> Redefines: IsDocumentEntity

### SetCodecFactory

    PROCEDURE (entity: ExternalEntity) SetCodecFactory(codecFactory: Factory)

### SetEncoding

    PROCEDURE (entity: ExternalEntity) SetEncoding(encoding: String)

### SetStandalone

    PROCEDURE (entity: ExternalEntity) SetStandalone(standalone: StandaloneType)

### SetVersion

    PROCEDURE (entity: ExternalEntity) SetVersion(version: String)

Class Detail: Fragment

Field Detail

### next

    FIELD next-: Fragment

> Refers to the next fragment in the list AttValue.fragmentList.

Constructor Detail

### InitFragment

    PROCEDURE InitFragment(f: Fragment)

Class Detail: InternalEntity

Class Detail: NameCP

Field Detail

### name

    FIELD name-: String

Constructor Detail

### InitNameCP

    PROCEDURE InitNameCP(nameCP: NameCP;
                         cpMode: CPModeType;
                         name: String)

Class Detail: NameNode

Field Detail

### name

    FIELD name-: String

### next

    FIELD next-: NameNode

Class Detail: Namespace

Field Detail

### declList

    FIELD declList-: Declaration

> Refers to the first element of the list of declarations. The other declarations can be reached through Declaration.next.

Constructor Detail

### NewNamespace

    PROCEDURE NewNamespace(): Namespace

Method Detail

### Add

    PROCEDURE (ns: Namespace) Add(decl: Declaration): BOOLEAN

> Adds the declaration decl to the namespace ns. Nothing is done if the namespace already contains a declaration of the same name. In this case, the value FALSE is returned. If the declaration was added to the namespace, then the result is TRUE.

### Get

    PROCEDURE (ns: Namespace) Get(name: String): Declaration

Class Detail: NamespaceDeclaration

Field Detail

### prefix

    FIELD prefix-: String

> The prefix being declared. Syntactically, this is the part of the attribute name following the xmlns: prefix. If the attribute name is simply xmlns, this field is NIL.

### uri

    FIELD uri-: StringURI

> The absolute URI (plus optional fragment identifier) of the namespace being declared. It may be NIL if the attribute name is xmlns.

Constructor Detail

### NewNamespaceDeclaration

    PROCEDURE NewNamespaceDeclaration(prefix: String;
                                      uri: StringURI): NamespaceDeclaration

Class Detail: Notation

Field Detail

### baseURI

    FIELD baseURI-: URI

> The base URI of the external entity. For a document entity, this is the URI passed to XML:Parser.NewChannel, and therefore may be NIL. For other entities, it is either derived from the public or system identifier, and always present.

### public

    FIELD public-: String

> Public identifier. May be NIL.

### system

    FIELD system-: String

> System identifier. May be NIL.

Class Detail: RegexpInfo

Class Detail: SeqCP

Field Detail

### list

    FIELD list-: CP

Constructor Detail

### InitSeqCP

    PROCEDURE InitSeqCP(seqCP: SeqCP;
                        cpMode: CPModeType;
                        list: CP)

Type Detail

### AttributeType

    TYPE AttributeType = SHORTINT

> Indicates the type of an attribute. See attrCDATA et al.

### CPModeType

    TYPE CPModeType = SHORTINT

### Char

    TYPE Char = Char

> Character type used to store names and character data from an XML document.

### CharPos

    TYPE CharPos = CharPos

> This integer type is used to store the position of a character in the input buffer or in a string.

### ContentType

    TYPE ContentType = SHORTINT

### DefaultType

    TYPE DefaultType = SHORTINT

> Indicates the defaulting mode of an attribute declaration. One of attrRequired, attrImplied, attrDefault, or attrFixed.

### ElementWhitespaceType

    TYPE ElementWhitespaceType = SHORTINT

### EntityType

    TYPE EntityType = SHORTINT

> Values of this type indicate the type of an entity. See entityInternalGeneral et al.

### StandaloneType

    TYPE StandaloneType = SHORTINT

> Used to store information about the ``standalone`' of an XML declaration. One of standaloneYes, standaloneNo, standaloneNotPresent, or standaloneNotApplicable.

### String

    TYPE String = CharArray

> A pointer to an array of Char.

### StringURI

    TYPE StringURI = POINTER TO ARRAY OF CHAR

### StringVar

    TYPE StringVar = ARRAY OF Char

> An open array with Char as element type.

Procedure Detail

### GetString

    PROCEDURE GetString(VAR string: ARRAY OF Char;
                        start: LONGINT;
                        end: LONGINT): String

### GetStringURI

    PROCEDURE GetStringURI(VAR string: ARRAY OF CHAR;
                           start: LONGINT;
                           end: LONGINT): StringURI

### GetStringValue

    PROCEDURE GetStringValue(string: ARRAY OF Char): String

Variable Detail

### undefAttr

    VAR undefAttr-: AttrDecl

Constant Detail

### attrCDATA

    CONST attrCDATA

### attrDefault

    CONST attrDefault

### attrENTITIES

    CONST attrENTITIES

### attrENTITY

    CONST attrENTITY

### attrENUMERATED

    CONST attrENUMERATED

### attrFixed

    CONST attrFixed

### attrID

    CONST attrID

### attrIDREF

    CONST attrIDREF

### attrIDREFS

    CONST attrIDREFS

### attrImplied

    CONST attrImplied

### attrNMTOKEN

    CONST attrNMTOKEN

### attrNMTOKENS

    CONST attrNMTOKENS

### attrNOTATION

    CONST attrNOTATION

### attrRequired

    CONST attrRequired

### contentANY

    CONST contentANY

### contentChildren

    CONST contentChildren

### contentEMPTY

    CONST contentEMPTY

### contentMixed

    CONST contentMixed

### cpOnce

    CONST cpOnce

### cpOptional

    CONST cpOptional

### cpRepeat0

    CONST cpRepeat0

### cpRepeat1

    CONST cpRepeat1

### elementWhitespaceNo

    CONST elementWhitespaceNo

> If the document source for a character sequence does not match the S production (for example, because it includes a non-whitespace character, a character reference, or is a CDATA section), then XML:Builder.Characters.elementWhitespace is elementWhitespaceNo.

### elementWhitespaceUnknown

    CONST elementWhitespaceUnknown

> If the document source matches the production S, but the parser does not know if the current element permits only element content, then the character data is flagged as elementWhitespaceUnknown.

### elementWhitespaceYes

    CONST elementWhitespaceYes

> This flag is used if the document source matches the production S, the parser is validating, and the current element only permits element content.

### entityDocument

    CONST entityDocument

> Document entity. It represents the top-level entity of a document, the one that holds the internal DTD subset and the root element.

### entityExternalDTDSubset

    CONST entityExternalDTDSubset

> Entity representing the external DTD subset.

### entityExternalGeneral

    CONST entityExternalGeneral

> External general entity.

### entityExternalParameter

    CONST entityExternalParameter

> External parameter entity. Such entities do not appear in the XML infoset.

### entityInternalGeneral

    CONST entityInternalGeneral

> Internal general entity.

### entityInternalParameter

    CONST entityInternalParameter

> Internal parameter entity. Such entities do not appear in the XML infoset.

### entityUnparsed

    CONST entityUnparsed

> Unparsed external general entity.

### standaloneNo

    CONST standaloneNo

### standaloneNotApplicable

    CONST standaloneNotApplicable

### standaloneNotPresent

    CONST standaloneNotPresent

### standaloneYes

    CONST standaloneYes