Class: RI::NamedThing
- Inherits:
-
Object
- Object
- RI::NamedThing
- Defined in:
- lib/rdoc/ri/ri_descriptions.rb
Direct Known Subclasses
AliasName, Attribute, Constant, IncludedModule, MethodSummary
Instance Attribute Summary collapse
-
#name ⇒ Object
readonly
Returns the value of attribute name.
Instance Method Summary collapse
- #<=>(other) ⇒ Object
- #eql?(other) ⇒ Boolean
- #hash ⇒ Object
-
#initialize(name) ⇒ NamedThing
constructor
A new instance of NamedThing.
Constructor Details
#initialize(name) ⇒ NamedThing
Returns a new instance of NamedThing.
11 12 13 |
# File 'lib/rdoc/ri/ri_descriptions.rb', line 11 def initialize(name) @name = name end |
Instance Attribute Details
#name ⇒ Object (readonly)
Returns the value of attribute name
10 11 12 |
# File 'lib/rdoc/ri/ri_descriptions.rb', line 10 def name @name end |
Instance Method Details
#<=>(other) ⇒ Object
14 15 16 |
# File 'lib/rdoc/ri/ri_descriptions.rb', line 14 def <=>(other) @name <=> other.name end |
#eql?(other) ⇒ Boolean
22 23 24 |
# File 'lib/rdoc/ri/ri_descriptions.rb', line 22 def eql?(other) @name.eql?(other) end |
#hash ⇒ Object
18 19 20 |
# File 'lib/rdoc/ri/ri_descriptions.rb', line 18 def hash @name.hash end |