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 Yegor Bugayenko
- 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.
66 67 68 |
# File 'lib/zold/txns.rb', line 66 def initialize(txns) @txns = txns end |
Instance Method Details
#fetch ⇒ Object
74 75 76 |
# File 'lib/zold/txns.rb', line 74 def fetch @fetch ||= @txns.fetch end |
#flush ⇒ Object
70 71 72 |
# File 'lib/zold/txns.rb', line 70 def flush @fetch = nil end |