3件ヒット
[1-3件を表示]
(0.170秒)
ライブラリ
- ビルトイン (3)
クラス
- File (1)
- Method (1)
- UnboundMethod (1)
検索結果
先頭3件
-
UnboundMethod
# owner -> Class | Module (96961.0) -
このメソッドが定義されている class か module を返します。
このメソッドが定義されている class か module を返します。
//emlist[例][ruby]{
Integer.instance_method(:to_s).owner # => Integer
Integer.instance_method(:to_c).owner # => Numeric
Integer.instance_method(:hash).owner # => Kernel
//} -
Method
# owner -> Class | Module (96943.0) -
このメソッドが定義されている class か module を返します。
このメソッドが定義されている class か module を返します。
//emlist[例][ruby]{
class Foo
def foo(arg)
"foo called with arg #{arg}"
end
end
m = Foo.new.method(:foo) # => #<Method: Foo#foo>
m.owner # => Foo
m = Foo.new.method(:puts) # => #<Method: Foo(Kernel)#puts>
m.owner # => Kernel
//} -
File
# chown(owner , group) -> 0 (33658.0) -
ファイルのオーナーとグループを変更します。
ファイルのオーナーとグループを変更します。
適切な権限があればファイルのオーナーとグループを変更できます。
所有者の変更に成功した場合は 0 を返します。変更に失敗した場合は
例外 Errno::EXXX が発生します。
@param owner chown(2) と同様に数値で指定します。nil または -1 を指定することで、オーナーを現在のままにすることができます。
@param group chown(2) と同様に数値で指定します。nil または -1 を指定することで、グループを現在のままにすることができます。
@raise IOError 自身が close されている...