class

Azu::Cache::Manager

Inherits Reference < Object

Main cache interface

Constructors

new(config : Configuration = Configuration.new)
Source

Instance methods

clear
Source
config
Source
decrement(key : String, amount : Int32 = 1, ttl : Time::Span | Nil = nil) : Int32 | Nil
Source
delete(key : String) : Bool
Source
exists?(key : String) : Bool
Source
fetch(key : String, ttl : Time::Span | Nil = nil, & : -> String) : String
Source
get(key : String) : String | Nil

Rails-like API methods with optional performance metrics

Source
get(key : String, ttl : Time::Span | Nil = nil, & : -> String) : String

Overloaded get method with block and TTL support (Rails-like)

Source
get_multi(keys : Array(String)) : Hash(String, String | Nil)

Multi-key operations

Source
increment(key : String, amount : Int32 = 1, ttl : Time::Span | Nil = nil) : Int32 | Nil

Counter operations

Source
ping

Redis-specific methods (only available when using Redis store)

Source
redis_info
Source
set(key : String, value : String, ttl : Time::Span | Nil = nil) : Bool
Source
set_multi(values : Hash(String, String), ttl : Time::Span | Nil = nil) : Bool
Source
size
Source
stats

Utility methods

Source
store
Source