cgv
Loading...
Searching...
No Matches
binary_io_reflection_handlers.h
1#pragma once
2
3#include <stdio.h>
4#include "io_reflection_handler.h"
5
6#include "lib_begin.h"
7
8namespace cgv {
9 namespace data {
10
11
14{
15protected:
16 FILE* fp;
17public:
19 binary_reflection_handler(const std::string& _content, unsigned _ver);
21 bool reflect_header();
23 void close();
24};
25
28{
29protected:
30 bool read_reflect_header(const std::string& _content, unsigned _ver);
31public:
32 binary_read_reflection_handler(const std::string& file_name, const std::string& _content, unsigned _ver);
34 binary_read_reflection_handler(FILE* _fp, const std::string& _content, unsigned _ver);
36 bool is_creative() const;
38 bool reflect_member_void(const std::string& member_name,
39 void* member_ptr, cgv::reflect::abst_reflection_traits* rt);
40};
41
42
45{
46public:
48 binary_write_reflection_handler(const std::string& file_name, const std::string& _content, unsigned _ver);
50 binary_write_reflection_handler(FILE* _fp, const std::string& _content, unsigned _ver);
52 bool reflect_member_void(const std::string& member_name,
53 void* member_ptr, cgv::reflect::abst_reflection_traits* rt);
54};
55
56
57 }
58}
59
60#include <cgv/config/lib_end.h>
common base for all io reflection handlers
the cgv namespace
Definition print.h:11
abstract interface for type reflection with basic type management and optional string conversion