class Rack::State::Store::Memory

The default state storage adapter: a slight subclassing of Hash. Memory is only suitable for development and single process apps.

Public Instance Methods

create(token, object) click to toggle source
# File lib/rack/state.rb, line 233
def create(token, object)
  raise KeyError if has_key? token
  store(token, object)
end
read(token) click to toggle source
# File lib/rack/state.rb, line 238
def read(token)
  fetch(token, nil)
end
update(token, object) click to toggle source
# File lib/rack/state.rb, line 242
def update(token, object)
  raise KeyError unless has_key? token
  store(token, object)
end