36件ヒット
[1-36件を表示]
(0.020秒)
種類
- インスタンスメソッド (24)
- 文書 (12)
ライブラリ
- ビルトイン (24)
クラス
- Module (24)
キーワード
-
class
_ exec (12) -
ruby 1
. 9 feature (12)
検索結果
先頭3件
-
Module
# module _ exec(*args) {|*vars| . . . } -> object (15107.0) -
与えられたブロックを指定された args を引数としてモジュールのコンテキストで評価します。
...す引数を指定します。
//emlist[例][ruby]{
class Thing
end
c = 1
Thing.class_exec{
def hello()
"Hello there!"
end
define_method(:foo) do # ローカル変数がブロックの外側を参照している
c
end
}
t = Thing.new
p t.hello() #=> "Hello there!"... -
ruby 1
. 9 feature (54.0) -
ruby 1.9 feature ruby version 1.9.0 は開発版です。 以下にあげる機能は将来削除されたり互換性のない仕様変更がなされるかもしれません。 1.9.1 以降は安定版です。 バグ修正がメインになります。
...: Hash#identical?
=== 2006-08-31
: Array#shuffle
: Array#shuffle!
追加
=== 2006-07-26
: __send
: __send!
追加
: invoke_method
: invoke_functional_method
削除
=== 2006-07-21
: Module#attr
オプショナル引数の assignable がなくなり、attr_reader 相当になりま......6-06-17
: BasicObject#invoke_method
: BasicObject#invoke_functional_method
追加
((<ruby-talk:197512>))
=== 2006-06-13
: IPsocket
: TCPsocket
: SOCKSsocket
: TCPserver
: UDPsocket
: UNIXsocket
: UNIXserver
削除
=== 2006-06-11
: __callee__ [new]
: __method__ [new]
((<URL:http://www......solete]
: scan [obsolete]
削除
=== 2005-10-21
: funcall [new]
fcall から改名
: Module#instance_exec [new]
: Module#module_exec [new]
追加
=== 2005-09-16
: ((<Dir/Dir.glob>)) [compat]
: ((<Dir/Dir.[]>)) [compat]
Dir.glob に配列を渡して複数のパタ... -
Module
# class _ exec(*args) {|*vars| . . . } -> object (7.0) -
与えられたブロックを指定された args を引数としてモジュールのコンテキストで評価します。
...す引数を指定します。
//emlist[例][ruby]{
class Thing
end
c = 1
Thing.class_exec{
def hello()
"Hello there!"
end
define_method(:foo) do # ローカル変数がブロックの外側を参照している
c
end
}
t = Thing.new
p t.hello() #=> "Hello there!"...