るりまサーチ

最速Rubyリファレンスマニュアル検索!
12件ヒット [1-12件を表示] (0.027秒)

別のキーワード

  1. kernel $pid
  2. kernel $6
  3. kernel $ors
  4. kernel $4
  5. kernel $5

検索結果

クラス/メソッドの定義 (30.0)

クラス/メソッドの定義 * クラス/メソッドの定義: * class * singleton_class * module * method * operator * nest_method * eval_method * singleton_method * class_method * limit * 定義に関する操作: * alias * undef * defined

...Y = 0
WRONLY = 1
end
include Constants
end

File.open("foo", File::RDONLY)

# あるいは

include File::Constants
File.open("foo", RDONLY)

# 上記はあくまでも例である。実際の File.open ではより簡便な
# File.open("foo", "r") という形式が使われる
//}

クラ...
...self._val + other._val
end
end
//}

=== 定義に関する操作

====[a:alias] alias

//emlist[例][ruby]{
alias foo bar
alias :foo :bar
alias $MATCH $&
//}

文法:

alias 新メソッド名 旧メソッド名
alias 新グローバル変数名 旧グローバル変数名...