Classes | Functions | Variables
rosbridge_library::internal::ros_loader Namespace Reference

Classes

class  InvalidClassException
class  InvalidModuleException
class  InvalidPackageException
class  InvalidTypeStringException

Functions

def _add_to_cache
def _get_class
def _get_from_cache
def _get_msg_class
def _get_srv_class
def _load_class
def _splittype
def get_message_class
def get_message_instance
def get_service_class
def get_service_instance
def get_service_request_instance
def get_service_response_instance

Variables

dictionary _loaded_msgs = {}
dictionary _loaded_srvs = {}
tuple _manifest_lock = Lock()
tuple _msgs_lock = Lock()
tuple _srvs_lock = Lock()

Function Documentation

def rosbridge_library.internal.ros_loader._add_to_cache (   cache,
  lock,
  key,
  value 
) [private]

Definition at line 212 of file ros_loader.py.

def rosbridge_library.internal.ros_loader._get_class (   typestring,
  subname,
  cache,
  lock 
) [private]
If not loaded, loads the specified class then returns an instance
of it.

Loaded classes are cached in the provided cache dict

Throws various exceptions if loading the msg class fails 

Definition at line 140 of file ros_loader.py.

def rosbridge_library.internal.ros_loader._get_from_cache (   cache,
  lock,
  key 
) [private]
Returns the value for the specified key from the cache.
Locks the lock before doing anything. Returns None if key not in cache 

Definition at line 218 of file ros_loader.py.

If not loaded, loads the specified msg class then returns an instance
of it

Throws various exceptions if loading the msg class fails 

Definition at line 122 of file ros_loader.py.

If not loaded, loads the specified srv class then returns an instance
of it

Throws various exceptions if loading the srv class fails 

Definition at line 131 of file ros_loader.py.

def rosbridge_library.internal.ros_loader._load_class (   modname,
  subname,
  classname 
) [private]
Loads the manifest and imports the module that contains the specified
type.

Logic is similar to that of roslib.message.get_message_class, but we want
more expressive exceptions.

Returns the loaded module, or None on failure 

Definition at line 172 of file ros_loader.py.

def rosbridge_library.internal.ros_loader._splittype (   typestring) [private]
Split the string the / delimiter and strip out empty strings

Performs similar logic to roslib.names.package_resource_name but is a bit
more forgiving about excess slashes

Definition at line 200 of file ros_loader.py.

Loads the message type specified.

Returns the loaded class, or throws exceptions on failure 

Definition at line 84 of file ros_loader.py.

If not loaded, loads the specified type.
Then returns an instance of it, or None. 

Definition at line 98 of file ros_loader.py.

Loads the service type specified.

Returns the loaded class, or None on failure 

Definition at line 91 of file ros_loader.py.

If not loaded, loads the specified type.
Then returns an instance of it, or None. 

Definition at line 105 of file ros_loader.py.

Definition at line 112 of file ros_loader.py.

Definition at line 117 of file ros_loader.py.


Variable Documentation

Definition at line 48 of file ros_loader.py.

Definition at line 49 of file ros_loader.py.

Definition at line 52 of file ros_loader.py.

Definition at line 50 of file ros_loader.py.

Definition at line 51 of file ros_loader.py.



rosbridge_library
Author(s): Jonathan Mace
autogenerated on Thu Aug 27 2015 14:50:35