13 entt::meta_factory<ui_tree>{}
20 .data<&ui_tree::content>(
"content"_hs)
33 try_save(ar, ser20::make_nvp(
"content", obj.content));
40 try_load(ar, ser20::make_nvp(
"content", obj.content));
47 std::ofstream stream(absolute_path);
50 stream.write(obj->content.c_str(), obj->content.size());
56 std::ofstream stream(absolute_path, std::ios::binary);
60 try_save(ar, ser20::make_nvp(
"ui_tree", *obj));
82 try_load(ar, ser20::make_nvp(
"ui_tree", *obj));
stdio-backed input stream. Accepts std::ios open flags (e.g. std::ios::binary) when opening a
attributes::value_type attribute
std::map< std::string, meta_any > attributes
std::string read_stream_str(std::istream &stream)
BinaryInputArchive iarchive_binary_t
simd::JSONOutputArchive oarchive_associative_t
BinaryOutputArchive oarchive_binary_t
simd::JSONInputArchive iarchive_associative_t
void save_to_file_bin(const std::string &absolute_path, const animation_clip &obj)
void load_from_file(const std::string &absolute_path, animation_clip &obj)
void save_to_file(const std::string &absolute_path, const animation_clip &obj)
void load_from_file_bin(const std::string &absolute_path, animation_clip &obj)
#define SAVE_INSTANTIATE(cls, Archive)
auto try_save(Archive &ar, ser20::NameValuePair< T > &&t, const hpp::source_location &loc=hpp::source_location::current()) -> bool
#define LOAD_INSTANTIATE(cls, Archive)
auto try_load(Archive &ar, ser20::NameValuePair< T > &&t, const hpp::source_location &loc=hpp::source_location::current()) -> bool
Represents a UI visual tree asset (HTML/RML document).
std::shared_ptr< ui_tree > sptr
Shared pointer to a visual tree.