DOMImplementation Class Reference

Inheritance diagram for DOMImplementation:

DOMIconaraDOMImplementation List of all members.

Detailed Description

DOMImplementation provides a way of creating nodes without knowing which specific implementation that is used.

The DOMImplementation class can also be used to obtain references to a specific implementation, which can be used, in turn, to create new nodes of that concrete implementation.

The default implementation can be obtained with defaultImplementation.

The builder API can use an instance of DOMImplementation to create nodes when it constructs a document. This means that the default builder can create documents that uses any implementation, there is no need to write a specific builder just for an implementation.

Note:
Never retain, release or try to copy instances of this class, the results are not defined. Alternative implementations should be instantiated only once, and added to the list of available implementations with addImplementation:. Implementations should always be obtained via the #implementationForIdentifier-method.


Public Member Functions

(NSString *)  name
(NSString *)  identifier
(Class)  concreteImplementationForProtocol:
(id< DOMNode >)  convertNode:

Static Public Member Functions

(DOMImplementation *)  defaultImplementation
(NSArray *)  availableImplementations
(DOMImplementation *)  implementationForIdentifier:
(void)  addImplementation:

Member Function Documentation

+ (void) addImplementation: (DOMImplementation *)  impl  
 

When an implementation is loaded, it should be added to the list of available implementations with this method.

+ (NSArray *) availableImplementations  
 

Returns a list of all available implementations.

This method has no useful purpose, but debugging.

- (Class) concreteImplementationForProtocol: (Protocol *)  prot  
 

Returns the concrete class that implements the specified protocol in this implementation.

- (id <DOMNode>) convertNode: (id< DOMNode >)  node  
 

Convert a node object to a node object in this implementation.

+ (DOMImplementation *) defaultImplementation  
 

Returns the default implementation. Currently this is the Iconara DOM implementation (identifier net.iconara.DOM).

- (NSString *) identifier  
 

Returns the identifier string of the implementation. The identifier should be a Java-style reverse domain name (i.e. "net.iconara.DOM").

+ (DOMImplementation *) implementationForIdentifier: (NSString *)  name  
 

Returns a specific implementation for an identifier, or nil if none is found.

- (NSString *) name  
 

Returns a human readable name of the implementation.