140件ヒット
[101-140件を表示]
(0.051秒)
別のキーワード
ライブラリ
- ビルトイン (128)
-
json
/ add / exception (12)
キーワード
- == (12)
- backtrace (12)
-
backtrace
_ locations (12) - cause (12)
- inspect (12)
-
set
_ backtrace (12) -
to
_ json (12) -
to
_ s (12)
検索結果
先頭4件
-
Exception
# backtrace -> [String] (12020.0) -
バックトレース情報を返します。
...)
* "#{sourcefile}:#{sourceline}"
(トップレベルの場合)
という形式の String の配列です。
//emlist[例][ruby]{
def methd
raise
end
begin
methd
rescue => e
p e.backtrace
end
#=> ["filename.rb:2:in `methd'", "filename.rb:6"]
//}
@see Exception#backtrace_locations... -
Exception
# message -> String (12014.0) -
エラーメッセージをあらわす文字列を返します。
...エラーメッセージをあらわす文字列を返します。
//emlist[例][ruby]{
begin
1 + nil
rescue => e
p e.message #=> "nil can't be coerced into Fixnum"
end
//}... -
Exception
# set _ backtrace(errinfo) -> nil | String | [String] (12014.0) -
バックトレース情報に errinfo を設定し、設定されたバックトレース 情報を返します。
...errinfo を設定し、設定されたバックトレース
情報を返します。
@param errinfo nil、String あるいは String の配列のいずれかを指定します。
//emlist[例][ruby]{
begin
begin
raise "inner"
rescue
raise "outer"
end
rescue
$!.backtrace # => ["/pa... -
Exception
# to _ s -> String (12014.0) -
エラーメッセージをあらわす文字列を返します。
...エラーメッセージをあらわす文字列を返します。
//emlist[例][ruby]{
begin
1 + nil
rescue => e
p e.message #=> "nil can't be coerced into Fixnum"
end
//}...