5件ヒット
[1-5件を表示]
(0.012秒)
種類
- モジュール関数 (3)
- インスタンスメソッド (2)
モジュール
- FileUtils (3)
キーワード
- casecmp? (2)
-
compare
_ file (1) - identical? (1)
検索結果
先頭5件
-
FileUtils
. # cmp(file _ a , file _ b) -> bool (54358.0) -
ファイル file_a と file_b の内容が同じなら真を返します。
ファイル file_a と file_b の内容が同じなら真を返します。
@param file_a ファイル名。
@param file_b ファイル名。
//emlist[][ruby]{
require 'fileutils'
FileUtils.cmp('somefile', 'somefile') #=> true
FileUtils.cmp('/dev/null', '/dev/urandom') #=> false
//} -
String
# casecmp?(other) -> bool | nil (18385.0) -
大文字小文字の違いを無視し文字列を比較します。 文字列が一致する場合には true を返し、一致しない場合には false を返します。
大文字小文字の違いを無視し文字列を比較します。
文字列が一致する場合には true を返し、一致しない場合には false を返します。
@param other self と比較する文字列
//emlist[例][ruby]{
"abcdef".casecmp?("abcde") #=> false
"aBcDeF".casecmp?("abcdef") #=> true
"abcdef".casecmp?("abcdefg") #=> false
"abcdef".casecmp?("ABCDEF") #=> true
"\u{e4 f6 fc}".ca... -
Symbol
# casecmp?(other) -> bool | nil (18385.0) -
大文字小文字の違いを無視しシンボルを比較します。 シンボルが一致する場合には true を返し、一致しない場合には false を返します。
大文字小文字の違いを無視しシンボルを比較します。
シンボルが一致する場合には true を返し、一致しない場合には false を返します。
@param other 比較対象のシンボルを指定します。
//emlist[][ruby]{
:abcdef.casecmp?(:abcde) #=> false
:aBcDeF.casecmp?(:abcdef) #=> true
:abcdef.casecmp?(:abcdefg) #=> false
:abcdef.casecmp?(:ABCDEF) #=> true
:"\u{e4 f6 fc}".casecmp?... -
FileUtils
. # compare _ file(file _ a , file _ b) -> bool (9058.0) -
ファイル file_a と file_b の内容が同じなら真を返します。
ファイル file_a と file_b の内容が同じなら真を返します。
@param file_a ファイル名。
@param file_b ファイル名。
//emlist[][ruby]{
require 'fileutils'
FileUtils.cmp('somefile', 'somefile') #=> true
FileUtils.cmp('/dev/null', '/dev/urandom') #=> false
//} -
FileUtils
. # identical?(file _ a , file _ b) -> bool (9058.0) -
ファイル file_a と file_b の内容が同じなら真を返します。
ファイル file_a と file_b の内容が同じなら真を返します。
@param file_a ファイル名。
@param file_b ファイル名。
//emlist[][ruby]{
require 'fileutils'
FileUtils.cmp('somefile', 'somefile') #=> true
FileUtils.cmp('/dev/null', '/dev/urandom') #=> false
//}