UFSStrategy.h
Go to the documentation of this file.
1 /*
2  * Copyright (C) 1996-2019 The Squid Software Foundation and contributors
3  *
4  * Squid software is distributed under GPLv2+ license and includes
5  * contributions from numerous individuals and organizations.
6  * Please see the COPYING and CONTRIBUTORS files for details.
7  */
8 
9 #ifndef SQUID_FS_UFS_UFSSTRATEGY_H
10 #define SQUID_FS_UFS_UFSSTRATEGY_H
11 
12 #include "DiskIO/DiskFile.h"
13 #include "StoreIOState.h"
14 
15 class Swapdir;
16 class StoreEntry;
17 class DiskIOStrategy;
18 
19 namespace Fs
20 {
21 namespace Ufs
22 {
25 {
26 public:
28  virtual ~UFSStrategy ();
29  virtual bool shedLoad();
30 
31  virtual int load();
32 
34  /* UFS specific */
35  virtual RefCount<DiskFile> newFile (char const *path);
37  StoreIOState::STIOCB *, void *);
39  StoreIOState::STIOCB *, void *);
40 
41  virtual void unlinkFile (char const *);
42  virtual void sync();
43 
44  virtual int callback();
45 
47  virtual void init();
48 
50  virtual void statfs(StoreEntry & sentry)const;
51 
54 
55 protected:
56 
57  friend class UFSSwapDir;
58 
59 private:
60  UFSStrategy(); //disabled
61  UFSStrategy(UFSStrategy const &); //disabled
62  UFSStrategy &operator=(UFSStrategy const &); //disabled
63 
64 };
65 
66 } //namespace Ufs
67 } //namespace Fs
68 
69 #endif /* SQUID_FS_UFS_UFSSTRATEGY_H */
70 
virtual void init()
Definition: UFSStrategy.cc:147
virtual void unlinkFile(char const *)
Definition: UFSStrategy.cc:51
virtual int load()
Definition: UFSStrategy.cc:25
virtual RefCount< DiskFile > newFile(char const *path)
Definition: UFSStrategy.cc:45
virtual int callback()
Definition: UFSStrategy.cc:141
StoreIOState::Pointer open(SwapDir *, StoreEntry *, StoreIOState::STFNCB *, StoreIOState::STIOCB *, void *)
Definition: UFSStrategy.cc:57
void STFNCB(void *their_data, int errflag, StoreIOState::Pointer self)
Definition: StoreIOState.h:41
StoreIOState::Pointer create(SwapDir *, StoreEntry *, StoreIOState::STFNCB *, StoreIOState::STIOCB *, void *)
Definition: UFSStrategy.cc:93
virtual bool shedLoad()
Definition: UFSStrategy.cc:19
void STIOCB(void *their_data, int errflag, StoreIOState::Pointer self)
Definition: StoreIOState.h:51
DiskIOStrategy * io
Definition: UFSStrategy.h:53
StoreIOState::Pointer createState(SwapDir *SD, StoreEntry *e, StoreIOState::STIOCB *callback, void *callback_data) const
Definition: UFSStrategy.cc:39
virtual ~UFSStrategy()
Definition: UFSStrategy.cc:33
virtual void statfs(StoreEntry &sentry) const
Definition: UFSStrategy.cc:159
Definition: Module.h:12
virtual void sync()
Definition: UFSStrategy.cc:153
UFSStrategy & operator=(UFSStrategy const &)
manages a single cache_dir
Definition: Disk.h:21

 

Introduction

Documentation

Support

Miscellaneous

Web Site Translations

Mirrors