Class: Ruboty::DMM::Agent
- Inherits:
-
Object
- Object
- Ruboty::DMM::Agent
- Defined in:
- lib/ruboty/dmm/agent.rb
Instance Attribute Summary collapse
-
#agent ⇒ Object
Returns the value of attribute agent.
Instance Method Summary collapse
-
#initialize ⇒ Agent
constructor
A new instance of Agent.
Constructor Details
#initialize ⇒ Agent
Returns a new instance of Agent.
6 7 8 9 10 11 12 |
# File 'lib/ruboty/dmm/agent.rb', line 6 def initialize @agent = ::Mechanize.new @agent.user_agent_alias = 'Mac Safari' @agent.ignore_bad_chunking = true @agent.request_headers = { 'Accept-Encoding' => '' } @agent.ignore_bad_chunking = true end |
Instance Attribute Details
#agent ⇒ Object
Returns the value of attribute agent.
4 5 6 |
# File 'lib/ruboty/dmm/agent.rb', line 4 def agent @agent end |