Class: ValidateableObject
- Inherits:
-
Object
- Object
- ValidateableObject
- Includes:
- ActiveModel::Validations
- Defined in:
- lib/validates_serialized/validateable_object.rb
Direct Known Subclasses
Instance Method Summary collapse
-
#initialize(object) ⇒ ValidateableObject
constructor
A new instance of ValidateableObject.
Methods included from ActiveModel::Validations
#validates_array_values_with, #validates_hash_values_with, #validates_serialized_with!
Constructor Details
#initialize(object) ⇒ ValidateableObject
Returns a new instance of ValidateableObject.
6 7 8 |
# File 'lib/validates_serialized/validateable_object.rb', line 6 def initialize(object) @object = object end |
Dynamic Method Handling
This class handles dynamic methods through the method_missing method
#method_missing(method, *args, &block) ⇒ Object (private)
11 12 13 14 |
# File 'lib/validates_serialized/validateable_object.rb', line 11 def method_missing(method, *args, &block) @object.send(method, *args, &block) rescue NoMethodError => e end |