Module: LucidShopify::Resource::Base
- Defined in:
- lib/lucid_shopify/resource/base.rb
Defined Under Namespace
Modules: ClassMethods
Instance Attribute Summary collapse
- #client ⇒ Client readonly
- #logger ⇒ Client readonly
Class Method Summary collapse
Instance Method Summary collapse
- #initialize(client: Container[:client], logger: Logger.new(IO::NULL)) ⇒ Object
- #resource ⇒ String abstract
Instance Attribute Details
#client ⇒ Client (readonly)
39 40 41 |
# File 'lib/lucid_shopify/resource/base.rb', line 39 def client @client end |
#logger ⇒ Client (readonly)
41 42 43 |
# File 'lib/lucid_shopify/resource/base.rb', line 41 def logger @logger end |
Class Method Details
.included(base) ⇒ Object
24 25 26 |
# File 'lib/lucid_shopify/resource/base.rb', line 24 def self.included(base) base.extend(ClassMethods) end |
Instance Method Details
#initialize(client: Container[:client], logger: Logger.new(IO::NULL)) ⇒ Object
32 33 34 35 36 |
# File 'lib/lucid_shopify/resource/base.rb', line 32 def initialize(client: Container[:client], logger: Logger.new(IO::NULL)) @client = client @logger = logger end |
#resource ⇒ String
This method is abstract.
Use LucidShopify::Resource::Base::ClassMethods#resource to implement (required)
48 49 50 |
# File 'lib/lucid_shopify/resource/base.rb', line 48 def resource raise NotImplementedError end |