29 lines
478 B
C++
29 lines
478 B
C++
#pragma once
|
|
|
|
#include <cstdint>
|
|
#include <ostream>
|
|
#include <string>
|
|
|
|
#include "hash.h"
|
|
|
|
struct FileSize {
|
|
FileSize(uint64_t);
|
|
uint64_t fs;
|
|
};
|
|
|
|
class File {
|
|
public:
|
|
File(FileSize, uint64_t inode, uint64_t linkcount, const std::string& path);
|
|
|
|
Hash createHash();
|
|
|
|
FileSize filesize;
|
|
uint64_t inode;
|
|
uint64_t linkcount;
|
|
std::string path;
|
|
};
|
|
|
|
// FileSize iomanip
|
|
// convert Bytes into human readable format
|
|
std::ostream& operator<<(std::ostream& str, const FileSize& fs);
|