PageRenderTime 26ms CodeModel.GetById 17ms app.highlight 5ms RepoModel.GetById 1ms app.codeStats 0ms

/include/nebu/nebuClient.h

https://github.com/deltaforge/nebu-common-cpp
C Header | 42 lines | 27 code | 12 blank | 3 comment | 0 complexity | 4f0ddeed3e3754a8a157387a2ef26cc3 MD5 | raw file
 1
 2#ifndef NEBU_NEBUCLIENT_H_
 3#define NEBU_NEBUCLIENT_H_
 4
 5#include "nebu/restClientAdapter.h"
 6
 7#include <memory>
 8#include <string>
 9
10namespace nebu
11{
12	namespace common
13	{
14
15		class NebuClient
16		{
17		public:
18			struct Response
19			{
20				int status_code;
21				std::string body;
22			};
23
24			NebuClient(std::shared_ptr<RestClientAdapter> restClient, const std::string &baseURI);
25			virtual ~NebuClient() { }
26
27			// NOT IMPLEMENTED:
28			//NebuClient(shared_ptr<RestClientAdapter> restClient, const std::string &baseURI,
29			//		const std::string &username, const std::string &password);
30
31			virtual Response performGET(const std::string &URI) const;
32
33		private:
34			std::shared_ptr<RestClientAdapter> restClient;
35			std::string baseURI;
36		};
37
38	}
39}
40
41#endif
42