mirror of
https://github.com/mudita/MuditaOS.git
synced 2026-02-01 09:52:25 -05:00
20 lines
396 B
C++
20 lines
396 B
C++
// Copyright (c) 2017-2024, Mudita Sp. z.o.o. All rights reserved.
|
|
// For licensing, see https://github.com/mudita/MuditaOS/blob/master/LICENSE.md
|
|
|
|
#include "sink/FileSink.hpp"
|
|
|
|
FileSink::FileSink(const std::string &filepath)
|
|
{
|
|
fs.open(filepath, std::fstream::out);
|
|
}
|
|
|
|
FileSink::~FileSink()
|
|
{
|
|
fs.close();
|
|
}
|
|
|
|
void FileSink::put(const char *data, size_t size)
|
|
{
|
|
fs.write(data, size);
|
|
}
|