xmlua.ProcessingInstruction
classIt's a class for processing instruction node.
Normaly, you can get processing instruction object by xmlua.Document:create_processing_instruction
.
Example:
local xmlua = require("xmlua")
local document = xmlua.XML.build({"root"})
local document_type = -- -> xmlua.ProcessingInstruction
document:create_processing_instruction()
It has methods of the following modules:
xmlua.Node
: Provides common methods of each nodes.It means that you can use methods in the modules.
target() -> string
It returns processing instruction as string
.
Example:
local xmlua = require("xmlua")
local document = xmlua.XML.build({"root"})
local processing_instruction =
document:create_processing_instruction("xml-stylesheet",
"href=\"www.test.com/test-style.xsl\" type=\"text/xsl\"")
print(processing_instruction:target())
-- xml-stylesheet
xmlua.Document
: The class for HTML document and XML document.
xmlua.Node
: Provides common methods of each nodes.