Interface DOMFactory
-
- All Known Implementing Classes:
- DefaultDOMFactory, DrawFigureFactory, JavaPrimitivesDOMFactory, NetFactory, PertFactory
public interface DOMFactoryDOMFactory.
Design PatternsAbstract Factory
DOMFactoryis used byDOMInputandDOMOutputfor creating Java objects and DOM elements. Abstract Factory:DOMFactory
Client:DOMInput,DOMOutput.Strategy
DOMFactoryis used byDOMInputandDOMOutputfor reading and writing objects. Client:DOMInput,DOMOutput.
Strategy:DOMFactory.
Chain of Responsibility
DOMFactorycan delegate reading and writing to objects which implement theDOMStorableinterface. Client:DOMFactory.
Handler:DOMStorable.
-
-
Method Summary
All Methods Instance Methods Abstract Methods Modifier and Type Method and Description java.lang.Objectcreate(java.lang.String name)Creates an object from the specified element name.java.lang.StringgetName(java.lang.Object o)Returns the element name for the specified object.java.lang.Objectread(DOMInput in)Reads the specified object fromDOMInput.voidwrite(DOMOutput out, java.lang.Object object)Writes the specified object to DOMOutput.
-
-
-
Method Detail
-
getName
java.lang.String getName(java.lang.Object o)
Returns the element name for the specified object.
-
create
java.lang.Object create(java.lang.String name)
Creates an object from the specified element name.
-
write
void write(DOMOutput out, java.lang.Object object) throws java.io.IOException
Writes the specified object to DOMOutput.This method is only ever called from DOMOutput. You should never call this method directly.
- Parameters:
object- The object to be written.- Throws:
java.io.IOException
-
read
java.lang.Object read(DOMInput in) throws java.io.IOException
Reads the specified object fromDOMInput.This method is only ever called from
DOMInput. You should never call this method directly.If the object returned by this method is an instanceof
DOMStorablethenDOMInputinvokes its read method.- Parameters:
in- TheDOMInputobject which creates the object from an element in a DOM.- Throws:
java.io.IOException
-
-
DataMelt 3.0 © DataMelt by jWork.ORG