- Aldebaran documentation |
- C++ Libraries |
- index

libqi-api 2.8.7.4

- Main Page
- Related Pages
- Namespaces
- Classes
- Files
- Examples

- File List
- File Members

All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
gateway.hpp
Go to the documentation of this file.
1 /*
2 ** Copyright (C) 2018 Aldebaran Robotics
3 ** See COPYING for the license
4 */
5
6 #ifndef QIMESSAGING_GATEWAY_HPP
7 #define QIMESSAGING_GATEWAY_HPP
8
9 #pragma once
10
11 #include <qi/messaging/servicedirectoryproxy.hpp>
12
13 namespace qi
14 {
15
16 class QI_API Gateway
17 {
18 private:
19 ServiceDirectoryProxy _proxy; // must be declared before any other member
20
21 public:
22 using IdValidationStatus = ServiceDirectoryProxy::IdValidationStatus;
23 using ListenStatus = ServiceDirectoryProxy::ListenStatus;
24 using ConnectionStatus = ServiceDirectoryProxy::ConnectionStatus;
25 using Status = ServiceDirectoryProxy::Status;
26
31 Gateway(bool enforceAuth = true);
32
33 ~Gateway();
34
35 QI_API_DEPRECATED_MSG("Use `status` instead.")
36 Property<bool>& connected;
37
38 Property<Status>& status;
39
40 UrlVector endpoints() const;
41
42 QI_API_DEPRECATED_MSG("Use listenAsync() instead.")
43 bool listen(const Url& url);
44
45 Future<ListenStatus> listenAsync(const Url& url);
46
47 QI_API_DEPRECATED_MSG("Use setValidateIdentity() instead.")
48 bool setIdentity(const std::string& key, const std::string& crt);
49
50 Future<IdValidationStatus> setValidateIdentity(const std::string& key, const std::string& crt);
51
52 void setAuthProviderFactory(AuthProviderFactoryPtr provider);
53
54 qi::Future<void> attachToServiceDirectory(const Url& serviceDirectoryUrl);
55
56 void close();
57 };
58 }
59
60 #endif // QIMESSAGING_GATEWAY_HPP
QI_API
#define QI_API
Definition: api.hpp:33
qi::ServiceDirectoryProxy::ListenStatus
ListenStatus
Definition: servicedirectoryproxy.hpp:61
qi::Future
Definition: executioncontext.hpp:20
qi::ServiceDirectoryProxy::IdValidationStatus
IdValidationStatus
Definition: servicedirectoryproxy.hpp:55
qi::Property
Definition: property.hpp:157
qi::AuthProviderFactoryPtr
boost::shared_ptr< AuthProviderFactory > AuthProviderFactoryPtr
Definition: authproviderfactory.hpp:36
qi::ServiceDirectoryProxy::ConnectionStatus
ConnectionStatus
Definition: servicedirectoryproxy.hpp:70
qi::ServiceDirectoryProxy::Status
Definition: servicedirectoryproxy.hpp:79
QI_API_DEPRECATED_MSG
#define QI_API_DEPRECATED_MSG(msg__)
Compiler flags to mark a function as deprecated. It will generate a compiler warning.
Definition: macro.hpp:55
qi::ServiceDirectoryProxy
Definition: servicedirectoryproxy.hpp:50
servicedirectoryproxy.hpp
qi::UrlVector
std::vector< Url > UrlVector
Definition: url.hpp:155
qi::Url
Definition: url.hpp:35
qi::Gateway
Definition: gateway.hpp:16