34namespace fs = std::filesystem;
47 uint64_t space_available = ns_reserved::FIM_RESERVED_OFFSET_REMOTE_END - ns_reserved::FIM_RESERVED_OFFSET_REMOTE_BEGIN;
48 uint64_t space_required = url.size();
49 return_if(space_available <= space_required, Error(
"E::Not enough space to fit remote URL"));
51 , FIM_RESERVED_OFFSET_REMOTE_BEGIN
52 , FIM_RESERVED_OFFSET_REMOTE_END
67 uint64_t offset_begin = ns_reserved::FIM_RESERVED_OFFSET_REMOTE_BEGIN;
68 uint64_t size = ns_reserved::FIM_RESERVED_OFFSET_REMOTE_END - offset_begin;
69 auto buffer = std::make_unique<char[]>(size);
Enhanced error handling framework built on std::expected.
Simplified macros for common control flow patterns with optional logging.
Remote recipe repository URL storage in reserved space.
Value< std::string > read(fs::path const &path_file_binary)
Reads the remote URL string from the target binary.
Value< void > write(fs::path const &path_file_binary, std::string_view const &url)
Writes the remote URL string to the target binary.
Value< void > write(fs::path const &path_file_binary, uint64_t offset_begin, uint64_t offset_end, const char *data, uint64_t length) noexcept
Writes data to a file in binary format.
Value< std::streamsize > read(fs::path const &path_file_binary, uint64_t offset, char *data, uint64_t length) noexcept
Reads data from a file in binary format.
Enhanced expected type with integrated logging capabilities.