module Airbrake::FileCache

def self.[](key)

Returns:
  • (Object) - the corresponding value

Parameters:
  • key (Object) --
def self.[](key)
  MUTEX.synchronize do
    data[key]
  end
end

def self.[]=(key, value)

Returns:
  • (Object) - the corresponding value

Parameters:
  • value (Object) --
  • key (Object) --
def self.[]=(key, value)
  MUTEX.synchronize do
    data[key] = value
    data.delete(data.keys.first) if data.size > MAX_SIZE
  end
end

def self.data

def self.data
  @data ||= {}
end

def self.empty?

Returns:
  • (Boolean) -
def self.empty?
  data.empty?
end

def self.reset

Returns:
  • (void) -

Other tags:
    Since: - v4.7.0
def self.reset
  @data = {}
end