るりまサーチ

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

別のキーワード

  1. openssl t61string
  2. asn1 t61string
  3. matrix t
  4. t61string new
  5. fiddle type_size_t

ライブラリ

クラス

モジュール

キーワード

検索結果

<< 1 2 3 ... > >>

Comparable#<=(other) -> bool (21319.0)

比較演算子 <=> をもとにオブジェクト同士を比較します。 <=> が負の整数か 0 を返した場合に、true を返します。 それ以外の整数を返した場合に、false を返します。

... <=> をもとにオブジェクト同士を比較します。
<=
> が負の整数か 0 を返した場合に、true を返します。
それ以外の整数を返した場合に、false を返します。

@param other 自身と比較したいオブジェクトを指定します。
@raise ArgumentE...
...rror <=> が nil を返したときに発生します。

//emlist[例][ruby]{
1 <= 0 # => false
1 <= 1 # => true
1 <= 2 # => true
//}...

Integer#<=(other) -> bool (21319.0)

比較演算子。数値として等しいまたは小さいか判定します。

...ram other 比較対象の数値
@return self よりも other の方が大きい場合か、
両者が等しい場合 true を返します。
そうでなければ false を返します。

//emlist[][ruby]{
1 <= 0 # => false
1 <= 1 # => true
1 <= 2 # => true
/...

Float#<=(other) -> bool (21307.0)

比較演算子。数値として等しいまたは小さいか判定します。

...@param other 比較対象の数値
@return self よりも other の方が大きい場合か、
両者が等しい場合 true を返します。
そうでなければ false を返します。

//emlist[例][ruby]{
3.14 < 3.1415 # => true
3.14 <= 3.1415 # => true
//}...

BigDecimal#<=(other) -> bool (21301.0)

self が other より小さいか等しい場合に true を、そうでない場合に false を返します。

...self が other より小さいか等しい場合に true を、そうでない場合に false
を返します。...

Module#<=(other) -> bool | nil (18337.0)

比較演算子。self が other の子孫であるか、self と other が 同一クラスである場合、 true を返します。 self が other の先祖である場合、false を返します。

...算子。self が other の子孫であるか、self と other が
同一クラスである場合、 true を返します。
self が other の先祖である場合、false を返します。

継承関係にないクラス同士の比較では
nil を返します。

@param other 比較対象のモ...
...e TypeError other がクラスやモジュールではない場合に発生します。

@see Module#<

//emlist[例][ruby]{
module Foo; end
module Bar
include Foo
end
module Baz
prepend Foo
end

B
ar.ancestors # => [Bar, Foo]
Foo <= Bar # => false
B
ar <= Foo # => true

B
az.ancestors # => [Foo, B...
...az]
Foo <= Baz # => false
B
az <= Foo # => true

Foo <= Foo # => true
Foo <= Object # => nil
//}...

絞り込み条件を変える

Hash#<=(other) -> bool (18331.0)

self が other のサブセットか同じである場合に真を返します。

...self が other のサブセットか同じである場合に真を返します。

@param other 自身と比較したい Hash オブジェクトを指定します。

//emlist[例][ruby]{
h1 = {a:1, b:2}
h2 = {a:1, b:2, c:3}
h1 <= h2 # => true
h2 <= h1 # => false
h1 <= h1 # => true
//}

@see...

Complex#<=(other) -> bool (18301.0)

@undef

@undef

Fixnum#<=(other) -> bool (18301.0)

比較演算子。数値として等しいまたは小さいか判定します。

...演算子。数値として等しいまたは小さいか判定します。

@param other 比較対象の数値
@return self よりも other の方が大きい場合か、
両者が等しい場合 true を返します。
そうでなければ false を返します。...

Object#<=>(other) -> 0 | nil (12213.0)

self === other である場合に 0 を返します。そうでない場合には nil を返します。

...self === other である場合に 0 を返します。そうでない場合には nil を返します。

//emlist[例][ruby]{
a = Object.new
b
= Object.new
a <=> a # => 0
a <=> b # => nil
//}

@see Object#===...

Comparable#between?(min, max) -> bool (12207.0)

比較演算子 <=> をもとに self が min と max の範囲内(min, max を含みます)にあるかを判断します。

...比較演算子 <=> をもとに self が min と max の範囲内(min, max
を含みます)にあるかを判断します。

以下のコードと同じです。
//emlist[][ruby]{
self >= min and self <= max
//}

@param min 範囲の下端を表すオブジェクトを指定します。

@param m...
...raise ArgumentError self <=> min か、self <=> max が nil を返
したときに発生します。

//emlist[例][ruby]{
3.between?(1, 5) # => true
6.between?(1, 5) # => false
'cat'.between?('ant', 'dog') # => true
'gnu'.between?('ant', 'dog') #...

絞り込み条件を変える

<< 1 2 3 ... > >>