28 #include <sys/types.h>
76 void init(
const Path & pid_file_path ) ;
99 void operator=(
const PidFile & ) ;
100 static bool mine(
SignalSafe ,
const char * path ) ;
101 static void create(
const Path & pid_file ) ;
void init(const Path &pid_file_path)
Used after default construction.
void check()
Throws an exception if the path is not absolute.
An empty structure that is used to indicate a signal-safe, reentrant implementation.
Path path() const
Returns the path as supplied to the constructor or init().
PidFile()
Default constructor.
static void cleanup(SignalSafe, const char *path)
Deletes the specified pid file if it contains this process's id.
void commit()
Creates the file.
#define G_EXCEPTION(class_name, description)
define as a function rather than a type if optimising for size
A class for creating pid files.
A Path object represents a file system path.