refactored some common platform dependent stuff into a new

library:  platform.  also removed test.cpp.
This commit is contained in:
crs
2002-06-04 12:26:23 +00:00
parent c3649df304
commit 5709d8ddef
29 changed files with 476 additions and 424 deletions

29
platform/CUnixPlatform.h Normal file
View File

@@ -0,0 +1,29 @@
#ifndef CUNIXPLATFORM_H
#define CUNIXPLATFORM_H
#include "IPlatform.h"
class CUnixPlatform : public IPlatform {
public:
CUnixPlatform();
virtual ~CUnixPlatform();
// IPlatform overrides
virtual bool installDaemon(/* FIXME */);
virtual bool uninstallDaemon(/* FIXME */);
virtual bool daemonize(const char* name);
virtual const char* getBasename(const char* pathname) const;
virtual CString getUserDirectory() const;
virtual CString getSystemDirectory() const;
virtual CString addPathComponent(
const CString& prefix,
const CString& suffix) const;
protected:
virtual void setDaemonLogger(const char* name);
private:
static void deamonLogger(int, const char*);
};
#endif