Class: Mushikago::Mitsubachi::Cookiejar
- Inherits:
-
Object
- Object
- Mushikago::Mitsubachi::Cookiejar
- Defined in:
- lib/mushikago/mitsubachi/cookiejar.rb
Overview
http_fetch/http_pushに渡すcookiejarオブジェクト
Instance Attribute Summary collapse
-
#cookies ⇒ Object
readonly
Returns the value of attribute cookies.
Instance Method Summary collapse
- #add(cookie) ⇒ Object
-
#initialize ⇒ Cookiejar
constructor
A new instance of Cookiejar.
- #to_json(*args) ⇒ Object
Constructor Details
#initialize ⇒ Cookiejar
Returns a new instance of Cookiejar.
17 18 19 |
# File 'lib/mushikago/mitsubachi/cookiejar.rb', line 17 def initialize @cookies = [] end |
Instance Attribute Details
#cookies ⇒ Object (readonly)
Returns the value of attribute cookies.
16 17 18 |
# File 'lib/mushikago/mitsubachi/cookiejar.rb', line 16 def @cookies end |
Instance Method Details
#add(cookie) ⇒ Object
21 22 23 |
# File 'lib/mushikago/mitsubachi/cookiejar.rb', line 21 def add @cookies << end |
#to_json(*args) ⇒ Object
25 26 27 |
# File 'lib/mushikago/mitsubachi/cookiejar.rb', line 25 def to_json *args @cookies.to_json(args) end |