Skip to content
LeviMC
English
AutoLightDark
LeviLamina
Loading...
Searching...
No Matches
StringOption.h
1#pragma once
2
3#include "mc/_HeaderOutputPredefine.h"
4
5// auto generated inclusion list
6#include "mc/options/option_types/Option.h"
7#include "mc/options/option_types/OptionID.h"
8#include "mc/options/option_types/OptionOwnerType.h"
9#include "mc/options/option_types/OptionResetFlags.h"
10
11class StringOption : public ::Option {
12public:
13 // member variables
14 // NOLINTBEGIN
15 ::ll::TypedStorage<8, 32, ::std::string> mValue;
16 ::ll::TypedStorage<8, 32, ::std::string> mDefaultValue;
17 ::ll::TypedStorage<8, 64, ::std::function<::std::string(::std::string const&)>> mCoerceValueCallback;
18 // NOLINTEND
19
20#ifdef LL_PLAT_S
21#else // LL_PLAT_C
22public:
23 // prevent constructor by default
24 StringOption();
25
26#endif
27public:
28 // virtual functions
29 // NOLINTBEGIN
30 virtual void save(::std::vector<::std::pair<::std::string, ::std::string>>& propertyVector) /*override*/;
31
32 virtual void load(::std::string const& valueString) /*override*/;
33 // NOLINTEND
34
35public:
36 // member functions
37 // NOLINTBEGIN
38#ifdef LL_PLAT_C
39 MCNAPI StringOption(
40 ::OptionID id,
41 ::OptionOwnerType ownerType,
42 ::OptionResetFlags resetFlags,
43 ::std::string const& captionId,
44 ::std::string const& saveTag,
45 ::std::string const& value
46 );
47
48 MCNAPI void set(::std::string const& value, bool saveOptionChange);
49#endif
50 // NOLINTEND
51
52public:
53 // constructor thunks
54 // NOLINTBEGIN
55#ifdef LL_PLAT_C
56 MCNAPI void* $ctor(
57 ::OptionID id,
58 ::OptionOwnerType ownerType,
59 ::OptionResetFlags resetFlags,
60 ::std::string const& captionId,
61 ::std::string const& saveTag,
62 ::std::string const& value
63 );
64#endif
65 // NOLINTEND
66
67public:
68 // virtual function thunks
69 // NOLINTBEGIN
70#ifdef LL_PLAT_C
71 MCNAPI void $save(::std::vector<::std::pair<::std::string, ::std::string>>& propertyVector);
72
73 MCNAPI void $load(::std::string const& valueString);
74#endif
75
76
77 // NOLINTEND
78};
MCAPI void $load(::std::map<::std::string, ::std::string > &propertyMap)
MCAPI void * $ctor(::OptionID id, ::OptionOwnerType ownerType, ::OptionResetFlags resetFlags, ::std::string const &captionId, ::std::string const &saveTag, ::OptionType optionType, ::GameVersion version)