nx_metadata_sdk 1.0 Metadata SDK

string.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 <nx/sdk/i_string.h>
6
7 #include <string>
8
9 #include <nx/sdk/helpers/ref_countable.h>
10
11 namespace nx {
12 namespace sdk {
13
14 class String: public RefCountable<IString>
15 {
16 public:
17 String() = default;
18 String(std::string s);
19
21 String(const char* s);
22
23 virtual const char* str() const override;
24
25 void setString(std::string s);
26
28 void setString(const char* s);
29
30 int size() const;
31
32 bool empty() const;
33
34 private:
35 std::string m_string;
36 };
37
38 } // namespace sdk
39 } // namespace nx
nx::sdk::String::str
virtual const char * str() const override
Definition: string.cpp:18
nx::sdk::String
Definition: string.h:14
nx
Definition: apple_utils.h:6
nx::sdk::RefCountable
Definition: ref_countable.h:84