mirror of
https://forge.chapril.org/tykayn/caisse-bliss
synced 2025-06-20 01:44:42 +02:00
add deps for js angular1.8
This commit is contained in:
parent
8e2da4f159
commit
b373892ddc
3800 changed files with 125627 additions and 40 deletions
50
.yarn/unplugged/@parcel-watcher-npm-2.5.1-018e8f2cc2/node_modules/@parcel/watcher/src/DirTree.hh
generated
vendored
Normal file
50
.yarn/unplugged/@parcel-watcher-npm-2.5.1-018e8f2cc2/node_modules/@parcel/watcher/src/DirTree.hh
generated
vendored
Normal file
|
@ -0,0 +1,50 @@
|
|||
#ifndef DIR_TREE_H
|
||||
#define DIR_TREE_H
|
||||
|
||||
#include <string>
|
||||
#include <unordered_map>
|
||||
#include <memory>
|
||||
#include "Event.hh"
|
||||
|
||||
#ifdef _WIN32
|
||||
#define DIR_SEP "\\"
|
||||
#else
|
||||
#define DIR_SEP "/"
|
||||
#endif
|
||||
|
||||
struct DirEntry {
|
||||
std::string path;
|
||||
uint64_t mtime;
|
||||
bool isDir;
|
||||
mutable void *state;
|
||||
|
||||
DirEntry(std::string p, uint64_t t, bool d);
|
||||
DirEntry(FILE *f);
|
||||
void write(FILE *f) const;
|
||||
bool operator==(const DirEntry &other) const {
|
||||
return path == other.path;
|
||||
}
|
||||
};
|
||||
|
||||
class DirTree {
|
||||
public:
|
||||
static std::shared_ptr<DirTree> getCached(std::string root);
|
||||
DirTree(std::string root) : root(root), isComplete(false) {}
|
||||
DirTree(std::string root, FILE *f);
|
||||
DirEntry *add(std::string path, uint64_t mtime, bool isDir);
|
||||
DirEntry *find(std::string path);
|
||||
DirEntry *update(std::string path, uint64_t mtime);
|
||||
void remove(std::string path);
|
||||
void write(FILE *f);
|
||||
void getChanges(DirTree *snapshot, EventList &events);
|
||||
|
||||
std::mutex mMutex;
|
||||
std::string root;
|
||||
bool isComplete;
|
||||
std::unordered_map<std::string, DirEntry> entries;
|
||||
|
||||
private:
|
||||
DirEntry *_find(std::string path);
|
||||
};
|
||||
|
||||
#endif
|
Loading…
Add table
Add a link
Reference in a new issue