別のキーワード
種類
ライブラリ
- English (11)
- ビルトイン (610)
- bigdecimal (113)
- csv (11)
- drb (22)
- e2mmap (96)
- fileutils (22)
- irb (11)
- json (11)
-
json
/ add / exception (22) - matrix (33)
-
minitest
/ unit (4) -
net
/ ftp (11) -
net
/ http (39) - psych (11)
- rexml (66)
-
rubygems
/ commands / lock _ command (11) -
rubygems
/ exceptions (99) -
rubygems
/ gem _ openssl (11) -
rubygems
/ security (33) -
rubygems
/ spec _ fetcher (11) - stringio (11)
- timeout (41)
-
webrick
/ httpauth / authenticator (22)
クラス
-
ARGF
. class (9) - BigDecimal (101)
-
DRb
:: DRbUnknown (11) -
Encoding
:: Converter (11) - Exception (168)
- Fiber (15)
-
Gem
:: Commands :: LockCommand (11) -
Gem
:: Security :: Policy (11) -
Gem
:: SpecFetcher (11) - IO (22)
-
JSON
:: State (11) -
MiniTest
:: Unit (2) -
MiniTest
:: Unit :: TestCase (1) -
REXML
:: ParseException (44) - SignalException (55)
- StringIO (11)
- Thread (87)
- TracePoint (22)
モジュール
- Exception2MessageMapper (78)
- FileUtils (22)
- Gem (11)
-
Gem
:: Security (11) - IRB (11)
- Kernel (244)
-
MiniTest
:: Assertions (1) -
Net
:: HTTPExceptions (11) - Timeout (19)
-
WEBrick
:: HTTPAuth :: Authenticator (11) -
WEBrick
:: HTTPAuth :: ProxyAuthenticator (11)
キーワード
-
$ ! (11) -
$ -d (11) -
$ DEBUG (11) -
$ ERROR _ INFO (11) -
1
. 6 . 8から1 . 8 . 0への変更点(まとめ) (11) - == (11)
- AuthException (22)
- BigDecimal (12)
- CSV (11)
- Complex (12)
- DRbUnknownError (11)
- DependencyRemovalException (11)
- E2MM (6)
-
EXCEPTION
_ ALL (11) -
EXCEPTION
_ INFINITY (11) -
EXCEPTION
_ NaN (11) -
EXCEPTION
_ OVERFLOW (11) -
EXCEPTION
_ UNDERFLOW (11) -
EXCEPTION
_ ZERODIVIDE (11) - EndOfYAMLException (11)
- ErrDimensionMismatch (11)
- ErrNotRegisteredException (6)
- ErrNotRegular (11)
- ErrOperationNotDefined (11)
- Exception2MessageMapper (6)
- FTPError (11)
- Fail (12)
- Float (6)
- FormatException (11)
- GemNotFoundException (11)
- GemNotInHomeException (11)
- HTTPClientException (6)
- HTTPExceptions (11)
- HTTPServerException (11)
- Integer (6)
- InvalidSpecificationException (11)
-
NEWS for Ruby 2
. 1 . 0 (11) -
NEWS for Ruby 2
. 3 . 0 (9) -
NEWS for Ruby 2
. 4 . 0 (8) -
NEWS for Ruby 2
. 5 . 0 (7) -
NEWS for Ruby 2
. 6 . 0 (6) -
NEWS for Ruby 3
. 0 . 0 (4) -
PASSTHROUGH
_ EXCEPTIONS (1) - ParseException (11)
- Raise (12)
- Rational (6)
- RemoteSourceException (11)
- Rubyの起動 (3)
- Ruby用語集 (11)
- SignalException (11)
- SystemExitException (11)
- Thread (11)
- TracePoint (11)
- UndefinedNamespaceException (11)
- abort (22)
-
abort
_ on _ exception (22) -
abort
_ on _ exception= (22) - backtrace (11)
-
backtrace
_ locations (11) - bind (6)
- cause (11)
- complain (11)
- context (11)
- debug (11)
-
def
_ exception (12) - e2mmap (6)
-
ensure
_ ssl _ available (11) - exception (44)
-
exception
_ details (1) -
extend
_ object (6) - fail (39)
- generate (11)
-
handle
_ interrupt (11) - inspect (11)
-
irb
_ abort (11) -
json
/ add / exception (11) -
json
_ create (11) -
last
_ error (11) - line (11)
- location (1)
- logger (11)
- mode (22)
-
net
/ http (11) - new (57)
- position (11)
- puke (1)
- raise (48)
-
raised
_ exception (11) -
read
_ nonblock (31) - remove (11)
-
report
_ on _ exception (16) -
report
_ on _ exception= (16) - response (11)
- rm (11)
-
ruby 1
. 6 feature (11) -
ruby 1
. 8 . 3 feature (11) -
ruby 1
. 8 . 4 feature (11) -
ruby 1
. 9 feature (11) -
rubygems
/ exceptions (11) -
save
_ exception _ mode (11) -
set
_ backtrace (11) - signm (11)
- signo (11)
- spawn (24)
- system (24)
- thread (2)
- timeout (41)
-
to
_ json (11) -
to
_ s (22) -
to
_ tty? (7) -
verify
_ gem (11) -
verify
_ trust _ dir (11) -
warn
_ legacy (11) -
write
_ nonblock (11) - yaml (11)
- スレッド (11)
- 制御構造 (11)
検索結果
先頭5件
-
Exception
# full _ message(highlight: true , order: :bottom) -> String (21018.0) -
例外の整形された文字列を返します。
...値は Exception.to_tty? の返り値と同じです。
@param order :top か :bottom で指定する必要があります。
バックトレースの一番奥がエラーメッセージの上(top)か下(bottom)かを指定します。
デフォルト値は Exception.to_tt......e[1m)\n\e[m"
$stderr = $stdout
p e.full_message # => "test.rb:2:in `<main>': test (RuntimeError)\n"
$stderr = STDERR
p e.full_message # => "\e[1mTraceback \e[m(most recent call last):\ntest.rb:2:in `<main>': \e[1mtest (\e[4;1mRuntimeError\e[m\e[1m)\n\e[m"
end
//}
@see Exception.to_tty?... -
Exception
# inspect -> String (21012.0) -
self のクラス名と message を文字列にして返します。
...self のクラス名と message を文字列にして返します。
//emlist[例][ruby]{
begin
raise "exception"
rescue
p $!.inspect # => "#<RuntimeError: exception>"
end
//}... -
Exception
# backtrace -> [String] (21006.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
. to _ tty? -> bool (21006.0) -
$stderr が変更されておらず、$stderr.tty? が真の場合は true を返します。
...$stderr が変更されておらず、$stderr.tty? が真の場合は true を返します。
[注意] 2.5.1 で追加されたメソッドです。
@see Exception#full_message......$stderr が変更されておらず、$stderr.tty? が真の場合は true を返します。
@see Exception#full_message... -
Exception
# message -> String (21000.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] (21000.0) -
バックトレース情報に errinfo を設定し、設定されたバックトレース 情報を返します。
バックトレース情報に errinfo を設定し、設定されたバックトレース
情報を返します。
@param errinfo nil、String あるいは String の配列のいずれかを指定します。
//emlist[例][ruby]{
begin
begin
raise "inner"
rescue
raise "outer"
end
rescue
$!.backtrace # => ["/path/to/test.rb:5:in `rescue in <main>'", "/path/to/test.rb:2:in `<main>'"]
$!.se... -
Exception
# to _ json(*args) -> String (21000.0) -
自身を JSON 形式の文字列に変換して返します。
自身を JSON 形式の文字列に変換して返します。
内部的にはハッシュにデータをセットしてから JSON::Generator::GeneratorMethods::Hash#to_json を呼び出しています。
@param args 引数はそのまま JSON::Generator::GeneratorMethods::Hash#to_json に渡されます。
//emlist[例][ruby]{
require "json/add/core"
begin
0/0
rescue => e
e.to_json # => "{\"json_class\":\"ZeroDivis... -
Exception
# to _ s -> String (21000.0) -
エラーメッセージをあらわす文字列を返します。
エラーメッセージをあらわす文字列を返します。
//emlist[例][ruby]{
begin
1 + nil
rescue => e
p e.message #=> "nil can't be coerced into Fixnum"
end
//} -
Gem
:: Exception (18000.0) -
RubyGems で扱う全ての例外のスーパークラスです。
RubyGems で扱う全ての例外のスーパークラスです。 -
Gem
:: Security :: Exception (18000.0) -
セキュリティ関連のエラーを表します。
セキュリティ関連のエラーを表します。