444件ヒット
[1-100件を表示]
(0.096秒)
別のキーワード
ライブラリ
- ビルトイン (231)
- bigdecimal (12)
- csv (12)
-
irb
/ context (72) -
irb
/ ext / math-mode (8) -
irb
/ inspector (24) -
irb
/ output-method (24) -
minitest
/ unit (1) - pp (36)
- win32ole (12)
- zlib (12)
クラス
- BigDecimal (12)
- Bignum (6)
-
CSV
:: Table (12) - Fixnum (6)
-
IRB
:: Context (80) -
IRB
:: Inspector (24) -
IRB
:: OutputMethod (24) - Integer (24)
- Method (12)
- Module (36)
- Object (60)
-
RubyVM
:: AbstractSyntaxTree :: Node (7) -
RubyVM
:: InstructionSequence (12) - String (12)
- Symbol (12)
- Thread (32)
-
Thread
:: Backtrace :: Location (12) - UnboundMethod (36)
-
WIN32OLE
_ EVENT (12) -
Zlib
:: GzipFile :: Error (12)
モジュール
キーワード
- % (12)
- [] (12)
-
_ _ inspect _ _ (12) -
bind
_ call (12) - handler= (12)
- init (12)
-
initialize
_ copy (12) - inspect? (12)
-
inspect
_ mode (12) -
inspect
_ mode= (12) -
inspect
_ value (12) - math? (4)
-
math
_ mode (4) -
mu
_ pp (1) - name (12)
- pp (12)
- ppx (12)
-
pretty
_ inspect (12) -
pretty
_ print (12) -
pretty
_ print _ inspect (12) -
to
_ s (68)
検索結果
先頭5件
-
Bignum
# inspect(base = 10) -> String (21202.0) -
self を引数で指定した基数の文字列表現に変換します。
...します。
@param base 基数を 2 から 36 の整数で指定します。
12345654321.to_s #=> "12345654321"
12345654321.to_s(2) #=> "1011011111110110111011110000110001"
12345654321.to_s(8) #=> "133766736061"
12345654321.to_s(16) #=> "2dfdbbc31"
78546939656......932.to_s(36) #=> "rubyrules"... -
Object
# inspect -> String (21132.0) -
オブジェクトを人間が読める形式に変換した文字列を返します。
...結果を使用して
オブジェクトを表示します。
//emlist[][ruby]{
[ 1, 2, 3..4, 'five' ].inspect # => "[1, 2, 3..4, \"five\"]"
Time.new.inspect # => "2008-03-08 19:43:39 +0900"
//}
inspect メソッドをオーバーライドしなかった場合、クラス名と......変数の名前、値の組を元にした文字列を返します。
//emlist[][ruby]{
class Foo
end
Foo.new.inspect # => "#<Foo:0x0300c868>"
class Bar
def initialize
@bar = 1
end
end
Bar.new.inspect # => "#<Bar:0x0300c868 @bar=1>"
//}
@see Kernel.#p... -
UnboundMethod
# inspect -> String (21120.0) -
self を読みやすい文字列として返します。
...self を読みやすい文字列として返します。
詳しくは Method#inspect を参照してください。
//emlist[例][ruby]{
String.instance_method(:count).inspect # => "#<UnboundMethod: String#count>"
//}
@see Method#inspect... -
CSV
:: Table # inspect -> String (21114.0) -
モードとサイズを US-ASCII な文字列で返します。
...モードとサイズを US-ASCII な文字列で返します。
//emlist[][ruby]{
require 'csv'
csv = CSV.new("a,b,c\n1,2,3", headers: true)
table = csv.read
p table.inspect # => "#<CSV::Table mode:col_or_row row_count:2>"
//}... -
BigDecimal
# inspect -> String (21108.0) -
BigDecimal オブジェクトを表す文字列を返します。
...
BigDecimal オブジェクトを表す文字列を返します。
//emlist[][ruby]{
require "bigdecimal"
BigDecimal("1234.5678").inspect
# => "0.12345678e4"
//}... -
RubyVM
:: AbstractSyntaxTree :: Node # inspect -> String (21108.0) -
self のデバッグ用の情報を含んだ文字列を返します。
...self のデバッグ用の情報を含んだ文字列を返します。
//emlist[][ruby]{
node = RubyVM::AbstractSyntaxTree.parse('1 + 1')
puts node.inspect
# => #<RubyVM::AbstractSyntaxTree::Node:SCOPE@1:0-1:5>
//}... -
RubyVM
:: InstructionSequence # inspect -> String (21108.0) -
self の情報をラベルとパスを含んだ人間に読みやすい文字列にして返します。
...んだ人間に読みやすい文字列にして返します。
//emlist[例][ruby]{
iseq = RubyVM::InstructionSequence.compile('num = 1 + 2')
iseq.inspect # => "<RubyVM::InstructionSequence:<compiled>@<compiled>>"
//}
@see RubyVM::InstructionSequence#label,
RubyVM::InstructionSequence#path... -
Symbol
# inspect -> String (21108.0) -
自身を人間に読みやすい文字列にして返します。
...自身を人間に読みやすい文字列にして返します。
:fred.inspect #=> ":fred"... -
Thread
:: Backtrace :: Location # inspect -> String (21108.0) -
Thread::Backtrace::Location#to_s の結果を人間が読みやすいような文 字列に変換したオブジェクトを返します。
...Thread::Backtrace::Location#to_s の結果を人間が読みやすいような文
字列に変換したオブジェクトを返します。
//emlist[例][ruby]{
# foo.rb
class Foo
attr_accessor :locations
def initialize(skip)
@locations = caller_locations(skip)
end
end
Foo.new(0..2).loc......ations.map do |call|
puts call.inspect
end
# => "path/to/foo.rb:5:in `initialize'"
# "path/to/foo.rb:9:in `new'"
# "path/to/foo.rb:9:in `<main>'"
//}... -
IRB
:: Context # inspect -> String (21102.0) -
自身を人間に読みやすい文字列にして返します。
自身を人間に読みやすい文字列にして返します。