Module: CaRuby::Database::Persistifier
- Included in:
- CaRuby::Database
- Defined in:
- lib/caruby/database/persistifier.rb
Overview
Database Persistable mediator. A module which includes Persistifier must implement the Reader#fetch_association method.
Instance Method Summary collapse
-
#clear ⇒ Object
Clears the cache.
-
#initialize ⇒ Object
Adds query capability to this Database.
Instance Method Details
#clear ⇒ Object
Clears the cache.
22 23 24 |
# File 'lib/caruby/database/persistifier.rb', line 22 def clear @cache.clear if @cache end |
#initialize ⇒ Object
Adds query capability to this Database.
14 15 16 17 18 19 |
# File 'lib/caruby/database/persistifier.rb', line 14 def initialize super @ftchd_vstr = Jinx::ReferenceVisitor.new { |ref| ref.class.fetched_domain_attributes } # the demand loader @lazy_loader = LazyLoader.new { |obj, pa| lazy_load(obj, pa) } end |