Team LiB
Previous Section Next Section

ProcessingInstructionorg.w3c.dom

Java 1.4

This interface represents an XML processing instruction (or PI) which specifies an arbitrary string of data to a named target processor. The getTarget( ) and getdata( ) methods return the target and data portions of a PI, and these values can also be obtained using the getNodeName( ) and getNodeValue( ) methods of the Node interface. You can alter the data portion of a PI with setData( ) or with the setNodeValue( ) method of Node. ProcessingInstruction nodes never have children.

Figure 21-13. org.w3c.dom.ProcessingInstruction


public interface ProcessingInstruction extends Node {
// Public Instance Methods
     String getData( );  
     String getTarget( );  
     void setData(String data) throws DOMException;  
}

Returned By

Document.createProcessingInstruction( )

    Team LiB
    Previous Section Next Section