From: Marcin Siodelski Date: Mon, 10 Sep 2012 13:37:23 +0000 (+0200) Subject: [2230] Added initial version of perfdhcp classes description doc. X-Git-Tag: trac2351_base~66^2~7 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=6febded786acd66e509faf6cc31f78a019609666;p=thirdparty%2Fkea.git [2230] Added initial version of perfdhcp classes description doc. --- diff --git a/tests/tools/perfdhcp/perfdhcp-classes.html b/tests/tools/perfdhcp/perfdhcp-classes.html new file mode 100644 index 0000000000..599bf46e8f --- /dev/null +++ b/tests/tools/perfdhcp/perfdhcp-classes.html @@ -0,0 +1,29 @@ + + + perfdhcp objects breakdown

perfdhcp objects breakdown

Marcin Siodelski

This is a companion document for BIND 10 version + 20120712.

Abstract

This document briefly describes C++ classes being part of the + perfdhcp tool.


Chapter 1. Classes

CommandOptions (command_options (.h, cc)

+ CommandOptions is a singleton class that parses perfdhcp command line + parameters and initializes its members accordingly. If parsed parameters + are invalid the parser function throws exception. +

+main(int argc, char* argv[]) {
+    try {
+        CommandOptions& command_options = CommandOptions::instance();
+        command_options.parse(argc, argv);
+    catch(const Exception& e) {
+        ...
+    }
+    ...
+}
+        

+ If argument parsing is successful than parsed values can be read from + CommandOptions singleton from any class or function in the program: +

+
+    ...
+    int rate = CommandOptions::instance().getRate();
+    ...
+
+        

+

\ No newline at end of file diff --git a/tests/tools/perfdhcp/perfdhcp-classes.xml b/tests/tools/perfdhcp/perfdhcp-classes.xml new file mode 100644 index 0000000000..13da7c6501 --- /dev/null +++ b/tests/tools/perfdhcp/perfdhcp-classes.xml @@ -0,0 +1,81 @@ + + + +%version; +]> + + + + + + + + perfdhcp objects breakdown + + + + 2012 + Internet Systems Consortium, Inc. ("ISC") + + + Marcin + Siodelski + + + This document briefly describes C++ classes being part of the + perfdhcp tool. + + + This is a companion document for BIND 10 version + &__VERSION__;. + + + + + Classes +
+ CommandOptions (command_options (.h, cc) + + CommandOptions is a singleton class that parses perfdhcp command line + parameters and initializes its members accordingly. If parsed parameters + are invalid the parser function throws exception. + + + + If argument parsing is successful than parsed values can be read from + CommandOptions singleton from any class or function in the program: + + + + +
+
+