|
Class: PI (in XML)
Object
|
+--XML::Node
|
+--XML::PI
- Package:
- stx:goodies/xml/vw
- Category:
- XML-VW-Nodes
- Version:
- rev:
1.14
date: 2022/07/21 11:21:33
- user: cg
- file: PI.st directory: goodies/xml/vw
- module: stx stc-classLibrary: vw
This class represents the XML Processing Instruction element. Processing instructions allow XML documents to contain instructions for applications. The 'name' instance variable represents the target of this processing instruction and is used to identify the application to which this processing instruction is directed.
XML processing instructions are delimited by the start-tag '<?' and the end-tag '?>'.
According to the XML 1.0 specification, the target names "XML", "xml" and so on are reserved for standardization
Instance Variables:
name <XML.NodeTag> the target of this processing instruction, used to identify the application to which this processing instruction is directed.
text <String> the processing instructions themselves
instance creation
-
name: nm text: aString
-
accessing
-
name
-
-
text
-
-
xPath
-
return the first xPath which uniquely refers to this node.
Going to be obsoleted by xPathAndAlternativesInto:
-
xPathAndUpTo: limit alternativesInto: aBlock
-
generates the preferred xPath as return value,
in addition enumerates this xPath and alternative xPathes into aBlock:
- unique attributes among siblings
- index
Useful to offer alternative xpathes in a GUI (eg. in the XML inspector)
comparing
-
= anXmlPI
-
(comment from inherited method)
return true if the receiver and the arg have the same structure.
Notice:
This method is partially open coded (inlined) by the compiler(s)
identical objects are always considered equal.
redefining it may not work as expected.
-
hash
-
(comment from inherited method)
return an Integer useful as a hash key for the receiver.
This hash should return same values for objects with same
contents (i.e. use this to hash on structure)
initialization
-
name: nm text: aString
-
printing
-
prettyPrintOn: aStream depth: indent
-
(comment from inherited method)
self subclassResponsibility
-
printCanonicalOn: aStream
-
(comment from inherited method)
Print myself on the stream in the form described by James
Clark's canonical XML.
-
printHTMLOn: aStream
-
(comment from inherited method)
Print myself on the stream in a form usual for HTML.
-
printNoIndentOn: aStream endSpacing: endSpacingBlock spacing: spacingBlock
-
(comment from inherited method)
Print myself on the stream with line breaks between adjacent
elements, but no indentation.
-
printOn: aStream
-
(comment from inherited method)
self printAsOneLineOn: aStream
testing
-
isLike: aNode
-
-
isProcessingInstruction
-
visiting
-
acceptVisitor: aVisitor
-
Double dispatch back to the visitor, passing my type encoded in
the selector (visitor pattern)
|