Class: RapidApi::ModelAdapters::Abstract
- Inherits:
-
Object
- Object
- RapidApi::ModelAdapters::Abstract
- Defined in:
- lib/rapid_api/model_adapters/abstract.rb
Direct Known Subclasses
Instance Attribute Summary collapse
-
#klass ⇒ Object
Returns the value of attribute klass.
Instance Method Summary collapse
- #create(_params, _scope = nil) ⇒ Object
- #destroy(_id, _scope = nil) ⇒ Object
- #find(_id, _scope = nil) ⇒ Object
- #find_all(_params = nil, _scope = nil) ⇒ Object
-
#initialize(klass) ⇒ Abstract
constructor
A new instance of Abstract.
- #update(_id, _params, _scope = nil) ⇒ Object
Constructor Details
#initialize(klass) ⇒ Abstract
Returns a new instance of Abstract.
7 8 9 |
# File 'lib/rapid_api/model_adapters/abstract.rb', line 7 def initialize(klass) @klass = klass end |
Instance Attribute Details
#klass ⇒ Object
Returns the value of attribute klass.
5 6 7 |
# File 'lib/rapid_api/model_adapters/abstract.rb', line 5 def klass @klass end |
Instance Method Details
#create(_params, _scope = nil) ⇒ Object
19 20 21 |
# File 'lib/rapid_api/model_adapters/abstract.rb', line 19 def create(_params, _scope=nil) raise NotImplementedError end |
#destroy(_id, _scope = nil) ⇒ Object
27 28 29 |
# File 'lib/rapid_api/model_adapters/abstract.rb', line 27 def destroy(_id, _scope=nil) raise NotImplementedError end |
#find(_id, _scope = nil) ⇒ Object
11 12 13 |
# File 'lib/rapid_api/model_adapters/abstract.rb', line 11 def find(_id, _scope=nil) raise NotImplementedError end |
#find_all(_params = nil, _scope = nil) ⇒ Object
15 16 17 |
# File 'lib/rapid_api/model_adapters/abstract.rb', line 15 def find_all(_params=nil, _scope=nil) raise NotImplementedError end |
#update(_id, _params, _scope = nil) ⇒ Object
23 24 25 |
# File 'lib/rapid_api/model_adapters/abstract.rb', line 23 def update(_id, _params, _scope=nil) raise NotImplementedError end |