2. Document Object Model (Core) Level 1
2.4 IDL Issues
The primary Document Object Model type definitions are
presented using the Object Management Group's Interface
Definition Language (IDL, ISO standard 14750). While a
complete tutorial on the IDL language is beyond the scope of
this document, a few key items deserve explicit mentioning:
- In the DOM's IDL definition, within each interface
there are primarily two kinds of things:
- Attribute definitions
- Method (IDL calls them "operation")
definitions
- Attribute definitions are a shorthand
notation for a pair of "get/set" or
accessor/mutator methods, and should not be
thought of, nor mapped in a particular language binding
to, data members directly.
- The "constructor" methods for the various
IDL objects are not specified explicitly. Specific
programming language implementations of the DOM will
provide suitable object creation methods; typically
these will be simple with no argument constructors,
although this is not a requirement.
- IDL's
long
datatype represents 32
signed bit integers. In other language bindings, for
example Java, this would be mapped to the Java
int
datatype.
More information on IDL is available from OMG
and in chapter 3 of the CORBA 2.0
specification.Note: The Object Management Group Interface Definition
Language (OMG IDL) was chosen as it was designed for
specifying language and implementation-neutral interfaces.
Various other IDLs could be used; the use of OMG IDL does
not imply a requirement to use a specific object binding
runtime.