lex_node.h
Go to the documentation of this file.
1 /*
2  * Copyright 2018 Amazon.com, Inc. or its affiliates. All Rights Reserved.
3  *
4  * Licensed under the Apache License, Version 2.0 (the "License").
5  * You may not use this file except in compliance with the License.
6  * A copy of the License is located at
7  *
8  * http://aws.amazon.com/apache2.0
9  *
10  * or in the "license" file accompanying this file. This file is distributed
11  * on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either
12  * express or implied. See the License for the specific language governing
13  * permissions and limitations under the License.
14  */
15 
16 #pragma once
17 
18 #include <aws/lex/LexRuntimeServiceClient.h>
19 #include <lex_common_msgs/AudioTextConversation.h>
20 #include <lex_common_msgs/AudioTextConversationRequest.h>
21 #include <lex_common_msgs/AudioTextConversationResponse.h>
22 
23 #include <lex_common/error_codes.h>
24 #include <lex_common/lex_common.h>
25 
26 #include <ros/ros.h>
27 #include <ros/spinner.h>
28 
29 namespace Aws {
30 namespace Lex {
31 
37 class LexNode
38 {
39 private:
44 
48  std::shared_ptr<PostContentInterface> post_content_;
49 
54 
63  bool LexServerCallback(lex_common_msgs::AudioTextConversationRequest & request,
64  lex_common_msgs::AudioTextConversationResponse & response);
65 
66 public:
70  LexNode();
71 
75  ~LexNode() = default;
76 
82  ErrorCode Init(std::shared_ptr<PostContentInterface> lex_interactor);
83 
89  explicit operator ros::NodeHandle &() { return node_handle_; }
90 };
91 
92 } // namespace Lex
93 } // namespace Aws
std::shared_ptr< PostContentInterface > post_content_
Definition: lex_node.h:48
~LexNode()=default
ErrorCode Init(std::shared_ptr< PostContentInterface > lex_interactor)
Definition: lex_node.cpp:53
bool LexServerCallback(lex_common_msgs::AudioTextConversationRequest &request, lex_common_msgs::AudioTextConversationResponse &response)
Definition: lex_node.cpp:64
ros::ServiceServer lex_server_
Definition: lex_node.h:43
ros::NodeHandle node_handle_
Definition: lex_node.h:53


lex_node
Author(s): AWS RoboMaker
autogenerated on Fri Mar 5 2021 03:13:38