5件ヒット
[1-5件を表示]
(0.100秒)
別のキーワード
クラス
- Exception (1)
-
Rake
:: FileList (1) - String (1)
- StringScanner (1)
モジュール
-
Rake
:: Cloneable (1)
キーワード
-
backtrace
_ locations (1) - clone (1)
- hash (1)
- string (1)
検索結果
先頭5件
-
Rake
:: FileList # ==(array) -> bool (54694.0) -
自身を配列に変換してから与えられた配列と比較します。
自身を配列に変換してから与えられた配列と比較します。
@param array 比較対象の配列を指定します。
//emlist[][ruby]{
# Rakefile での記載例とする
task default: :test_rake_app
task :test_rake_app do
file_list = FileList.new('lib/**/*.rb', 'test/test*.rb')
file_list == file_list.to_a # => true
end
//} -
StringScanner
# string -> String (448.0) -
スキャン対象にしている文字列を返します。
スキャン対象にしている文字列を返します。
//emlist[例][ruby]{
require 'strscan'
s = StringScanner.new('test string')
s.string # => "test string"
//}
返り値は freeze されていません。
//emlist[例][ruby]{
require 'strscan'
s = StringScanner.new('test string')
s.string.frozen? # => false
//}
なお、このメソッドは StringScanner.new に渡した
文字列をその... -
Exception
# backtrace _ locations -> [Thread :: Backtrace :: Location] (412.0) -
バックトレース情報を返します。Exception#backtraceに似ていますが、 Thread::Backtrace::Location の配列を返す点が異なります。
バックトレース情報を返します。Exception#backtraceに似ていますが、
Thread::Backtrace::Location の配列を返す点が異なります。
現状では Exception#set_backtrace によって戻り値が変化する事はあり
ません。
//emlist[例: test.rb][ruby]{
require "date"
def check_long_month(month)
return if Date.new(2000, month, -1).day == 31
raise "#{month} is not long month"
end
... -
Rake
:: Cloneable # clone -> object (358.0) -
自身を複製します。
自身を複製します。
自身がフリーズされていれば返されるオブジェクトもフリーズされています。
//emlist[][ruby]{
# Rakefile での記載例とする
task default: :test_rake_app
task :test_rake_app do
file_list = FileList['a.c', 'b.c']
clone = file_list.clone
clone # => ["a.c", "b.c"]
clone.exclude("a.c")
clone == file_list # => f... -
String
# hash -> Integer (358.0) -
self のハッシュ値を返します。 eql? で等しい文字列は、常にハッシュ値も等しくなります。
self のハッシュ値を返します。
eql? で等しい文字列は、常にハッシュ値も等しくなります。
//emlist[例][ruby]{
"test".hash # => 4038258770210371295
("te" + "st").hash == "test".hash # => true
//}
@see Hash