-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathcase_string.hpp
More file actions
40 lines (32 loc) · 1.03 KB
/
Copy pathcase_string.hpp
File metadata and controls
40 lines (32 loc) · 1.03 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
/* File: /lib/utils/case_string.hpp
*
* This file is a part of cpplib project which is distributed under MIT License.
* See file LICENSE for full license details.
*
* Copyright (c) 2020-present Nikita Zuev (V.Slavski!) <[email protected]>
*/
#ifndef CPPLIB__lib__utils__case_string__hpp
#define CPPLIB__lib__utils__case_string__hpp
#include <string>
#include <vector>
#include "../../lib/cstring.hpp"
namespace lib::utils {
// DECLARATION lib::utils::case_string
/// @todo Code check, full test, and code cleanup required.
/// @todo case_string_t<CharT>, case_string, case_wstring
class case_string final {
public:
case_string & operator = ( const cstring & name );
::std::string lower() const;
::std::string upper() const;
::std::string pascal() const;
::std::string camel() const;
::std::string snake_lower() const;
::std::string snake_upper() const;
private:
void tokenize( const cstring & name );
::std::string name;
::std::vector<cstring> tokens;
};
} // namespace lib::utils
#endif // CPPLIB__lib__utils__case_string__hpp