Class: RBI::Type::Module
- Inherits:
-
Type
- Object
- Type
- RBI::Type::Module
- Defined in:
- lib/rbi/type.rb
Overview
The module of another type like T::Module[Foo].
Instance Attribute Summary collapse
- #type ⇒ Object readonly
Instance Method Summary collapse
- #==(other) ⇒ Object
-
#initialize(type) ⇒ Module
constructor
A new instance of Module.
- #normalize ⇒ Object
- #simplify ⇒ Object
- #to_rbi ⇒ Object
Constructor Details
#initialize(type) ⇒ Module
Returns a new instance of Module.
283 284 285 286 |
# File 'lib/rbi/type.rb', line 283 def initialize(type) super() @type = type end |
Instance Attribute Details
#type ⇒ Object (readonly)
280 281 282 |
# File 'lib/rbi/type.rb', line 280 def type @type end |
Instance Method Details
#==(other) ⇒ Object
290 291 292 |
# File 'lib/rbi/type.rb', line 290 def ==(other) Module === other && @type == other.type end |
#normalize ⇒ Object
302 303 304 |
# File 'lib/rbi/type.rb', line 302 def normalize self end |
#simplify ⇒ Object
308 309 310 |
# File 'lib/rbi/type.rb', line 308 def simplify self end |
#to_rbi ⇒ Object
296 297 298 |
# File 'lib/rbi/type.rb', line 296 def to_rbi "::T::Module[#{@type}]" end |