|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectorg.jruby.runtime.Block
public class Block
Internal live representation of a block ({...} or do ... end).
Nested Class Summary | |
---|---|
static class |
Block.Type
|
Field Summary | |
---|---|
static Block |
NULL_BLOCK
All Block variables should either refer to a real block or this NULL_BLOCK. |
Block.Type |
type
|
Constructor Summary | |
---|---|
protected |
Block()
|
|
Block(BlockBody body,
Binding binding)
|
Method Summary | |
---|---|
Arity |
arity()
What is the arity of this block? |
IRubyObject |
call(ThreadContext context,
IRubyObject[] args)
|
Block |
cloneBlock()
|
void |
escape()
|
Binding |
getBinding()
|
BlockBody |
getBody()
|
Frame |
getFrame()
Gets the frame. |
RubyProc |
getProcObject()
Retrieve the proc object associated with this block |
boolean |
isEscaped()
|
boolean |
isGiven()
Is the current block a real yield'able block instead a null one |
void |
setProcObject(RubyProc procObject)
Set the proc object associated with this block |
IRubyObject |
yield(ThreadContext context,
IRubyObject value)
|
IRubyObject |
yield(ThreadContext context,
IRubyObject value,
IRubyObject self,
RubyModule klass,
boolean aValue)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public Block.Type type
public static final Block NULL_BLOCK
Constructor Detail |
---|
protected Block()
public Block(BlockBody body, Binding binding)
Method Detail |
---|
public IRubyObject call(ThreadContext context, IRubyObject[] args)
public IRubyObject yield(ThreadContext context, IRubyObject value)
public IRubyObject yield(ThreadContext context, IRubyObject value, IRubyObject self, RubyModule klass, boolean aValue)
public Block cloneBlock()
public Arity arity()
public RubyProc getProcObject()
public void setProcObject(RubyProc procObject)
procObject
- public final boolean isGiven()
public Binding getBinding()
public BlockBody getBody()
public Frame getFrame()
public boolean isEscaped()
public void escape()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |