Module: Merb::MemcacheStore
Instance Method Summary collapse
-
#delete_session(session_id) ⇒ Object
Parameters session_id<String>:: ID of the session to delete.
-
#retrieve_session(session_id) ⇒ Object
Parameters session_id<String>:: ID of the session to retrieve.
-
#store_session(session_id, data) ⇒ Object
Parameters session_id<String>:: ID of the session to set.
Instance Method Details
#delete_session(session_id) ⇒ Object
Parameters
- session_id<String>
-
ID of the session to delete.
52 53 54 |
# File 'lib/merb-core/dispatch/session/memcached.rb', line 52 def delete_session(session_id) delete("session:#{session_id}") end |
#retrieve_session(session_id) ⇒ Object
Parameters
- session_id<String>
-
ID of the session to retrieve.
Returns
- ContainerSession
-
The session corresponding to the ID.
39 40 41 |
# File 'lib/merb-core/dispatch/session/memcached.rb', line 39 def retrieve_session(session_id) get("session:#{session_id}") end |
#store_session(session_id, data) ⇒ Object
Parameters
- session_id<String>
-
ID of the session to set.
- data<ContainerSession>
-
The session to set.
46 47 48 |
# File 'lib/merb-core/dispatch/session/memcached.rb', line 46 def store_session(session_id, data) set("session:#{session_id}", data) end |