|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jruby.ast.Node
org.jruby.ast.ArgsNode
arguments for a function. this is used both in the function definition and in actual function calls
Field Summary |
Fields inherited from class org.jruby.ast.Node |
instruction, nodeId |
Constructor Summary | |
ArgsNode(ISourcePosition position,
ListNode arguments,
ListNode optionalArguments,
int restArguments,
ArgumentNode restArgNode,
BlockArgNode blockArgNode)
|
Method Summary | |
Instruction |
accept(NodeVisitor iVisitor)
Accept for the visitor pattern. |
java.util.List |
childNodes()
|
ListNode |
getArgs()
Gets main arguments (as Tokens) |
int |
getArgsCount()
|
Arity |
getArity()
|
BlockArgNode |
getBlockArgNode()
Gets the blockArgNode. |
ListNode |
getOptArgs()
Gets the optArgs. |
int |
getRestArg()
Gets the restArg. |
ArgumentNode |
getRestArgNode()
Gets the restArgNode. |
Methods inherited from class org.jruby.ast.Node |
addComment, addComments, createList, createList, createList, createList, getComments, getNodeName, getPosition, getPositionIncludingComments, hasComments, setPosition, toString |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public ArgsNode(ISourcePosition position, ListNode arguments, ListNode optionalArguments, int restArguments, ArgumentNode restArgNode, BlockArgNode blockArgNode)
optionalArguments
- Node describing the optional arguments
This Block will contain assignments to locals (LAsgnNode)restArguments
- index of the rest argument in the local table
(the array argument prefixed by a * which collects
all additional params)
or -1 if there is none.restArgNode
- The rest argument (*args).blockArgNode
- An optional block argument (&arg).Method Detail |
public Instruction accept(NodeVisitor iVisitor)
accept
in class Node
iVisitor
- the visitorpublic ListNode getArgs()
public Arity getArity()
public int getArgsCount()
public ListNode getOptArgs()
public int getRestArg()
public ArgumentNode getRestArgNode()
public BlockArgNode getBlockArgNode()
public java.util.List childNodes()
childNodes
in class Node
|
|||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |