Exception: Relaxo::Model::TypeError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/relaxo/model/document.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(document) ⇒ TypeError

Returns a new instance of TypeError.



40
41
42
43
44
# File 'lib/relaxo/model/document.rb', line 40

def initialize(document)
	@document = document
	
	super "Expected type #{@document.class.type} but got #{@document.type}!"
end

Instance Attribute Details

#documentObject (readonly)

Returns the value of attribute document.



46
47
48
# File 'lib/relaxo/model/document.rb', line 46

def document
  @document
end