5件ヒット
[1-5件を表示]
(0.113秒)
クラス
- OptionParser (2)
- Pathname (1)
- Thread (2)
検索結果
先頭5件
-
OptionParser
# to _ s -> String (45343.0) -
サマリの文字列を返します。
サマリの文字列を返します。
//emlist[例][ruby]{
require "optparse"
options = {}
opts = OptionParser.new do |opts|
opts.banner = "Usage: example.rb [options]"
opts.on("-v", "--[no-]verbose", "Run verbosely") do |v|
options[:verbose] = v
end
end
puts opts.help
# => Usage: example.rb [options]
# -v... -
Thread
# to _ s -> String (45325.0) -
自身を人間が読める形式に変換した文字列を返します。
自身を人間が読める形式に変換した文字列を返します。
//emlist[例][ruby]{
a = Thread.current
a.inspect # => "#<Thread:0x00007fdbaf07ddb0 run>"
b = Thread.new{}
b.inspect # => "#<Thread:0x00007fdbaf8f7d10@(irb):3 dead>"
//} -
Pathname
# truncate(length) -> 0 (18352.0) -
File.truncate(self.to_s, length) と同じです。
File.truncate(self.to_s, length) と同じです。
@param length 変更したいサイズを整数で与えます。
@see File.truncate -
OptionParser
# help -> String (43.0) -
サマリの文字列を返します。
サマリの文字列を返します。
//emlist[例][ruby]{
require "optparse"
options = {}
opts = OptionParser.new do |opts|
opts.banner = "Usage: example.rb [options]"
opts.on("-v", "--[no-]verbose", "Run verbosely") do |v|
options[:verbose] = v
end
end
puts opts.help
# => Usage: example.rb [options]
# -v... -
Thread
# inspect -> String (25.0) -
自身を人間が読める形式に変換した文字列を返します。
自身を人間が読める形式に変換した文字列を返します。
//emlist[例][ruby]{
a = Thread.current
a.inspect # => "#<Thread:0x00007fdbaf07ddb0 run>"
b = Thread.new{}
b.inspect # => "#<Thread:0x00007fdbaf8f7d10@(irb):3 dead>"
//}