RAPP Platform  v0.6.0
RAPP Platform is a collection of ROS nodes and back-end processes that aim to deliver ready-to-use generic services to robots
 All Classes Namespaces Files Functions Variables Macros
src.rapp_http_request_handler.RappHttpRequestHandler Class Reference

Performs http requests. More...

Inheritance diagram for src.rapp_http_request_handler.RappHttpRequestHandler:
Collaboration diagram for src.rapp_http_request_handler.RappHttpRequestHandler:

Public Member Functions

def __init__
 
def perform_request
 Execute the request and verify response. More...
 

Private Member Functions

def _modify_response
 Return the proper response format. More...
 

Private Attributes

 _accepted_status
 The value of valid response status code. More...
 
 _headers
 The request additional headers. More...
 
 _params
 The request parameters. More...
 
 _response_format
 The required response format. More...
 
 _server_timeout
 Seconds to wait for any server response. More...
 
 _url
 The server url. More...
 

Detailed Description

Performs http requests.

Definition at line 30 of file rapp_http_request_handler.py.

Constructor & Destructor Documentation

def src.rapp_http_request_handler.RappHttpRequestHandler.__init__ (   self)

Definition at line 32 of file rapp_http_request_handler.py.

Member Function Documentation

def src.rapp_http_request_handler.RappHttpRequestHandler._modify_response (   self,
  response,
  form = None 
)
private

Return the proper response format.

Parameters
response[request module response] The servers response
form[string] The required response format

RappError Format transformation error

Definition at line 97 of file rapp_http_request_handler.py.

def src.rapp_http_request_handler.RappHttpRequestHandler.perform_request (   self,
  url_add = None,
  params_dict = None,
  headers_dict = None 
)

Execute the request and verify response.

Parameters
url_add[string] The server url
params_dict[dict] The request's parameters
headers_dict[dict] The request's additional headers dictionary
Returns
response [request module response] The servers response

RappError Request error

Definition at line 60 of file rapp_http_request_handler.py.

Member Data Documentation

src.rapp_http_request_handler.RappHttpRequestHandler._accepted_status
private

The value of valid response status code.

Definition at line 46 of file rapp_http_request_handler.py.

src.rapp_http_request_handler.RappHttpRequestHandler._headers
private

The request additional headers.

Definition at line 38 of file rapp_http_request_handler.py.

src.rapp_http_request_handler.RappHttpRequestHandler._params
private

The request parameters.

Definition at line 36 of file rapp_http_request_handler.py.

src.rapp_http_request_handler.RappHttpRequestHandler._response_format
private

The required response format.

Definition at line 41 of file rapp_http_request_handler.py.

src.rapp_http_request_handler.RappHttpRequestHandler._server_timeout
private

Seconds to wait for any server response.

Definition at line 44 of file rapp_http_request_handler.py.

src.rapp_http_request_handler.RappHttpRequestHandler._url
private

The server url.

Definition at line 34 of file rapp_http_request_handler.py.


The documentation for this class was generated from the following file: