Public Member Functions | |
ProcessingInstruction (String target, Map data) | |
ProcessingInstruction (String target, String data) | |
ProcessingInstruction | setTarget (String newTarget) |
Element | getParent () |
ProcessingInstruction | detach () |
Document | getDocument () |
String | getTarget () |
String | getData () |
List | getNames () |
ProcessingInstruction | setData (String data) |
ProcessingInstruction | setData (Map data) |
String | getValue (String name) |
ProcessingInstruction | setValue (String name, String value) |
boolean | removeValue (String name) |
String | toString () |
final boolean | equals (Object ob) |
final int | hashCode () |
Object | clone () |
Protected Member Functions | |
ProcessingInstruction () | |
ProcessingInstruction | setParent (Element parent) |
ProcessingInstruction | setDocument (Document document) |
Protected Attributes | |
String | target |
String | rawData |
Map | mapData |
Object | parent |
ProcessingInstruction
defines behavior for an XML processing instruction, modeled in Java. Methods allow the user to obtain the target of the PI as well as its data. The data can always be accessed as a String, and where appropriate can be retrieved as name/value pairs.
org::jdom::ProcessingInstruction::ProcessingInstruction | ( | ) | [inline, protected] |
Default, no-args constructor for implementations to use if needed.
org::jdom::ProcessingInstruction::ProcessingInstruction | ( | String | target, | |
Map | data | |||
) | [inline] |
This will create a new ProcessingInstruction
with the specified target and data.
target | String target of PI. | |
data | Map data for PI, in name/value pairs |
IllegalTargetException | if the given target is illegal as a processing instruction name. |
org::jdom::ProcessingInstruction::ProcessingInstruction | ( | String | target, | |
String | data | |||
) | [inline] |
This will create a new ProcessingInstruction
with the specified target and data.
target | String target of PI. | |
data | String data for PI. |
IllegalTargetException | if the given target is illegal as a processing instruction name. |
ProcessingInstruction org::jdom::ProcessingInstruction::setTarget | ( | String | newTarget | ) | [inline] |
This will set the target for the PI.
newTarget | String new target of PI. |
ProcessingInstruction
- this PI modified. Element org::jdom::ProcessingInstruction::getParent | ( | ) | [inline] |
This will return the parent of this ProcessingInstruction
. If there is no parent, then this returns null
.
ProcessingInstruction
ProcessingInstruction org::jdom::ProcessingInstruction::setParent | ( | Element | parent | ) | [inline, protected] |
This will set the parent of this ProcessingInstruction
.
parent | Element to be new parent. |
ProcessingInstruction
modified. ProcessingInstruction org::jdom::ProcessingInstruction::detach | ( | ) | [inline] |
This detaches the PI from its parent, or does nothing if the PI has no parent.
ProcessingInstruction
- this ProcessingInstruction
modified. Document org::jdom::ProcessingInstruction::getDocument | ( | ) | [inline] |
ProcessingInstruction org::jdom::ProcessingInstruction::setDocument | ( | Document | document | ) | [inline, protected] |
String org::jdom::ProcessingInstruction::getTarget | ( | ) | [inline] |
This will retrieve the target of the PI.
String
- target of PI. String org::jdom::ProcessingInstruction::getData | ( | ) | [inline] |
This will return the raw data from all instructions.
String
- data of PI. List org::jdom::ProcessingInstruction::getNames | ( | ) | [inline] |
This will return a List
containing the names of the "attribute" style pieces of name/value pairs in this PI's data.
List
- the List
containing the "attribute" names. ProcessingInstruction org::jdom::ProcessingInstruction::setData | ( | String | data | ) | [inline] |
This will set the raw data for the PI.
data | String data of PI. |
ProcessingInstruction
- this PI modified. ProcessingInstruction org::jdom::ProcessingInstruction::setData | ( | Map | data | ) | [inline] |
This will set the name/value pairs within the passed Map
as the pairs for the data of this PI. The keys should be the pair name and the values should be the pair values.
ProcessingInstruction
- modified PI. String org::jdom::ProcessingInstruction::getValue | ( | String | name | ) | [inline] |
This will return the value for a specific name/value pair on the PI. If no such pair is found for this PI, null is returned.
name | String name of name/value pair to lookup value for. |
String
- value of name/value pair. ProcessingInstruction org::jdom::ProcessingInstruction::setValue | ( | String | name, | |
String | value | |||
) | [inline] |
This will set the value for the specified name/value pair. If no matching pair is found, the supplied pair is added to the PI data.
name | String name of pair. | |
value | String value for pair. |
ProcessingInstruction
this PI modified. boolean org::jdom::ProcessingInstruction::removeValue | ( | String | name | ) | [inline] |
This will remove the name/value pair with the specified name.
boolean
- whether the requested instruction was removed. String org::jdom::ProcessingInstruction::toString | ( | ) | [inline] |
This returns a String
representation of the ProcessingInstruction
, suitable for debugging. If the XML representation of the ProcessingInstruction
is desired, org.jdom.output.XMLOutputter#outputString(ProcessingInstruction) should be used.
String
- information about the ProcessingInstruction
final boolean org::jdom::ProcessingInstruction::equals | ( | Object | ob | ) | [inline] |
This tests for equality of this ProcessingInstruction
to the supplied Object
.
ob | Object to compare to. |
boolean
- whether the ProcessingInstruction
is equal to the supplied Object
. final int org::jdom::ProcessingInstruction::hashCode | ( | ) | [inline] |
Object org::jdom::ProcessingInstruction::clone | ( | ) | [inline] |
This will return a clone of this ProcessingInstruction
.
Object
- clone of this ProcessingInstruction
.
String org::jdom::ProcessingInstruction::target [protected] |
The target of the PI
String org::jdom::ProcessingInstruction::rawData [protected] |
The data for the PI as a String
Map org::jdom::ProcessingInstruction::mapData [protected] |
The data for the PI in name/value pairs
Object org::jdom::ProcessingInstruction::parent [protected] |
Parent element, document, or null if none