Public Member Functions | Public Attributes | Private Attributes
lama_interfaces.map_agent.MapAgent Class Reference

List of all members.

Public Member Functions

def __init__
def get_descriptor_links
def get_edge_list
def get_lama_object_list
def get_vertex_list
def timeout
def timeout
def wait_for_service

Public Attributes

 action_service_class
 action_service_name
 proxy
 timeout

Private Attributes

 _timeout

Detailed Description

Class to interact with the map through service calls

The service calls must be done through MapAgent.proxy.
Example of database request through service call:
    map_action = ActOnMapRequest()
    map_action.action = map_action.GET_DESCRIPTOR_LINKS
    map_action.object.id = request_object_id
    map_action.interface_name = request_interface_name
    response = MapAgent().proxy(map_action)
A few function members are provided to facilitate such requests
(get_vertex_list, get_edge_list).

Definition at line 23 of file map_agent.py.


Constructor & Destructor Documentation

def lama_interfaces.map_agent.MapAgent.__init__ (   self,
  timeout = None 
)
Parameters
----------
- timeout: None or double. Timeout for contacting service. If None,
    the service is supposed to be up and wait_for_service will not be
    called. If 0, wait_for_service() is called, i.e. wait undefinitely.
    Otherwise, wait_for_service(timeout) is called.

Definition at line 36 of file map_agent.py.


Member Function Documentation

def lama_interfaces.map_agent.MapAgent.get_descriptor_links (   self,
  id_,
  interface_name = None 
)
Retrieve the list of DescriptorLink associated with a Lama object

Return a list of DescriptorLink. If interface_name is given, return
all DescriptorLink corresponding to this interface_name, otherwise, and
if interface_name is '' or '*', return all DescriptorLink.

Parameters
----------
- id_: int, lama object id in the database.
- interface_name: string, default to None.
    If None, '', or '*', all DescriptorLink are returned.
    Otherwise, only DescriptorLink from this interface are returned.

Definition at line 146 of file map_agent.py.

def lama_interfaces.map_agent.MapAgent.get_edge_list (   self,
  criteria = None 
)
Return the list of edges as LamaObject that match the search criteria

Retrieve all edges that match the search criteria.

Search criteria are attributes of criteria with non-default values
(defaults are 0 or '').
Return a list of LamaObject, an empty list of no LamaObject matches, or
None on service error.

Parameters
----------
- criteria: an instance of LamaObject, supposed of type EDGE.

Definition at line 91 of file map_agent.py.

Return the list of vertices and edges as LamaObject

Definition at line 79 of file map_agent.py.

def lama_interfaces.map_agent.MapAgent.get_vertex_list (   self,
  criteria = None 
)
Return the list of vertices as LamaObject that match the criteria

Retrieve all vertices that match the search criteria.

Search criteria are attributes of criteria with non-default values
(defaults are 0 or '').
Return a list of LamaObject, an empty list of no LamaObject matches, or
None on service error.

Parameters
----------
- criteria: an instance of LamaObject, supposed of type VERTEX.

Definition at line 118 of file map_agent.py.

Definition at line 54 of file map_agent.py.

def lama_interfaces.map_agent.MapAgent.timeout (   self,
  value 
)

Definition at line 58 of file map_agent.py.

Definition at line 61 of file map_agent.py.


Member Data Documentation

Definition at line 43 of file map_agent.py.

Definition at line 43 of file map_agent.py.

Definition at line 43 of file map_agent.py.

Definition at line 43 of file map_agent.py.

Definition at line 61 of file map_agent.py.


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


interfaces
Author(s): Gaël Ecorchard , Karel Košnar
autogenerated on Sat Jun 8 2019 19:03:14