るりまサーチ

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

別のキーワード

  1. net/imap param
  2. win32ole win32ole_param
  3. win32ole_param retval?
  4. win32ole_param output?
  5. win32ole_param input?

クラス

検索結果

BasicObject#!=(other) -> bool (18133.0)

オブジェクトが other と等しくないことを判定します。

...否定して返します。
このため、サブクラスで BasicObject#== を再定義しても != とは自動的に整合性が
とれるようになっています。

ただし、 BasicObject#!= 自身や BasicObject#! を再定義した際には、ユーザーの責任で
整合性を保た...
...るものと想定されています。

@param other 比較対象となるオブジェクト
@see BasicObject#==, BasicObject#!

//emlist[例][ruby]{
class NonequalityRecorder < BasicObject
def initialize
@count = 0
end
attr_reader :count

def !=(other)
@count += 1
super
end
e...
...nd
recorder = NonequalityRecorder.new

recorder != 1
puts 'hoge' if recorder != "str"

p recorder.count #=> 2
//}...

Integer#anybits?(mask) -> bool (21.0)

self & mask のいずれかのビットが 1 なら true を返します。

...self & mask のいずれかのビットが 1 なら true を返します。

self & mask != 0 と等価です。

@param mask ビットマスクを整数で指定します。

//emlist[][ruby]{
42.anybits?(42) # => true
0b1010_1010.anybits?(0b1000_0010) # => true
0b1010_1010.anybit...