Exception

ruby/spec describes 45 methods in core/exception, and Metorex implements 45 of them. The parameters are what Method#parameters answers under Metorex.

Errno::EINVAL#

Exception#

  • Exception#==: implemented, parameters [[:req]]. Returns whether object is the same class as self and its #message and #backtrace are equal to those of self.
  • Exception#backtrace: implemented, parameters []. Returns the backtrace (the list of code locations that led to the exception), as an array of strings. An example calling it.
  • Exception#backtrace_locations: implemented, parameters []. Returns the backtrace (the list of code locations that led to the exception), as an array of Thread::Backtrace::Location instances. An example calling it.
  • Exception#cause: implemented, parameters []. Returns the previous value of global variable $!, which may be nil (see Global Variables): An example calling it.
  • Exception#detailed_message: implemented, parameters [[:rest]]. Returns the message string with enhancements: An example calling it.
  • Exception#dup: implemented, parameters []. Produces a shallow copy of obj---the instance variables of obj are copied, but not the objects they reference. An example calling it.
  • Exception#exception: implemented, parameters [[:rest]]. Returns an exception object of the same class as self; useful for creating a similar exception, but with a different message. An example calling it.
  • Exception.exception: implemented, parameters [[:req, :args]]. Returns an exception object of the same class as self; useful for creating a similar exception, but with a different message. An example calling it.
  • Exception#full_message: implemented, parameters [[:rest]]. Returns an enhanced message string: An example calling it.
  • Exception#inspect: implemented, parameters []. Returns a string representation of self: An example calling it.
  • Exception#message: implemented, parameters []. Returns #to_s. An example calling it.
  • Exception.new: implemented, parameters [[:rest]]. Returns a new exception object. An example calling it.
  • Exception#set_backtrace: implemented, parameters [[:req]]. Sets the backtrace value for self; returns the given value. An example calling it.
  • Exception#to_s: implemented, parameters []. Returns a string representation of self: An example calling it.

FrozenError#

  • FrozenError#message: implemented, parameters []. Returns #to_s. An example calling it.
  • FrozenError.new: implemented, parameters [[:rest]]. Construct a new FrozenError exception. An example calling it.
  • FrozenError#receiver: implemented, parameters []. Return the receiver associated with this FrozenError exception. An example calling it.

Interrupt#

  • Interrupt.new: implemented, parameters [[:rest]]. Construct a new SignalException object. An example calling it.

LoadError#

LocalJumpError#

  • LocalJumpError#exit_value: implemented, parameters []. Returns the exit value associated with this LocalJumpError.
  • LocalJumpError#reason: implemented, parameters []. The reason this block was terminated: :break, :redo, :retry, :next, :return, or :noreason.

NameError#

  • NameError#dup: implemented, parameters []. Produces a shallow copy of obj---the instance variables of obj are copied, but not the objects they reference. An example calling it.
  • NameError#name: implemented, parameters []. Return the name associated with this NameError exception. An example calling it.
  • NameError.new: implemented, parameters [[:rest]]. Construct a new NameError exception. An example calling it.
  • NameError#receiver: implemented, parameters []. Return the receiver associated with this NameError exception. An example calling it.
  • NameError#to_s: implemented, parameters []. Returns a string representation of self: An example calling it.

NoMethodError#

  • NoMethodError#args: implemented, parameters []. Return the arguments passed in as the third parameter to the constructor. An example calling it.
  • NoMethodError#dup: implemented, parameters []. Produces a shallow copy of obj---the instance variables of obj are copied, but not the objects they reference. An example calling it.
  • NoMethodError#message: implemented, parameters []. Returns #to_s. An example calling it.
  • NoMethodError.new: implemented, parameters [[:rest]]. Construct a NoMethodError exception for a method of the given name called with the given arguments. An example calling it.

SignalException#

StopIteration#

  • StopIteration#result: implemented, parameters []. Returns the return value of the iterator. An example calling it.

SyntaxError#

SystemCallError#

  • SystemCallError.===: implemented, parameters [[:req]]. Return true if the receiver is a generic SystemCallError, or if the error numbers self and other are the same.
  • SystemCallError#backtrace: implemented, parameters []. Returns the backtrace (the list of code locations that led to the exception), as an array of strings. An example calling it.
  • SystemCallError#dup: implemented, parameters []. Produces a shallow copy of obj---the instance variables of obj are copied, but not the objects they reference. An example calling it.
  • SystemCallError#errno: implemented, parameters []. Return this SystemCallError's error number. An example calling it.
  • SystemCallError#message: implemented, parameters []. Returns #to_s. An example calling it.
  • SystemCallError.new: implemented, parameters [[:rest]]. If errno corresponds to a known system error code, constructs the appropriate Errno class for that error, otherwise constructs a generic SystemCallError object. An example calling it.

SystemExit#

  • SystemExit#status: implemented, parameters []. Return the status value associated with this system exit. An example calling it.
  • SystemExit#success?: implemented, parameters []. Returns true if exiting successful, false if not. An example calling it.

UncaughtThrowError#

  • UncaughtThrowError#tag: implemented, parameters []. Return the tag object which was called for. An example calling it.

The method summaries are the first sentences of Ruby's own documentation for each method, read from MRI 4.0.6's ri data. Ruby's documentation is distributed under Ruby's license.