code(script = Proc.new)
Instance Public methods
def code(script = Proc.new)
if script.kind_of?(String) cmd = proc{|*args| ScopeArgs.new(@fullname,*args).instance_eval(script)} elsif script.kind_of?(Proc) cmd = proc{|*args| ScopeArgs.new(@fullname,*args).instance_eval(&script)} else fail ArgumentError, "String or Proc is expected" end TkNamespace::NsCode.new(tk_call_without_enc('namespace', 'code', _get_eval_string(cmd, false)))
end
Please login to continue.