Class: Zold::CachedTxns
- Inherits:
-
Object
- Object
- Zold::CachedTxns
- Defined in:
- lib/zold/txns.rb
Overview
Cached transactions.
- Author
-
Yegor Bugayenko ([email protected])
- Copyright
-
Copyright © 2018-2025 Zerocracy
- License
-
MIT
Instance Method Summary collapse
- #fetch ⇒ Object
- #flush ⇒ Object
-
#initialize(txns) ⇒ CachedTxns
constructor
A new instance of CachedTxns.
Constructor Details
#initialize(txns) ⇒ CachedTxns
Returns a new instance of CachedTxns.
49 50 51 |
# File 'lib/zold/txns.rb', line 49 def initialize(txns) @txns = txns end |
Instance Method Details
#fetch ⇒ Object
57 58 59 |
# File 'lib/zold/txns.rb', line 57 def fetch @fetch ||= @txns.fetch end |
#flush ⇒ Object
53 54 55 |
# File 'lib/zold/txns.rb', line 53 def flush @fetch = nil end |