tippecanoe/memfile.hpp

23 lines
370 B
C++
Raw Normal View History

#ifndef MEMFILE_HPP
#define MEMFILE_HPP
#include <atomic>
struct memfile {
2017-11-07 23:25:54 +00:00
int fd = 0;
char *map = NULL;
std::atomic<long long> len;
2017-11-07 23:25:54 +00:00
long long off = 0;
unsigned long tree = 0;
memfile()
: len(0) {
}
};
struct memfile *memfile_open(int fd);
int memfile_close(struct memfile *file);
int memfile_write(struct memfile *file, void *s, long long len);
#endif