Method: ActiveFedora::LdpCache::ClassMethods#cache

Defined in:
lib/active_fedora/ldp_cache.rb

#cache(&block) ⇒ Object

Enable the query cache within the block if Active Fedora is configured. If it’s not, it will execute the given block.



7
8
9
10
# File 'lib/active_fedora/ldp_cache.rb', line 7

def cache(&block)
  connection = ActiveFedora.fedora.connection
  connection.cache(&block)
end