21 #ifndef INCLUDE_OLA_SLP_SLPCLIENT_H_
22 #define INCLUDE_OLA_SLP_SLPCLIENT_H_
25 #include <ola/OlaClientWrapper.h>
28 #include <ola/network/Socket.h>
30 #include <ola/slp/Base.h>
31 #include <ola/slp/URLEntry.h>
46 std::vector<std::string> scopes;
66 const std::vector<std::string> &scopes,
67 const std::string &service,
75 const std::vector<std::string> &scopes,
76 const std::string &service,
84 const std::vector<std::string> &scopes,
85 const std::string &service,
92 const std::vector<std::string> &scopes,
93 const std::string &service,
95 const std::vector<URLEntry> &> *callback);
106 std::auto_ptr<class SLPClientCore> m_core;
116 SLPClient *GetClient()
const {
return m_client.get(); }
119 std::auto_ptr<SLPClient> m_client;
121 void CreateClient() {
122 if (!m_client.get()) {
123 m_client.reset(
new SLPClient(m_socket.get()));
127 bool StartupClient() {
128 bool ok = m_client->Setup();
129 m_client->SetCloseHandler(
131 &BaseClientWrapper::SocketClosed));
136 m_socket.reset(ola::network::TCPSocket::Connect(
139 OLA_SLP_DEFAULT_PORT)));
146 #endif // INCLUDE_OLA_SLP_SLPCLIENT_H_