Module: ActiveEncode::Core::ClassMethods
- Defined in:
- lib/active_encode/core.rb
Instance Method Summary collapse
- #create(input, options = nil) ⇒ Object
- #default_options(input) ⇒ Object
- #find(id) ⇒ Object
- #list(*filters) ⇒ Object
Instance Method Details
#create(input, options = nil) ⇒ Object
27 28 29 30 |
# File 'lib/active_encode/core.rb', line 27 def create(input, = nil) object = new(input, ) object.create! end |
#default_options(input) ⇒ Object
23 24 25 |
# File 'lib/active_encode/core.rb', line 23 def (input) {} end |
#find(id) ⇒ Object
32 33 34 |
# File 'lib/active_encode/core.rb', line 32 def find(id) engine_adapter.find(id, cast: self) end |
#list(*filters) ⇒ Object
36 37 38 |
# File 'lib/active_encode/core.rb', line 36 def list(*filters) engine_adapter.list(filters) end |