Class: Joey::Video

Inherits:
Model
  • Object
show all
Defined in:
lib/joey/video.rb

Instance Attribute Summary

Attributes inherited from Model

#client, #errors

Instance Method Summary collapse

Methods inherited from Model

define_properties, find, get_all, has_association, hash_populating_accessor, hash_populating_association, #initialize, recognize?

Constructor Details

This class inherits a constructor from Joey::Model

Instance Method Details

#valid?Boolean

Returns:

  • (Boolean)


16
17
18
19
20
# File 'lib/joey/video.rb', line 16

def valid?
  self.validate
  puts self.errors.inspect unless self.errors.empty?
  self.errors.empty?
end

#validateObject



12
13
14
# File 'lib/joey/video.rb', line 12

def validate
  self.errors = []
end