/** * Return a binding representing the previous call's state * @return the current binding */ @Deprecated public Binding previousBinding() { Frame frame = getPreviousFrame(); return new Binding(frame, getPreviousRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the previous call's state * @return the current binding */ @Deprecated public Binding previousBinding() { Frame frame = getPreviousFrame(); return new Binding(frame, getPreviousRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the previous call's state but with a specified self * @param self the self object to use * @return the current binding, using the specified self */ @Deprecated public Binding previousBinding(IRubyObject self) { Frame frame = getPreviousFrame(); return new Binding(self, frame, frame.getVisibility(), getPreviousRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the previous call's state but with a specified self * @param self the self object to use * @return the current binding, using the specified self */ @Deprecated public Binding previousBinding(IRubyObject self) { Frame frame = getPreviousFrame(); return new Binding(self, frame, frame.getVisibility(), getPreviousRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state but with the * specified visibility, scope, and self. For shared-scope binding * consumers like for loops. * * @param self the self object to use * @param visibility the visibility to use * @param scope the scope to use * @return the current binding using the specified self, scope, and visibility */ public Binding currentBinding(IRubyObject self, Visibility visibility, DynamicScope scope) { Frame frame = getCurrentFrame().capture(); return new Binding(self, frame, visibility, getRubyClass(), scope, backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state but with the * specified visibility, scope, and self. For shared-scope binding * consumers like for loops. * * @param self the self object to use * @param visibility the visibility to use * @param scope the scope to use * @return the current binding using the specified self, scope, and visibility */ public Binding currentBinding(IRubyObject self, Visibility visibility, DynamicScope scope) { Frame frame = getCurrentFrame().capture(); return new Binding(self, frame, visibility, getRubyClass(), scope, backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state but with the * specified scope and self. * @param self the self object to use * @param scope the scope to use * @return the current binding using the specified self and scope */ public Binding currentBinding(IRubyObject self, DynamicScope scope) { Frame frame = getCurrentFrame().capture(); return new Binding(self, frame, frame.getVisibility(), getRubyClass(), scope, backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state but with the * specified visibility and self. * @param self the self object to use * @param visibility the visibility to use * @return the current binding using the specified self and visibility */ public Binding currentBinding(IRubyObject self, Visibility visibility) { Frame frame = getCurrentFrame().capture(); return new Binding(self, frame, visibility, getRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state but with the * specified scope and self. * @param self the self object to use * @param scope the scope to use * @return the current binding using the specified self and scope */ public Binding currentBinding(IRubyObject self, DynamicScope scope) { Frame frame = getCurrentFrame().capture(); return new Binding(self, frame, frame.getVisibility(), getRubyClass(), scope, backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state but with the * specified visibility and self. * @param self the self object to use * @param visibility the visibility to use * @return the current binding using the specified self and visibility */ public Binding currentBinding(IRubyObject self, Visibility visibility) { Frame frame = getCurrentFrame().capture(); return new Binding(self, frame, visibility, getRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state but with a specified self * @param self the self object to use * @return the current binding, using the specified self */ public Binding currentBinding(IRubyObject self) { Frame frame = getCurrentFrame().capture(); return new Binding(self, frame, frame.getVisibility(), getRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state * @return the current binding */ public Binding currentBinding() { Frame frame = getCurrentFrame().capture(); return new Binding(frame, parentIndex < 0 ? frame.getKlazz() : getRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state but with a specified self * @param self the self object to use * @return the current binding, using the specified self */ public Binding currentBinding(IRubyObject self) { Frame frame = getCurrentFrame().capture(); return new Binding(self, frame, frame.getVisibility(), getRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
/** * Return a binding representing the current call's state * @return the current binding */ public Binding currentBinding() { Frame frame = getCurrentFrame().capture(); return new Binding(frame, parentIndex < 0 ? frame.getKlazz() : getRubyClass(), getCurrentScope(), backtrace[backtraceIndex].clone()); }
oldBinding.getKlass(), oldBinding.getDynamicScope(), oldBinding.getBacktrace().clone()); block = new Block(procBlock.getBody(), newBinding);
oldBinding.getKlass(), oldBinding.getDynamicScope(), oldBinding.getBacktrace().clone()); block = new Block(procBlock.getBody(), newBinding);