launch.actions.declare_boolean_launch_argument module
Module for the DeclareBooleanLaunchArgument action.
- class launch.actions.declare_boolean_launch_argument.DeclareBooleanLaunchArgument[source]
Bases:
DeclareLaunchArgumentAction that declares a new boolean launch argument.
This is a bit of syntactic sugar for
launch.actions.DeclareLaunchArgumentthat sets the choices to be either true or false (caps-insensitive)>>> ld = LaunchDescription([ ... DeclareBooleanLaunchArgument('simple_argument'), # default value is False ... DeclareBooleanLaunchArgument('with_default_value', default_value=True), ... # other actions here, ... ... ])
<launch> <bool_arg name="simple_argument"/> <bool_arg name="with_default_value" default_value="true"/> </launch>