org.jruby.runtime
Class ObjectSpace
java.lang.Object
org.jruby.runtime.ObjectSpace
public class ObjectSpace
- extends java.lang.Object
FIXME: This version is faster than the previous, but both suffer from a
crucial flaw: It is impossible to create an ObjectSpace with an iterator
that doesn't either: a. hold on to objects that might otherwise be collected
or b. have no way to guarantee that a call to hasNext() will be correct or
that a subsequent call to next() will produce an object. For our purposes,
for now, this may be acceptable.
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ObjectSpace
public ObjectSpace()
registerObjectId
public void registerObjectId(long id,
IRubyObject object)
calculateObjectId
public static long calculateObjectId(java.lang.Object object)
createAndRegisterObjectId
public long createAndRegisterObjectId(IRubyObject rubyObject)
id2ref
public IRubyObject id2ref(long id)
idOf
@Deprecated
public long idOf(IRubyObject rubyObject)
- Deprecated.
addFinalizer
public void addFinalizer(IRubyObject object,
IRubyObject proc)
removeFinalizers
public void removeFinalizers(long id)
add
public void add(IRubyObject object)
iterator
public java.util.Iterator iterator(RubyModule rubyClass)
Copyright © 2002-2009 JRuby Team. All Rights Reserved.