 |
Kea
1.5.0
|
Go to the documentation of this file.
7 #ifndef LFC_CONTROLLER_H
8 #define LFC_CONTROLLER_H
79 void launch(
int argc,
char* argv[],
const bool test_mode);
109 return (protocol_version_);
116 return (config_file_);
123 return (previous_file_);
137 return (output_file_);
144 return (finish_file_);
157 int protocol_version_;
160 std::string config_file_;
161 std::string previous_file_;
162 std::string copy_file_;
163 std::string output_file_;
164 std::string finish_file_;
165 std::string pid_file_;
171 void usage(
const std::string& text);
177 std::string getVersion(
const bool extended)
const;
190 template<
typename LeaseObjectType,
typename LeaseFileType,
typename StorageType>
191 void processLeases()
const;
197 void startLogger(
const bool test_mode)
const;
203 #endif // LFC_CONTROLLER_H
Exception thrown when the command line is invalid.
std::string getPreviousFile() const
Gets the previous file name.
static const char * lfc_bin_name_
Defines the executable name, by convention this should match the executable name.
RunTimeFail(const char *file, size_t line, const char *what)
std::string getOutputFile() const
Gets the output file name.
This is a base class for exceptions thrown from the DNS library module.
Defines the logger used by the top-level component of kea-dhcp-ddns.
virtual const char * what() const
Returns a C-style character string of the cause of the exception.
std::string getConfigFile() const
Gets the config file name.
void launch(int argc, char *argv[], const bool test_mode)
Acts as the primary entry point to start execution of the process.
~LFCController()
Destructor.
std::string getFinishFile() const
Gets the finish file name.
static const char * lfc_app_name_
Defines the application name, it may be used to locate configuration data and appears in log statemen...
Process controller for LFC process.
int getProtocolVersion() const
Gets the protocol version of the leases files.
std::string getPidFile() const
Gets the pid file name.
LFCController()
Constructor.
void fileRotate() const
Rotate files.
InvalidUsage(const char *file, size_t line, const char *what)
std::string getCopyFile() const
Gets the copy file name.
void parseArgs(int argc, char *argv[])
Process the command line arguments.
Exceptions thrown when a method is unable to manipulate (remove or rename) a file.