Parser for roslaunch XML format. Loads parsed representation into ROSConfig model.
Method | __init__ |
@param resolve_anon: If True (default), will resolve $(anon foo). If false, will leave these args as-is. @type resolve_anon: bool @param args_only: if True, will only load arg tags (e.g. autocompletion purposes) @type args_only: bool... |
Method | load |
load XML file into launch configuration @param filename: XML config file to load @type filename: str @param ros_config: launch configuration to load XML file into @type ros_config: L{ROSLaunchConfig} @param core: if True, load file using ROS core rules @type core: bool @param argv: override command-line arguments (mainly for arg testing) @type argv: [str]... |
Method | load |
Load XML text into launch configuration @param xml_text: XML configuration @type xml_text: str @param ros_config: launch configuration to load XML file into @type ros_config: L{ROSLaunchConfig} @param core: if True, load file using ROS core rules @type core: bool... |
Method | opt |
Helper routine for fetching and resolving optional tag attributes @param tag DOM tag @param context LoaderContext @param attrs (str): list of attributes to resolve |
Method | reqd |
Helper routine for fetching and resolving required tag attributes @param tag: DOM tag @param attrs: list of attributes to resolve @type attrs: (str) @raise KeyError: if required attribute is missing |
Method | resolve |
Wrapper around substitution_args.resolve_args to set common parameters |
Constant | ARG |
Undocumented |
Constant | ENV |
Undocumented |
Constant | GROUP |
Undocumented |
Constant | INCLUDE |
Undocumented |
Constant | MACHINE |
Undocumented |
Constant | NODE |
Undocumented |
Constant | PARAM |
Undocumented |
Constant | REMAP |
Undocumented |
Constant | ROSPARAM |
Undocumented |
Constant | TEST |
Undocumented |
Instance Variable | args |
Undocumented |
Instance Variable | resolve |
Undocumented |
Instance Variable | root |
Undocumented |
Method | _arg |
Process an <arg> tag. |
Method | _check |
Undocumented |
Method | _env |
Undocumented |
Method | _include |
Undocumented |
Method | _launch |
Undocumented |
Method | _load |
subroutine of launch for loading XML DOM into config. Load_launch assumes that it is creating the root XmlContext, and is thus affected by command-line arguments. @param launch: DOM node of the root <launch> tag in the file @type launch: L{Node} @param ros_config: launch configuration to load XML file into @type ros_config: L{ROSLaunchConfig} @param is_core: (optional) if True, load file using ROS core rules... |
Method | _machine |
Undocumented |
Method | _node |
Process XML <node> or <test> tag @param tag: DOM node @type tag: Node @param context: namespace context @type context: L{LoaderContext} @param params: ROS parameter list @type params: [L{Param}] @param clear_params: list of ROS parameter names to clear before setting parameters @type clear_params: [str] @param default_machine: default machine to assign to node @type default_machine: str @param is_test: if set, will load as L{Test} object instead of L{Node} object @type is_test: bool... |
Method | _ns |
Common processing routine for xml tags with NS and CLEAR_PARAMS attributes |
Method | _param |
@param force_local: if True, param must be added to context instead of ros_config @type force_local: bool |
Method | _parse |
Undocumented |
Method | _recurse |
@return: new default machine for current context @rtype: L{Machine} |
Method | _remap |
Undocumented |
Method | _rosparam |
Undocumented |
Method | _test |
Process attributes of <test> tag not present in <node> @return: test_name, time_limit @rtype: str, int |
Inherited from Loader
:
Method | add |
Add L{Param} instances to launch config. Dictionary values are unrolled into individual parameters. |
Method | load |
Load environment variable setting |
Method | load |
Load rosparam setting |
Method | param |
Parse text representation of param spec into Python value @param name: param name, for error message use only @type name: str @param verbose: print verbose output @type verbose: bool @param textfile: name of text file to load from, or None @type textfile: str @param binfile: name of binary file to load from, or None @type binfile: str @param command: command to execute for parameter value, or None @type command: str @raise ValueError: if parameters are invalid... |
@param resolve_anon: If True (default), will resolve $(anon foo). If false, will leave these args as-is. @type resolve_anon: bool @param args_only: if True, will only load arg tags (e.g. autocompletion purposes) @type args_only: bool
load XML file into launch configuration @param filename: XML config file to load @type filename: str @param ros_config: launch configuration to load XML file into @type ros_config: L{ROSLaunchConfig} @param core: if True, load file using ROS core rules @type core: bool @param argv: override command-line arguments (mainly for arg testing) @type argv: [str]
Load XML text into launch configuration @param xml_text: XML configuration @type xml_text: str @param ros_config: launch configuration to load XML file into @type ros_config: L{ROSLaunchConfig} @param core: if True, load file using ROS core rules @type core: bool
Helper routine for fetching and resolving optional tag attributes @param tag DOM tag @param context LoaderContext @param attrs (str): list of attributes to resolve
Helper routine for fetching and resolving required tag attributes @param tag: DOM tag @param attrs: list of attributes to resolve @type attrs: (str) @raise KeyError: if required attribute is missing
Undocumented
Value |
|
subroutine of launch for loading XML DOM into config. Load_launch assumes that it is creating the root XmlContext, and is thus affected by command-line arguments. @param launch: DOM node of the root <launch> tag in the file @type launch: L{Node} @param ros_config: launch configuration to load XML file into @type ros_config: L{ROSLaunchConfig} @param is_core: (optional) if True, load file using ROS core rules. Default False. @type is_core: bool @param filename: (optional) name of file being loaded @type filename: str @param verbose: (optional) print verbose output. Default False. @type verbose: bool @param argv: (optional) command-line args. Default sys.argv.
def _node_tag(self, tag, context, ros_config, default_machine, is_test=False, verbose=True): ¶
Process XML <node> or <test> tag @param tag: DOM node @type tag: Node @param context: namespace context @type context: L{LoaderContext} @param params: ROS parameter list @type params: [L{Param}] @param clear_params: list of ROS parameter names to clear before setting parameters @type clear_params: [str] @param default_machine: default machine to assign to node @type default_machine: str @param is_test: if set, will load as L{Test} object instead of L{Node} object @type is_test: bool
Common processing routine for xml tags with NS and CLEAR_PARAMS attributes
@param tag: DOM Node @type tag: Node @param context: current namespace context @type context: LoaderContext @param clear_params: list of params to clear @type clear_params: [str] @param node_name: name of node (for use when tag_name == 'node') @type node_name: str @param include_filename: <include> filename if this is an <include> tag. If specified, context will use include rules. @type include_filename: str @return: loader context @rtype: L{LoaderContext}
@param force_local: if True, param must be added to context instead of ros_config @type force_local: bool