Class: Decaptcha::Response
- Inherits:
-
Object
- Object
- Decaptcha::Response
- Defined in:
- lib/decaptcha/response.rb
Instance Attribute Summary collapse
-
#balance ⇒ Object
Returns the value of attribute balance.
-
#banned ⇒ Object
Returns the value of attribute banned.
-
#deleted ⇒ Object
Returns the value of attribute deleted.
-
#id ⇒ Object
Returns the value of attribute id.
-
#invalid ⇒ Object
Returns the value of attribute invalid.
-
#location ⇒ Object
Returns the value of attribute location.
-
#status ⇒ Object
Returns the value of attribute status.
-
#text ⇒ Object
Returns the value of attribute text.
Class Method Summary collapse
Instance Attribute Details
#balance ⇒ Object
Returns the value of attribute balance.
9 10 11 |
# File 'lib/decaptcha/response.rb', line 9 def balance @balance end |
#banned ⇒ Object
Returns the value of attribute banned.
10 11 12 |
# File 'lib/decaptcha/response.rb', line 10 def banned @banned end |
#deleted ⇒ Object
Returns the value of attribute deleted.
8 9 10 |
# File 'lib/decaptcha/response.rb', line 8 def deleted @deleted end |
#id ⇒ Object
Returns the value of attribute id.
3 4 5 |
# File 'lib/decaptcha/response.rb', line 3 def id @id end |
#invalid ⇒ Object
Returns the value of attribute invalid.
7 8 9 |
# File 'lib/decaptcha/response.rb', line 7 def invalid @invalid end |
#location ⇒ Object
Returns the value of attribute location.
4 5 6 |
# File 'lib/decaptcha/response.rb', line 4 def location @location end |
#status ⇒ Object
Returns the value of attribute status.
6 7 8 |
# File 'lib/decaptcha/response.rb', line 6 def status @status end |
#text ⇒ Object
Returns the value of attribute text.
5 6 7 |
# File 'lib/decaptcha/response.rb', line 5 def text @text end |
Class Method Details
.new_from_location(location) ⇒ Object
12 13 14 15 16 17 18 |
# File 'lib/decaptcha/response.rb', line 12 def self.new_from_location location r = Response.new r.location = location location =~ /(\d+)\Z/ r.id = $1 r end |