Class: RETS4R::Client::MetadataRequest
- Inherits:
-
Object
- Object
- RETS4R::Client::MetadataRequest
- Defined in:
- lib/rets4r/client/metadata_request.rb
Instance Attribute Summary collapse
-
#client ⇒ Object
Returns the value of attribute client.
-
#method ⇒ Object
Returns the value of attribute method.
-
#retry_auth ⇒ Object
Returns the value of attribute retry_auth.
-
#uri ⇒ Object
Returns the value of attribute uri.
Instance Method Summary collapse
- #data ⇒ Object
- #header ⇒ Object
-
#initialize(uri, type, id, format, request_struct) ⇒ MetadataRequest
constructor
A new instance of MetadataRequest.
- #request ⇒ Object
Constructor Details
#initialize(uri, type, id, format, request_struct) ⇒ MetadataRequest
Returns a new instance of MetadataRequest.
5 6 7 8 9 10 11 |
# File 'lib/rets4r/client/metadata_request.rb', line 5 def initialize(uri, type, id, format, request_struct) @uri = uri @type = type @id = id @format = format @request_struct = request_struct end |
Instance Attribute Details
#client ⇒ Object
Returns the value of attribute client.
4 5 6 |
# File 'lib/rets4r/client/metadata_request.rb', line 4 def client @client end |
#method ⇒ Object
Returns the value of attribute method.
4 5 6 |
# File 'lib/rets4r/client/metadata_request.rb', line 4 def method @method end |
#retry_auth ⇒ Object
Returns the value of attribute retry_auth.
4 5 6 |
# File 'lib/rets4r/client/metadata_request.rb', line 4 def retry_auth @retry_auth end |
#uri ⇒ Object
Returns the value of attribute uri.
4 5 6 |
# File 'lib/rets4r/client/metadata_request.rb', line 4 def uri @uri end |
Instance Method Details
#data ⇒ Object
15 16 17 18 19 20 21 |
# File 'lib/rets4r/client/metadata_request.rb', line 15 def data { 'Type' => @type, 'ID' => @id, 'Format' => @format } end |
#header ⇒ Object
22 23 24 |
# File 'lib/rets4r/client/metadata_request.rb', line 22 def header { 'Accept' => 'text/xml,text/plain;q=0.5' } end |
#request ⇒ Object
12 13 14 |
# File 'lib/rets4r/client/metadata_request.rb', line 12 def request @request_struct.request(uri, data, header) end |