summaryrefslogtreecommitdiffabout
path: root/include
authorMichael Krelin <hacker@klever.net>2007-03-04 00:28:39 (UTC)
committer Michael Krelin <hacker@klever.net>2007-03-04 00:28:39 (UTC)
commita3f38aafb288db5791b8dea34154cacc3c039971 (patch) (side-by-side diff)
treeb7f735ef9fde95de5935c1784d8d9486a3e4cf10 /include
parentca2207bcf18ed5b0dd1a0e370e9973d717ff87c9 (diff)
downloadsitecing-a3f38aafb288db5791b8dea34154cacc3c039971.zip
sitecing-a3f38aafb288db5791b8dea34154cacc3c039971.tar.gz
sitecing-a3f38aafb288db5791b8dea34154cacc3c039971.tar.bz2
some doxygen improvements
Diffstat (limited to 'include') (more/less context) (ignore whitespace changes)
-rw-r--r--include/sitecing/cgi_component.h11
-rw-r--r--include/sitecing/component_factory.h14
-rw-r--r--include/sitecing/component_so.h6
-rw-r--r--include/sitecing/configuration.h23
-rw-r--r--include/sitecing/file_factory.h4
-rw-r--r--include/sitecing/process_manager.h2
-rw-r--r--include/sitecing/scoreboard.h3
-rw-r--r--include/sitecing/sitecing_parser.h6
-rw-r--r--include/sitecing/sitecing_util.h24
-rw-r--r--include/sitecing/util.h4
10 files changed, 63 insertions, 34 deletions
diff --git a/include/sitecing/cgi_component.h b/include/sitecing/cgi_component.h
index 91df689..0cad438 100644
--- a/include/sitecing/cgi_component.h
+++ b/include/sitecing/cgi_component.h
@@ -26,29 +26,20 @@ namespace sitecing {
/**
* The interface to the CGI gateway.
*/
kingate::cgi_gateway* __CGI;
cgi_component();
virtual ~cgi_component();
- /**
- * @overload acomponent::__set_interface()
- */
void __set_interface(sitecing_interface* scif);
- /**
- * @overload acomponent::__on_change_interface()
- */
- void __on_change_interface(sitecing_interface *o);
+ void __on_change_interface(sitecing_interface *oscif);
/**
* Invoked on the change of the interface to the CGI.
*/
virtual void __on_change_CGI(kingate::cgi_gateway *o);
- /**
- * @overload acomponent::__on_imports()
- */
virtual void __on_imports();
};
}
#endif /* __SITECING_CGI_COMPONENT_H */
diff --git a/include/sitecing/component_factory.h b/include/sitecing/component_factory.h
index 9ddf70d..8f103e0 100644
--- a/include/sitecing/component_factory.h
+++ b/include/sitecing/component_factory.h
@@ -37,31 +37,19 @@ namespace sitecing {
*/
configuration& config;
/**
* @param c reference to the configuration container.
*/
component_factory(configuration& c);
- /**
- * @overload file_factory::get_dependencies()
- */
virtual void get_dependencies(const string& dst,file_list_t& deps);
- /**
- * @overload file_factory::is_uptodate()
- */
- virtual bool is_uptodate(const string& dst,file_list_t *deps=NULL);
- /**
- * @overload file_factory::build()
- */
+ virtual bool is_uptodate(const string& dst,file_list_t *deps=0);
virtual void build(const string& dst);
- /**
- * @overload file_factory::make()
- */
virtual void make(const string& dst);
/**
* Helper function for executing external command.
* @param cmd the command to execute.
* @param args the command line arguments.
* @param stdo stdout for the child process.
* @param stde stderr for the child process.
diff --git a/include/sitecing/component_so.h b/include/sitecing/component_so.h
index 3239d4a..3daceef 100644
--- a/include/sitecing/component_so.h
+++ b/include/sitecing/component_so.h
@@ -144,16 +144,22 @@ namespace sitecing {
template<typename CT>
class so_component_t : public sitecing::so_component {
public:
/**
* @param s The untyped instance container.
*/
so_component_t(const so_component& s)
: so_component(s) { }
+
+ /**
+ * typed dereference operator
+ * @return the pointer to the most derived component instance
+ * @see acomponent::__the_most_derived_this()
+ */
CT* operator->() {
return static_cast<CT*>(ac->__the_most_derived_this());
}
};
}
#endif /* __SITECING_COMPONENT_SO_H */
diff --git a/include/sitecing/configuration.h b/include/sitecing/configuration.h
index 330a5a6..a2bf612 100644
--- a/include/sitecing/configuration.h
+++ b/include/sitecing/configuration.h
@@ -139,18 +139,27 @@ namespace sitecing {
* The action handler component.
*/
string action;
/**
* Arguments for the action hander coponent.
*/
list<string> args;
+ /**
+ * @param s regex pattern
+ * @param a action handler
+ */
action_handler_t(const string& s,const string& a)
: s_regex(s), regex(s), action(a) { }
+ /**
+ * Copy constructor
+ *
+ * @param s source object
+ */
action_handler_t(const action_handler_t& s)
: s_regex(s.s_regex), regex(s.regex), action (s.action), args(s.args) { }
};
/**
* Type for the list of action handlers.
*/
typedef list<action_handler_t> action_handlers_t;
/**
@@ -213,17 +222,17 @@ namespace sitecing {
* See if the data is still valid.
* @return true if yes.
*/
bool is_valid();
/**
* Load the configuration file.
* @param config the main configuration container.
- * @param the configuration file.
+ * @param cfile the configuration file.
*/
void parse(configuration *config,const string& cfile);
};
/**
* The main configuration container.
*/
class configuration {
@@ -293,17 +302,17 @@ namespace sitecing {
*/
flag_multi_process = 0x00000400,
/**
* Was the user specified?
* @see user
*/
flag_user = 0x00000800,
/**
- * @Was the group specified?
+ * Was the group specified?
* @see group
*/
flag_group = 0x00001000,
/**
* Was the root to change to specified?
* @see chroot
*/
flag_chroot = 0x00002000,
@@ -385,32 +394,40 @@ namespace sitecing {
* The file to store PID into.
*/
string pid_file;
/**
* Whether we should fork into background.
*/
bool daemonize;
+ /**
+ * Type for the config options map
+ * @see specs
+ */
typedef map<string,config_options> specs_t;
/**
* The local config options map.
*/
specs_t specs;
+ /**
+ * Type for the loaded per-dir config map
+ * @see loaded_specs
+ */
typedef map<string,loaded_options> loaded_specs_t;
/**
* The local config options as specified in per-dir config files
* map.
*/
loaded_specs_t loaded_specs;
configuration();
/**
* @param cfile the configuration file.
- * @param ab @todo TODO:: document me
+ * @param ab document me @todo TODO:: document me
*/
configuration(const string& cfile,bool ab=false);
/**
* Parse the configuration file.
* @param cfile the configuration file.
*/
void parse(const string& cfile);
diff --git a/include/sitecing/file_factory.h b/include/sitecing/file_factory.h
index 7ec82da..43a27bb 100644
--- a/include/sitecing/file_factory.h
+++ b/include/sitecing/file_factory.h
@@ -27,23 +27,23 @@ namespace sitecing {
*/
typedef list<string> file_list_t;
file_factory()
: depth(0) { }
/**
* Fetch depndencies for the given file.
- * @param dst destination file.
+ * @param dst the destination file.
* @param deps where to put dependencies to.
*/
virtual void get_dependencies(const string& dst,file_list_t& deps) = 0;
/**
* Check if the destination is up to day.
- * @param the destination file.
+ * @param dst the destination file.
* @param deps if the deps pointer is non there, the dependencies
* retrieved will be stored there.
* @return true if yes.
* @see get_dependencies()
*/
virtual bool is_uptodate(const string& dst,file_list_t* deps=0);
/**
* Build the file requested.
diff --git a/include/sitecing/process_manager.h b/include/sitecing/process_manager.h
index 73415d3..921f159 100644
--- a/include/sitecing/process_manager.h
+++ b/include/sitecing/process_manager.h
@@ -49,17 +49,17 @@ namespace sitecing {
/**
* The main loop.
*/
void manage();
/**
* The worker function.
- * @param the slot allocated for the process.
+ * @param slot the slot allocated for the process.
*/
virtual void process(int slot) = 0;
/**
* @todo TODO: wish I could remember -- document me.
*/
void manage_children();
/**
diff --git a/include/sitecing/scoreboard.h b/include/sitecing/scoreboard.h
index 788f881..1371ab1 100644
--- a/include/sitecing/scoreboard.h
+++ b/include/sitecing/scoreboard.h
@@ -40,16 +40,19 @@ namespace sitecing {
* The process is accepting connection.
*/
state_accept,
/**
* The process is processing request.
*/
state_processing
} state;
+ /**
+ * Process ID
+ */
pid_t pid;
};
/**
* The scoreboard manager.
*/
class scoreboard {
/**
diff --git a/include/sitecing/sitecing_parser.h b/include/sitecing/sitecing_parser.h
index a8474f3..a53ef22 100644
--- a/include/sitecing/sitecing_parser.h
+++ b/include/sitecing/sitecing_parser.h
@@ -83,17 +83,18 @@ class sitecing_parser : public sitecing_parserFlexLexer {
*/
bool bTypeOnly;
/**
* @param t type.
* @param n name.
* @param i initializer.
* @param bc whether it is a component.
- * @param bto @todo TODO: @see bTypeOnly.
+ * @param bto document me @todo TODO:
+ * @see bTypeOnly.
*/
member_variable(const string& t,const string& n,const string& i,bool bc = false,bool bto = false)
: type(t), name(n), initializer(i), bComponent(bc), bTypeOnly(bto) { }
};
/**
* The list of member variables.
*/
typedef list<member_variable> member_variables_t;
@@ -216,18 +217,17 @@ class sitecing_parser : public sitecing_parserFlexLexer {
*/
string _name;
/**
* The argument declaration. Obviously for member functions.
*/
string _args;
/**
- * @param flags.
- * @see flags
+ * @param f processing flags @see flags
*/
modus_operandi(int f = 0)
: modus(modus_code), flags(f) { }
/**
* Change the processing mode.
*/
void modify(modus_t m);
diff --git a/include/sitecing/sitecing_util.h b/include/sitecing/sitecing_util.h
index f642c74..233292c 100644
--- a/include/sitecing/sitecing_util.h
+++ b/include/sitecing/sitecing_util.h
@@ -14,41 +14,65 @@
namespace sitecing {
using namespace std;
/**
* Base class for utility exceptions.
*/
class utility_error : public konforka::exception {
public:
+ /**
+ * @param fi file name
+ * @param fu function name
+ * @param l line number
+ * @param w what
+ */
utility_error(const string& fi,const string& fu,int l,const string& w)
: konforka::exception(fi,fu,l,w) { }
};
/**
* No prefix or suffix found to strip out.
*/
class utility_no_affix : public utility_error {
public:
+ /**
+ * @param fi file name
+ * @param fu function name
+ * @param l line number
+ * @param w what
+ */
utility_no_affix(const string& fi,const string& fu,int l,const string& w)
: utility_error(fi,fu,l,w) { }
};
/**
* No prefix to strip found.
*/
class utility_no_prefix : public utility_no_affix {
public:
+ /**
+ * @param fi file name
+ * @param fu function name
+ * @param l line number
+ * @param w what
+ */
utility_no_prefix(const string& fi,const string& fu,int l,const string& w)
: utility_no_affix(fi,fu,l,w) { }
};
/**
* No suffix to strip found.
*/
class utility_no_suffix : public utility_no_affix {
public:
+ /**
+ * @param fi file name
+ * @param fu function name
+ * @param l line number
+ * @param w what
+ */
utility_no_suffix(const string& fi,const string& fu,int l,const string& w)
: utility_no_affix(fi,fu,l,w) { }
};
/**
* The file lock object. Released at the object destruction.
*/
class file_lock {
diff --git a/include/sitecing/util.h b/include/sitecing/util.h
index 5750ab6..a38ae90 100644
--- a/include/sitecing/util.h
+++ b/include/sitecing/util.h
@@ -17,25 +17,25 @@ namespace sitecing {
* the html_escape options enumeration.
*/
enum html_escape_options {
/**
* Turn spaces into &nbsp;
*/
html_escape_nbsp = 0x0001,
/**
- * Turn newlines into <br/> or <br>.
+ * Turn newlines into br/ or br.
*/
html_escape_br = 0x0002,
/**
* Turn quotes to &quot;
*/
html_escape_quot = 0x0004,
/**
- * Do not put '/' into <br/> consruct.
+ * Do not put '/' into br consruct.
*/
html_escape_br_noslash = 0x0008
};
/**
* Escape string suitable for html output.
* @param str the string.
* @param flags options.
* @return the string escaped.