nx_server_plugin_sdk 1.0 Server Plugin SDK

string_list.h
1 // Copyright 2018-present Network Optix, Inc. Licensed under MPL 2.0: www.mozilla.org/MPL/2.0/
2
3 #pragma once
4
5 #include <string>
6 #include <vector>
7
8 #include <nx/sdk/helpers/ref_countable.h>
9 #include <nx/sdk/i_string_list.h>
10
11 namespace nx::sdk {
12
13 class StringList: public nx::sdk::RefCountable<IStringList>
14 {
15 public:
16 virtual int count() const override;
17
19 virtual const char* at(int index) const override;
20
21 void addString(std::string str);
22 void clear();
23
24 private:
25 std::vector<std::string> m_strings;
26 };
27
28 } // namespace nx::sdk
nx::sdk
Definition: device_agent.h:12
nx::sdk::StringList::at
virtual const char * at(int index) const override
Definition: string_list.cpp:12
nx::sdk::StringList
Definition: string_list.h:13
nx::sdk::RefCountable
Definition: ref_countable.h:83