class HttpCacheController

Public Instance Methods

collection() click to toggle source
# File test/http_cache_responder_test.rb, line 20
def collection
  respond_with [Address.new(Time.utc(2009)), Address.new(Time.utc(2008))]
end
empty() click to toggle source
# File test/http_cache_responder_test.rb, line 30
def empty
  respond_with []
end
nested() click to toggle source
# File test/http_cache_responder_test.rb, line 16
def nested
  respond_with Address.new(Time.utc(2009)), Address.new(Time.utc(2008))
end
not_persisted() click to toggle source
# File test/http_cache_responder_test.rb, line 24
def not_persisted
  model = Address.new(Time.utc(2009))
  model.persisted = false
  respond_with(model)
end
single() click to toggle source
# File test/http_cache_responder_test.rb, line 10
def single
  options = params.slice(:http_cache)
  response.last_modified = Time.utc(2008) if params[:last_modified]
  respond_with(Address.new(Time.utc(2009)), options)
end