DocumentEvent (Object/DOM)

An interface that extends the Document object to support a DOM compliant event structure.


DOM level - 2
JavaScript - 1.5
Netscape - 6.0
JavaScript syntax:NmyDocumentEvent = myDocument
Object methods:createEvent()

This is not an object class that exists on its own. Rather it is an extension to the underlying Document object. It could be considered to be a sub-class of Document that inherits all the properties and methods of the Document class. Objects of this type are likely to report that they belong to the Document class rather than the DocumentEvent class although that may be implementation dependent.

The syntax listing shows that a DocumentEvent object is equal to a Document object although as is the case with Document, you cannot be certain which one of several possible documents you may have been passed if several windows, frames or layers are in use at once.

createEvent()1.5 1.5 n/a6.0 6.0 n/a n/a n/a n/a2 2 n/a n/a-