1.1 --- a/libfsserver/include/fsserver/provider_registry.h Fri Dec 31 00:56:25 2021 +0100
1.2 +++ b/libfsserver/include/fsserver/provider_registry.h Tue Jan 04 19:22:01 2022 +0100
1.3 @@ -25,14 +25,19 @@
1.4 #include <mutex>
1.5
1.6 #include <mem/types.h>
1.7 -#include <fsserver/accountable.h>
1.8
1.9
1.10
1.11 -/* Mapping type from file identifiers to page mappers. */
1.12 +/* Forward declaration. */
1.13 +
1.14 +class Provider;
1.15 +
1.16
1.17 -typedef std::map<fileid_t, Accountable *> FileMapping;
1.18 -typedef std::pair<fileid_t, Accountable *> FileMappingEntry;
1.19 +
1.20 +/* Mapping type from file identifiers to providers. */
1.21 +
1.22 +typedef std::map<fileid_t, Provider *> ProviderMapping;
1.23 +typedef std::pair<fileid_t, Provider *> ProviderMappingEntry;
1.24
1.25
1.26
1.27 @@ -41,21 +46,21 @@
1.28 class ProviderRegistry
1.29 {
1.30 protected:
1.31 - FileMapping _providers;
1.32 + ProviderMapping _providers;
1.33 std::mutex _lock;
1.34
1.35 /* Filesystem object access. */
1.36
1.37 - Accountable *get(fileid_t fileid);
1.38 + Provider *get(fileid_t fileid);
1.39
1.40 - void remove(fileid_t fileid, Accountable *obj);
1.41 + void remove(fileid_t fileid, Provider *obj);
1.42
1.43 - void set(fileid_t fileid, Accountable *obj);
1.44 + void set(fileid_t fileid, Provider *obj);
1.45
1.46 public:
1.47 /* Methods for resources. */
1.48
1.49 - void detach(fileid_t fileid, Accountable *mapper);
1.50 + void detach(fileid_t fileid, Provider *mapper);
1.51 };
1.52
1.53 // vim: tabstop=4 expandtab shiftwidth=4