Exception: NameError
- Inherits:
-
StandardError
- Object
- Exception
- StandardError
- NameError
- Defined in:
- error.c
Direct Known Subclasses
Defined Under Namespace
Classes: message
Instance Method Summary collapse
-
#new(msg[, name]) ⇒ Object
constructor
Construct a new NameError exception.
-
#name ⇒ String?
Return the name associated with this NameError exception.
-
#to_s ⇒ String
Produce a nicely-formated string representing the
NameError
.
Methods inherited from Exception
#backtrace, #exception, exception, #inspect, #message, #set_backtrace, #to_str
Constructor Details
#new(msg[, name]) ⇒ Object
Construct a new NameError exception. If given the name parameter may subsequently be examined using the NameError.name
method.
627 628 629 |
# File 'error.c', line 627 static VALUE name_err_initialize(argc, argv, self) int argc; |
Instance Method Details
#name ⇒ String?
Return the name associated with this NameError exception.
648 649 650 |
# File 'error.c', line 648 static VALUE name_err_name(self) VALUE self; |
#to_s ⇒ String
Produce a nicely-formated string representing the NameError
.
662 663 664 |
# File 'error.c', line 662 static VALUE name_err_to_s(exc) VALUE exc; |