Module: LucidShopify::Resource::Base
- Defined in:
- lib/lucid_shopify/resource/base.rb
Defined Under Namespace
Modules: ClassMethods
Class Method Summary collapse
Instance Method Summary collapse
- #client ⇒ Client
- #client=(new_client) ⇒ Object
- #logger ⇒ Logger
- #logger=(new_logger) ⇒ Object
- #resource ⇒ String abstract
Class Method Details
.included(base) ⇒ Object
29 30 31 |
# File 'lib/lucid_shopify/resource/base.rb', line 29 def self.included(base) base.extend(ClassMethods) end |
Instance Method Details
#client ⇒ Client
45 46 47 |
# File 'lib/lucid_shopify/resource/base.rb', line 45 def client @client ||= Container[:client] end |
#client=(new_client) ⇒ Object
52 53 54 |
# File 'lib/lucid_shopify/resource/base.rb', line 52 def client=(new_client) @client = new_client end |
#logger ⇒ Logger
59 60 61 |
# File 'lib/lucid_shopify/resource/base.rb', line 59 def logger @logger ||= Logger.new(IO::NULL) end |
#logger=(new_logger) ⇒ Object
66 67 68 |
# File 'lib/lucid_shopify/resource/base.rb', line 66 def logger=(new_logger) @logger = new_logger end |
#resource ⇒ String
This method is abstract.
Use LucidShopify::Resource::Base::ClassMethods#resource to implement (required)
38 39 40 |
# File 'lib/lucid_shopify/resource/base.rb', line 38 def resource raise NotImplementedError end |