Sen API
Sen Libraries
Loading...
Searching...
No Matches
util.h File Reference
#include "sen/core/base/memory_block.h"
#include "sen/core/base/span.h"
#include "sen/core/io/input_stream.h"
#include "sen/kernel/type_specs_utils.h"
#include "v1.stl.h"
#include <spdlog/logger.h>
#include <cstdint>
#include <filesystem>

Go to the source code of this file.

Namespaces

namespace  sen
namespace  sen::db

Functions

std::shared_ptr< spdlog::logger > sen::db::getLogger ()
uint32_t sen::db::getFileHeaderSize ()
template<typename T, typename B>
void sen::db::writeToBuffer (const T &data, B &buffer)
template<typename T>
void sen::db::write (T &&data, FILE *file)
template<typename T>
std::shared_ptr< ResizableHeapBlock > sen::db::writeSizeAndDataToBuffer (const T &data)
void sen::db::writeToCompressedBuffer (const std::vector< uint8_t > &memBuf, std::vector< uint8_t > &lz4Buf)
void sen::db::uncompressBuffer (const std::vector< uint8_t > &lz4Buf, std::vector< uint8_t > &memBuf, std::size_t decompressedSize)
FILE * sen::db::openFile (const std::filesystem::path &path)
const ::sen::ClassType * sen::db::searchOwner (const ::sen::ClassType *classType, const ::sen::Property *property) noexcept
 Returns the class in the hierarchy of classes that owns the property. Returns nullptr if not found.
const ::sen::ClassType * sen::db::searchOwner (const ::sen::ClassType *classType, const ::sen::Event *event) noexcept
 Returns the class in the hierarchy of classes to which the event is mapped. Returns nullptr if not found.
MemberHash sen::db::computePlatformDependentPropertyId (const ::sen::ClassType *classType, const ::sen::Property *property)
 Computes the old version (platform-dependent) of the property id. Used for retro-compatibility.
MemberHash sen::db::computePlatformDependentEventId (const ::sen::ClassType *classType, const ::sen::Event *event)
 Computes the old version (platform-dependent) of the event id. Used for retro-compatibility.
void sen::db::doWrite (const Span< const uint8_t > &span, FILE *file)