module documentation

Library for supporting message and service generation for all ROS client libraries. This is mainly responsible for calculating the md5sums and message definitions of classes.

Function compute_full_text Compute full text of message/service, including text of embedded types. The text of the main msg/srv is listed first. Embedded msg/srv files are denoted first by an 80-character '=' separator, followed by a type declaration line,'MSG: pkg/type', followed by the text of the embedded type.
Function compute_md5 Compute md5 hash for message/service @param get_deps_dict dict: dictionary returned by get_dependencies call @type get_deps_dict: dict @return: md5 hash @rtype: str
Function compute_md5_text Compute the text used for md5 calculation. MD5 spec states that we removes comments and non-meaningful whitespace. We also strip packages names from type names. For convenience sake, constants are reordered ahead of other declarations, in the order that they were originally defined.
Function compute_md5_v1 Compute original V1 md5 hash for message/service. This was replaced with V2 in ROS 0.6. @param get_deps_dict: dictionary returned by get_dependencies call @type get_deps_dict: dict @return: md5 hash @rtype: str...
Function get_dependencies Compute dependencies of the specified Msgs/Srvs @param spec: message or service instance @type spec: L{roslib.msgs.MsgSpec}/L{roslib.srvs.SrvSpec} @param package: package name @type package: str @param stdout: (optional) stdout pipe @type stdout: file @param stderr: (optional) stderr pipe @type stderr: file @param compute_files: (optional, default=True) compute file dependencies of message ('files' key in return value) @type compute_files: bool @return: dict:...
Function get_file_dependencies Compute dependencies of the specified message/service file @param f: message or service file to get dependencies for @type f: str @param stdout pipe: stdout pipe @type stdout: file @param stderr pipe: stderr pipe @type stderr: file @return: 'files': list of files that \x07 file depends on, 'deps': list of dependencies by type, 'spec': Msgs/Srvs instance...
Function _add_msgs_depends Add the list of message types that spec depends on to depends. @param spec: message to compute dependencies for @type spec: roslib.msgs.MsgSpec/roslib.srvs.SrvSpec @param deps [str]: list of dependencies...
Function _compute_hash subroutine of compute_md5() @param get_deps_dict: dictionary returned by get_dependencies call @type get_deps_dict: dict @param hash: hash instance @type hash: hash instance
Function _compute_hash_v1 subroutine of compute_md5_v1() @param get_deps_dict: dictionary returned by get_dependencies call @type get_deps_dict: dict @param hash: hash instance @type hash: hash instance
Variable _header_type_name Undocumented
def compute_full_text(get_deps_dict):

Compute full text of message/service, including text of embedded types. The text of the main msg/srv is listed first. Embedded msg/srv files are denoted first by an 80-character '=' separator, followed by a type declaration line,'MSG: pkg/type', followed by the text of the embedded type.

@param get_deps_dict dict: dictionary returned by get_dependencies call @type get_deps_dict: dict @return: concatenated text for msg/srv file and embedded msg/srv types. @rtype: str

def compute_md5(get_deps_dict, rospack=None):

Compute md5 hash for message/service @param get_deps_dict dict: dictionary returned by get_dependencies call @type get_deps_dict: dict @return: md5 hash @rtype: str

def compute_md5_text(get_deps_dict, spec, rospack=None):

Compute the text used for md5 calculation. MD5 spec states that we removes comments and non-meaningful whitespace. We also strip packages names from type names. For convenience sake, constants are reordered ahead of other declarations, in the order that they were originally defined.

@return: text for ROS MD5-processing @rtype: str

def compute_md5_v1(get_deps_dict):

Compute original V1 md5 hash for message/service. This was replaced with V2 in ROS 0.6. @param get_deps_dict: dictionary returned by get_dependencies call @type get_deps_dict: dict @return: md5 hash @rtype: str

def get_dependencies(spec, package, compute_files=True, stdout=sys.stdout, stderr=sys.stderr, rospack=None):

Compute dependencies of the specified Msgs/Srvs @param spec: message or service instance @type spec: L{roslib.msgs.MsgSpec}/L{roslib.srvs.SrvSpec} @param package: package name @type package: str @param stdout: (optional) stdout pipe @type stdout: file @param stderr: (optional) stderr pipe @type stderr: file @param compute_files: (optional, default=True) compute file dependencies of message ('files' key in return value) @type compute_files: bool @return: dict:

  • 'files': list of files that \x07 file depends on
  • 'deps': list of dependencies by type
  • 'spec': Msgs/Srvs instance.
  • 'uniquedeps': list of dependencies with duplicates removed,
  • 'package': package that dependencies were generated relative to.

@rtype: dict

def get_file_dependencies(f, stdout=sys.stdout, stderr=sys.stderr, rospack=None):

Compute dependencies of the specified message/service file @param f: message or service file to get dependencies for @type f: str @param stdout pipe: stdout pipe @type stdout: file @param stderr pipe: stderr pipe @type stderr: file @return: 'files': list of files that \x07 file depends on, 'deps': list of dependencies by type, 'spec': Msgs/Srvs instance. @rtype: dict

def _add_msgs_depends(rospack, spec, deps, package_context):

Add the list of message types that spec depends on to depends. @param spec: message to compute dependencies for @type spec: roslib.msgs.MsgSpec/roslib.srvs.SrvSpec @param deps [str]: list of dependencies. This list will be updated with the dependencies of spec when the method completes @type deps: [str] @raise KeyError for invalid dependent types due to missing package dependencies.

def _compute_hash(get_deps_dict, hash, rospack=None):

subroutine of compute_md5() @param get_deps_dict: dictionary returned by get_dependencies call @type get_deps_dict: dict @param hash: hash instance @type hash: hash instance

def _compute_hash_v1(get_deps_dict, hash):

subroutine of compute_md5_v1() @param get_deps_dict: dictionary returned by get_dependencies call @type get_deps_dict: dict @param hash: hash instance @type hash: hash instance

_header_type_name: str =

Undocumented