Class: Contraction::ReferenceType

Inherits:
Object
  • Object
show all
Defined in:
lib/parser/type_parser.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(klass) ⇒ ReferenceType

Returns a new instance of ReferenceType.



131
132
133
# File 'lib/parser/type_parser.rb', line 131

def initialize(klass)
  @klass = klass
end

Instance Attribute Details

#klassObject (readonly)

Returns the value of attribute klass.



130
131
132
# File 'lib/parser/type_parser.rb', line 130

def klass
  @klass
end

Instance Method Details

#check(thing) ⇒ Object



135
136
137
# File 'lib/parser/type_parser.rb', line 135

def check(thing)
  thing.is_a? klass
end