11件ヒット
[1-11件を表示]
(0.030秒)
ライブラリ
- ビルトイン (11)
検索結果
-
Module
# >=(other) -> bool | nil (18250.0) -
比較演算子。self が other の先祖か同一クラスである場合、 true を返します。 self が other の子孫である場合、false を返します。
...士の比較では
nil を返します。
@param other 比較対象のモジュールやクラス
@raise TypeError other がクラスやモジュールではない場合に発生します。
@see Module#<
//emlist[例][ruby]{
module Foo; end
module Bar
include Foo
end
module Baz
prepend Foo......end
Bar.ancestors # => [Bar, Foo]
Foo >= Bar # => true
Bar >= Foo # => false
Baz.ancestors # => [Foo, Baz]
Foo >= Baz # => true
Baz >= Foo # => false
Foo >= Foo # => true
Foo >= Object # => nil
//}...