Lodestone.Conversion
Loading...
Searching...
No Matches
VersionedBlockIO.h
Go to the documentation of this file.
1//
2// Created by DexrnZacAttack on 10/15/25 using zPc-i2.
3//
4#ifndef LODESTONE_VERSIONEDBLOCKIO_H
5#define LODESTONE_VERSIONEDBLOCKIO_H
6
7#include <iostream>
8#include <map>
9#include <memory>
10#include <variant>
11
14
17
20 public:
21 constexpr void
22 registerBlock(const uint32_t version,
25 m_fromInternalConversionMap[version][internal] = blk;
26 }
27
28 constexpr void
29 removeBlock(const uint32_t version,
31 m_fromInternalConversionMap[version][internal] = nullptr;
32 }
33
34 std::unique_ptr<BlockIO> getIo(uint32_t version);
35
36 private:
37 std::map<uint32_t,
41 };
42} // namespace lodestone::conversion::block::version
43
44#endif // LODESTONE_VERSIONEDBLOCKIO_H
#define LODESTONE_API
gtl::flat_hash_map< T... > map_t
constexpr void removeBlock(const uint32_t version, const lodestone::common::registry::Identifier *internal)
Definition VersionedBlockIO.h:29
std::map< uint32_t, map_t< const lodestone::common::registry::Identifier *, data::AbstractBlockData * > > m_fromInternalConversionMap
Definition VersionedBlockIO.h:40
constexpr void registerBlock(const uint32_t version, const lodestone::common::registry::Identifier *internal, data::AbstractBlockData *blk)
Definition VersionedBlockIO.h:22