Module: Cash::Index::Attributes
- Included in:
- Cash::Index
- Defined in:
- lib/cash/index.rb
Instance Method Summary collapse
- #buffer ⇒ Object
- #limit ⇒ Object
- #order ⇒ Object
- #order_column ⇒ Object
- #ttl ⇒ Object
- #window ⇒ Object
Instance Method Details
#buffer ⇒ Object
58 59 60 |
# File 'lib/cash/index.rb', line 58 def buffer [:buffer] end |
#limit ⇒ Object
54 55 56 |
# File 'lib/cash/index.rb', line 54 def limit [:limit] end |
#order ⇒ Object
50 51 52 |
# File 'lib/cash/index.rb', line 50 def order @order ||= [:order] || :asc end |
#order_column ⇒ Object
66 67 68 |
# File 'lib/cash/index.rb', line 66 def order_column [:order_column] || 'id' end |
#ttl ⇒ Object
46 47 48 |
# File 'lib/cash/index.rb', line 46 def ttl @ttl ||= [:ttl] || @config.ttl end |
#window ⇒ Object
62 63 64 |
# File 'lib/cash/index.rb', line 62 def window limit && limit + buffer end |