Vector BLF

Loading...
Searching...
No Matches
AbstractFile.h
1// SPDX-FileCopyrightText: 2013-2021 Tobias Lorenz <tobias.lorenz@gmx.net>
2//
3// SPDX-License-Identifier: GPL-3.0-or-later
4
5#pragma once
6
7#include <Vector/BLF/platform.h>
8
9#include <ios>
10
11#include <Vector/BLF/vector_blf_export.h>
12
13 namespace Vector {
14 namespace BLF {
15
19 struct VECTOR_BLF_EXPORT AbstractFile {
20 AbstractFile() noexcept = default;
21 virtual ~AbstractFile() noexcept = default;
22 AbstractFile(const AbstractFile &) = default;
23 AbstractFile & operator=(const AbstractFile &) = default;
24 AbstractFile(AbstractFile &&) = default;
25 AbstractFile & operator=(AbstractFile &&) = default;
26
32 virtual std::streamsize gcount() const = 0;
33
42 virtual void read(char * s, std::streamsize n) = 0;
43
49 virtual std::streampos tellg() = 0;
50
57 virtual void seekg(std::streamoff off, const std::ios_base::seekdir way = std::ios_base::cur) = 0;
58
65 virtual void write(const char * s, std::streamsize n) = 0;
66
72 virtual std::streampos tellp() = 0;
73
79 virtual bool good() const = 0;
80
86 virtual bool eof() const = 0;
87
93 virtual void skipp(std::streamsize s) final;
94};
95
96}
97}
Vector::BLF::AbstractFile::seekg
virtual void seekg(std::streamoff off, const std::ios_base::seekdir way=std::ios_base::cur)=0
Vector::BLF::AbstractFile::tellg
virtual std::streampos tellg()=0
Vector::BLF::AbstractFile::gcount
virtual std::streamsize gcount() const =0
Vector::BLF::AbstractFile::good
virtual bool good() const =0
Vector::BLF::AbstractFile::eof
virtual bool eof() const =0
Vector::BLF::AbstractFile::write
virtual void write(const char *s, std::streamsize n)=0
Vector::BLF::AbstractFile::tellp
virtual std::streampos tellp()=0
Vector::BLF::AbstractFile::skipp
virtual void skipp(std::streamsize s) final
Definition AbstractFile.cpp:12
Vector::BLF::AbstractFile::read
virtual void read(char *s, std::streamsize n)=0