Class: Libis::Services::Oai::Query
- Inherits:
-
Object
- Object
- Libis::Services::Oai::Query
- Defined in:
- lib/libis/services/oai.rb
Instance Method Summary collapse
- #[](key, value) ⇒ Object
-
#initialize(options = {}) ⇒ Query
constructor
A new instance of Query.
- #to_hash ⇒ Object
Constructor Details
#initialize(options = {}) ⇒ Query
Returns a new instance of Query.
13 14 15 16 |
# File 'lib/libis/services/oai.rb', line 13 def initialize( = {}) = [:metadata_prefix] ||= 'oai_dc' end |
Instance Method Details
#[](key, value) ⇒ Object
18 19 20 |
# File 'lib/libis/services/oai.rb', line 18 def [](key, value) [key] = value end |
#to_hash ⇒ Object
22 23 24 25 26 27 28 29 30 |
# File 'lib/libis/services/oai.rb', line 22 def to_hash { from: [:from], until: [:until], metadata_prefix: [:metadata_prefix], set: [:set], resumption_token: [:token] || [:resumption_token] }.cleanup end |