Class: SyntaxTree::XString
Overview
XString represents the contents of an XStringLiteral.
`ls`
Instance Attribute Summary collapse
-
#location ⇒ Object
readonly
- Location
-
the location of this node.
-
#parts ⇒ Object
readonly
- Array[ StringEmbExpr | StringDVar | TStringContent ]
-
the parts of the xstring.
Instance Method Summary collapse
-
#initialize(parts:, location:) ⇒ XString
constructor
A new instance of XString.
Methods inherited from Node
#child_nodes, #deconstruct, #deconstruct_keys, #format, #pretty_print, #to_json
Constructor Details
#initialize(parts:, location:) ⇒ XString
Returns a new instance of XString.
11746 11747 11748 11749 |
# File 'lib/syntax_tree/node.rb', line 11746 def initialize(parts:, location:) @parts = parts @location = location end |
Instance Attribute Details
#location ⇒ Object (readonly)
- Location
-
the location of this node
11744 11745 11746 |
# File 'lib/syntax_tree/node.rb', line 11744 def location @location end |
#parts ⇒ Object (readonly)
- Array[ StringEmbExpr | StringDVar | TStringContent ]
-
the parts of the
xstring
11741 11742 11743 |
# File 'lib/syntax_tree/node.rb', line 11741 def parts @parts end |