General Purpose library for Freestanding C++ and POSIX systems
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 

29 regels
601 B

#pragma once
#include <cstddef>
#include <atomic>
namespace gp {
namespace system {
class system;
}
template<typename> class buffer;
class file_description {
std::atomic_int64_t ref_counter;
public:
virtual void read() = 0;
virtual void write() = 0;
virtual void set_attr() = 0;
virtual void get_attr() = 0;
virtual void seek() = 0;
virtual void close() = 0;
static file_description* open(system::system&, gp::buffer<std::byte>);
static file_description* create(system::system&, gp::buffer<std::byte>);
static file_description* remove(system::system&, gp::buffer<std::byte>);
};
}