-
Notifications
You must be signed in to change notification settings - Fork 4
/
Copy pathcmd_dump_bf.h
40 lines (33 loc) · 1005 Bytes
/
cmd_dump_bf.h
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
#ifndef cmd_dump_bf_H
#define cmd_dump_bf_H
#include <string>
#include <cstdlib>
#include <cstdint>
#include <iostream>
#include "bloom_filter.h"
#include "commands.h"
class DumpBFCommand: public Command
{
public:
static const std::uint64_t defaultEndPosition = 100;
public:
DumpBFCommand(const std::string& name): Command(name) {}
virtual ~DumpBFCommand() {}
virtual void short_description (std::ostream& s);
virtual void usage (std::ostream& s, const std::string& message="");
virtual void debug_help (std::ostream& s);
virtual void parse (int _argc, char** _argv);
virtual int execute (void);
virtual void dump_one_bloom_filter (const std::string& bfName, const BloomFilter* bf);
std::vector<std::string> bfFilenames;
std::uint64_t startPosition; // origin-zero, half-open
std::uint64_t endPosition;
std::uint32_t lineWrap;
std::uint32_t chunkSize;
char alphabet[2];
std::string showAs;
bool doComplement;
size_t nameWidth;
size_t onesCountWidth;
};
#endif // cmd_dump_bf_H