Package org.jruby.ast
Class BackRefNode
java.lang.Object
org.jruby.ast.Node
org.jruby.ast.BackRefNode
Regexp back reference:
- $& last successful match
- $+ highest numbered group matched in last successful match.
- $` what precedes the last successful match
- $' what follows the last successful match
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate final charthe character which generated the back referenceFields inherited from class org.jruby.ast.Node
containsVariableAssignment, EMPTY_LIST, newline -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription<T> Taccept(NodeVisitor<T> iVisitor) Accept for the visitor pattern.chargetType()Gets the typeMethods inherited from class org.jruby.ast.Node
containsVariableAssignment, createList, createList, createList, createList, executesOnce, findFirstChild, getFile, getLine, getNodeName, isNewline, isNil, needsDefinitionCheck, setLine, setNewline, toString, toString, toStringExtraInfo, toStringInternal, unsetNewline
-
Field Details
-
type
private final char typethe character which generated the back reference
-
-
Constructor Details
-
BackRefNode
public BackRefNode(int line, int type)
-
-
Method Details
-
getNodeType
- Specified by:
getNodeTypein classNode- Returns:
- the nodeId
-
accept
Accept for the visitor pattern. -
getByteName
-
getType
public char getType()Gets the type- Returns:
- the character which generates the back reference
-
childNodes
- Specified by:
childNodesin classNode
-