Class: Chromable::Settings
- Inherits:
-
Object
- Object
- Chromable::Settings
- Defined in:
- lib/chromable.rb
Overview
Chromable settings class to hide them from Rails models.
Instance Attribute Summary collapse
-
#collection_name ⇒ Object
rubocop:disable Lint/DuplicateMethods.
-
#document ⇒ Object
Returns the value of attribute document.
-
#embedder ⇒ Object
Returns the value of attribute embedder.
-
#keep_document ⇒ Object
Returns the value of attribute keep_document.
-
#metadata ⇒ Object
Returns the value of attribute metadata.
Instance Method Summary collapse
-
#initialize(document:, metadata: nil, embedder: nil, collection_name: nil, keep_document: true) ⇒ Settings
constructor
A new instance of Settings.
Constructor Details
#initialize(document:, metadata: nil, embedder: nil, collection_name: nil, keep_document: true) ⇒ Settings
Returns a new instance of Settings.
19 20 21 22 23 24 25 |
# File 'lib/chromable.rb', line 19 def initialize(document:, metadata: nil, embedder: nil, collection_name: nil, keep_document: true) @collection_name = collection_name @document = document @metadata = @embedder = @keep_document = keep_document end |
Instance Attribute Details
#collection_name ⇒ Object
rubocop:disable Lint/DuplicateMethods
27 28 29 |
# File 'lib/chromable.rb', line 27 def collection_name @collection_name end |
#document ⇒ Object
Returns the value of attribute document.
17 18 19 |
# File 'lib/chromable.rb', line 17 def document @document end |
#embedder ⇒ Object
Returns the value of attribute embedder.
17 18 19 |
# File 'lib/chromable.rb', line 17 def @embedder end |
#keep_document ⇒ Object
Returns the value of attribute keep_document.
17 18 19 |
# File 'lib/chromable.rb', line 17 def keep_document @keep_document end |
#metadata ⇒ Object
Returns the value of attribute metadata.
17 18 19 |
# File 'lib/chromable.rb', line 17 def @metadata end |