Class: WebFinger::Request
- Inherits:
-
Object
- Object
- WebFinger::Request
- Defined in:
- lib/webfinger/request.rb
Instance Attribute Summary collapse
-
#relations ⇒ Object
Returns the value of attribute relations.
-
#resource ⇒ Object
Returns the value of attribute resource.
Instance Method Summary collapse
- #discover! ⇒ Object
-
#initialize(resource, options = {}) ⇒ Request
constructor
A new instance of Request.
Constructor Details
#initialize(resource, options = {}) ⇒ Request
Returns a new instance of Request.
5 6 7 8 9 |
# File 'lib/webfinger/request.rb', line 5 def initialize(resource, = {}) self.resource = resource self.relations = Array([:rel] || [:relations]) @options = end |
Instance Attribute Details
#relations ⇒ Object
Returns the value of attribute relations.
3 4 5 |
# File 'lib/webfinger/request.rb', line 3 def relations @relations end |
#resource ⇒ Object
Returns the value of attribute resource.
3 4 5 |
# File 'lib/webfinger/request.rb', line 3 def resource @resource end |
Instance Method Details
#discover! ⇒ Object
11 12 13 14 15 |
# File 'lib/webfinger/request.rb', line 11 def discover! handle_response do WebFinger.http_client.get(endpoint.to_s) end end |