summaryrefslogtreecommitdiffstats
path: root/src/core/io/physfs.hh
blob: 8cf84be3e396da1877a46d8c297b5999a5a7b88b (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
// SPDX-License-Identifier: BSD-2-Clause
// Copyright (c) 2025 Kirill Dmitrievich
// File: physfs.hh
// Description: PhysFS utilities

#ifndef CORE_IO_PHYSFS_HH
#define CORE_IO_PHYSFS_HH
#pragma once

namespace physfs
{
bool read_file(std::string_view path, std::vector<std::byte>& buffer);
bool read_file(std::string_view path, std::string& buffer);
bool write_file(std::string_view path, const std::vector<std::byte>& buffer);
bool write_file(std::string_view path, const std::string& buffer);
} // namespace physfs

namespace physfs
{
std::string_view last_error(void);
} // namespace physfs

#endif