2 #include <dialogflow_ros/DialogflowEvent.h> 3 #include <dialogflow_ros/DialogflowParameter.h> 5 int main(
int argc,
char **argv)
7 ros::init(argc, argv,
"test_intent_event");
14 dialogflow_ros::DialogflowEvent event;
15 event.event_name =
"objects_found";
16 dialogflow_ros::DialogflowParameter parameter;
17 parameter.param_name =
"objects";
18 std::string milk =
"milk";
19 std::string snack =
"snack";
20 std::vector<std::string> object_list = {milk, snack};
22 parameter.value = object_list;
25 event.parameters.push_back(parameter);
28 std::cout <<
"Parameter: " << parameter << std::endl;
29 std::cout <<
"Values" << std::endl;
30 for (
auto val : parameter.value)
31 std::cout << val << std::endl;
void publish(const boost::shared_ptr< M > &message) const
int main(int argc, char **argv)
ROSCPP_DECL void init(int &argc, char **argv, const std::string &name, uint32_t options=0)
Publisher advertise(const std::string &topic, uint32_t queue_size, bool latch=false)
uint32_t getNumSubscribers() const