Unicorn XML Toolkit
Version 1.00.00

Namespace BasicDom
Class CDocumentFactory

class CDocumentFactory: public CInterface {
public:
    CDocumentFactory(int nBaseId, bool bExtensions=true);
    ~CDocumentFactory();
public:
    XDocument CreateDocument();
    };

The factory generating DOM or XDM documents implemented by BasicDom .

The document factory can be used to create empty DOM or XDM documents. DOM or XDM nodes of other types can be created by calling specific member functions of these documents.

An application may define several document factories. Each document factory is assigned a unique integer base identifier. Base identifiers are used to generate node identifiers, unique within each application.

Each document factory supports only one document model: either DOM or XDM. The supported document model must be specified when the document factory is constructed.

Application writers are strongly adviced to use DOM rather than XDM, unless the XPath-style namespace support (that is, each element node owning the unique collection of all namespace nodes in scope on that element) is required.

Since:
1.00.00
Version:
1.00.00
Author:
Alexey Gokhberg
See Also:
Dom::IDocument
Constructor/Destructor Summary
CDocumentFactory (int nBaseId, bool bExtensions=true);
����������Constructs the document factory.
~CDocumentFactory ();
����������Destroys the document factory.

Function Summary
XDocument CreateDocument ();
����������Creates an empty DOM or XDM document.

Constructor/Destructor Detail

CDocumentFactory

CDocumentFactory(int nBaseId, bool bExtensions=true);

Constructs the document factory.

Parameters:
nBaseId - the base identifier
bExtensions - true if this document factory must support XDM; false if it must support DOM

~CDocumentFactory

~CDocumentFactory();

Destroys the document factory.

Function Detail

CreateDocument

XDocument CreateDocument();

Creates an empty DOM or XDM document.

The architecture of the document is either DOM or XDM depending on the value of bExtensions parameter specified at the construction time of this document factory.

Returns:
the newly created document

Unicorn XML Toolkit
Version 1.00.00


This document was created using Unicorn DOC++.

Copyright 1999-2001 Unicorn Enterprises SA.
All Rights Reserved.