source: cpp/common/util-file.h @ 1124

Last change on this file since 1124 was 1124, checked in by Maciej Komosinski, 3 years ago

Added helper utility functions

File size: 713 bytes
RevLine 
[840]1// This file is a part of Framsticks SDK.  http://www.framsticks.com/
[1124]2// Copyright (C) 1999-2021  Maciej Komosinski and Szymon Ulatowski.
[840]3// See LICENSE.txt for details.
4
5#ifndef _UTIL_FILES_H_
6#define _UTIL_FILES_H_
7
8#include "nonstd_stl.h"
[1124]9#include "virtfile/virtfile.h"
[840]10
11bool readCompleteFile(const char* filename, vector<char>& data, bool warn_on_missing_file = true);
12bool readCompleteFile(const char* filename, string& out, bool warn_on_missing_file = true);
13bool writeCompleteFile(const char* filename, const std::string& text, bool warn_on_fail = true);
14bool writeCompleteFile(const char* filename, vector<char>& data, bool warn_on_fail = true);
[1124]15string readUntilEOL(VirtFILE *f);
[840]16
17#endif
Note: See TracBrowser for help on using the repository browser.