Hyper API for C++  0.0.15888
Hyper client library for C++ applications
Endpoint.hpp
Go to the documentation of this file.
1 
5 #ifndef TABLEAU_HYPER_ENDPOINT_HPP
6 #define TABLEAU_HYPER_ENDPOINT_HPP
7 
8 #include <string>
9 #include <utility>
10 
11 namespace hyperapi {
12 
14 class Endpoint final {
15  public:
24  Endpoint(std::string connectionDescriptor, std::string userAgent)
25  : connectionDescriptor(std::move(connectionDescriptor)), userAgent(std::move(userAgent)) {
26  }
27 
32  const std::string& getConnectionDescriptor() const { return connectionDescriptor; }
33 
38  const std::string& getUserAgent() const { return userAgent; }
39 
40  private:
42  std::string connectionDescriptor;
44  std::string userAgent;
45 };
46 }
47 
48 #endif
hyperapi::Endpoint::Endpoint
Endpoint(std::string connectionDescriptor, std::string userAgent)
Creates an Endpoint from the given connection descriptor.
Definition: Endpoint.hpp:24
hyperapi::Endpoint
Describes a network endpoint at which a Hyper server is accessible.
Definition: Endpoint.hpp:14
hyperapi
The primary namespace of the Hyper API for C++.
Definition: ByteSpan.hpp:15
hyperapi::Endpoint::getUserAgent
const std::string & getUserAgent() const
Returns the user agent.
Definition: Endpoint.hpp:38
hyperapi::Endpoint::getConnectionDescriptor
const std::string & getConnectionDescriptor() const
Returns the connection descriptor.
Definition: Endpoint.hpp:32