Class: MotionDataWrapper::Model

Inherits:
NSManagedObject
  • Object
show all
Includes:
CoreData, FinderMethods, Persistence, Validations
Defined in:
lib/motion_data_wrapper/model.rb,
lib/motion_data_wrapper/model/core_data.rb,
lib/motion_data_wrapper/model/persistence.rb,
lib/motion_data_wrapper/model/validations.rb,
lib/motion_data_wrapper/model/finder_methods.rb

Defined Under Namespace

Modules: CoreData, FinderMethods, Persistence, Validations

Instance Method Summary collapse

Methods included from Validations

#errors, #valid?

Methods included from Persistence

#awakeFromFetch, #awakeFromInsert, #destroy, #destroyed?, included, #new_record?, #persisted?, #save, #save!

Methods included from FinderMethods

included

Methods included from CoreData

included

Instance Method Details

#inspectObject



8
9
10
11
12
13
14
15
# File 'lib/motion_data_wrapper/model.rb', line 8

def inspect
  properties = []
  entity.properties.select { |p| p.is_a?(NSAttributeDescription) }.each do |property|
    properties << "#{property.name}: #{valueForKey(property.name).inspect}"
  end

  "#<#{entity.name} #{properties.join(", ")}>"
end