diff -Nru incron-0.5.10/appargs.cpp incron-0.5.12/appargs.cpp --- incron-0.5.10/appargs.cpp 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/appargs.cpp 2019-02-18 12:34:17.000000000 +0000 @@ -6,6 +6,7 @@ * application arguments processor * * Copyright (C) 2007, 2008, 2012 Lukas Jelinek, + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can redistribute it and/or * modify it under the terms of one of the following licenses: @@ -222,7 +223,7 @@ bool AppArgs::ParseLong(const char* pchStr, std::string& rName, std::string& rVal, bool& rfHasVal) { - StringTokenizer tok(pchStr+2, '='); + StringTokenizer tok(pchStr+2, "="); if (!tok.HasMoreTokens()) return false; diff -Nru incron-0.5.10/CHANGELOG incron-0.5.12/CHANGELOG --- incron-0.5.10/CHANGELOG 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/CHANGELOG 2019-02-18 12:34:17.000000000 +0000 @@ -1,3 +1,18 @@ +0.5.12 2015-02-01 +* added recursive directory watching +* added configuration parameters: recursive, dotdirs and loopable +* added upstart script +* extended manpages and readme + +0.5.11 2015-01-26 +* first release from GitHub +* swiched all readme and manpage files to new upstream +* many bugfixes of improtant bugs +* tab delimiteres in config files allowed +* ignore dotfiles in /etc/incron.d +* added proper redirection and piping abilities to commands +* commands are now executed in a shel environment + 0.5.10 2012-04-05 * some includes fixed to build correctly with GCC 4.6 (and 4.4-4.5 - #0000385, #0000447) * some type issues fixed (#0000447) diff -Nru incron-0.5.10/debian/changelog incron-0.5.12/debian/changelog --- incron-0.5.10/debian/changelog 2018-04-03 12:29:01.000000000 +0000 +++ incron-0.5.12/debian/changelog 2019-02-19 02:44:46.000000000 +0000 @@ -1,8 +1,28 @@ -incron (0.5.10-3build1) bionic; urgency=high +incron (0.5.12-1) unstable; urgency=medium - * No change rebuild to pick up -fPIE compiler default + * New upstream release (Closes: #860199) + - Fix bug 'incron silently discards command output' (Closes: 419518) + - Fix bug 'incron logs command to execute but command is not + executed' (Closes: #584134) + - Fix bug 'allow whitespace delimiters in incrontab files' + (Closes: #456821) + - Fix bug 'ignore dotfiles in /etc/incron.d' (Closes: #606770) + - Fix bug 'avoids shadowing a variable and also enables more warnings + when compiling' (Closes: #503973) + * Remove all patches (merged upstream) + * Upstream development has moved to github: + - Update watch file accordingly + - Update homepage in control file + * New upstream developer: update copyright file accordingly + * Bump Standards-Version to 4.3.0 + * Switch debhelper compatibility to 12 + * Update Vcs-Git and Vcs-Browser with new repository on salsa.debian.org + * Change priority from extra to optional + * Fix debian/copyright Format URI to use https + * Add debian/upstream/metadata + * Add a patch to fix manpages typos - -- Balint Reczey Tue, 03 Apr 2018 12:29:01 +0000 + -- Emmanuel Bouthenot Tue, 19 Feb 2019 02:44:46 +0000 incron (0.5.10-3) unstable; urgency=medium @@ -127,5 +147,3 @@ * Initial release (Closes: #409173) -- Emmanuel Bouthenot Sat, 17 Feb 2007 11:03:57 +0100 - - diff -Nru incron-0.5.10/debian/compat incron-0.5.12/debian/compat --- incron-0.5.10/debian/compat 2012-04-08 19:50:50.000000000 +0000 +++ incron-0.5.12/debian/compat 2019-02-19 02:44:46.000000000 +0000 @@ -1 +1 @@ -9 +12 diff -Nru incron-0.5.10/debian/control incron-0.5.12/debian/control --- incron-0.5.10/debian/control 2018-04-03 12:29:01.000000000 +0000 +++ incron-0.5.12/debian/control 2019-02-19 02:44:46.000000000 +0000 @@ -1,19 +1,18 @@ Source: incron Section: admin -Priority: extra -Maintainer: Ubuntu Developers -XSBC-Original-Maintainer: Emmanuel Bouthenot +Priority: optional +Maintainer: Emmanuel Bouthenot Uploaders: Michael Prokop Build-Depends: - debhelper (>= 9), - dh-systemd (>= 1.5) -Standards-Version: 3.9.5 -Homepage: http://inotify.aiken.cz/ -Vcs-Git: git://anonscm.debian.org/users/kolter/incron.git -Vcs-Browser: http://anonscm.debian.org/git/users/kolter/incron.git + debhelper (>= 12) +Standards-Version: 4.3.0 +Homepage: https://github.com/ar-/incron +Vcs-Git: https://salsa.debian.org/kolter/incron.git +Vcs-Browser: https://salsa.debian.org/kolter/incron Package: incron Architecture: any +Pre-Depends: ${misc:Pre-Depends} Depends: ${shlibs:Depends}, ${misc:Depends}, lsb-base (>= 3.2-14), adduser Description: cron-like daemon which handles filesystem events incron is an "inotify cron" system. It works like the regular cron but is diff -Nru incron-0.5.10/debian/copyright incron-0.5.12/debian/copyright --- incron-0.5.10/debian/copyright 2014-03-20 22:33:45.000000000 +0000 +++ incron-0.5.12/debian/copyright 2019-02-19 02:44:46.000000000 +0000 @@ -1,14 +1,15 @@ -Format: http://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ +Format: https://www.debian.org/doc/packaging-manuals/copyright-format/1.0/ Upstream-Name: incron -Upstream-Contact: Lukas Jelinek -Source: http://inotify.aiken.cz/ +Upstream-Contact: Andreas Altair Redmer +Source: https://github.com/ar-/incron Files: * Copyright: 2006-2012, Lukas Jelinek, + 2014-2019, Andreas Altair Redmer License: GPL-2+ Files: debian/* -Copyright: 2008-2014, Emmanuel Bouthenot +Copyright: 2008-2019, Emmanuel Bouthenot License: GPL-2+ License: GPL-2+ diff -Nru incron-0.5.10/debian/dirs incron-0.5.12/debian/dirs --- incron-0.5.10/debian/dirs 2012-04-08 18:51:19.000000000 +0000 +++ incron-0.5.12/debian/dirs 1970-01-01 00:00:00.000000000 +0000 @@ -1,4 +0,0 @@ -etc/incron.d -usr/bin -usr/sbin -var/spool/incron diff -Nru incron-0.5.10/debian/docs incron-0.5.12/debian/docs --- incron-0.5.10/debian/docs 2012-04-08 18:51:19.000000000 +0000 +++ incron-0.5.12/debian/docs 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -README -TODO diff -Nru incron-0.5.10/debian/examples incron-0.5.12/debian/examples --- incron-0.5.10/debian/examples 2012-04-08 18:51:19.000000000 +0000 +++ incron-0.5.12/debian/examples 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -incron.conf.example diff -Nru incron-0.5.10/debian/gbp.conf incron-0.5.12/debian/gbp.conf --- incron-0.5.10/debian/gbp.conf 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/gbp.conf 2019-02-19 02:33:35.000000000 +0000 @@ -0,0 +1,8 @@ +[DEFAULT] +debian-branch = unstable + +[import-orig] +filter = [ + 'debian', + 'doc/html' + ] diff -Nru incron-0.5.10/debian/incron.dirs incron-0.5.12/debian/incron.dirs --- incron-0.5.10/debian/incron.dirs 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/incron.dirs 2019-02-19 02:32:55.000000000 +0000 @@ -0,0 +1,4 @@ +etc/incron.d +usr/bin +usr/sbin +var/spool/incron diff -Nru incron-0.5.10/debian/incron.docs incron-0.5.12/debian/incron.docs --- incron-0.5.10/debian/incron.docs 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/incron.docs 2019-02-19 02:32:55.000000000 +0000 @@ -0,0 +1,2 @@ +README +TODO diff -Nru incron-0.5.10/debian/incron.examples incron-0.5.12/debian/incron.examples --- incron-0.5.10/debian/incron.examples 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/incron.examples 2019-02-19 02:32:55.000000000 +0000 @@ -0,0 +1 @@ +incron.conf.example diff -Nru incron-0.5.10/debian/incron.init.d incron-0.5.12/debian/incron.init.d --- incron-0.5.10/debian/incron.init.d 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/incron.init.d 2019-02-19 02:32:55.000000000 +0000 @@ -0,0 +1,66 @@ +#! /bin/sh +# +# incron This init.d script is used to start incron +# + +### BEGIN INIT INFO +# Provides: incron +# Required-Start: $remote_fs $syslog +# Required-Stop: $remote_fs $syslog +# Default-Start: 2 3 4 5 +# Default-Stop: 0 1 6 +# Short-Description: Start, stop or reload incron +# Description: incron is a file system events scheduler +### END INIT INFO + +PATH=/sbin:/bin:/usr/sbin:/usr/bin +INCROND=/usr/sbin/incrond +NAME=incron +DESC="File system events scheduler" +INCROND_PID=/var/run/incrond.pid +INCROND_CONF=/etc/incron.conf + +if [ ! -x "$INCROND" ]; then + exit 0 +fi + +# loading lsb functions +. /lib/lsb/init-functions + +case "$1" in + start) + log_daemon_msg "Starting $DESC" + log_progress_msg "$NAME" + start_daemon -p "$INCROND_PID" "$INCROND" -f "$INCROND_CONF" + log_end_msg $? + ;; + stop) + log_daemon_msg "Stopping $DESC" + log_progress_msg "$NAME" + killproc -p "$INCROND_PID" "$INCROND" + log_end_msg $? + ;; + reload) + log_daemon_msg "Reloading $DESC" + log_progress_msg "$NAME" + echo -n + log_end_msg $? + ;; + restart|force-reload) + $0 stop + sleep 1 + $0 start + ;; + status) + if ! status_of_proc "$(basename "$INCROND")" "$NAME" ; then + exit $? + fi + ;; + *) + N=/etc/init.d/$NAME + echo "Usage: $N {start|stop|restart|reload|force-reload|status}" >&2 + exit 1 + ;; +esac + +exit 0 diff -Nru incron-0.5.10/debian/incron.install incron-0.5.12/debian/incron.install --- incron-0.5.10/debian/incron.install 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/incron.install 2019-02-19 02:32:55.000000000 +0000 @@ -0,0 +1,2 @@ +incrontab usr/bin +incrond usr/sbin diff -Nru incron-0.5.10/debian/incron.manpages incron-0.5.12/debian/incron.manpages --- incron-0.5.10/debian/incron.manpages 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/incron.manpages 2019-02-19 02:32:55.000000000 +0000 @@ -0,0 +1,4 @@ +incrontab.1 +incrontab.5 +incrond.8 +incron.conf.5 diff -Nru incron-0.5.10/debian/incron.postinst incron-0.5.12/debian/incron.postinst --- incron-0.5.10/debian/incron.postinst 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/incron.postinst 2019-02-19 02:32:55.000000000 +0000 @@ -0,0 +1,31 @@ +#!/bin/sh +# +# postinst script for incron +# + +set -e + +case "$1" in + configure|reconfigure) + # add group for incrontabs + getent group incron > /dev/null 2>&1 || addgroup --system incron + + if ! dpkg-statoverride --list /usr/bin/incrontab > /dev/null ; then + dpkg-statoverride --update --add root incron 2755 /usr/bin/incrontab + fi + + if ! dpkg-statoverride --list /var/spool/incron > /dev/null ; then + dpkg-statoverride --update --add root incron 1731 /var/spool/incron + fi + + for f in /etc/incron.allow /etc/incron.deny ; do + if ! dpkg-statoverride --list $f > /dev/null ; then + dpkg-statoverride --update --add root incron 640 $f + fi + done + ;; +esac + +#DEBHELPER# + +exit 0 diff -Nru incron-0.5.10/debian/incron.postrm incron-0.5.12/debian/incron.postrm --- incron-0.5.10/debian/incron.postrm 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/incron.postrm 2019-02-19 02:32:55.000000000 +0000 @@ -0,0 +1,25 @@ +#!/bin/sh +# +# postrm script for incron +# + +set -e + +case "$1" in + remove) + if dpkg-statoverride --list /usr/bin/incrontab > /dev/null ; then + dpkg-statoverride --remove /usr/bin/incrontab + fi + ;; + purge) + for f in /etc/incron.allow /etc/incron.deny /var/spool/incron ; do + if dpkg-statoverride --list $f > /dev/null ; then + dpkg-statoverride --remove $f + fi + done + ;; +esac + +#DEBHELPER# + +exit 0 diff -Nru incron-0.5.10/debian/incron.service incron-0.5.12/debian/incron.service --- incron-0.5.10/debian/incron.service 2014-03-17 14:25:52.000000000 +0000 +++ incron-0.5.12/debian/incron.service 2019-02-19 02:44:46.000000000 +0000 @@ -1,10 +1,13 @@ [Unit] Description=file system events scheduler +Documentation=man:incrond(8) [Service] Type=forking PIDFile=/run/incrond.pid ExecStart=/usr/sbin/incrond +PrivateTmp=true + [Install] WantedBy=multi-user.target diff -Nru incron-0.5.10/debian/init.d incron-0.5.12/debian/init.d --- incron-0.5.10/debian/init.d 2012-04-08 20:59:01.000000000 +0000 +++ incron-0.5.12/debian/init.d 1970-01-01 00:00:00.000000000 +0000 @@ -1,66 +0,0 @@ -#! /bin/sh -# -# incron This init.d script is used to start incron -# - -### BEGIN INIT INFO -# Provides: incron -# Required-Start: $remote_fs $syslog -# Required-Stop: $remote_fs $syslog -# Default-Start: 2 3 4 5 -# Default-Stop: 0 1 6 -# Short-Description: Start, stop or reload incron -# Description: incron is a file system events scheduler -### END INIT INFO - -PATH=/sbin:/bin:/usr/sbin:/usr/bin -INCROND=/usr/sbin/incrond -NAME=incron -DESC="File system events scheduler" -INCROND_PID=/var/run/incrond.pid -INCROND_CONF=/etc/incron.conf - -if [ ! -x "$INCROND" ]; then - exit 0 -fi - -# loading lsb functions -. /lib/lsb/init-functions - -case "$1" in - start) - log_daemon_msg "Starting $DESC" - log_progress_msg "$NAME" - start_daemon -p "$INCROND_PID" "$INCROND" -f "$INCROND_CONF" - log_end_msg $? - ;; - stop) - log_daemon_msg "Stopping $DESC" - log_progress_msg "$NAME" - killproc -p "$INCROND_PID" "$INCROND" - log_end_msg $? - ;; - reload) - log_daemon_msg "Reloading $DESC" - log_progress_msg "$NAME" - echo -n - log_end_msg $? - ;; - restart|force-reload) - $0 stop - sleep 1 - $0 start - ;; - status) - if ! status_of_proc "$(basename "$INCROND")" "$NAME" ; then - exit $? - fi - ;; - *) - N=/etc/init.d/$NAME - echo "Usage: $N {start|stop|restart|reload|force-reload|status}" >&2 - exit 1 - ;; -esac - -exit 0 diff -Nru incron-0.5.10/debian/install incron-0.5.12/debian/install --- incron-0.5.10/debian/install 2012-04-08 18:51:19.000000000 +0000 +++ incron-0.5.12/debian/install 1970-01-01 00:00:00.000000000 +0000 @@ -1,2 +0,0 @@ -incrontab usr/bin -incrond usr/sbin diff -Nru incron-0.5.10/debian/manpages incron-0.5.12/debian/manpages --- incron-0.5.10/debian/manpages 2012-04-08 18:51:19.000000000 +0000 +++ incron-0.5.12/debian/manpages 1970-01-01 00:00:00.000000000 +0000 @@ -1,4 +0,0 @@ -incrontab.1 -incrontab.5 -incrond.8 -incron.conf.5 diff -Nru incron-0.5.10/debian/patches/01_manpages_typos incron-0.5.12/debian/patches/01_manpages_typos --- incron-0.5.10/debian/patches/01_manpages_typos 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/patches/01_manpages_typos 2019-02-19 02:44:46.000000000 +0000 @@ -0,0 +1,39 @@ +Description: Fix typos in manpages +Author: Emmanuel Bouthenot +Forwarded: no +Last-Update: 2019-02-19 +--- +This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ +--- a/incron.conf.5 ++++ b/incron.conf.5 +@@ -35,7 +35,7 @@ + .BR Default : \fIincrond\fR + .TP + \fBeditor\fP +-This name or path is used to run as an editor for editing incron tables. Default \fIno editor\fR is given, system editor used, this option overide this. ++This name or path is used to run as an editor for editing incron tables. Default \fIno editor\fR is given, system editor used, this option override this. + .SH "SEE ALSO" + incrond(8), incrontab(1), incrontab(5) + .SH "AUTHOR" +--- a/incrond.8 ++++ b/incrond.8 +@@ -30,7 +30,7 @@ + .SH "SEE ALSO" + incrontab(1), incrontab(5), incron.conf(5) + .SH "BUGS" +-incrond is currently not resistent against looping. ++incrond is currently not resistant against looping. + .SH "AUTHOR" + Andreas Altair Redmer (please report bugs to https://github.com/ar-/incron/issues ). + Lukas Jelinek . +--- a/incrontab.5 ++++ b/incrontab.5 +@@ -14,7 +14,7 @@ + + + +-Where \fIpath\fR is an absolute filesystem path, \fImask\fR is an event mask (in symbolic or numeric form) and \fIcommand\fR is an executable file (or a script) with its arguments. See bellow for event mask symbols. The executable file may be noted as an absolute path or only as the name itself (PATH locations are examined). ++Where \fIpath\fR is an absolute filesystem path, \fImask\fR is an event mask (in symbolic or numeric form) and \fIcommand\fR is an executable file (or a script) with its arguments. See below for event mask symbols. The executable file may be noted as an absolute path or only as the name itself (PATH locations are examined). + + Please remember that the same path may occur only once per table (otherwise only the first occurrence takes effect and an error message is emitted to the system log). + Please not that the * wildcard is allowed to observe a range of files. diff -Nru incron-0.5.10/debian/patches/fix_ftbfs_gcc47 incron-0.5.12/debian/patches/fix_ftbfs_gcc47 --- incron-0.5.10/debian/patches/fix_ftbfs_gcc47 2012-04-08 20:48:43.000000000 +0000 +++ incron-0.5.12/debian/patches/fix_ftbfs_gcc47 1970-01-01 00:00:00.000000000 +0000 @@ -1,15 +0,0 @@ -Description: Fix a FTBFS with GCC 4.7 -Forwarded: http://bts.aiken.cz/view.php?id=713 -Author: Emmanuel Bouthenot -Bug-Debian: http://bugs.debian.org/667209 -Last-Update: 2012-04-08 ---- a/icd-main.cpp -+++ b/icd-main.cpp -@@ -24,6 +24,7 @@ - #include - #include - #include -+#include - #include - #include - #include diff -Nru incron-0.5.10/debian/patches/fix_incrontab_bad_ownership incron-0.5.12/debian/patches/fix_incrontab_bad_ownership --- incron-0.5.10/debian/patches/fix_incrontab_bad_ownership 2014-11-03 20:30:15.000000000 +0000 +++ incron-0.5.12/debian/patches/fix_incrontab_bad_ownership 1970-01-01 00:00:00.000000000 +0000 @@ -1,26 +0,0 @@ -Description: Fix bad ownership of user's incrontab installed by root -Author: Emmanuel Bouthenot -Bug-Debian: https://bugs.debian.org/709300 -Forwarded: http://bts.aiken.cz/view.php?id=744 -Last-Update: 2014-03-20 ---- -This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ ---- a/ict-main.cpp -+++ b/ict-main.cpp -@@ -99,6 +99,16 @@ - return false; - } - -+ struct passwd* ppwd = getpwnam(rUser.c_str()); -+ if (ppwd == NULL) { -+ fprintf(stderr, "cannot find user '%s': %s\n", rUser.c_str(), strerror(errno)); -+ return false; -+ } -+ if (chown(out.c_str(), ppwd->pw_uid, -1) != 0) { -+ fprintf(stderr, "cannot set owner '%s' to table '%s': %s\n", rUser.c_str(), out.c_str(), strerror(errno)); -+ return false; -+ } -+ - return true; - } - diff -Nru incron-0.5.10/debian/patches/fix_incrontab_path_with_spaces_handling incron-0.5.12/debian/patches/fix_incrontab_path_with_spaces_handling --- incron-0.5.10/debian/patches/fix_incrontab_path_with_spaces_handling 2014-03-20 22:24:24.000000000 +0000 +++ incron-0.5.12/debian/patches/fix_incrontab_path_with_spaces_handling 1970-01-01 00:00:00.000000000 +0000 @@ -1,18 +0,0 @@ -Description: Fix badly escaped $@ in incrontabs with paths containing spaces -Author: Emmanuel Bouthenot -Bug-Debian: https://bugs.debian.org/605021 -Forwarded: http://bts.aiken.cz/view.php?id=741 -Last-Update: 2014-03-17 ---- -This patch header follows DEP-3: http://dep.debian.net/deps/dep3/ ---- a/usertable.cpp -+++ b/usertable.cpp -@@ -336,7 +336,7 @@ - else { - cmd.append(cs.substr(oldpos, pos-oldpos)); - if (cs[px] == '@') { // base path -- cmd.append(pW->GetPath()); -+ cmd.append(IncronTabEntry::GetSafePath(pW->GetPath())); - oldpos = pos + 2; - } - else if (cs[px] == '#') { // file name diff -Nru incron-0.5.10/debian/patches/fix_inotify_syscall_conditional incron-0.5.12/debian/patches/fix_inotify_syscall_conditional --- incron-0.5.10/debian/patches/fix_inotify_syscall_conditional 2014-11-03 20:36:38.000000000 +0000 +++ incron-0.5.12/debian/patches/fix_inotify_syscall_conditional 1970-01-01 00:00:00.000000000 +0000 @@ -1,30 +0,0 @@ -Description: Fix inotify syscall conditional - the code checks if the syscall number for inotify_init is defined, if it isn't - then it assumes it needs to include sys/inotify-syscalls.h (a header which as - far as I can tell has not existed for years) to get the inotify stuff. - - However the inotify_init syscall is deprecated and doesn't exist at all on - arm64 (and probablly won't exist on other architectures that are regarded as - completely new either). - - The c library function inotify_init appears to now be implemented using the - inotify_init1 syscall - - This patch updates the conditional logic to also check for the inotify_init1 - syscall number and hence allows it to build on arm64 (and presumablly other - new architectures). -Author: Peter Michael Green -Bug-Debian: https://bugs.debian.org/767758 -Forwarded: http://bts.aiken.cz/view.php?id=748 -Last-Update: 2014-11-03 ---- a/inotify-cxx.h -+++ b/inotify-cxx.h -@@ -36,7 +36,7 @@ - #include - - // Use this if syscalls not defined --#ifndef __NR_inotify_init -+#if not defined(__NR_inotify_init) && not defined(__NR_inotify_init1) - #include - #endif // __NR_inotify_init - diff -Nru incron-0.5.10/debian/patches/fix_typo_manpage incron-0.5.12/debian/patches/fix_typo_manpage --- incron-0.5.10/debian/patches/fix_typo_manpage 2012-04-08 20:49:53.000000000 +0000 +++ incron-0.5.12/debian/patches/fix_typo_manpage 1970-01-01 00:00:00.000000000 +0000 @@ -1,27 +0,0 @@ -Description: Fix some typos in manpages -Forwarded: http://bts.aiken.cz/view.php?id=714 -Author: Emmanuel Bouthenot -Bug-Debian: http://bugs.debian.org/501587 -Last-Update: 2012-04-08 ---- a/incrontab.1 -+++ b/incrontab.1 -@@ -8,7 +8,7 @@ - .SH "DESCRIPTION" - incrontab is a table manipulator for the inotify cron (incron) system. It creates, removes, modifies and lists user tables (\fIincrontab\fR(5)). - --Each user (including system users even they haven't home directories) has an incron table which can't be manipulated directly (only root can effectively change these tables and is NOT recommended to do so). -+Each user (including even system users without home directories) has an incron table which can't be manipulated directly (only root can effectively change these tables and is NOT recommended to do so). - - All informational messages of this program are printed to the standard error output (stderr). - ---- a/incrontab.5 -+++ b/incrontab.5 -@@ -56,7 +56,7 @@ - .br - \fBIN_ONLYDIR\fR Only watch pathname if it is a directory - --Additionaly, there is a symbol which doesn't appear in the inotify symbol set. It it \fBIN_NO_LOOP\fR. This symbol disables monitoring events until the current one is completely handled (until its child process exits). -+Additionally, there is a symbol which doesn't appear in the inotify symbol set. It it \fBIN_NO_LOOP\fR. This symbol disables monitoring events until the current one is completely handled (until its child process exits). - - .SH "WILDCARDS" - The following wildards may be used inside command specification: diff -Nru incron-0.5.10/debian/patches/series incron-0.5.12/debian/patches/series --- incron-0.5.10/debian/patches/series 2014-11-03 20:29:02.000000000 +0000 +++ incron-0.5.12/debian/patches/series 2019-02-19 02:44:46.000000000 +0000 @@ -1,5 +1 @@ -fix_typo_manpage -fix_ftbfs_gcc47 -fix_incrontab_path_with_spaces_handling -fix_incrontab_bad_ownership -fix_inotify_syscall_conditional +01_manpages_typos diff -Nru incron-0.5.10/debian/postinst incron-0.5.12/debian/postinst --- incron-0.5.10/debian/postinst 2014-03-20 22:36:06.000000000 +0000 +++ incron-0.5.12/debian/postinst 1970-01-01 00:00:00.000000000 +0000 @@ -1,31 +0,0 @@ -#!/bin/sh -# -# postinst script for incron -# - -set -e - -case "$1" in - configure|reconfigure) - # add group for incrontabs - getent group incron > /dev/null 2>&1 || addgroup --system incron - - if ! dpkg-statoverride --list /usr/bin/incrontab > /dev/null ; then - dpkg-statoverride --update --add root incron 2755 /usr/bin/incrontab - fi - - if ! dpkg-statoverride --list /var/spool/incron > /dev/null ; then - dpkg-statoverride --update --add root incron 1731 /var/spool/incron - fi - - for f in /etc/incron.allow /etc/incron.deny ; do - if ! dpkg-statoverride --list $f > /dev/null ; then - dpkg-statoverride --update --add root incron 640 $f - fi - done - ;; -esac - -#DEBHELPER# - -exit 0 diff -Nru incron-0.5.10/debian/postrm incron-0.5.12/debian/postrm --- incron-0.5.10/debian/postrm 2014-03-20 22:36:56.000000000 +0000 +++ incron-0.5.12/debian/postrm 1970-01-01 00:00:00.000000000 +0000 @@ -1,25 +0,0 @@ -#!/bin/sh -# -# postrm script for incron -# - -set -e - -case "$1" in - remove) - if dpkg-statoverride --list /usr/bin/incrontab > /dev/null ; then - dpkg-statoverride --remove /usr/bin/incrontab - fi - ;; - purge) - for f in /etc/incron.allow /etc/incron.deny /var/spool/incron ; do - if dpkg-statoverride --list $f > /dev/null ; then - dpkg-statoverride --remove $f - fi - done - ;; -esac - -#DEBHELPER# - -exit 0 diff -Nru incron-0.5.10/debian/README.Debian incron-0.5.12/debian/README.Debian --- incron-0.5.10/debian/README.Debian 2012-04-08 18:51:19.000000000 +0000 +++ incron-0.5.12/debian/README.Debian 2019-02-19 02:44:46.000000000 +0000 @@ -7,7 +7,7 @@ Users are not allowed to use incron by default because a bad usage of incron with (loops) can make the whole system hanging. See BUGS section in incrond(8) - manpage. Be carefull with users allowed to use incron. + manpage. Be careful with users allowed to use incron. Systems incrontabs goes to /etc/incron.d . diff -Nru incron-0.5.10/debian/rules incron-0.5.12/debian/rules --- incron-0.5.10/debian/rules 2014-11-03 20:41:00.000000000 +0000 +++ incron-0.5.12/debian/rules 2019-02-19 02:44:46.000000000 +0000 @@ -2,6 +2,8 @@ PACKAGE = incron +export DEB_BUILD_MAINT_OPTIONS=hardening=+all + override_dh_auto_install: echo @@ -12,4 +14,4 @@ touch $(CURDIR)/debian/$(PACKAGE)/etc/incron.deny %: - dh $@ --with systemd + dh $@ diff -Nru incron-0.5.10/debian/source.lintian-overrides incron-0.5.12/debian/source.lintian-overrides --- incron-0.5.10/debian/source.lintian-overrides 2012-04-08 19:57:58.000000000 +0000 +++ incron-0.5.12/debian/source.lintian-overrides 1970-01-01 00:00:00.000000000 +0000 @@ -1 +0,0 @@ -incron source: package-needs-versioned-debhelper-build-depends 9 diff -Nru incron-0.5.10/debian/upstream/metadata incron-0.5.12/debian/upstream/metadata --- incron-0.5.10/debian/upstream/metadata 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/debian/upstream/metadata 2019-02-19 02:44:46.000000000 +0000 @@ -0,0 +1,7 @@ +Name: incron +Homepage: https://github.com/ar-/incron +Repository: https://github.com/ar-/incron.git +Repository-Browse: https://github.com/ar-/incron +Changelog: https://raw.githubusercontent.com/ar-/incron/master/CHANGELOG +Bug-Database: https://github.com/ar-/incron/issues +Bug-Submit: https://github.com/ar-/incron/issues/new diff -Nru incron-0.5.10/debian/watch incron-0.5.12/debian/watch --- incron-0.5.10/debian/watch 2012-04-08 18:51:19.000000000 +0000 +++ incron-0.5.12/debian/watch 2019-02-19 02:32:55.000000000 +0000 @@ -1,2 +1,2 @@ version=3 -http://inotify.aiken.cz/download/incron/incron-([.0-9]*)\.tar\.gz +https://github.com/ar-/incron/tags .*/archive/(\d[\d\.]+)\.tar\.gz diff -Nru incron-0.5.10/doc/html/annotated.html incron-0.5.12/doc/html/annotated.html --- incron-0.5.10/doc/html/annotated.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/annotated.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,84 +0,0 @@ - - - - -incron: Class List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
Class List
-
-
-
Here are the classes, structs, unions and interfaces with brief descriptions:
- - - - - - - - - - - - - - - -
AppArgOption_tArgument option type
AppArgsApplication arguments
AppInstanceApplication instance management class
AppInstExceptionException class
EventDispatcherEvent dispatcher class
IncronCfgConfiguration class
IncronTabIncron table class
IncronTabEntryIncron table entry class
InotifyInotify class
InotifyEventInotify event class
InotifyExceptionClass for inotify exceptions
InotifyWatchInotify watch class
ProcData_tChild process data
StringTokenizerSimple string tokenizer class
UserTableUser table class
-
- - - - - - diff -Nru incron-0.5.10/doc/html/appargs_8cpp.html incron-0.5.12/doc/html/appargs_8cpp.html --- incron-0.5.10/doc/html/appargs_8cpp.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/appargs_8cpp.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,86 +0,0 @@ - - - - -incron: appargs.cpp File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
appargs.cpp File Reference
-
-
- -

application arguments processor implementation -More...

-
#include <cstdio>
-#include <cstring>
-#include "strtok.h"
-#include "appargs.h"
-

Detailed Description

-

application arguments processor implementation

-

application arguments processor

-

Copyright (C) 2007, 2008, 2012 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can redistribute it and/or modify it under the terms of one of the following licenses:

-
    -
  • 1. X11-style license (see LICENSE-X11)
  • -
  • 2. GNU Lesser General Public License, version 2.1 (see LICENSE-LGPL)
  • -
  • 3. GNU General Public License, version 2 (see LICENSE-GPL)
  • -
-

If you want to help with choosing the best license for you, please visit http://www.gnu.org/licenses/license-list.html.

-

Credits: Christian Ruppert (new include to build with GCC 4.4+)

-
- - - - - - diff -Nru incron-0.5.10/doc/html/appargs_8h.html incron-0.5.12/doc/html/appargs_8h.html --- incron-0.5.10/doc/html/appargs_8h.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/appargs_8h.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,211 +0,0 @@ - - - - -incron: appargs.h File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
appargs.h File Reference
-
-
- -

application arguments processor header -More...

-
#include <cstring>
-#include <map>
-#include <deque>
-
-

Go to the source code of this file.

- - - - - - - - - - - - - - - - - - - -

-Classes

struct  AppArgOption_t
 Argument option type. More...
class  AppArgs
 Application arguments. More...

-Defines

#define APPARGS_NOLIMIT   0x7fffffff
 value count has no limit

-Typedefs

typedef std::map< std::string,
-AppArgOption_t * > 
AA_LONG_MAP
 Mapping from long option name to option data.
typedef std::map< char,
-AppArgOption_t * > 
AA_SHORT_MAP
 Mapping from short option name to option data.
typedef std::deque< std::string > AA_VAL_LIST
 Value list type.

-Enumerations

enum  AppArgType_t { AAT_NO_VALUE, -AAT_OPTIONAL_VALUE, -AAT_MANDATORY_VALUE - }
 Option argument type. More...
-

Detailed Description

-

application arguments processor header

-

application arguments processor

-

Copyright (C) 2007, 2008 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can redistribute it and/or modify it under the terms of one of the following licenses:

-
    -
  • 1. X11-style license (see LICENSE-X11)
  • -
  • 2. GNU Lesser General Public License, version 2.1 (see LICENSE-LGPL)
  • -
  • 3. GNU General Public License, version 2 (see LICENSE-GPL)
  • -
-

If you want to help with choosing the best license for you, please visit http://www.gnu.org/licenses/license-list.html.

-

Define Documentation

- -
-
- - - - -
#define APPARGS_NOLIMIT   0x7fffffff
-
-
- -

value count has no limit

- -
-
-

Typedef Documentation

- -
-
- - - - -
typedef std::map<std::string, AppArgOption_t*> AA_LONG_MAP
-
-
- -

Mapping from long option name to option data.

- -
-
- -
-
- - - - -
typedef std::map<char, AppArgOption_t*> AA_SHORT_MAP
-
-
- -

Mapping from short option name to option data.

- -
-
- -
-
- - - - -
typedef std::deque<std::string> AA_VAL_LIST
-
-
- -

Value list type.

- -
-
-

Enumeration Type Documentation

- -
-
- - - - -
enum AppArgType_t
-
-
- -

Option argument type.

-
Enumerator:
- - - -
AAT_NO_VALUE  -

no value needed

-
AAT_OPTIONAL_VALUE  -

optional value

-
AAT_MANDATORY_VALUE  -

mandatory value

-
-
-
- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/appargs_8h_source.html incron-0.5.12/doc/html/appargs_8h_source.html --- incron-0.5.10/doc/html/appargs_8h_source.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/appargs_8h_source.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,168 +0,0 @@ - - - - -incron: appargs.h Source File - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
appargs.h
-
-
-Go to the documentation of this file.
00001 
-00003 
-00023 #ifndef APPARGS_H_
-00024 #define APPARGS_H_
-00025 
-00026 #include <cstring>
-00027 #include <map>
-00028 #include <deque>
-00029 
-00030 
-00031 
-00033 typedef enum
-00034 {
-00035   AAT_NO_VALUE,       
-00036   AAT_OPTIONAL_VALUE, 
-00037   AAT_MANDATORY_VALUE 
-00038 } AppArgType_t;
-00039 
-00040 
-00041 #define APPARGS_NOLIMIT 0x7fffffff ///< value count has no limit
-00042 
-00044 typedef struct
-00045 {
-00046   AppArgType_t type;  
-00047   bool mand;          
-00048   bool found;         
-00049   std::string val;    
-00050   bool hasVal;        
-00051 } AppArgOption_t;
-00052 
-00053 
-00055 typedef std::map<std::string, AppArgOption_t*> AA_LONG_MAP;
-00056 
-00058 typedef std::map<char, AppArgOption_t*> AA_SHORT_MAP;
-00059 
-00061 typedef std::deque<std::string> AA_VAL_LIST;
-00062 
-00063 
-00065 
-00088 class AppArgs
-00089 {
-00090 public:
-00092 
-00096   static void Init(size_t valMinCnt = 0, size_t valMaxCnt = APPARGS_NOLIMIT);
-00097 
-00099 
-00103   static void Destroy();
-00104 
-00106 
-00112   static void Parse(int argc, const char* const* argv);
-00113   
-00115 
-00124   static bool IsValid();
-00125   
-00127 
-00131   static bool ExistsOption(const std::string& rArg);
-00132   
-00134 
-00139   static bool GetOption(const std::string& rArg, std::string& rVal);
-00140 
-00142 
-00153   static bool AddOption(const std::string& rName, char cShort, AppArgType_t type, bool fMandatory);
-00154   
-00156 
-00159   static size_t GetValueCount();
-00160   
-00162 
-00167   static bool GetValue(size_t index, std::string& rVal);
-00168   
-00170 
-00173   static void Dump();  
-00174   
-00175 protected:
-00177 
-00181   static bool IsOption(const char* pchStr);
-00182   
-00184 
-00191   static bool IsLongOption(const char* pchStr);
-00192   
-00194 
-00201   static bool ParseLong(const char* pchStr, std::string& rName, std::string& rVal, bool& rfHasVal);
-00202   
-00204 
-00212   static void ParseShort(const char* pchStr, char& rcName, std::string& rVal, bool& rfHasVal);
-00213 
-00215 
-00220   static void DumpOption(const std::string& rName, char cShort, AppArgOption_t* pOpt);
-00221   
-00222   
-00223 private:
-00224   static size_t s_minCnt;         
-00225   static size_t s_maxCnt;         
-00226 
-00227   static AA_LONG_MAP s_longMap;   
-00228   static AA_SHORT_MAP s_shortMap; 
-00229   static AA_VAL_LIST s_valList;   
-00230   
-00231 };
-00232 
-00233 
-00234 #endif /*APPARGS_H_*/
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/appinst_8cpp.html incron-0.5.12/doc/html/appinst_8cpp.html --- incron-0.5.10/doc/html/appinst_8cpp.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/appinst_8cpp.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,111 +0,0 @@ - - - - -incron: appinst.cpp File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
appinst.cpp File Reference
-
-
- -

Application instance class implementation. -More...

-
#include <fcntl.h>
-#include <unistd.h>
-#include <errno.h>
-#include <signal.h>
-#include <cstdio>
-#include "appinst.h"
-
- - - -

-Defines

#define APPLOCK_PERM   (S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH)
 Lockfile permissions (currently 0644)
-

Detailed Description

-

Application instance class implementation.

-

Copyright (C) 2007, 2008, 2012 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can redistribute it and/or modify it under the terms of one of the following licenses:

-
    -
  • 1. X11-style license (see LICENSE-X11)
  • -
  • 2. GNU Lesser General Public License, version 2.1 (see LICENSE-LGPL)
  • -
  • 3. GNU General Public License, version 2 (see LICENSE-GPL)
  • -
-

If you want to help with choosing the best license for you, please visit http://www.gnu.org/licenses/license-list.html.

-

Credits: Christian Ruppert (new include to build with GCC 4.4+)

-

Define Documentation

- -
-
- - - - -
#define APPLOCK_PERM   (S_IRUSR | S_IWUSR | S_IRGRP | S_IROTH)
-
-
- -

Lockfile permissions (currently 0644)

- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/appinst_8h.html incron-0.5.12/doc/html/appinst_8h.html --- incron-0.5.10/doc/html/appinst_8h.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/appinst_8h.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,111 +0,0 @@ - - - - -incron: appinst.h File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
appinst.h File Reference
-
-
- -

Application instance class header. -More...

-
#include <string>
-
-

Go to the source code of this file.

- - - - - - - - -

-Classes

class  AppInstException
 Exception class. More...
class  AppInstance
 Application instance management class. More...

-Defines

#define APPLOCK_BASEDIR   "/var/run"
-

Detailed Description

-

Application instance class header.

-

Copyright (C) 2007, 2008 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can redistribute it and/or modify it under the terms of one of the following licenses:

-
    -
  • 1. X11-style license (see LICENSE-X11)
  • -
  • 2. GNU Lesser General Public License, version 2.1 (see LICENSE-LGPL)
  • -
  • 3. GNU General Public License, version 2 (see LICENSE-GPL)
  • -
-

If you want to help with choosing the best license for you, please visit http://www.gnu.org/licenses/license-list.html.

-

Define Documentation

- -
-
- - - - -
#define APPLOCK_BASEDIR   "/var/run"
-
-
- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/appinst_8h_source.html incron-0.5.12/doc/html/appinst_8h_source.html --- incron-0.5.10/doc/html/appinst_8h_source.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/appinst_8h_source.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,133 +0,0 @@ - - - - -incron: appinst.h Source File - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
appinst.h
-
-
-Go to the documentation of this file.
00001 
-00003 
-00021 #ifndef APPINST_H_
-00022 #define APPINST_H_
-00023 
-00024 
-00025 #include <string>
-00026 
-00027 
-00028 #define APPLOCK_BASEDIR "/var/run"
-00029 
-00030 
-00032 
-00035 class AppInstException
-00036 {
-00037 public:
-00039 
-00042   AppInstException(int iErr) : m_iErr(iErr) {}
-00043   
-00045 
-00048   inline int GetErrorNumber() const
-00049   {
-00050     return m_iErr;
-00051   }
-00052   
-00053 private:
-00054   int m_iErr; 
-00055     
-00056 };
-00057 
-00059 
-00064 class AppInstance
-00065 {
-00066 public:
-00068 
-00075   AppInstance(const std::string& rName, const std::string& rBase = APPLOCK_BASEDIR);
-00076   
-00078   ~AppInstance();
-00079   
-00081 
-00089   bool Lock();
-00090   
-00092 
-00097   void Unlock();
-00098   
-00100 
-00107   bool Exists() const;
-00108   
-00110 
-00116   bool SendSignal(int iSigNo) const;
-00117   
-00119 
-00124   inline bool Terminate() const
-00125   {
-00126     return SendSignal(SIGTERM);
-00127   }
-00128   
-00129 protected:
-00130   bool DoLock();
-00131   
-00132 private:
-00133   std::string m_path; 
-00134   bool m_fLocked;     
-00135 };
-00136 
-00137 #endif /*APPINST_H_*/
-
-
- - - - - - Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/bc_s.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/bc_s.png differ diff -Nru incron-0.5.10/doc/html/classAppArgs.html incron-0.5.12/doc/html/classAppArgs.html --- incron-0.5.10/doc/html/classAppArgs.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classAppArgs.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,641 +0,0 @@ - - - - -incron: AppArgs Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
- -
- -

Application arguments. - More...

- -

#include <appargs.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Static Public Member Functions

static void Init (size_t valMinCnt=0, size_t valMaxCnt=APPARGS_NOLIMIT)
 Initializes the processor.
static void Destroy ()
 Releases resources allocated by the processor.
static void Parse (int argc, const char *const *argv)
 Parses arguments and builds the appropriate structure.
static bool IsValid ()
 Checks whether the arguments have valid form.
static bool ExistsOption (const std::string &rArg)
 Checks whether an option exists.
static bool GetOption (const std::string &rArg, std::string &rVal)
 Extracts an option value.
static bool AddOption (const std::string &rName, char cShort, AppArgType_t type, bool fMandatory)
 Adds an option.
static size_t GetValueCount ()
 Returns the count of values.
static bool GetValue (size_t index, std::string &rVal)
 Extracts a value.
static void Dump ()
 Dumps information about options and value to STDERR.

-Static Protected Member Functions

static bool IsOption (const char *pchStr)
 Checks whether a string is an option.
static bool IsLongOption (const char *pchStr)
 Checks whether a string is a long option.
static bool ParseLong (const char *pchStr, std::string &rName, std::string &rVal, bool &rfHasVal)
 Parses a string and attempts to treat it as a long option.
static void ParseShort (const char *pchStr, char &rcName, std::string &rVal, bool &rfHasVal)
 Parses a string and attempts to treat it as a short option.
static void DumpOption (const std::string &rName, char cShort, AppArgOption_t *pOpt)
 Dumps an option to STDERR.
-

Detailed Description

-

Application arguments.

-

This class is set-up for processing command line arguments. Then it parses these arguments and builds data which can be queried later.

-

There are two categories of arguments:

-
    -
  • options (a.k.a. switches)
  • -
  • values
  • -
-

Options represent changeable parameters of the application. Values are a kind of input data.

-

Each option has one of the following types:

-
    -
  • no value (two-state logic, e.g. running on foreground/background)
  • -
  • optional value (e.g. for logging: another file than default can be specified)
  • -
  • mandatory value (e.g. custom configuration file)
  • -
-

Each option always have two forms - long one (introcuded by two hyphens, e.g. --edit) and short one (introduced by one hyphen, e.g. -e). These forms are functionally equivalent.

-

Unknown options are silently ignored.

-

Member Function Documentation

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
bool AppArgs::AddOption (const std::string & rName,
char cShort,
AppArgType_t type,
bool fMandatory 
) [static]
-
-
- -

Adds an option.

-

This method is intended to be called between initilization and parsing. It adds an option which may (or must) occur inside the argument vector.

-
Parameters:
- - - - - -
[in]rNamelong option name
[in]cShortshort (one-character) option name
[in]typeargument type
[in]fMandatoryoption is mandatory yes/no
-
-
-
Returns:
true = success, false = failure (e.g. option already exists)
- -
-
- -
-
- - - - - - - -
void AppArgs::Destroy () [static]
-
-
- -

Releases resources allocated by the processor.

-

This method should be called if the argument values are no longer needed.

- -
-
- -
-
- - - - - - - -
void AppArgs::Dump () [static]
-
-
- -

Dumps information about options and value to STDERR.

-
Attention:
This method may be very slow.
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
void AppArgs::DumpOption (const std::string & rName,
char cShort,
AppArgOption_tpOpt 
) [static, protected]
-
-
- -

Dumps an option to STDERR.

-
Parameters:
- - - - -
[in]rNamelong option name
[in]cShortshort option name
[in]pOptoption data
-
-
- -
-
- -
-
- - - - - - - - -
bool AppArgs::ExistsOption (const std::string & rArg) [static]
-
-
- -

Checks whether an option exists.

-
Parameters:
- - -
[in]rArglong option name
-
-
-
Returns:
true = option exists, false = otherwise
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool AppArgs::GetOption (const std::string & rArg,
std::string & rVal 
) [static]
-
-
- -

Extracts an option value.

-
Parameters:
- - - -
[in]rArglong option name
[out]rValoption value
-
-
-
Returns:
true = value extracted, false = option not found or has no value
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool AppArgs::GetValue (size_t index,
std::string & rVal 
) [static]
-
-
- -

Extracts a value.

-
Parameters:
- - - -
[in]indexvalue index
[out]rValextracted value
-
-
-
Returns:
true = value extracted, false = otherwise
- -
-
- -
-
- - - - - - - -
size_t AppArgs::GetValueCount () [static]
-
-
- -

Returns the count of values.

-
Returns:
count of values
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
void AppArgs::Init (size_t valMinCnt = 0,
size_t valMaxCnt = APPARGS_NOLIMIT 
) [static]
-
-
- -

Initializes the processor.

-
Parameters:
- - - -
[in]valMinCntminimum count of values
[in]valMaxCntmaximum number of values (no effect if lower than valMinCnt)
-
-
- -
-
- -
-
- - - - - - - - -
bool AppArgs::IsLongOption (const char * pchStr) [static, protected]
-
-
- -

Checks whether a string is a long option.

-

This methos assumes the string is an option (if not the behavior is undefined).

-
Parameters:
- - -
[in]pchStrtext string
-
-
-
Returns:
true = option, false = otherwise
- -
-
- -
-
- - - - - - - - -
bool AppArgs::IsOption (const char * pchStr) [static, protected]
-
-
- -

Checks whether a string is an option.

-
Parameters:
- - -
[in]pchStrtext string
-
-
-
Returns:
true = option, false = otherwise
- -
-
- -
-
- - - - - - - -
bool AppArgs::IsValid () [static]
-
-
- -

Checks whether the arguments have valid form.

-

Arguments are valid if:

-
    -
  • all mandatory options are present
  • -
  • all options with mandatory values have their values
  • -
  • value count is between its minimum and maximum
  • -
  • there are no unknown options (if unknown options are not accepted)
  • -
-
Returns:
true = arguments valid, false = otherwise
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
void AppArgs::Parse (int argc,
const char *const * argv 
) [static]
-
-
- -

Parses arguments and builds the appropriate structure.

-
Parameters:
- - - -
[in]argcargument count
[in]argvargument vector
-
-
-
Attention:
All errors are silently ignored.
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
bool AppArgs::ParseLong (const char * pchStr,
std::string & rName,
std::string & rVal,
bool & rfHasVal 
) [static, protected]
-
-
- -

Parses a string and attempts to treat it as a long option.

-
Parameters:
- - - - - -
[in]pchStrtext string
[out]rNameoption name
[out]rValvalue string
[out]rfHasValoption has value yes/no
-
-
-
Returns:
true = success, false = failure
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
void AppArgs::ParseShort (const char * pchStr,
char & rcName,
std::string & rVal,
bool & rfHasVal 
) [static, protected]
-
-
- -

Parses a string and attempts to treat it as a short option.

-
Parameters:
- - - - - -
[in]pchStrtext string
[out]rcNameoption name
[out]rValvalue string
[out]rfHasValoption has value yes/no
-
-
-
Attention:
This method assumes the string is a valid short option.
- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classAppArgs-members.html incron-0.5.12/doc/html/classAppArgs-members.html --- incron-0.5.10/doc/html/classAppArgs-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classAppArgs-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,83 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
AppArgs Member List
-
-
-This is the complete list of members for AppArgs, including all inherited members. - - - - - - - - - - - - - - - -
AddOption(const std::string &rName, char cShort, AppArgType_t type, bool fMandatory)AppArgs [static]
Destroy()AppArgs [static]
Dump()AppArgs [static]
DumpOption(const std::string &rName, char cShort, AppArgOption_t *pOpt)AppArgs [protected, static]
ExistsOption(const std::string &rArg)AppArgs [static]
GetOption(const std::string &rArg, std::string &rVal)AppArgs [static]
GetValue(size_t index, std::string &rVal)AppArgs [static]
GetValueCount()AppArgs [static]
Init(size_t valMinCnt=0, size_t valMaxCnt=APPARGS_NOLIMIT)AppArgs [static]
IsLongOption(const char *pchStr)AppArgs [protected, static]
IsOption(const char *pchStr)AppArgs [protected, static]
IsValid()AppArgs [static]
Parse(int argc, const char *const *argv)AppArgs [static]
ParseLong(const char *pchStr, std::string &rName, std::string &rVal, bool &rfHasVal)AppArgs [protected, static]
ParseShort(const char *pchStr, char &rcName, std::string &rVal, bool &rfHasVal)AppArgs [protected, static]
- - - - - - diff -Nru incron-0.5.10/doc/html/classAppInstance.html incron-0.5.12/doc/html/classAppInstance.html --- incron-0.5.10/doc/html/classAppInstance.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classAppInstance.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,284 +0,0 @@ - - - - -incron: AppInstance Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
AppInstance Class Reference
-
-
- -

Application instance management class. - More...

- -

#include <appinst.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - -

-Public Member Functions

 AppInstance (const std::string &rName, const std::string &rBase=APPLOCK_BASEDIR)
 Constructor.
 ~AppInstance ()
 Destructor.
bool Lock ()
 Attempts to lock the instance.
void Unlock ()
 Unlocks the instance.
bool Exists () const
 Checks whether an instance of this application exists.
bool SendSignal (int iSigNo) const
 Sends a signal to an instance of this application.
bool Terminate () const
 Terminates an instance of this application.

-Protected Member Functions

bool DoLock ()
-

Detailed Description

-

Application instance management class.

-

This class is intended for application which require to be running only once (one instance only). It provides some methods for simple locking, signaling etc.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - - - - - - - - - - - -
AppInstance::AppInstance (const std::string & rName,
const std::string & rBase = APPLOCK_BASEDIR 
)
-
-
- -

Constructor.

-
Parameters:
- - - -
[in]rNameapplication name
[in]rBaselockfile base directory
-
-
-
Attention:
If an empty base directory is given it is replaced by the default value.
- -
-
- -
-
- - - - - - - -
AppInstance::~AppInstance ()
-
-
- -

Destructor.

- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
bool AppInstance::DoLock () [protected]
-
-
- -
-
- -
-
- - - - - - - -
bool AppInstance::Exists () const
-
-
- -

Checks whether an instance of this application exists.

-

If this instance has acquired the lockfile the call will be successful. Otherwise it checks for existence of another running instance.

-
Returns:
true = instance exists, false = otherwise
- -
-
- -
-
- - - - - - - -
bool AppInstance::Lock ()
-
-
- -

Attempts to lock the instance.

-

This method attempts to create a lockfile. If the file already exists it checks whether its owner is still living. If it does this method fails. Otherwise it unlinks this file and re-attempts to create it.

-
Returns:
true = instance locked, false = otherwise
- -
-
- -
-
- - - - - - - - -
bool AppInstance::SendSignal (int iSigNo) const
-
-
- -

Sends a signal to an instance of this application.

-

This method doesn't signal the current instance.

-
Parameters:
- - -
[in]iSigNosignal number
-
-
-
Returns:
true = success, false = otherwise
- -
-
- -
-
- - - - - - - -
bool AppInstance::Terminate () const [inline]
-
-
- -

Terminates an instance of this application.

-

This method doesn't terminate the current instance.

-
Returns:
true = success, false = otherwise
- -
-
- -
-
- - - - - - - -
void AppInstance::Unlock ()
-
-
- -

Unlocks the instance.

-

This method removes (unlinks) the appropriate lockfile. If the instance hasn't been locked this method has no effect.

- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classAppInstance-members.html incron-0.5.12/doc/html/classAppInstance-members.html --- incron-0.5.10/doc/html/classAppInstance-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classAppInstance-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,76 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
AppInstance Member List
-
-
-This is the complete list of members for AppInstance, including all inherited members. - - - - - - - - -
AppInstance(const std::string &rName, const std::string &rBase=APPLOCK_BASEDIR)AppInstance
DoLock()AppInstance [protected]
Exists() const AppInstance
Lock()AppInstance
SendSignal(int iSigNo) const AppInstance
Terminate() const AppInstance [inline]
Unlock()AppInstance
~AppInstance()AppInstance
- - - - - - diff -Nru incron-0.5.10/doc/html/classAppInstException.html incron-0.5.12/doc/html/classAppInstException.html --- incron-0.5.10/doc/html/classAppInstException.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classAppInstException.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,136 +0,0 @@ - - - - -incron: AppInstException Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
AppInstException Class Reference
-
-
- -

Exception class. - More...

- -

#include <appinst.h>

- -

List of all members.

- - - - - - -

-Public Member Functions

 AppInstException (int iErr)
 Constructor.
int GetErrorNumber () const
 Returns the error number.
-

Detailed Description

-

Exception class.

-

This class provides information about occurred errors.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - -
AppInstException::AppInstException (int iErr) [inline]
-
-
- -

Constructor.

-
Parameters:
- - -
[in]iErrerror number
-
-
- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
int AppInstException::GetErrorNumber () const [inline]
-
-
- -

Returns the error number.

-
Returns:
error number
- -
-
-
The documentation for this class was generated from the following file: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classAppInstException-members.html incron-0.5.12/doc/html/classAppInstException-members.html --- incron-0.5.10/doc/html/classAppInstException-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classAppInstException-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,70 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
AppInstException Member List
-
-
-This is the complete list of members for AppInstException, including all inherited members. - - -
AppInstException(int iErr)AppInstException [inline]
GetErrorNumber() const AppInstException [inline]
- - - - - - diff -Nru incron-0.5.10/doc/html/classes.html incron-0.5.12/doc/html/classes.html --- incron-0.5.10/doc/html/classes.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classes.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,84 +0,0 @@ - - - - -incron: Class Index - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
Class Index
-
-
-
A | E | I | P | S | U
- - - - - - - - -
  A  
-
  E  
-
IncronTab   
  P  
-
  U  
-
IncronTabEntry   
AppArgOption_t   EventDispatcher   Inotify   ProcData_t   UserTable   
AppArgs   
  I  
-
InotifyEvent   
  S  
-
AppInstance   InotifyException   
AppInstException   IncronCfg   InotifyWatch   StringTokenizer   
-
A | E | I | P | S | U
-
- - - - - - diff -Nru incron-0.5.10/doc/html/classEventDispatcher.html incron-0.5.12/doc/html/classEventDispatcher.html --- incron-0.5.10/doc/html/classEventDispatcher.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classEventDispatcher.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,319 +0,0 @@ - - - - -incron: EventDispatcher Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
EventDispatcher Class Reference
-
-
- -

Event dispatcher class. - More...

- -

#include <usertable.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 EventDispatcher (int iPipeFd, Inotify *pIn, InotifyWatch *pSys, InotifyWatch *pUser)
 Constructor.
 ~EventDispatcher ()
 Destructor.
bool ProcessEvents ()
 Processes events.
void Register (UserTable *pTab)
 Registers an user table.
void Unregister (UserTable *pTab)
 Unregisters an user table.
size_t GetSize () const
 Returns the poll data size.
struct pollfd * GetPollData ()
 Returns the poll data.
void Rebuild ()
 Rebuilds the poll array data.
void Clear ()
 Removes all registered user tables.
-

Detailed Description

-

Event dispatcher class.

-

This class processes events and distributes them as needed.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
EventDispatcher::EventDispatcher (int iPipeFd,
InotifypIn,
InotifyWatchpSys,
InotifyWatchpUser 
)
-
-
- -

Constructor.

-
Parameters:
- - - - - -
[in]iPipeFdpipe descriptor
[in]pIninotify object for table management
[in]pSyswatch for system tables
[in]pUserwatch for user tables
-
-
- -
-
- -
-
- - - - - - - -
EventDispatcher::~EventDispatcher ()
-
-
- -

Destructor.

- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
void EventDispatcher::Clear () [inline]
-
-
- -

Removes all registered user tables.

-

It doesn't cause poll data rebuilding.

- -
-
- -
-
- - - - - - - -
struct pollfd* EventDispatcher::GetPollData () [inline, read]
-
-
- -

Returns the poll data.

-
Returns:
poll data
- -
-
- -
-
- - - - - - - -
size_t EventDispatcher::GetSize () const [inline]
-
-
- -

Returns the poll data size.

-
Returns:
poll data size
- -
-
- -
-
- - - - - - - -
bool EventDispatcher::ProcessEvents ()
-
-
- -

Processes events.

-
Returns:
pipe event occurred yes/no
- -
-
- -
-
- - - - - - - -
void EventDispatcher::Rebuild ()
-
-
- -

Rebuilds the poll array data.

- -
-
- -
-
- - - - - - - - -
void EventDispatcher::Register (UserTablepTab)
-
-
- -

Registers an user table.

-
Parameters:
- - -
[in]pTabuser table
-
-
- -
-
- -
-
- - - - - - - - -
void EventDispatcher::Unregister (UserTablepTab)
-
-
- -

Unregisters an user table.

-
Parameters:
- - -
[in]pTabuser table
-
-
- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classEventDispatcher-members.html incron-0.5.12/doc/html/classEventDispatcher-members.html --- incron-0.5.10/doc/html/classEventDispatcher-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classEventDispatcher-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,77 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
EventDispatcher Member List
-
-
-This is the complete list of members for EventDispatcher, including all inherited members. - - - - - - - - - -
Clear()EventDispatcher [inline]
EventDispatcher(int iPipeFd, Inotify *pIn, InotifyWatch *pSys, InotifyWatch *pUser)EventDispatcher
GetPollData()EventDispatcher [inline]
GetSize() const EventDispatcher [inline]
ProcessEvents()EventDispatcher
Rebuild()EventDispatcher
Register(UserTable *pTab)EventDispatcher
Unregister(UserTable *pTab)EventDispatcher
~EventDispatcher()EventDispatcher
- - - - - - diff -Nru incron-0.5.10/doc/html/classIncronCfg.html incron-0.5.12/doc/html/classIncronCfg.html --- incron-0.5.10/doc/html/classIncronCfg.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classIncronCfg.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,413 +0,0 @@ - - - - -incron: IncronCfg Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
- -
- -

Configuration class. - More...

- -

#include <incroncfg.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - -

-Static Public Member Functions

static void Init ()
 Initializes default configuration values.
static void Load (const std::string &rPath)
 Loads configuration values.
static bool GetValue (const std::string &rKey, std::string &rVal)
 Retrieves a configuration value.
static bool GetValue (const std::string &rKey, int &rVal)
 Retrieves a configuration value.
static bool GetValue (const std::string &rKey, unsigned &rVal)
 Retrieves a configuration value.
static bool GetValue (const std::string &rKey, bool &rVal)
 Retrieves a configuration value.
static std::string BuildPath (const std::string &rPath, const std::string &rName)
 Builds a file path.

-Static Protected Member Functions

static bool ParseLine (const char *s, std::string &rKey, std::string &rVal)
 Parses a line a attempts to get a key and a value.
static bool IsComment (const char *s)
 Checks whether a line is a comment.
-

Detailed Description

-

Configuration class.

-

This class provides access to values loaded from a configuration file (either a explicitly specified one or the default one).

-

Member Function Documentation

- -
-
- - - - - - - - - - - - - - - - - - -
std::string IncronCfg::BuildPath (const std::string & rPath,
const std::string & rName 
) [static]
-
-
- -

Builds a file path.

-

This function composes a path from a base path and a file name.

-
Parameters:
- - - -
[in]rPathbase path
[in]rNamefile name
-
-
-
Returns:
full path
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool IncronCfg::GetValue (const std::string & rKey,
std::string & rVal 
) [static]
-
-
- -

Retrieves a configuration value.

-

This method attempts to find the appropriate configuration value for the given key and stores it into the given variable.

-
Parameters:
- - - -
[in]rKeyvalue key
[out]rValretrieved value
-
-
-
Returns:
true = success, false = failure (invalid key)
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool IncronCfg::GetValue (const std::string & rKey,
int & rVal 
) [static]
-
-
- -

Retrieves a configuration value.

-

This method attempts to find the appropriate configuration value for the given key and stores it into the given variable.

-
Parameters:
- - - -
[in]rKeyvalue key
[out]rValretrieved value
-
-
-
Returns:
true = success, false = failure (invalid key)
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool IncronCfg::GetValue (const std::string & rKey,
unsigned & rVal 
) [static]
-
-
- -

Retrieves a configuration value.

-

This method attempts to find the appropriate configuration value for the given key and stores it into the given variable.

-
Parameters:
- - - -
[in]rKeyvalue key
[out]rValretrieved value
-
-
-
Returns:
true = success, false = failure (invalid key)
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool IncronCfg::GetValue (const std::string & rKey,
bool & rVal 
) [static]
-
-
- -

Retrieves a configuration value.

-

This method attempts to find the appropriate configuration value for the given key and stores it into the given variable.

-
Parameters:
- - - -
[in]rKeyvalue key
[out]rValretrieved value
-
-
-
Returns:
true = success, false = failure (invalid key)
- -
-
- -
-
- - - - - - - -
void IncronCfg::Init () [static]
-
-
- -

Initializes default configuration values.

- -
-
- -
-
- - - - - - - - -
bool IncronCfg::IsComment (const char * s) [static, protected]
-
-
- -

Checks whether a line is a comment.

-
Parameters:
- - -
[in]stext line
-
-
-
Returns:
true = comment, false = otherwise
- -
-
- -
-
- - - - - - - - -
void IncronCfg::Load (const std::string & rPath) [static]
-
-
- -

Loads configuration values.

-

This method attempts to load configuration values from the specified file. If it fails (e.g. the file doesn't exist) the default file is read. As the last resort (for the case the default file can't be loaded) the hard-wired values are used.

-
Parameters:
- - -
[in]rPathconfiguration file path
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
bool IncronCfg::ParseLine (const char * s,
std::string & rKey,
std::string & rVal 
) [static, protected]
-
-
- -

Parses a line a attempts to get a key and a value.

-
Parameters:
- - - - -
[in]stext line
[out]rKeykey
[out]rValvalue
-
-
-
Returns:
true = success, false = failure
- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classIncronCfg-members.html incron-0.5.12/doc/html/classIncronCfg-members.html --- incron-0.5.10/doc/html/classIncronCfg-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classIncronCfg-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,77 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
IncronCfg Member List
-
-
-This is the complete list of members for IncronCfg, including all inherited members. - - - - - - - - - -
BuildPath(const std::string &rPath, const std::string &rName)IncronCfg [static]
GetValue(const std::string &rKey, std::string &rVal)IncronCfg [static]
GetValue(const std::string &rKey, int &rVal)IncronCfg [static]
GetValue(const std::string &rKey, unsigned &rVal)IncronCfg [static]
GetValue(const std::string &rKey, bool &rVal)IncronCfg [static]
Init()IncronCfg [static]
IsComment(const char *s)IncronCfg [protected, static]
Load(const std::string &rPath)IncronCfg [static]
ParseLine(const char *s, std::string &rKey, std::string &rVal)IncronCfg [protected, static]
- - - - - - diff -Nru incron-0.5.10/doc/html/classIncronTabEntry.html incron-0.5.12/doc/html/classIncronTabEntry.html --- incron-0.5.10/doc/html/classIncronTabEntry.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classIncronTabEntry.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,427 +0,0 @@ - - - - -incron: IncronTabEntry Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
- -
- -

Incron table entry class. - More...

- -

#include <incrontab.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 IncronTabEntry ()
 Constructor.
 IncronTabEntry (const std::string &rPath, uint32_t uMask, const std::string &rCmd)
 Constructor.
 ~IncronTabEntry ()
 Destructor.
std::string ToString () const
 Converts the entry to string representation.
const std::string & GetPath () const
 Returns the watch filesystem path.
int32_t GetMask () const
 Returns the event mask.
const std::string & GetCmd () const
 Returns the command string.
bool IsNoLoop () const
 Checks whether this entry has set loop-avoidance.

-Static Public Member Functions

static bool Parse (const std::string &rStr, IncronTabEntry &rEntry)
 Parses a string and attempts to extract entry parameters.
static std::string GetSafePath (const std::string &rPath)
 Add backslashes before spaces in the source path.

-Protected Attributes

std::string m_path
 watch path
uint32_t m_uMask
 event mask
std::string m_cmd
 command string
bool m_fNoLoop
 no loop yes/no
-

Detailed Description

-

Incron table entry class.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - -
IncronTabEntry::IncronTabEntry ()
-
-
- -

Constructor.

-

Creates an empty entry for later use with Parse().

-
See also:
Parse()
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
IncronTabEntry::IncronTabEntry (const std::string & rPath,
uint32_t uMask,
const std::string & rCmd 
)
-
-
- -

Constructor.

-

Creates an entry based on defined parameters.

-
Parameters:
- - - - -
[in]rPathwatched filesystem path
[in]uMaskevent mask
[in]rCmdcommand string
-
-
- -
-
- -
-
- - - - - - - -
IncronTabEntry::~IncronTabEntry () [inline]
-
-
- -

Destructor.

- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
const std::string& IncronTabEntry::GetCmd () const [inline]
-
-
- -

Returns the command string.

-
Returns:
command string
- -
-
- -
-
- - - - - - - -
int32_t IncronTabEntry::GetMask () const [inline]
-
-
- -

Returns the event mask.

-
Returns:
event mask
- -
-
- -
-
- - - - - - - -
const std::string& IncronTabEntry::GetPath () const [inline]
-
-
- -

Returns the watch filesystem path.

-
Returns:
watch path
- -
-
- -
-
- - - - - - - - -
std::string IncronTabEntry::GetSafePath (const std::string & rPath) [static]
-
-
- -

Add backslashes before spaces in the source path.

-

It also adds backslashes before all original backslashes of course.

-

The source string is not modified and a copy is returned instead.

-

This method is intended to be used for paths in user tables.

-
Parameters:
- - -
[in]rPathpath to be modified
-
-
-
Returns:
modified path
- -
-
- -
-
- - - - - - - -
bool IncronTabEntry::IsNoLoop () const [inline]
-
-
- -

Checks whether this entry has set loop-avoidance.

-
Returns:
true = no loop, false = loop allowed
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool IncronTabEntry::Parse (const std::string & rStr,
IncronTabEntryrEntry 
) [static]
-
-
- -

Parses a string and attempts to extract entry parameters.

-
Parameters:
- - - -
[in]rStrparsed string
[out]rEntryparametrized entry
-
-
-
Returns:
true = success, false = failure
- -
-
- -
-
- - - - - - - -
std::string IncronTabEntry::ToString () const
-
-
- -

Converts the entry to string representation.

-

This method creates a string for use in a table file.

-
Returns:
string representation
- -
-
-

Member Data Documentation

- -
-
- - - - -
std::string IncronTabEntry::m_cmd [protected]
-
-
- -

command string

- -
-
- -
-
- - - - -
bool IncronTabEntry::m_fNoLoop [protected]
-
-
- -

no loop yes/no

- -
-
- -
-
- - - - -
std::string IncronTabEntry::m_path [protected]
-
-
- -

watch path

- -
-
- -
-
- - - - -
uint32_t IncronTabEntry::m_uMask [protected]
-
-
- -

event mask

- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classIncronTabEntry-members.html incron-0.5.12/doc/html/classIncronTabEntry-members.html --- incron-0.5.10/doc/html/classIncronTabEntry-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classIncronTabEntry-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,82 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
IncronTabEntry Member List
-
-
-This is the complete list of members for IncronTabEntry, including all inherited members. - - - - - - - - - - - - - - -
GetCmd() const IncronTabEntry [inline]
GetMask() const IncronTabEntry [inline]
GetPath() const IncronTabEntry [inline]
GetSafePath(const std::string &rPath)IncronTabEntry [static]
IncronTabEntry()IncronTabEntry
IncronTabEntry(const std::string &rPath, uint32_t uMask, const std::string &rCmd)IncronTabEntry
IsNoLoop() const IncronTabEntry [inline]
m_cmdIncronTabEntry [protected]
m_fNoLoopIncronTabEntry [protected]
m_pathIncronTabEntry [protected]
m_uMaskIncronTabEntry [protected]
Parse(const std::string &rStr, IncronTabEntry &rEntry)IncronTabEntry [static]
ToString() const IncronTabEntry
~IncronTabEntry()IncronTabEntry [inline]
- - - - - - diff -Nru incron-0.5.10/doc/html/classIncronTab.html incron-0.5.12/doc/html/classIncronTab.html --- incron-0.5.10/doc/html/classIncronTab.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classIncronTab.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,406 +0,0 @@ - - - - -incron: IncronTab Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
- -
- -

Incron table class. - More...

- -

#include <incrontab.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 IncronTab ()
 Constructor.
 ~IncronTab ()
 Destructor.
void Add (const IncronTabEntry &rEntry)
 Add an entry to the table.
void Clear ()
 Removes all entries.
bool IsEmpty () const
 Checks whether the table is empty.
int GetCount () const
 Returns the count of entries.
IncronTabEntryGetEntry (int index)
 Returns an entry.
bool Load (const std::string &rPath)
 Loads the table.
bool Save (const std::string &rPath)
 Saves the table.

-Static Public Member Functions

static bool CheckUser (const std::string &rUser)
 Checks whether an user has permission to use incron.
static std::string GetUserTablePath (const std::string &rUser)
 Composes a path to an user incron table file.
static std::string GetSystemTablePath (const std::string &rName)
 Composes a path to a system incron table file.

-Protected Attributes

std::deque< IncronTabEntrym_tab
 incron table
-

Detailed Description

-

Incron table class.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - -
IncronTab::IncronTab () [inline]
-
-
- -

Constructor.

- -
-
- -
-
- - - - - - - -
IncronTab::~IncronTab () [inline]
-
-
- -

Destructor.

- -
-
-

Member Function Documentation

- -
-
- - - - - - - - -
void IncronTab::Add (const IncronTabEntryrEntry) [inline]
-
-
- -

Add an entry to the table.

-
Parameters:
- - -
[in]rEntrytable entry
-
-
- -
-
- -
-
- - - - - - - - -
bool IncronTab::CheckUser (const std::string & rUser) [static]
-
-
- -

Checks whether an user has permission to use incron.

-
Parameters:
- - -
[in]rUseruser name
-
-
-
Returns:
true = permission OK, false = otherwise
- -
-
- -
-
- - - - - - - -
void IncronTab::Clear () [inline]
-
-
- -

Removes all entries.

- -
-
- -
-
- - - - - - - -
int IncronTab::GetCount () const [inline]
-
-
- -

Returns the count of entries.

-
Returns:
count of entries
- -
-
- -
-
- - - - - - - - -
IncronTabEntry& IncronTab::GetEntry (int index) [inline]
-
-
- -

Returns an entry.

-
Returns:
reference to the entry for the given index
-
Attention:
This method doesn't test index bounds. If you pass an invalid value the program may crash and/or behave unpredictible way!
- -
-
- -
-
- - - - - - - - -
std::string IncronTab::GetSystemTablePath (const std::string & rName) [static]
-
-
- -

Composes a path to a system incron table file.

-
Parameters:
- - -
[in]rNametable name (pseudouser)
-
-
-
Returns:
path to the table file
-
Attention:
No tests (existence, permission etc.) are done.
- -
-
- -
-
- - - - - - - - -
std::string IncronTab::GetUserTablePath (const std::string & rUser) [static]
-
-
- -

Composes a path to an user incron table file.

-
Parameters:
- - -
[in]rUseruser name
-
-
-
Returns:
path to the table file
-
Attention:
No tests (existence, permission etc.) are done.
- -
-
- -
-
- - - - - - - -
bool IncronTab::IsEmpty () const [inline]
-
-
- -

Checks whether the table is empty.

-
Returns:
true = empty, false = otherwise
- -
-
- -
-
- - - - - - - - -
bool IncronTab::Load (const std::string & rPath)
-
-
- -

Loads the table.

-
Parameters:
- - -
[in]rPathpath to a source table file
-
-
-
Returns:
true = success, false = failure
- -
-
- -
-
- - - - - - - - -
bool IncronTab::Save (const std::string & rPath)
-
-
- -

Saves the table.

-
Parameters:
- - -
[in]rPathpath to a destination table file
-
-
-
Returns:
true = success, false = failure
- -
-
-

Member Data Documentation

- -
-
- - - - -
std::deque<IncronTabEntry> IncronTab::m_tab [protected]
-
-
- -

incron table

- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classIncronTab-members.html incron-0.5.12/doc/html/classIncronTab-members.html --- incron-0.5.10/doc/html/classIncronTab-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classIncronTab-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,81 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
IncronTab Member List
-
-
-This is the complete list of members for IncronTab, including all inherited members. - - - - - - - - - - - - - -
Add(const IncronTabEntry &rEntry)IncronTab [inline]
CheckUser(const std::string &rUser)IncronTab [static]
Clear()IncronTab [inline]
GetCount() const IncronTab [inline]
GetEntry(int index)IncronTab [inline]
GetSystemTablePath(const std::string &rName)IncronTab [static]
GetUserTablePath(const std::string &rUser)IncronTab [static]
IncronTab()IncronTab [inline]
IsEmpty() const IncronTab [inline]
Load(const std::string &rPath)IncronTab
m_tabIncronTab [protected]
Save(const std::string &rPath)IncronTab
~IncronTab()IncronTab [inline]
- - - - - - diff -Nru incron-0.5.10/doc/html/classInotifyEvent.html incron-0.5.12/doc/html/classInotifyEvent.html --- incron-0.5.10/doc/html/classInotifyEvent.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classInotifyEvent.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,488 +0,0 @@ - - - - -incron: InotifyEvent Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
InotifyEvent Class Reference
-
-
- -

inotify event class - More...

- -

#include <inotify-cxx.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 InotifyEvent ()
 Constructor.
 InotifyEvent (const struct inotify_event *pEvt, InotifyWatch *pWatch)
 Constructor.
 ~InotifyEvent ()
 Destructor.
int32_t GetDescriptor () const
 Returns the event watch descriptor.
uint32_t GetMask () const
 Returns the event mask.
bool IsType (uint32_t uType) const
 Checks for the event type.
uint32_t GetCookie () const
 Returns the event cookie.
uint32_t GetLength () const
 Returns the event name length.
const std::string & GetName () const
 Returns the event name.
void GetName (std::string &rName) const
 Extracts the event name.
InotifyWatchGetWatch ()
 Returns the source watch.
void DumpTypes (std::string &rStr) const
 Fills the string with all types contained in the event mask.

-Static Public Member Functions

static bool IsType (uint32_t uValue, uint32_t uType)
 Checks a value for the event type.
static uint32_t GetMaskByName (const std::string &rName)
 Finds the appropriate mask for a name.
static void DumpTypes (uint32_t uValue, std::string &rStr)
 Fills the string with all types contained in an event mask value.
-

Detailed Description

-

inotify event class

-

It holds all information about inotify event and provides access to its particular values.

-

This class is not (and is not intended to be) thread-safe and therefore it must not be used concurrently in multiple threads.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - -
InotifyEvent::InotifyEvent () [inline]
-
-
- -

Constructor.

-

Creates a plain event.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
InotifyEvent::InotifyEvent (const struct inotify_event * pEvt,
InotifyWatchpWatch 
) [inline]
-
-
- -

Constructor.

-

Creates an event based on inotify event data. For NULL pointers it works the same way as InotifyEvent().

-
Parameters:
- - - -
[in]pEvtevent data
[in]pWatchinotify watch
-
-
- -
-
- -
-
- - - - - - - -
InotifyEvent::~InotifyEvent () [inline]
-
-
- -

Destructor.

- -
-
-

Member Function Documentation

- -
-
- - - - - - - - - - - - - - - - - - -
void InotifyEvent::DumpTypes (uint32_t uValue,
std::string & rStr 
) [static]
-
-
- -

Fills the string with all types contained in an event mask value.

-
Parameters:
- - - -
[in]uValueevent mask value
[out]rStrdumped event types
-
-
- -
-
- -
-
- - - - - - - - -
void InotifyEvent::DumpTypes (std::string & rStr) const
-
-
- -

Fills the string with all types contained in the event mask.

-
Parameters:
- - -
[out]rStrdumped event types
-
-
- -
-
- -
-
- - - - - - - -
uint32_t InotifyEvent::GetCookie () const [inline]
-
-
- -

Returns the event cookie.

-
Returns:
event cookie
- -
-
- -
-
- - - - - - - -
int32_t InotifyEvent::GetDescriptor () const
-
-
- -

Returns the event watch descriptor.

-
Returns:
watch descriptor
-
See also:
InotifyWatch::GetDescriptor()
- -
-
- -
-
- - - - - - - -
uint32_t InotifyEvent::GetLength () const [inline]
-
-
- -

Returns the event name length.

-
Returns:
event name length
- -
-
- -
-
- - - - - - - -
uint32_t InotifyEvent::GetMask () const [inline]
-
-
- -

Returns the event mask.

-
Returns:
event mask
-
See also:
InotifyWatch::GetMask()
- -
-
- -
-
- - - - - - - - -
uint32_t InotifyEvent::GetMaskByName (const std::string & rName) [static]
-
-
- -

Finds the appropriate mask for a name.

-
Parameters:
- - -
[in]rNamemask name
-
-
-
Returns:
mask for name; 0 on failure
- -
-
- -
-
- - - - - - - -
const std::string& InotifyEvent::GetName () const [inline]
-
-
- -

Returns the event name.

-
Returns:
event name
- -
-
- -
-
- - - - - - - - -
void InotifyEvent::GetName (std::string & rName) const [inline]
-
-
- -

Extracts the event name.

-
Parameters:
- - -
[out]rNameevent name
-
-
- -
-
- -
-
- - - - - - - -
InotifyWatch* InotifyEvent::GetWatch () [inline]
-
-
- -

Returns the source watch.

-
Returns:
source watch
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
static bool InotifyEvent::IsType (uint32_t uValue,
uint32_t uType 
) [inline, static]
-
-
- -

Checks a value for the event type.

-
Parameters:
- - - -
[in]uValuechecked value
[in]uTypetype which is checked for
-
-
-
Returns:
true = the value contains the given type, false = otherwise
- -
-
- -
-
- - - - - - - - -
bool InotifyEvent::IsType (uint32_t uType) const [inline]
-
-
- -

Checks for the event type.

-
Parameters:
- - -
[in]uTypetype which is checked for
-
-
-
Returns:
true = event mask contains the given type, false = otherwise
- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classInotifyEvent-members.html incron-0.5.12/doc/html/classInotifyEvent-members.html --- incron-0.5.10/doc/html/classInotifyEvent-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classInotifyEvent-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,83 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
InotifyEvent Member List
-
-
-This is the complete list of members for InotifyEvent, including all inherited members. - - - - - - - - - - - - - - - -
DumpTypes(uint32_t uValue, std::string &rStr)InotifyEvent [static]
DumpTypes(std::string &rStr) const InotifyEvent
GetCookie() const InotifyEvent [inline]
GetDescriptor() const InotifyEvent
GetLength() const InotifyEvent [inline]
GetMask() const InotifyEvent [inline]
GetMaskByName(const std::string &rName)InotifyEvent [static]
GetName() const InotifyEvent [inline]
GetName(std::string &rName) const InotifyEvent [inline]
GetWatch()InotifyEvent [inline]
InotifyEvent()InotifyEvent [inline]
InotifyEvent(const struct inotify_event *pEvt, InotifyWatch *pWatch)InotifyEvent [inline]
IsType(uint32_t uValue, uint32_t uType)InotifyEvent [inline, static]
IsType(uint32_t uType) const InotifyEvent [inline]
~InotifyEvent()InotifyEvent [inline]
- - - - - - diff -Nru incron-0.5.10/doc/html/classInotifyException.html incron-0.5.12/doc/html/classInotifyException.html --- incron-0.5.10/doc/html/classInotifyException.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classInotifyException.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,253 +0,0 @@ - - - - -incron: InotifyException Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
InotifyException Class Reference
-
-
- -

Class for inotify exceptions. - More...

- -

#include <inotify-cxx.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - -

-Public Member Functions

 InotifyException (const std::string &rMsg="", int iErr=0, void *pSrc=NULL)
 Constructor.
const std::string & GetMessage () const
 Returns the exception message.
int GetErrorNumber () const
 Returns the exception error number.
void * GetSource () const
 Returns the exception source.

-Protected Attributes

std::string m_msg
 message
int m_err
 error number
void * m_pSrc
 source
-

Detailed Description

-

Class for inotify exceptions.

-

This class allows to acquire information about exceptional events. It makes easier to log or display error messages and to identify problematic code locations.

-

Although this class is basically thread-safe it is not intended to be shared between threads.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
InotifyException::InotifyException (const std::string & rMsg = "",
int iErr = 0,
void * pSrc = NULL 
) [inline]
-
-
- -

Constructor.

-
Parameters:
- - - - -
[in]rMsgmessage
[in]iErrerror number (see errno.h)
[in]pSrcsource
-
-
- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
int InotifyException::GetErrorNumber () const [inline]
-
-
- -

Returns the exception error number.

-

If not applicable this value is 0 (zero).

-
Returns:
error number (standardized; see errno.h)
- -
-
- -
-
- - - - - - - -
const std::string& InotifyException::GetMessage () const [inline]
-
-
- -

Returns the exception message.

-
Returns:
message
- -
-
- -
-
- - - - - - - -
void* InotifyException::GetSource () const [inline]
-
-
- -

Returns the exception source.

-
Returns:
source
- -
-
-

Member Data Documentation

- -
-
- - - - -
int InotifyException::m_err [protected]
-
-
- -

error number

- -
-
- -
-
- - - - -
std::string InotifyException::m_msg [protected]
-
-
- -

message

- -
-
- -
-
- - - - -
void* InotifyException::m_pSrc [mutable, protected]
-
-
- -

source

- -
-
-
The documentation for this class was generated from the following file: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classInotifyException-members.html incron-0.5.12/doc/html/classInotifyException-members.html --- incron-0.5.10/doc/html/classInotifyException-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classInotifyException-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,75 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
InotifyException Member List
-
-
-This is the complete list of members for InotifyException, including all inherited members. - - - - - - - -
GetErrorNumber() const InotifyException [inline]
GetMessage() const InotifyException [inline]
GetSource() const InotifyException [inline]
InotifyException(const std::string &rMsg="", int iErr=0, void *pSrc=NULL)InotifyException [inline]
m_errInotifyException [protected]
m_msgInotifyException [protected]
m_pSrcInotifyException [mutable, protected]
- - - - - - diff -Nru incron-0.5.10/doc/html/classInotify.html incron-0.5.12/doc/html/classInotify.html --- incron-0.5.10/doc/html/classInotify.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classInotify.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,989 +0,0 @@ - - - - -incron: Inotify Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
Inotify Class Reference
-
-
- -

inotify class - More...

- -

#include <inotify-cxx.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 Inotify () throw (InotifyException)
 Constructor.
 ~Inotify ()
 Destructor.
void Close ()
 Removes all watches and closes the inotify device.
void Add (InotifyWatch *pWatch) throw (InotifyException)
 Adds a new watch.
void Add (InotifyWatch &rWatch) throw (InotifyException)
 Adds a new watch.
void Remove (InotifyWatch *pWatch) throw (InotifyException)
 Removes a watch.
void Remove (InotifyWatch &rWatch) throw (InotifyException)
 Removes a watch.
void RemoveAll ()
 Removes all watches.
size_t GetWatchCount () const
 Returns the count of watches.
size_t GetEnabledCount () const
 Returns the count of enabled watches.
void WaitForEvents (bool fNoIntr=false) throw (InotifyException)
 Waits for inotify events.
size_t GetEventCount ()
 Returns the count of received and queued events.
bool GetEvent (InotifyEvent *pEvt) throw (InotifyException)
 Extracts a queued inotify event.
bool GetEvent (InotifyEvent &rEvt) throw (InotifyException)
 Extracts a queued inotify event.
bool PeekEvent (InotifyEvent *pEvt) throw (InotifyException)
 Extracts a queued inotify event (without removing).
bool PeekEvent (InotifyEvent &rEvt) throw (InotifyException)
 Extracts a queued inotify event (without removing).
InotifyWatchFindWatch (int iDescriptor)
 Searches for a watch by a watch descriptor.
InotifyWatchFindWatch (const std::string &rPath)
 Searches for a watch by a filesystem path.
int GetDescriptor () const
 Returns the file descriptor.
void SetNonBlock (bool fNonBlock) throw (InotifyException)
 Enables/disables non-blocking mode.
void SetCloseOnExec (bool fClOnEx) throw (InotifyException)
 Enables/disables closing on exec.

-Static Public Member Functions

static uint32_t GetCapability (InotifyCapability_t cap) throw (InotifyException)
 Acquires a particular inotify capability/limit.
static void SetCapability (InotifyCapability_t cap, uint32_t val) throw (InotifyException)
 Modifies a particular inotify capability/limit.
static uint32_t GetMaxEvents () throw (InotifyException)
 Returns the maximum number of events in the kernel queue.
static void SetMaxEvents (uint32_t val) throw (InotifyException)
 Sets the maximum number of events in the kernel queue.
static uint32_t GetMaxInstances () throw (InotifyException)
 Returns the maximum number of inotify instances per process.
static void SetMaxInstances (uint32_t val) throw (InotifyException)
 Sets the maximum number of inotify instances per process.
static uint32_t GetMaxWatches () throw (InotifyException)
 Returns the maximum number of inotify watches per instance.
static void SetMaxWatches (uint32_t val) throw (InotifyException)
 Sets the maximum number of inotify watches per instance.

-Friends

class InotifyWatch
-

Detailed Description

-

inotify class

-

It holds information about the inotify device descriptor and manages the event queue.

-

If the INOTIFY_THREAD_SAFE is defined this class is thread-safe.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - -
Inotify::Inotify () throw (InotifyException)
-
-
- -

Constructor.

-

Creates and initializes an instance of inotify communication object (opens the inotify device).

-
Exceptions:
- - -
InotifyExceptionthrown if inotify isn't available
-
-
- -
-
- -
-
- - - - - - - -
Inotify::~Inotify ()
-
-
- -

Destructor.

-

Calls Close() due to clean-up.

- -
-
-

Member Function Documentation

- -
-
- - - - - - - - -
void Inotify::Add (InotifyWatchpWatch) throw (InotifyException)
-
-
- -

Adds a new watch.

-
Parameters:
- - -
[in]pWatchinotify watch
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if adding failed
-
-
- -
-
- -
-
- - - - - - - - -
void Inotify::Add (InotifyWatchrWatch) throw (InotifyException) [inline]
-
-
- -

Adds a new watch.

-
Parameters:
- - -
[in]rWatchinotify watch
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if adding failed
-
-
- -
-
- -
-
- - - - - - - -
void Inotify::Close ()
-
-
- -

Removes all watches and closes the inotify device.

- -
-
- -
-
- - - - - - - - -
InotifyWatch * Inotify::FindWatch (int iDescriptor)
-
-
- -

Searches for a watch by a watch descriptor.

-

It tries to find a watch by the given descriptor.

-
Parameters:
- - -
[in]iDescriptorwatch descriptor
-
-
-
Returns:
pointer to a watch; NULL if no such watch exists
- -
-
- -
-
- - - - - - - - -
InotifyWatch * Inotify::FindWatch (const std::string & rPath)
-
-
- -

Searches for a watch by a filesystem path.

-

It tries to find a watch by the given filesystem path.

-
Parameters:
- - -
[in]rPathfilesystem path
-
-
-
Returns:
pointer to a watch; NULL if no such watch exists
-
Attention:
The path must be exactly identical to the one used for the searched watch. Be careful about absolute/relative and case-insensitive paths.
- -
-
- -
-
- - - - - - - - -
uint32_t Inotify::GetCapability (InotifyCapability_t cap) throw (InotifyException) [static]
-
-
- -

Acquires a particular inotify capability/limit.

-
Parameters:
- - -
[in]capcapability/limit identifier
-
-
-
Returns:
capability/limit value
-
Exceptions:
- - -
InotifyExceptionthrown if the given value cannot be acquired
-
-
- -
-
- -
-
- - - - - - - -
int Inotify::GetDescriptor () const [inline]
-
-
- -

Returns the file descriptor.

-

The descriptor can be used in standard low-level file functions (poll(), select(), fcntl() etc.).

-
Returns:
valid file descriptor or -1 for inactive object
-
See also:
SetNonBlock()
- -
-
- -
-
- - - - - - - -
size_t Inotify::GetEnabledCount () const [inline]
-
-
- -

Returns the count of enabled watches.

-
Returns:
count of enabled watches
-
See also:
GetWatchCount()
- -
-
- -
-
- - - - - - - - -
bool Inotify::GetEvent (InotifyEventpEvt) throw (InotifyException)
-
-
- -

Extracts a queued inotify event.

-

The extracted event is removed from the queue. If the pointer is NULL it does nothing.

-
Parameters:
- - -
[in,out]pEvtevent object
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if the provided pointer is NULL
-
-
- -
-
- -
-
- - - - - - - - -
bool Inotify::GetEvent (InotifyEventrEvt) throw (InotifyException) [inline]
-
-
- -

Extracts a queued inotify event.

-

The extracted event is removed from the queue.

-
Parameters:
- - -
[in,out]rEvtevent object
-
-
-
Exceptions:
- - -
InotifyExceptionthrown only in very anomalous cases
-
-
- -
-
- -
-
- - - - - - - -
size_t Inotify::GetEventCount () [inline]
-
-
- -

Returns the count of received and queued events.

-

This number is related to the events in the queue inside this object, not to the events pending in the kernel.

-
Returns:
count of events
- -
-
- -
-
- - - - - - - -
static uint32_t Inotify::GetMaxEvents () throw (InotifyException) [inline, static]
-
-
- -

Returns the maximum number of events in the kernel queue.

-
Returns:
maximum number of events in the kernel queue
-
Exceptions:
- - -
InotifyExceptionthrown if the given value cannot be acquired
-
-
- -
-
- -
-
- - - - - - - -
static uint32_t Inotify::GetMaxInstances () throw (InotifyException) [inline, static]
-
-
- -

Returns the maximum number of inotify instances per process.

-

It means the maximum number of open inotify file descriptors per running process.

-
Returns:
maximum number of inotify instances
-
Exceptions:
- - -
InotifyExceptionthrown if the given value cannot be acquired
-
-
- -
-
- -
-
- - - - - - - -
static uint32_t Inotify::GetMaxWatches () throw (InotifyException) [inline, static]
-
-
- -

Returns the maximum number of inotify watches per instance.

-

It means the maximum number of inotify watches per inotify file descriptor.

-
Returns:
maximum number of inotify watches
-
Exceptions:
- - -
InotifyExceptionthrown if the given value cannot be acquired
-
-
- -
-
- -
-
- - - - - - - -
size_t Inotify::GetWatchCount () const [inline]
-
-
- -

Returns the count of watches.

-

This is the total count of all watches (regardless whether enabled or not).

-
Returns:
count of watches
-
See also:
GetEnabledCount()
- -
-
- -
-
- - - - - - - - -
bool Inotify::PeekEvent (InotifyEventpEvt) throw (InotifyException)
-
-
- -

Extracts a queued inotify event (without removing).

-

The extracted event stays in the queue. If the pointer is NULL it does nothing.

-
Parameters:
- - -
[in,out]pEvtevent object
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if the provided pointer is NULL
-
-
- -
-
- -
-
- - - - - - - - -
bool Inotify::PeekEvent (InotifyEventrEvt) throw (InotifyException) [inline]
-
-
- -

Extracts a queued inotify event (without removing).

-

The extracted event stays in the queue.

-
Parameters:
- - -
[in,out]rEvtevent object
-
-
-
Exceptions:
- - -
InotifyExceptionthrown only in very anomalous cases
-
-
- -
-
- -
-
- - - - - - - - -
void Inotify::Remove (InotifyWatchpWatch) throw (InotifyException)
-
-
- -

Removes a watch.

-

If the given watch is not present it does nothing.

-
Parameters:
- - -
[in]pWatchinotify watch
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if removing failed
-
-
- -
-
- -
-
- - - - - - - - -
void Inotify::Remove (InotifyWatchrWatch) throw (InotifyException) [inline]
-
-
- -

Removes a watch.

-

If the given watch is not present it does nothing.

-
Parameters:
- - -
[in]rWatchinotify watch
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if removing failed
-
-
- -
-
- -
-
- - - - - - - -
void Inotify::RemoveAll ()
-
-
- -

Removes all watches.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
void Inotify::SetCapability (InotifyCapability_t cap,
uint32_t val 
) throw (InotifyException) [static]
-
-
- -

Modifies a particular inotify capability/limit.

-
Parameters:
- - - -
[in]capcapability/limit identifier
[in]valnew capability/limit value
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if the given value cannot be set
-
-
-
Attention:
Using this function requires root privileges. Beware of setting extensive values - it may seriously affect system performance and/or stability.
- -
-
- -
-
- - - - - - - - -
void Inotify::SetCloseOnExec (bool fClOnEx) throw (InotifyException)
-
-
- -

Enables/disables closing on exec.

-

Enable this if you want to close the descriptor when executing another program. Otherwise, the descriptor will be inherited.

-

Closing on exec is disabled by default.

-
Parameters:
- - -
[in]fClOnExenable/disable closing on exec
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if setting failed
-
-
-
See also:
GetDescriptor(), SetNonBlock()
- -
-
- -
-
- - - - - - - - -
static void Inotify::SetMaxEvents (uint32_t val) throw (InotifyException) [inline, static]
-
-
- -

Sets the maximum number of events in the kernel queue.

-
Parameters:
- - -
[in]valnew value
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if the given value cannot be set
-
-
-
Attention:
Using this function requires root privileges. Beware of setting extensive values - the greater value is set here the more physical memory may be used for the inotify infrastructure.
- -
-
- -
-
- - - - - - - - -
static void Inotify::SetMaxInstances (uint32_t val) throw (InotifyException) [inline, static]
-
-
- -

Sets the maximum number of inotify instances per process.

-
Parameters:
- - -
[in]valnew value
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if the given value cannot be set
-
-
-
Attention:
Using this function requires root privileges. Beware of setting extensive values - the greater value is set here the more physical memory may be used for the inotify infrastructure.
- -
-
- -
-
- - - - - - - - -
static void Inotify::SetMaxWatches (uint32_t val) throw (InotifyException) [inline, static]
-
-
- -

Sets the maximum number of inotify watches per instance.

-
Parameters:
- - -
[in]valnew value
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if the given value cannot be set
-
-
-
Attention:
Using this function requires root privileges. Beware of setting extensive values - the greater value is set here the more physical memory may be used for the inotify infrastructure.
- -
-
- -
-
- - - - - - - - -
void Inotify::SetNonBlock (bool fNonBlock) throw (InotifyException)
-
-
- -

Enables/disables non-blocking mode.

-

Use this mode if you want to monitor the descriptor (acquired thru GetDescriptor()) in functions such as poll(), select() etc.

-

Non-blocking mode is disabled by default.

-
Parameters:
- - -
[in]fNonBlockenable/disable non-blocking mode
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if setting mode failed
-
-
-
See also:
GetDescriptor(), SetCloseOnExec()
- -
-
- -
-
- - - - - - - - -
void Inotify::WaitForEvents (bool fNoIntr = false) throw (InotifyException)
-
-
- -

Waits for inotify events.

-

It waits until one or more events occur. When called in nonblocking mode it only retrieves occurred events to the internal queue and exits.

-
Parameters:
- - -
[in]fNoIntrif true it re-calls the system call after a handled signal
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if reading events failed
-
-
-
See also:
SetNonBlock()
- -
-
-

Friends And Related Function Documentation

- -
-
- - - - -
friend class InotifyWatch [friend]
-
-
- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classInotify-members.html incron-0.5.12/doc/html/classInotify-members.html --- incron-0.5.10/doc/html/classInotify-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classInotify-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,98 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
Inotify Member List
-
-
-This is the complete list of members for Inotify, including all inherited members. - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
Add(InotifyWatch *pWatch)Inotify
Add(InotifyWatch &rWatch)Inotify [inline]
Close()Inotify
FindWatch(int iDescriptor)Inotify
FindWatch(const std::string &rPath)Inotify
GetCapability(InotifyCapability_t cap)Inotify [static]
GetDescriptor() const Inotify [inline]
GetEnabledCount() const Inotify [inline]
GetEvent(InotifyEvent *pEvt)Inotify
GetEvent(InotifyEvent &rEvt)Inotify [inline]
GetEventCount()Inotify [inline]
GetMaxEvents()Inotify [inline, static]
GetMaxInstances()Inotify [inline, static]
GetMaxWatches()Inotify [inline, static]
GetWatchCount() const Inotify [inline]
Inotify()Inotify
InotifyWatch classInotify [friend]
PeekEvent(InotifyEvent *pEvt)Inotify
PeekEvent(InotifyEvent &rEvt)Inotify [inline]
Remove(InotifyWatch *pWatch)Inotify
Remove(InotifyWatch &rWatch)Inotify [inline]
RemoveAll()Inotify
SetCapability(InotifyCapability_t cap, uint32_t val)Inotify [static]
SetCloseOnExec(bool fClOnEx)Inotify
SetMaxEvents(uint32_t val)Inotify [inline, static]
SetMaxInstances(uint32_t val)Inotify [inline, static]
SetMaxWatches(uint32_t val)Inotify [inline, static]
SetNonBlock(bool fNonBlock)Inotify
WaitForEvents(bool fNoIntr=false)Inotify
~Inotify()Inotify
- - - - - - diff -Nru incron-0.5.10/doc/html/classInotifyWatch.html incron-0.5.12/doc/html/classInotifyWatch.html --- incron-0.5.10/doc/html/classInotifyWatch.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classInotifyWatch.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,371 +0,0 @@ - - - - -incron: InotifyWatch Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
InotifyWatch Class Reference
-
-
- -

inotify watch class - More...

- -

#include <inotify-cxx.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 InotifyWatch (const std::string &rPath, int32_t uMask, bool fEnabled=true)
 Constructor.
 ~InotifyWatch ()
 Destructor.
int32_t GetDescriptor () const
 Returns the watch descriptor.
const std::string & GetPath () const
 Returns the watched file path.
uint32_t GetMask () const
 Returns the watch event mask.
void SetMask (uint32_t uMask) throw (InotifyException)
 Sets the watch event mask.
InotifyGetInotify ()
 Returns the appropriate inotify class instance.
void SetEnabled (bool fEnabled) throw (InotifyException)
 Enables/disables the watch.
bool IsEnabled () const
 Checks whether the watch is enabled.
bool IsRecursive () const
 Checks whether the watch is recursive.

-Friends

class Inotify
-

Detailed Description

-

inotify watch class

-

It holds information about the inotify watch on a particular inode.

-

If the INOTIFY_THREAD_SAFE is defined this class is thread-safe.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
InotifyWatch::InotifyWatch (const std::string & rPath,
int32_t uMask,
bool fEnabled = true 
) [inline]
-
-
- -

Constructor.

-

Creates an inotify watch. Because this watch is inactive it has an invalid descriptor (-1).

-
Parameters:
- - - - -
[in]rPathwatched file path
[in]uMaskmask for events
[in]fEnabledevents enabled yes/no
-
-
- -
-
- -
-
- - - - - - - -
InotifyWatch::~InotifyWatch () [inline]
-
-
- -

Destructor.

- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
int32_t InotifyWatch::GetDescriptor () const [inline]
-
-
- -

Returns the watch descriptor.

-
Returns:
watch descriptor; -1 for inactive watch
- -
-
- -
-
- - - - - - - -
Inotify* InotifyWatch::GetInotify () [inline]
-
-
- -

Returns the appropriate inotify class instance.

-
Returns:
inotify instance
- -
-
- -
-
- - - - - - - -
uint32_t InotifyWatch::GetMask () const [inline]
-
-
- -

Returns the watch event mask.

-
Returns:
event mask
- -
-
- -
-
- - - - - - - -
const std::string& InotifyWatch::GetPath () const [inline]
-
-
- -

Returns the watched file path.

-
Returns:
file path
- -
-
- -
-
- - - - - - - -
bool InotifyWatch::IsEnabled () const [inline]
-
-
- -

Checks whether the watch is enabled.

-
Returns:
true = enables, false = disabled
- -
-
- -
-
- - - - - - - -
bool InotifyWatch::IsRecursive () const [inline]
-
-
- -

Checks whether the watch is recursive.

-

A recursive watch monitors a directory itself and all its subdirectories. This watch is a logical object which may have many underlying kernel watches.

-
Returns:
currently always false (recursive watches not yet supported)
-
Attention:
Recursive watches are currently NOT supported. They are planned for future versions.
- -
-
- -
-
- - - - - - - - -
void InotifyWatch::SetEnabled (bool fEnabled) throw (InotifyException)
-
-
- -

Enables/disables the watch.

-

If the watch is active (added to an instance of Inotify) this method may fail due to unsuccessful re-setting the watch in the kernel.

-

Re-setting the current state has no effect.

-
Parameters:
- - -
[in]fEnabledset enabled yes/no
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if enabling/disabling fails
-
-
- -
-
- -
-
- - - - - - - - -
void InotifyWatch::SetMask (uint32_t uMask) throw (InotifyException)
-
-
- -

Sets the watch event mask.

-

If the watch is active (added to an instance of Inotify) this method may fail due to unsuccessful re-setting the watch in the kernel.

-
Parameters:
- - -
[in]uMaskevent mask
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if changing fails
-
-
- -
-
-

Friends And Related Function Documentation

- -
-
- - - - -
friend class Inotify [friend]
-
-
- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classInotifyWatch-members.html incron-0.5.12/doc/html/classInotifyWatch-members.html --- incron-0.5.10/doc/html/classInotifyWatch-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classInotifyWatch-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,79 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
InotifyWatch Member List
-
-
-This is the complete list of members for InotifyWatch, including all inherited members. - - - - - - - - - - - -
GetDescriptor() const InotifyWatch [inline]
GetInotify()InotifyWatch [inline]
GetMask() const InotifyWatch [inline]
GetPath() const InotifyWatch [inline]
Inotify classInotifyWatch [friend]
InotifyWatch(const std::string &rPath, int32_t uMask, bool fEnabled=true)InotifyWatch [inline]
IsEnabled() const InotifyWatch [inline]
IsRecursive() const InotifyWatch [inline]
SetEnabled(bool fEnabled)InotifyWatch
SetMask(uint32_t uMask)InotifyWatch
~InotifyWatch()InotifyWatch [inline]
- - - - - - diff -Nru incron-0.5.10/doc/html/classStringTokenizer.html incron-0.5.12/doc/html/classStringTokenizer.html --- incron-0.5.10/doc/html/classStringTokenizer.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classStringTokenizer.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,407 +0,0 @@ - - - - -incron: StringTokenizer Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
StringTokenizer Class Reference
-
-
- -

Simple string tokenizer class. - More...

- -

#include <strtok.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 StringTokenizer (const std::string &rStr, char cDelim= ',', char cPrefix= '\0')
 Constructor.
 ~StringTokenizer ()
 Destructor.
bool HasMoreTokens () const
 Checks whether the tokenizer can provide more tokens.
std::string GetNextToken (bool fSkipEmpty=false)
 Returns the next token.
std::string GetNextTokenRaw (bool fSkipEmpty=false)
 Returns the next token.
std::string GetRemainder ()
 Returns the remainder of the source string.
void SetDelimiter (char cDelim)
 Sets a delimiter (separator) character.
char GetDelimiter () const
 Returns the delimiter (separator) character.
void SetPrefix (char cPrefix)
 Sets a prefix character.
char GetPrefix () const
 Returns the prefix character.
void SetNoPrefix ()
 Sets the prefix to 'no prefix'.
void Reset ()
 Resets the tokenizer.
-

Detailed Description

-

Simple string tokenizer class.

-

This class implements a string tokenizer. It splits a string by a character to a number of elements (tokens) which are provided sequentially.

-

All operations are made on a copy of the original string (which may be in fact a copy-on-write instance).

-

The original string is left unchanged. All tokens are returned as newly created strings.

-

There is possibility to specify a prefix character which causes the consecutive character is not considered as a delimiter. If you don't specify this character (or specify the NUL character, 0x00) this feature is disabled. The mostly used prefix is a backslash ('\').

-

This class is not thread-safe.

-

Performance note: This class is currently not intended to be very fast. Speed optimizations will be done later.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
StringTokenizer::StringTokenizer (const std::string & rStr,
char cDelim = ',',
char cPrefix = '\0' 
)
-
-
- -

Constructor.

-

Creates a ready-to-use tokenizer.

-
Parameters:
- - - - -
[in]rStrstring for tokenizing
[in]cDelimdelimiter (separator) character
[in]cPrefixcharacter which is prepended if a character must not separate tokens
-
-
- -
-
- -
-
- - - - - - - -
StringTokenizer::~StringTokenizer () [inline]
-
-
- -

Destructor.

- -
-
-

Member Function Documentation

- -
-
- - - - - - - -
char StringTokenizer::GetDelimiter () const [inline]
-
-
- -

Returns the delimiter (separator) character.

-
Returns:
delimiter character
- -
-
- -
-
- - - - - - - - -
std::string StringTokenizer::GetNextToken (bool fSkipEmpty = false)
-
-
- -

Returns the next token.

-

If a prefix is defined it is stripped from the returned string (e.g. 'abc\ def' is transformed to 'abc def' while the prefix is '\').

-
Parameters:
- - -
[in]fSkipEmptyskip empty strings (more consecutive delimiters)
-
-
-
Returns:
next token or "" if no more tokens available
-
See also:
GetNextTokenRaw()
- -
-
- -
-
- - - - - - - - -
std::string StringTokenizer::GetNextTokenRaw (bool fSkipEmpty = false)
-
-
- -

Returns the next token.

-

This method always returns an unmodified string even if it contains prefix characters.

-
Parameters:
- - -
[in]fSkipEmptyskip empty strings (more consecutive delimiters)
-
-
-
Returns:
next token or "" if no more tokens available
-
See also:
GetNextToken()
- -
-
- -
-
- - - - - - - -
char StringTokenizer::GetPrefix () const [inline]
-
-
- -

Returns the prefix character.

-
Returns:
prefix character
- -
-
- -
-
- - - - - - - -
std::string StringTokenizer::GetRemainder ()
-
-
- -

Returns the remainder of the source string.

-

This method returns everything what has not been processed (tokenized) yet and moves the current position to the end of the string.

-

If a prefix is defined it is stripped from the returned string.

-
Returns:
remainder string
- -
-
- -
-
- - - - - - - -
bool StringTokenizer::HasMoreTokens () const [inline]
-
-
- -

Checks whether the tokenizer can provide more tokens.

-
Returns:
true = more tokens available, false = otherwise
- -
-
- -
-
- - - - - - - -
void StringTokenizer::Reset () [inline]
-
-
- -

Resets the tokenizer.

-

Re-initializes tokenizing to the start of the string.

- -
-
- -
-
- - - - - - - - -
void StringTokenizer::SetDelimiter (char cDelim) [inline]
-
-
- -

Sets a delimiter (separator) character.

-

The new delimiter has effect only to tokens returned later; the position in the string is not affected.

-

If you specify a NUL character (0x00) here the prefix will not be used.

-
Parameters:
- - -
[in]cDelimdelimiter character
-
-
- -
-
- -
-
- - - - - - - -
void StringTokenizer::SetNoPrefix () [inline]
-
-
- -

Sets the prefix to 'no prefix'.

-

Calling this method is equivalent to SetPrefix((char) 0).

-
See also:
SetPrefix()
- -
-
- -
-
- - - - - - - - -
void StringTokenizer::SetPrefix (char cPrefix) [inline]
-
-
- -

Sets a prefix character.

-

The new prefix has effect only to tokens returned later; the position in the string is not affected.

-
Parameters:
- - -
[in]cPrefixprefix character
-
-
-
See also:
SetNoPrefix()
- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classStringTokenizer-members.html incron-0.5.12/doc/html/classStringTokenizer-members.html --- incron-0.5.10/doc/html/classStringTokenizer-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classStringTokenizer-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,80 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
StringTokenizer Member List
-
-
-This is the complete list of members for StringTokenizer, including all inherited members. - - - - - - - - - - - - -
GetDelimiter() const StringTokenizer [inline]
GetNextToken(bool fSkipEmpty=false)StringTokenizer
GetNextTokenRaw(bool fSkipEmpty=false)StringTokenizer
GetPrefix() const StringTokenizer [inline]
GetRemainder()StringTokenizer
HasMoreTokens() const StringTokenizer [inline]
Reset()StringTokenizer [inline]
SetDelimiter(char cDelim)StringTokenizer [inline]
SetNoPrefix()StringTokenizer [inline]
SetPrefix(char cPrefix)StringTokenizer [inline]
StringTokenizer(const std::string &rStr, char cDelim= ',', char cPrefix= '\0')StringTokenizer
~StringTokenizer()StringTokenizer [inline]
- - - - - - diff -Nru incron-0.5.10/doc/html/classUserTable.html incron-0.5.12/doc/html/classUserTable.html --- incron-0.5.10/doc/html/classUserTable.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classUserTable.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,381 +0,0 @@ - - - - -incron: UserTable Class Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
UserTable Class Reference
-
-
- -

User table class. - More...

- -

#include <usertable.h>

- -

List of all members.

- - - - - - - - - - - - - - - - - - - - - - - - - -

-Public Member Functions

 UserTable (EventDispatcher *pEd, const std::string &rUser, bool fSysTable)
 Constructor.
virtual ~UserTable ()
 Destructor.
void Load ()
 Loads the table.
void Dispose ()
 Removes all entries from the table.
void OnEvent (InotifyEvent &rEvt)
 Processes an inotify event.
bool MayAccess (const std::string &rPath, bool fNoFollow) const
 Checks whether the user may access a file.
bool IsSystem () const
 Checks whether it is a system table.
InotifyGetInotify ()
 Returns the related inotify object.
void RunAsUser (char *const *argv) const
 Runs a program as the table's user.

-Static Public Member Functions

static void FinishDone ()
 Cleans-up all zombie child processes and enables disabled watches.
static bool CheckUser (const char *user)
 Checks whether an user exists and has permission to use incron.
-

Detailed Description

-

User table class.

-

This class processes inotify events for an user. It creates child processes which do appropriate actions as defined in the user table file.

-

Constructor & Destructor Documentation

- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
UserTable::UserTable (EventDispatcherpEd,
const std::string & rUser,
bool fSysTable 
)
-
-
- -

Constructor.

-
Parameters:
- - - - -
[in]pEdevent dispatcher
[in]rUseruser name
[in]fSysTablesystem table yes/no
-
-
- -
-
- -
-
- - - - - - - -
UserTable::~UserTable () [virtual]
-
-
- -

Destructor.

- -
-
-

Member Function Documentation

- -
-
- - - - - - - - -
static bool UserTable::CheckUser (const char * user) [inline, static]
-
-
- -

Checks whether an user exists and has permission to use incron.

-

It searches for the given user name in the user database. If it failes it returns 'false'. Otherwise it checks permission files for this user (see InCronTab::CheckUser()).

-
Parameters:
- - -
[in]useruser name
-
-
-
Returns:
true = user has permission to use incron, false = otherwise
-
See also:
InCronTab::CheckUser()
- -
-
- -
-
- - - - - - - -
void UserTable::Dispose ()
-
-
- -

Removes all entries from the table.

-

All entries are unregistered from the event dispatcher and their watches are destroyed.

- -
-
- -
-
- - - - - - - -
void UserTable::FinishDone () [static]
-
-
- -

Cleans-up all zombie child processes and enables disabled watches.

-
Attention:
This method must be called AFTER processing all events which has been caused by the processes.
- -
-
- -
-
- - - - - - - -
Inotify* UserTable::GetInotify () [inline]
-
-
- -

Returns the related inotify object.

-
Returns:
related inotify object
- -
-
- -
-
- - - - - - - -
bool UserTable::IsSystem () const
-
-
- -

Checks whether it is a system table.

-
Returns:
true = system table, false = user table
- -
-
- -
-
- - - - - - - -
void UserTable::Load ()
-
-
- -

Loads the table.

-

All loaded entries have their inotify watches and are registered for event dispatching. If loading fails the table remains empty.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
bool UserTable::MayAccess (const std::string & rPath,
bool fNoFollow 
) const
-
-
- -

Checks whether the user may access a file.

-

Any access right (RWX) is sufficient.

-
Parameters:
- - - -
[in]rPathabsolute file path
[in]fNoFollowdon't follow a symbolic link
-
-
-
Returns:
true = access granted, false = otherwise
- -
-
- -
-
- - - - - - - - -
void UserTable::OnEvent (InotifyEventrEvt)
-
-
- -

Processes an inotify event.

-
Parameters:
- - -
[in]rEvtinotify event
-
-
- -
-
- -
-
- - - - - - - - -
void UserTable::RunAsUser (char *const * argv) const
-
-
- -

Runs a program as the table's user.

-
Attention:
Don't call from the main process (before forking)!
- -
-
-
The documentation for this class was generated from the following files: -
- - - - - - diff -Nru incron-0.5.10/doc/html/classUserTable-members.html incron-0.5.12/doc/html/classUserTable-members.html --- incron-0.5.10/doc/html/classUserTable-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/classUserTable-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,79 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
UserTable Member List
-
-
-This is the complete list of members for UserTable, including all inherited members. - - - - - - - - - - - -
CheckUser(const char *user)UserTable [inline, static]
Dispose()UserTable
FinishDone()UserTable [static]
GetInotify()UserTable [inline]
IsSystem() const UserTable
Load()UserTable
MayAccess(const std::string &rPath, bool fNoFollow) const UserTable
OnEvent(InotifyEvent &rEvt)UserTable
RunAsUser(char *const *argv) const UserTable
UserTable(EventDispatcher *pEd, const std::string &rUser, bool fSysTable)UserTable
~UserTable()UserTable [virtual]
- - - - - - Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/closed.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/closed.png differ diff -Nru incron-0.5.10/doc/html/doxygen.css incron-0.5.12/doc/html/doxygen.css --- incron-0.5.10/doc/html/doxygen.css 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/doxygen.css 1970-01-01 00:00:00.000000000 +0000 @@ -1,946 +0,0 @@ -/* The standard CSS for doxygen */ - -body, table, div, p, dl { - font-family: Lucida Grande, Verdana, Geneva, Arial, sans-serif; - font-size: 12px; -} - -/* @group Heading Levels */ - -h1 { - font-size: 150%; -} - -.title { - font-size: 150%; - font-weight: bold; - margin: 10px 2px; -} - -h2 { - font-size: 120%; -} - -h3 { - font-size: 100%; -} - -dt { - font-weight: bold; -} - -div.multicol { - -moz-column-gap: 1em; - -webkit-column-gap: 1em; - -moz-column-count: 3; - -webkit-column-count: 3; -} - -p.startli, p.startdd, p.starttd { - margin-top: 2px; -} - -p.endli { - margin-bottom: 0px; -} - -p.enddd { - margin-bottom: 4px; -} - -p.endtd { - margin-bottom: 2px; -} - -/* @end */ - -caption { - font-weight: bold; -} - -span.legend { - font-size: 70%; - text-align: center; -} - -h3.version { - font-size: 90%; - text-align: center; -} - -div.qindex, div.navtab{ - background-color: #EBEFF6; - border: 1px solid #A3B4D7; - text-align: center; -} - -div.qindex, div.navpath { - width: 100%; - line-height: 140%; -} - -div.navtab { - margin-right: 15px; -} - -/* @group Link Styling */ - -a { - color: #3D578C; - font-weight: normal; - text-decoration: none; -} - -.contents a:visited { - color: #4665A2; -} - -a:hover { - text-decoration: underline; -} - -a.qindex { - font-weight: bold; -} - -a.qindexHL { - font-weight: bold; - background-color: #9CAFD4; - color: #ffffff; - border: 1px double #869DCA; -} - -.contents a.qindexHL:visited { - color: #ffffff; -} - -a.el { - font-weight: bold; -} - -a.elRef { -} - -a.code { - color: #4665A2; -} - -a.codeRef { - color: #4665A2; -} - -/* @end */ - -dl.el { - margin-left: -1cm; -} - -.fragment { - font-family: monospace, fixed; - font-size: 105%; -} - -pre.fragment { - border: 1px solid #C4CFE5; - background-color: #FBFCFD; - padding: 4px 6px; - margin: 4px 8px 4px 2px; - overflow: auto; - word-wrap: break-word; - font-size: 9pt; - line-height: 125%; -} - -div.ah { - background-color: black; - font-weight: bold; - color: #ffffff; - margin-bottom: 3px; - margin-top: 3px; - padding: 0.2em; - border: solid thin #333; - border-radius: 0.5em; - -webkit-border-radius: .5em; - -moz-border-radius: .5em; - box-shadow: 2px 2px 3px #999; - -webkit-box-shadow: 2px 2px 3px #999; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; - background-image: -webkit-gradient(linear, left top, left bottom, from(#eee), to(#000),color-stop(0.3, #444)); - background-image: -moz-linear-gradient(center top, #eee 0%, #444 40%, #000); -} - -div.groupHeader { - margin-left: 16px; - margin-top: 12px; - font-weight: bold; -} - -div.groupText { - margin-left: 16px; - font-style: italic; -} - -body { - background-color: white; - color: black; - margin: 0; -} - -div.contents { - margin-top: 10px; - margin-left: 8px; - margin-right: 8px; -} - -td.indexkey { - background-color: #EBEFF6; - font-weight: bold; - border: 1px solid #C4CFE5; - margin: 2px 0px 2px 0; - padding: 2px 10px; -} - -td.indexvalue { - background-color: #EBEFF6; - border: 1px solid #C4CFE5; - padding: 2px 10px; - margin: 2px 0px; -} - -tr.memlist { - background-color: #EEF1F7; -} - -p.formulaDsp { - text-align: center; -} - -img.formulaDsp { - -} - -img.formulaInl { - vertical-align: middle; -} - -div.center { - text-align: center; - margin-top: 0px; - margin-bottom: 0px; - padding: 0px; -} - -div.center img { - border: 0px; -} - -address.footer { - text-align: right; - padding-right: 12px; -} - -img.footer { - border: 0px; - vertical-align: middle; -} - -/* @group Code Colorization */ - -span.keyword { - color: #008000 -} - -span.keywordtype { - color: #604020 -} - -span.keywordflow { - color: #e08000 -} - -span.comment { - color: #800000 -} - -span.preprocessor { - color: #806020 -} - -span.stringliteral { - color: #002080 -} - -span.charliteral { - color: #008080 -} - -span.vhdldigit { - color: #ff00ff -} - -span.vhdlchar { - color: #000000 -} - -span.vhdlkeyword { - color: #700070 -} - -span.vhdllogic { - color: #ff0000 -} - -/* @end */ - -/* -.search { - color: #003399; - font-weight: bold; -} - -form.search { - margin-bottom: 0px; - margin-top: 0px; -} - -input.search { - font-size: 75%; - color: #000080; - font-weight: normal; - background-color: #e8eef2; -} -*/ - -td.tiny { - font-size: 75%; -} - -.dirtab { - padding: 4px; - border-collapse: collapse; - border: 1px solid #A3B4D7; -} - -th.dirtab { - background: #EBEFF6; - font-weight: bold; -} - -hr { - height: 0px; - border: none; - border-top: 1px solid #4A6AAA; -} - -hr.footer { - height: 1px; -} - -/* @group Member Descriptions */ - -table.memberdecls { - border-spacing: 0px; - padding: 0px; -} - -.mdescLeft, .mdescRight, -.memItemLeft, .memItemRight, -.memTemplItemLeft, .memTemplItemRight, .memTemplParams { - background-color: #F9FAFC; - border: none; - margin: 4px; - padding: 1px 0 0 8px; -} - -.mdescLeft, .mdescRight { - padding: 0px 8px 4px 8px; - color: #555; -} - -.memItemLeft, .memItemRight, .memTemplParams { - border-top: 1px solid #C4CFE5; -} - -.memItemLeft, .memTemplItemLeft { - white-space: nowrap; -} - -.memItemRight { - width: 100%; -} - -.memTemplParams { - color: #4665A2; - white-space: nowrap; -} - -/* @end */ - -/* @group Member Details */ - -/* Styles for detailed member documentation */ - -.memtemplate { - font-size: 80%; - color: #4665A2; - font-weight: normal; - margin-left: 9px; -} - -.memnav { - background-color: #EBEFF6; - border: 1px solid #A3B4D7; - text-align: center; - margin: 2px; - margin-right: 15px; - padding: 2px; -} - -.mempage { - width: 100%; -} - -.memitem { - padding: 0; - margin-bottom: 10px; - margin-right: 5px; -} - -.memname { - white-space: nowrap; - font-weight: bold; - margin-left: 6px; -} - -.memproto, dl.reflist dt { - border-top: 1px solid #A8B8D9; - border-left: 1px solid #A8B8D9; - border-right: 1px solid #A8B8D9; - padding: 6px 0px 6px 0px; - color: #253555; - font-weight: bold; - text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); - /* opera specific markup */ - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - border-top-right-radius: 8px; - border-top-left-radius: 8px; - /* firefox specific markup */ - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - -moz-border-radius-topright: 8px; - -moz-border-radius-topleft: 8px; - /* webkit specific markup */ - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - -webkit-border-top-right-radius: 8px; - -webkit-border-top-left-radius: 8px; - background-image:url('nav_f.png'); - background-repeat:repeat-x; - background-color: #E2E8F2; - -} - -.memdoc, dl.reflist dd { - border-bottom: 1px solid #A8B8D9; - border-left: 1px solid #A8B8D9; - border-right: 1px solid #A8B8D9; - padding: 2px 5px; - background-color: #FBFCFD; - border-top-width: 0; - /* opera specific markup */ - border-bottom-left-radius: 8px; - border-bottom-right-radius: 8px; - box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - /* firefox specific markup */ - -moz-border-radius-bottomleft: 8px; - -moz-border-radius-bottomright: 8px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 5px 5px 5px; - background-image: -moz-linear-gradient(center top, #FFFFFF 0%, #FFFFFF 60%, #F7F8FB 95%, #EEF1F7); - /* webkit specific markup */ - -webkit-border-bottom-left-radius: 8px; - -webkit-border-bottom-right-radius: 8px; - -webkit-box-shadow: 5px 5px 5px rgba(0, 0, 0, 0.15); - background-image: -webkit-gradient(linear,center top,center bottom,from(#FFFFFF), color-stop(0.6,#FFFFFF), color-stop(0.60,#FFFFFF), color-stop(0.95,#F7F8FB), to(#EEF1F7)); -} - -dl.reflist dt { - padding: 5px; -} - -dl.reflist dd { - margin: 0px 0px 10px 0px; - padding: 5px; -} - -.paramkey { - text-align: right; -} - -.paramtype { - white-space: nowrap; -} - -.paramname { - color: #602020; - white-space: nowrap; -} -.paramname em { - font-style: normal; -} - -.params, .retval, .exception, .tparams { - border-spacing: 6px 2px; -} - -.params .paramname, .retval .paramname { - font-weight: bold; - vertical-align: top; -} - -.params .paramtype { - font-style: italic; - vertical-align: top; -} - -.params .paramdir { - font-family: "courier new",courier,monospace; - vertical-align: top; -} - - - - -/* @end */ - -/* @group Directory (tree) */ - -/* for the tree view */ - -.ftvtree { - font-family: sans-serif; - margin: 0px; -} - -/* these are for tree view when used as main index */ - -.directory { - font-size: 9pt; - font-weight: bold; - margin: 5px; -} - -.directory h3 { - margin: 0px; - margin-top: 1em; - font-size: 11pt; -} - -/* -The following two styles can be used to replace the root node title -with an image of your choice. Simply uncomment the next two styles, -specify the name of your image and be sure to set 'height' to the -proper pixel height of your image. -*/ - -/* -.directory h3.swap { - height: 61px; - background-repeat: no-repeat; - background-image: url("yourimage.gif"); -} -.directory h3.swap span { - display: none; -} -*/ - -.directory > h3 { - margin-top: 0; -} - -.directory p { - margin: 0px; - white-space: nowrap; -} - -.directory div { - display: none; - margin: 0px; -} - -.directory img { - vertical-align: -30%; -} - -/* these are for tree view when not used as main index */ - -.directory-alt { - font-size: 100%; - font-weight: bold; -} - -.directory-alt h3 { - margin: 0px; - margin-top: 1em; - font-size: 11pt; -} - -.directory-alt > h3 { - margin-top: 0; -} - -.directory-alt p { - margin: 0px; - white-space: nowrap; -} - -.directory-alt div { - display: none; - margin: 0px; -} - -.directory-alt img { - vertical-align: -30%; -} - -/* @end */ - -div.dynheader { - margin-top: 8px; -} - -address { - font-style: normal; - color: #2A3D61; -} - -table.doxtable { - border-collapse:collapse; -} - -table.doxtable td, table.doxtable th { - border: 1px solid #2D4068; - padding: 3px 7px 2px; -} - -table.doxtable th { - background-color: #374F7F; - color: #FFFFFF; - font-size: 110%; - padding-bottom: 4px; - padding-top: 5px; - text-align:left; -} - -table.fieldtable { - width: 100%; - margin-bottom: 10px; - border: 1px solid #A8B8D9; - border-spacing: 0px; - -moz-border-radius: 4px; - -webkit-border-radius: 4px; - border-radius: 4px; - -moz-box-shadow: rgba(0, 0, 0, 0.15) 2px 2px 2px; - -webkit-box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); - box-shadow: 2px 2px 2px rgba(0, 0, 0, 0.15); -} - -.fieldtable td, .fieldtable th { - padding: 3px 7px 2px; -} - -.fieldtable td.fieldtype, .fieldtable td.fieldname { - white-space: nowrap; - border-right: 1px solid #A8B8D9; - border-bottom: 1px solid #A8B8D9; - vertical-align: top; -} - -.fieldtable td.fielddoc { - border-bottom: 1px solid #A8B8D9; - width: 100%; -} - -.fieldtable tr:last-child td { - border-bottom: none; -} - -.fieldtable th { - background-image:url('nav_f.png'); - background-repeat:repeat-x; - background-color: #E2E8F2; - font-size: 90%; - color: #253555; - padding-bottom: 4px; - padding-top: 5px; - text-align:left; - -moz-border-radius-topleft: 4px; - -moz-border-radius-topright: 4px; - -webkit-border-top-left-radius: 4px; - -webkit-border-top-right-radius: 4px; - border-top-left-radius: 4px; - border-top-right-radius: 4px; - border-bottom: 1px solid #A8B8D9; -} - - -.tabsearch { - top: 0px; - left: 10px; - height: 36px; - background-image: url('tab_b.png'); - z-index: 101; - overflow: hidden; - font-size: 13px; -} - -.navpath ul -{ - font-size: 11px; - background-image:url('tab_b.png'); - background-repeat:repeat-x; - height:30px; - line-height:30px; - color:#8AA0CC; - border:solid 1px #C2CDE4; - overflow:hidden; - margin:0px; - padding:0px; -} - -.navpath li -{ - list-style-type:none; - float:left; - padding-left:10px; - padding-right:15px; - background-image:url('bc_s.png'); - background-repeat:no-repeat; - background-position:right; - color:#364D7C; -} - -.navpath li.navelem a -{ - height:32px; - display:block; - text-decoration: none; - outline: none; -} - -.navpath li.navelem a:hover -{ - color:#6884BD; -} - -.navpath li.footer -{ - list-style-type:none; - float:right; - padding-left:10px; - padding-right:15px; - background-image:none; - background-repeat:no-repeat; - background-position:right; - color:#364D7C; - font-size: 8pt; -} - - -div.summary -{ - float: right; - font-size: 8pt; - padding-right: 5px; - width: 50%; - text-align: right; -} - -div.summary a -{ - white-space: nowrap; -} - -div.ingroups -{ - margin-left: 5px; - font-size: 8pt; - padding-left: 5px; - width: 50%; - text-align: left; -} - -div.ingroups a -{ - white-space: nowrap; -} - -div.header -{ - background-image:url('nav_h.png'); - background-repeat:repeat-x; - background-color: #F9FAFC; - margin: 0px; - border-bottom: 1px solid #C4CFE5; -} - -div.headertitle -{ - padding: 5px 5px 5px 7px; -} - -dl -{ - padding: 0 0 0 10px; -} - -dl.note, dl.warning, dl.attention, dl.pre, dl.post, dl.invariant, dl.deprecated, dl.todo, dl.test, dl.bug -{ - border-left:4px solid; - padding: 0 0 0 6px; -} - -dl.note -{ - border-color: #D0C000; -} - -dl.warning, dl.attention -{ - border-color: #FF0000; -} - -dl.pre, dl.post, dl.invariant -{ - border-color: #00D000; -} - -dl.deprecated -{ - border-color: #505050; -} - -dl.todo -{ - border-color: #00C0E0; -} - -dl.test -{ - border-color: #3030E0; -} - -dl.bug -{ - border-color: #C08050; -} - -#projectlogo -{ - text-align: center; - vertical-align: bottom; - border-collapse: separate; -} - -#projectlogo img -{ - border: 0px none; -} - -#projectname -{ - font: 300% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 2px 0px; -} - -#projectbrief -{ - font: 120% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 0px; -} - -#projectnumber -{ - font: 50% Tahoma, Arial,sans-serif; - margin: 0px; - padding: 0px; -} - -#titlearea -{ - padding: 0px; - margin: 0px; - width: 100%; - border-bottom: 1px solid #5373B4; -} - -.image -{ - text-align: center; -} - -.dotgraph -{ - text-align: center; -} - -.mscgraph -{ - text-align: center; -} - -.caption -{ - font-weight: bold; -} - -div.zoom -{ - border: 1px solid #90A5CE; -} - -dl.citelist { - margin-bottom:50px; -} - -dl.citelist dt { - color:#334975; - float:left; - font-weight:bold; - margin-right:10px; - padding:5px; -} - -dl.citelist dd { - margin:2px 0; - padding:5px 0; -} - -@media print -{ - #top { display: none; } - #side-nav { display: none; } - #nav-path { display: none; } - body { overflow:visible; } - h1, h2, h3, h4, h5, h6 { page-break-after: avoid; } - .summary { display: none; } - .memitem { page-break-inside: avoid; } - #doc-content - { - margin-left:0 !important; - height:auto !important; - width:auto !important; - overflow:inherit; - display:inline; - } - pre.fragment - { - overflow: visible; - text-wrap: unrestricted; - white-space: -moz-pre-wrap; /* Moz */ - white-space: -pre-wrap; /* Opera 4-6 */ - white-space: -o-pre-wrap; /* Opera 7 */ - white-space: pre-wrap; /* CSS3 */ - word-wrap: break-word; /* IE 5.5+ */ - } -} - Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/doxygen.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/doxygen.png differ diff -Nru incron-0.5.10/doc/html/files.html incron-0.5.12/doc/html/files.html --- incron-0.5.10/doc/html/files.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/files.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,86 +0,0 @@ - - - - -incron: File List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
File List
-
-
-
Here is a list of all files with brief descriptions:
- - - - - - - - - - - - - - - - - -
appargs.cppApplication arguments processor implementation
appargs.h [code]Application arguments processor header
appinst.cppApplication instance class implementation
appinst.h [code]Application instance class header
icd-main.cppInotify cron daemon main file
ict-main.cppInotify cron table manipulator main file
incron.h [code]Inotify cron basic definition file
incroncfg.cppInotify cron configuration implementation
incroncfg.h [code]Inotify cron configuration header
incrontab.cppInotify cron table manipulator classes implementation
incrontab.h [code]Inotify cron table manipulator classes header
inotify-cxx.cppInotify C++ interface implementation
inotify-cxx.h [code]Inotify C++ interface header
strtok.cppString tokenizer implementation
strtok.h [code]String tokenizer header
usertable.cppInotify cron daemon user tables implementation
usertable.h [code]Inotify cron daemon user tables header
-
- - - - - - diff -Nru incron-0.5.10/doc/html/functions_func.html incron-0.5.12/doc/html/functions_func.html --- incron-0.5.10/doc/html/functions_func.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/functions_func.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,540 +0,0 @@ - - - - -incron: Class Members - Functions - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - - -
-
-  - -

- a -

- - -

- b -

- - -

- c -

- - -

- d -

- - -

- e -

- - -

- f -

- - -

- g -

- - -

- h -

- - -

- i -

- - -

- l -

- - -

- m -

- - -

- o -

- - -

- p -

- - -

- r -

- - -

- s -

- - -

- t -

- - -

- u -

- - -

- w -

- - -

- ~ -

-
- - - - - - diff -Nru incron-0.5.10/doc/html/functions.html incron-0.5.12/doc/html/functions.html --- incron-0.5.10/doc/html/functions.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/functions.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,592 +0,0 @@ - - - - -incron: Class Members - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - - -
-
-
Here is a list of all class members with links to the classes they belong to:
- -

- a -

- - -

- b -

- - -

- c -

- - -

- d -

- - -

- e -

- - -

- f -

- - -

- g -

- - -

- h -

- - -

- i -

- - -

- l -

- - -

- m -

- - -

- o -

- - -

- p -

- - -

- r -

- - -

- s -

- - -

- t -

- - -

- u -

- - -

- v -

- - -

- w -

- - -

- ~ -

-
- - - - - - diff -Nru incron-0.5.10/doc/html/functions_rela.html incron-0.5.12/doc/html/functions_rela.html --- incron-0.5.10/doc/html/functions_rela.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/functions_rela.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,79 +0,0 @@ - - - - -incron: Class Members - Related Functions - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/functions_vars.html incron-0.5.12/doc/html/functions_vars.html --- incron-0.5.10/doc/html/functions_vars.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/functions_vars.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,118 +0,0 @@ - - - - -incron: Class Members - Variables - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/globals_defs.html incron-0.5.12/doc/html/globals_defs.html --- incron-0.5.10/doc/html/globals_defs.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/globals_defs.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,217 +0,0 @@ - - - - -incron: File Members - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - - -
-
-  - -

- a -

- - -

- c -

- - -

- d -

- - -

- i -

- - -

- p -

-
- - - - - - diff -Nru incron-0.5.10/doc/html/globals_enum.html incron-0.5.12/doc/html/globals_enum.html --- incron-0.5.10/doc/html/globals_enum.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/globals_enum.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,82 +0,0 @@ - - - - -incron: File Members - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/globals_eval.html incron-0.5.12/doc/html/globals_eval.html --- incron-0.5.10/doc/html/globals_eval.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/globals_eval.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,94 +0,0 @@ - - - - -incron: File Members - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/globals_func.html incron-0.5.12/doc/html/globals_func.html --- incron-0.5.10/doc/html/globals_func.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/globals_func.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,116 +0,0 @@ - - - - -incron: File Members - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/globals.html incron-0.5.12/doc/html/globals.html --- incron-0.5.10/doc/html/globals.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/globals.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,377 +0,0 @@ - - - - -incron: File Members - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - - -
-
-
Here is a list of all file members with links to the files they belong to:
- -

- a -

- - -

- c -

- - -

- d -

- - -

- e -

- - -

- f -

- - -

- g -

- - -

- i -

- - -

- l -

- - -

- m -

- - -

- o -

- - -

- p -

- - -

- r -

- - -

- s -

-
- - - - - - diff -Nru incron-0.5.10/doc/html/globals_type.html incron-0.5.12/doc/html/globals_type.html --- incron-0.5.10/doc/html/globals_type.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/globals_type.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,115 +0,0 @@ - - - - -incron: File Members - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/globals_vars.html incron-0.5.12/doc/html/globals_vars.html --- incron-0.5.10/doc/html/globals_vars.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/globals_vars.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,93 +0,0 @@ - - - - -incron: File Members - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - - -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/icd-main_8cpp.html incron-0.5.12/doc/html/icd-main_8cpp.html --- incron-0.5.10/doc/html/icd-main_8cpp.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/icd-main_8cpp.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,526 +0,0 @@ - - - - -incron: icd-main.cpp File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
icd-main.cpp File Reference
-
-
- -

inotify cron daemon main file -More...

-
#include <map>
-#include <signal.h>
-#include <wait.h>
-#include <fcntl.h>
-#include <pwd.h>
-#include <dirent.h>
-#include <syslog.h>
-#include <errno.h>
-#include <sys/poll.h>
-#include <sys/stat.h>
-#include <cstdio>
-#include <cstring>
-#include "inotify-cxx.h"
-#include "appinst.h"
-#include "appargs.h"
-#include "incron.h"
-#include "incrontab.h"
-#include "usertable.h"
-#include "incroncfg.h"
-
- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Defines

#define INCRON_LOG_OPTS   (LOG_CONS | LOG_PID)
 Logging options (console as fallback, log PID)
#define INCRON_LOG_FACIL   LOG_CRON
 Logging facility (use CRON)
#define INCROND_VERSION   INCROND_NAME " " INCRON_VERSION
 incrond version string
#define INCROND_DESCRIPTION
 incrontab description string
#define INCROND_HELP
 incrontab help string
#define CHILD_PIPE_BUF_LEN   32
#define POLL_EAGAIN_WAIT   3
 Second to wait on EAGAIN.

-Functions

void on_signal (int signo)
 Handles a signal.
void load_tables (EventDispatcher *pEd) throw (InotifyException)
 Attempts to load all (user and system) incron tables.
void free_tables (EventDispatcher *pEd)
 Deallocates all memory used by incron tables and unregisters them from the dispatcher.
void prepare_pipe ()
 Prepares a 'dead/done child' notification pipe.
void init_poll_array (struct pollfd pfd[], int pipefd, int infd)
 Checks whether a parameter string is a specific command.
int main (int argc, char **argv)
 Main application function.

-Variables

SUT_MAP g_ut
 User name to user table mapping table.
volatile bool g_fFinish = false
 Finish program yes/no.
int g_cldPipe [2]
 Pipe for notifying about dead children.
char g_cldPipeBuf [CHILD_PIPE_BUF_LEN]
bool g_daemon = true
 Daemonize true/false.
-

Detailed Description

-

inotify cron daemon main file

-

inotify cron system

-

Copyright (C) 2006, 2007, 2008, 2012 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can use it, redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL).

-

Credits: Christian Ruppert (new include to build with GCC 4.4+)

-

Define Documentation

- -
-
- - - - -
#define CHILD_PIPE_BUF_LEN   32
-
-
- -
-
- -
-
- - - - -
#define INCRON_LOG_FACIL   LOG_CRON
-
-
- -

Logging facility (use CRON)

- -
-
- -
-
- - - - -
#define INCRON_LOG_OPTS   (LOG_CONS | LOG_PID)
-
-
- -

Logging options (console as fallback, log PID)

- -
-
- -
-
- - - - -
#define INCROND_DESCRIPTION
-
-
-Value:
"incrond - inotify cron daemon\n" \
-                            "(c) Lukas Jelinek, 2006, 2007, 2008"
-
-

incrontab description string

- -
-
- -
-
- - - - -
#define INCROND_HELP
-
-
-Value:
INCROND_DESCRIPTION "\n\n" \
-          "usage: incrond [<options>]\n\n" \
-          "<operation> may be one of the following:\n" \
-          "These options may be used:\n" \
-          "  -?, --about                  gives short information about program\n" \
-          "  -h, --help                   prints this help text\n" \
-          "  -n, --foreground             runs on foreground (no daemonizing)\n" \
-          "  -k, --kill                   terminates running instance of incrond\n" \
-          "  -f <FILE>, --config=<FILE>   overrides default configuration file  (requires root privileges)\n" \
-          "  -V, --version                prints program version\n\n" \
-          "For reporting bugs please use http://bts.aiken.cz\n"
-
-

incrontab help string

- -
-
- -
-
- - - - -
#define INCROND_VERSION   INCROND_NAME " " INCRON_VERSION
-
-
- -

incrond version string

- -
-
- -
-
- - - - -
#define POLL_EAGAIN_WAIT   3
-
-
- -

Second to wait on EAGAIN.

- -
-
-

Function Documentation

- -
-
- - - - - - - - -
void free_tables (EventDispatcherpEd)
-
-
- -

Deallocates all memory used by incron tables and unregisters them from the dispatcher.

-
Parameters:
- - -
[in]pEdevent dispatcher
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - - - - - - - -
void init_poll_array (struct pollfd pfd[],
int pipefd,
int infd 
)
-
-
- -

Checks whether a parameter string is a specific command.

-

The string is accepted if it equals either the short or long form of the command.

-
Parameters:
- - - - -
[in]schecked string
[in]shortCmdshort form of command
[in]longCmdlong form of command
-
-
-
Returns:
true = string accepted, false = otherwise Initializes a poll array.
-
Parameters:
- - - - -
[out]pfdpoll structure array
[in]pipefdpipe file descriptor
[in]infdinotify infrastructure file descriptor
-
-
- -
-
- -
-
- - - - - - - - -
void load_tables (EventDispatcherpEd) throw (InotifyException)
-
-
- -

Attempts to load all (user and system) incron tables.

-

Loaded tables are registered for processing events.

-
Parameters:
- - -
[in]pEdinotify event dispatcher
-
-
-
Exceptions:
- - -
InotifyExceptionthrown if base table directory cannot be read
-
-
- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int main (int argc,
char ** argv 
)
-
-
- -

Main application function.

-
Parameters:
- - - -
[in]argcargument count
[in]argvargument array
-
-
-
Returns:
0 on success, 1 on error
-
Attention:
In daemon mode, it finishes immediately.
- -
-
- -
-
- - - - - - - - -
void on_signal (int signo)
-
-
- -

Handles a signal.

-

For SIGTERM and SIGINT it sets the program finish variable. For SIGCHLD it writes a character into the notification pipe (this is a workaround made due to disability to reliably wait for dead children).

-
Parameters:
- - -
[in]signosignal number
-
-
- -
-
- -
-
- - - - - - - -
void prepare_pipe ()
-
-
- -

Prepares a 'dead/done child' notification pipe.

-

This function returns no value at all and on error it throws an exception.

- -
-
-

Variable Documentation

- -
-
- - - - -
int g_cldPipe[2]
-
-
- -

Pipe for notifying about dead children.

- -
-
- -
-
- - - - -
char g_cldPipeBuf[CHILD_PIPE_BUF_LEN]
-
-
- -
-
- -
-
- - - - -
bool g_daemon = true
-
-
- -

Daemonize true/false.

- -
-
- -
-
- - - - -
volatile bool g_fFinish = false
-
-
- -

Finish program yes/no.

- -
-
- -
-
- - - - -
SUT_MAP g_ut
-
-
- -

User name to user table mapping table.

- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/ict-main_8cpp.html incron-0.5.12/doc/html/ict-main_8cpp.html --- incron-0.5.10/doc/html/ict-main_8cpp.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/ict-main_8cpp.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,408 +0,0 @@ - - - - -incron: ict-main.cpp File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
ict-main.cpp File Reference
-
-
- -

inotify cron table manipulator main file -More...

-
#include <argp.h>
-#include <pwd.h>
-#include <string>
-#include <unistd.h>
-#include <sys/stat.h>
-#include <sys/wait.h>
-#include <sys/inotify.h>
-#include <fcntl.h>
-#include <stdlib.h>
-#include <limits.h>
-#include <cstring>
-#include <cstdio>
-#include "inotify-cxx.h"
-#include "appargs.h"
-#include "incron.h"
-#include "incrontab.h"
-#include "incroncfg.h"
-
- - - - - - - - - - - - - - - - - - - - - - - - - -

-Defines

#define INCRON_ALT_EDITOR   "/etc/alternatives/editor"
 Alternative editor.
#define INCRON_DEFAULT_EDITOR   "vim"
 Default (hard-wired) editor.
#define INCRONTAB_VERSION   INCRONTAB_NAME " " INCRON_VERSION
 incrontab version string
#define INCRONTAB_DESCRIPTION
 incrontab description string
#define INCRONTAB_HELP
 incrontab help string

-Functions

bool copy_from_file (const std::string &rPath, const std::string &rUser)
 Copies a file to an user table.
bool remove_table (const std::string &rUser)
 Removes an user table.
bool list_table (const std::string &rUser)
 Lists an user table.
bool edit_table (const std::string &rUser)
 Allows to edit an user table.
void list_types ()
 Prints the list of all available inotify event types.
bool reload_table (const std::string &rUser)
 Reloads an user table.
int main (int argc, char **argv)
-

Detailed Description

-

inotify cron table manipulator main file

-

inotify cron system

-

Copyright (C) 2006, 2007, 2008, 2012 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can use it, redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL).

-

Credits: kolter (fix for segfaulting on --user) Christian Ruppert (new include to build with GCC 4.4+)

-

Define Documentation

- -
-
- - - - -
#define INCRON_ALT_EDITOR   "/etc/alternatives/editor"
-
-
- -

Alternative editor.

- -
-
- -
-
- - - - -
#define INCRON_DEFAULT_EDITOR   "vim"
-
-
- -

Default (hard-wired) editor.

- -
-
- -
-
- - - - -
#define INCRONTAB_DESCRIPTION
-
-
-Value:
"incrontab - inotify cron table manipulator\n" \
-                              "(c) Lukas Jelinek, 2006, 2007, 208"
-
-

incrontab description string

- -
-
- -
-
- - - - -
#define INCRONTAB_HELP
-
-
-Value:
INCRONTAB_DESCRIPTION "\n\n" \
-          "usage: incrontab [<options>] <operation>\n" \
-          "       incrontab [<options>] <FILE-TO-IMPORT>\n\n" \
-          "<operation> may be one of the following:\n" \
-          "  -?, --about                  gives short information about program\n" \
-          "  -h, --help                   prints this help text\n" \
-          "  -l, --list                   lists user table\n" \
-          "  -r, --remove                 removes user table\n" \
-          "  -e, --edit                   provides editing user table\n" \
-          "  -t, --types                  list supported event types\n" \
-          "  -d, --reload                 request incrond to reload user table\n" \
-          "  -V, --version                prints program version\n\n" \
-          "\n" \
-          "These options may be used:\n" \
-          "  -u <USER>, --user=<USER>     overrides current user (requires root privileges)\n" \
-          "  -f <FILE>, --config=<FILE>   overrides default configuration file  (requires root privileges)\n\n" \
-          "For reporting bugs please use http://bts.aiken.cz\n"
-
-

incrontab help string

- -
-
- -
-
- - - - -
#define INCRONTAB_VERSION   INCRONTAB_NAME " " INCRON_VERSION
-
-
- -

incrontab version string

- -
-
-

Function Documentation

- -
-
- - - - - - - - - - - - - - - - - - -
bool copy_from_file (const std::string & rPath,
const std::string & rUser 
)
-
-
- -

Copies a file to an user table.

-
Parameters:
- - - -
[in]rPathpath to file
[in]rUseruser name
-
-
-
Returns:
true = success, false = failure
- -
-
- -
-
- - - - - - - - -
bool edit_table (const std::string & rUser)
-
-
- -

Allows to edit an user table.

-
Parameters:
- - -
[in]rUseruser name
-
-
-
Returns:
true = success, false = failure
-
Attention:
This function is very complex and may contain various bugs including security ones. Please keep it in mind..
- -
-
- -
-
- - - - - - - - -
bool list_table (const std::string & rUser)
-
-
- -

Lists an user table.

-
Parameters:
- - -
[in]rUseruser name
-
-
-
Returns:
true = success, false = failure
- -
-
- -
-
- - - - - - - -
void list_types ()
-
-
- -

Prints the list of all available inotify event types.

- -
-
- -
-
- - - - - - - - - - - - - - - - - - -
int main (int argc,
char ** argv 
)
-
-
- -
-
- -
-
- - - - - - - - -
bool reload_table (const std::string & rUser)
-
-
- -

Reloads an user table.

-
Parameters:
- - -
[in]rUseruser name
-
-
-
Returns:
true = success, false = otherwise
- -
-
- -
-
- - - - - - - - -
bool remove_table (const std::string & rUser)
-
-
- -

Removes an user table.

-
Parameters:
- - -
[in]rUseruser name
-
-
-
Returns:
true = success, false = failure
- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/incron_8h.html incron-0.5.12/doc/html/incron_8h.html --- incron-0.5.10/doc/html/incron_8h.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/incron_8h.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,186 +0,0 @@ - - - - -incron: incron.h File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
incron.h File Reference
-
-
- -

inotify cron basic definition file -More...

- -

Go to the source code of this file.

- - - - - - - - - - - - - - -

-Defines

#define INCRON_NAME   "incron"
 Common application name.
#define INCROND_NAME   "incrond"
 Daemon name.
#define INCRONTAB_NAME   "incrontab"
 Table manipulator name.
#define INCRON_VERSION   "0.5.10"
 Application version (release)
#define INCRON_BUG_ADDRESS   "<bugs@aiken.cz>"
 Address for sending bugs.
#define INCRON_CONFIG   "/etc/incron.conf"
 Default configuration file.
-

Detailed Description

-

inotify cron basic definition file

-

inotify cron system

-

Copyright (C) 2006, 2007, 2008, 2009 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can use it, redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL).

-

Define Documentation

- -
-
- - - - -
#define INCRON_BUG_ADDRESS   "<bugs@aiken.cz>"
-
-
- -

Address for sending bugs.

- -
-
- -
-
- - - - -
#define INCRON_CONFIG   "/etc/incron.conf"
-
-
- -

Default configuration file.

- -
-
- -
-
- - - - -
#define INCRON_NAME   "incron"
-
-
- -

Common application name.

- -
-
- -
-
- - - - -
#define INCRON_VERSION   "0.5.10"
-
-
- -

Application version (release)

- -
-
- -
-
- - - - -
#define INCROND_NAME   "incrond"
-
-
- -

Daemon name.

- -
-
- -
-
- - - - -
#define INCRONTAB_NAME   "incrontab"
-
-
- -

Table manipulator name.

- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/incron_8h_source.html incron-0.5.12/doc/html/incron_8h_source.html --- incron-0.5.10/doc/html/incron_8h_source.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/incron_8h_source.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,86 +0,0 @@ - - - - -incron: incron.h Source File - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
incron.h
-
-
-Go to the documentation of this file.
00001 
-00003 
-00017 #ifndef _INCRON_H_
-00018 #define _INCRON_H_
-00019 
-00021 #define INCRON_NAME "incron"
-00022 
-00024 #define INCROND_NAME "incrond"
-00025 
-00027 #define INCRONTAB_NAME "incrontab"
-00028 
-00030 #define INCRON_VERSION "0.5.10"
-00031 
-00033 #define INCRON_BUG_ADDRESS "<bugs@aiken.cz>"
-00034 
-00036 #define INCRON_CONFIG "/etc/incron.conf"
-00037 
-00038 
-00039 #endif //_INCRON_H_
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/incroncfg_8cpp.html incron-0.5.12/doc/html/incroncfg_8cpp.html --- incron-0.5.10/doc/html/incroncfg_8cpp.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/incroncfg_8cpp.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,134 +0,0 @@ - - - - -incron: incroncfg.cpp File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
incroncfg.cpp File Reference
-
-
- -

inotify cron configuration implementation -More...

-
#include <fstream>
-#include <sstream>
-#include <cstring>
-#include "incroncfg.h"
-
- - - - - -

-Defines

#define INCRON_CFG_DEFAULT   "/etc/incron.conf"

-Typedefs

typedef std::map< std::string,
-std::string > 
CFG_MAP
typedef CFG_MAP::iterator CFG_ITER
-

Detailed Description

-

inotify cron configuration implementation

-

incron configuration

-

Copyright (C) 2007, 2008, 2012 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can use it, redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL).

-

Credits: Christian Ruppert (new include to build with GCC 4.4+)

-

Define Documentation

- -
-
- - - - -
#define INCRON_CFG_DEFAULT   "/etc/incron.conf"
-
-
- -
-
-

Typedef Documentation

- -
-
- - - - -
typedef CFG_MAP::iterator CFG_ITER
-
-
- -
-
- -
-
- - - - -
typedef std::map<std::string, std::string> CFG_MAP
-
-
- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/incroncfg_8h.html incron-0.5.12/doc/html/incroncfg_8h.html --- incron-0.5.10/doc/html/incroncfg_8h.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/incroncfg_8h.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,87 +0,0 @@ - - - - -incron: incroncfg.h File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
incroncfg.h File Reference
-
-
- -

inotify cron configuration header -More...

-
#include <cstring>
-#include <map>
-
-

Go to the source code of this file.

- - - - -

-Classes

class  IncronCfg
 Configuration class. More...
-

Detailed Description

-

inotify cron configuration header

-

incron configuration

-

Copyright (C) 2007, 2008 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can use it, redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL).

-
- - - - - - diff -Nru incron-0.5.10/doc/html/incroncfg_8h_source.html incron-0.5.12/doc/html/incroncfg_8h_source.html --- incron-0.5.10/doc/html/incroncfg_8h_source.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/incroncfg_8h_source.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,114 +0,0 @@ - - - - -incron: incroncfg.h Source File - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
incroncfg.h
-
-
-Go to the documentation of this file.
00001 
-00003 
-00017 #ifndef INCRONCFG_H_
-00018 #define INCRONCFG_H_
-00019 
-00020 
-00021 #include <cstring>
-00022 #include <map>
-00023 
-00025 
-00030 class IncronCfg
-00031 {
-00032 public:
-00033 
-00035   static void Init();
-00036 
-00038 
-00047   static void Load(const std::string& rPath);
-00048 
-00050 
-00059   static bool GetValue(const std::string& rKey, std::string& rVal);
-00060   
-00062 
-00071   static bool GetValue(const std::string& rKey, int& rVal);
-00072   
-00074 
-00083   static bool GetValue(const std::string& rKey, unsigned& rVal);
-00084   
-00086 
-00095   static bool GetValue(const std::string& rKey, bool& rVal);
-00096   
-00098 
-00105   static std::string BuildPath(const std::string& rPath, const std::string& rName);
-00106   
-00107 protected:
-00109 
-00115   static bool ParseLine(const char* s, std::string& rKey, std::string& rVal);
-00116   
-00118 
-00122   static bool IsComment(const char* s);
-00123 
-00124 private:
-00125   static std::map<std::string, std::string> m_values;
-00126   static std::map<std::string, std::string> m_defaults;
-00127 };
-00128 
-00129 #endif /*INCRONCFG_H_*/
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/incrontab_8cpp.html incron-0.5.12/doc/html/incrontab_8cpp.html --- incron-0.5.10/doc/html/incrontab_8cpp.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/incrontab_8cpp.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,82 +0,0 @@ - - - - -incron: incrontab.cpp File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
incrontab.cpp File Reference
-
-
- -

inotify cron table manipulator classes implementation -More...

-
#include <sstream>
-#include <cstdio>
-#include <errno.h>
-#include "inotify-cxx.h"
-#include "incrontab.h"
-#include "incroncfg.h"
-

Detailed Description

-

inotify cron table manipulator classes implementation

-

inotify cron system

-

Copyright (C) 2006, 2007, 2008, 2012 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can use it, redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL).

-

Credits: Christian Ruppert (new include to build with GCC 4.4+)

-
- - - - - - diff -Nru incron-0.5.10/doc/html/incrontab_8h.html incron-0.5.12/doc/html/incrontab_8h.html --- incron-0.5.10/doc/html/incrontab_8h.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/incrontab_8h.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,90 +0,0 @@ - - - - -incron: incrontab.h File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
incrontab.h File Reference
-
-
- -

inotify cron table manipulator classes header -More...

-
#include <string>
-#include <deque>
-#include "strtok.h"
-
-

Go to the source code of this file.

- - - - - - -

-Classes

class  IncronTabEntry
 Incron table entry class. More...
class  IncronTab
 Incron table class. More...
-

Detailed Description

-

inotify cron table manipulator classes header

-

inotify cron system

-

Copyright (C) 2006, 2007, 2008 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can use it, redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL).

-
- - - - - - diff -Nru incron-0.5.10/doc/html/incrontab_8h_source.html incron-0.5.12/doc/html/incrontab_8h_source.html --- incron-0.5.10/doc/html/incrontab_8h_source.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/incrontab_8h_source.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,192 +0,0 @@ - - - - -incron: incrontab.h Source File - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
incrontab.h
-
-
-Go to the documentation of this file.
00001 
-00003 
-00017 #ifndef _INCRONTAB_H_
-00018 #define _INCRONTAB_H_
-00019 
-00020 #include <string>
-00021 #include <deque>
-00022 
-00023 #include "strtok.h"
-00024 
-00025 /*
-00027 #define INCRON_USER_TABLE_BASE "/var/spool/incron/"
-00028 
-00030 #define INCRON_SYS_TABLE_BASE "/etc/incron.d/"
-00031 */
-00032 
-00034 class IncronTabEntry
-00035 {
-00036 public:
-00038 
-00043   IncronTabEntry();
-00044 
-00046 
-00053   IncronTabEntry(const std::string& rPath, uint32_t uMask, const std::string& rCmd);
-00054   
-00056   ~IncronTabEntry() {}
-00057   
-00059 
-00064   std::string ToString() const;
-00065   
-00067 
-00072   static bool Parse(const std::string& rStr, IncronTabEntry& rEntry);
-00073   
-00075 
-00078   inline const std::string& GetPath() const
-00079   {
-00080     return m_path;
-00081   }
-00082   
-00084 
-00087   inline int32_t GetMask() const
-00088   {
-00089     return m_uMask;
-00090   }
-00091   
-00093 
-00096   inline const std::string& GetCmd() const
-00097   {
-00098     return m_cmd;
-00099   }
-00100   
-00102 
-00105   inline bool IsNoLoop() const
-00106   {
-00107     return m_fNoLoop;
-00108   }
-00109   
-00111 
-00123   static std::string GetSafePath(const std::string& rPath);
-00124   
-00125 protected:
-00126   std::string m_path; 
-00127   uint32_t m_uMask;   
-00128   std::string m_cmd;  
-00129   bool m_fNoLoop;     
-00130 };
-00131 
-00132 
-00134 class IncronTab
-00135 {
-00136 public:
-00138   IncronTab() {}
-00139   
-00141   ~IncronTab() {}
-00142   
-00144 
-00147   inline void Add(const IncronTabEntry& rEntry)
-00148   {
-00149     m_tab.push_back(rEntry);
-00150   }
-00151   
-00153   inline void Clear()
-00154   {
-00155     m_tab.clear();
-00156   }
-00157   
-00159 
-00162   inline bool IsEmpty() const
-00163   {
-00164     return m_tab.empty();
-00165   }
-00166   
-00168 
-00171   inline int GetCount() const
-00172   {
-00173     return (int) m_tab.size();
-00174   }
-00175   
-00177 
-00184   inline IncronTabEntry& GetEntry(int index)
-00185   {
-00186     return m_tab[index];
-00187   }
-00188   
-00190 
-00194   bool Load(const std::string& rPath);
-00195   
-00197 
-00201   bool Save(const std::string& rPath);
-00202   
-00204 
-00208   static bool CheckUser(const std::string& rUser);
-00209   
-00211 
-00217   static std::string GetUserTablePath(const std::string& rUser);
-00218   
-00220 
-00226   static std::string GetSystemTablePath(const std::string& rName);
-00227 
-00228 protected:
-00229   std::deque<IncronTabEntry> m_tab; 
-00230 };
-00231 
-00232 
-00233 #endif //_INCRONTAB_H_
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/index.html incron-0.5.12/doc/html/index.html --- incron-0.5.10/doc/html/index.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/index.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,61 +0,0 @@ - - - - -incron: Main Page - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - -
-
-
-
incron Documentation
-
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/inotify-cxx_8cpp.html incron-0.5.12/doc/html/inotify-cxx_8cpp.html --- incron-0.5.10/doc/html/inotify-cxx_8cpp.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/inotify-cxx_8cpp.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,133 +0,0 @@ - - - - -incron: inotify-cxx.cpp File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
inotify-cxx.cpp File Reference
-
-
- -

inotify C++ interface implementation -More...

-
#include <errno.h>
-#include <unistd.h>
-#include <fcntl.h>
-#include <cstdio>
-#include "inotify-cxx.h"
-
- - - - - -

-Defines

#define PROCFS_INOTIFY_BASE   "/proc/sys/fs/inotify/"
 procfs inotify base path
#define DUMP_SEP
 dump separator (between particular entries)
-

Detailed Description

-

inotify C++ interface implementation

-

inotify C++ interface

-

Copyright (C) 2006, 2007, 2008, 2012 Lukas Jelinek <lukas@aiken.cz>

-

This program is free software; you can redistribute it and/or modify it under the terms of one of the following licenses:

-
    -
  • 1. X11-style license (see LICENSE-X11)
  • -
  • 2. GNU Lesser General Public License, version 2.1 (see LICENSE-LGPL)
  • -
  • 3. GNU General Public License, version 2 (see LICENSE-GPL)
  • -
-

If you want to help with choosing the best license for you, please visit http://www.gnu.org/licenses/license-list.html.

-

Credits: Christian Ruppert (new include to build with GCC 4.4+)

-

Define Documentation

- -
-
- - - - -
#define DUMP_SEP
-
-
-Value:
({ \
-    if (!rStr.empty()) { \
-      rStr.append(","); \
-    } \
-  })
-
-

dump separator (between particular entries)

- -
-
- -
-
- - - - -
#define PROCFS_INOTIFY_BASE   "/proc/sys/fs/inotify/"
-
-
- -

procfs inotify base path

- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/inotify-cxx_8h.html incron-0.5.12/doc/html/inotify-cxx_8h.html --- incron-0.5.10/doc/html/inotify-cxx_8h.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/inotify-cxx_8h.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,374 +0,0 @@ - - - - -incron: inotify-cxx.h File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
inotify-cxx.h File Reference
-
-
- -

inotify C++ interface header -More...

-
#include <stdint.h>
-#include <string>
-#include <deque>
-#include <map>
-#include <sys/syscall.h>
-#include <sys/inotify.h>
-#include <sys/inotify-syscalls.h>
-
-

Go to the source code of this file.

- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -

-Classes

class  InotifyException
 Class for inotify exceptions. More...
class  InotifyEvent
 inotify event class More...
class  InotifyWatch
 inotify watch class More...
class  Inotify
 inotify class More...

-Defines

#define INOTIFY_EVENT_SIZE   (sizeof(struct inotify_event))
 Event struct size.
#define INOTIFY_BUFLEN   (1024 * (INOTIFY_EVENT_SIZE + 16))
 Event buffer length.
#define IN_EXC_MSG(msg)   (std::string(__PRETTY_FUNCTION__) + ": " + msg)
 Helper macro for creating exception messages.
#define IN_LOCK_DECL
 inotify-cxx thread safety
#define IN_LOCK_INIT
#define IN_LOCK_DONE
#define IN_READ_BEGIN
#define IN_READ_END
#define IN_READ_END_NOTHROW
#define IN_WRITE_BEGIN
#define IN_WRITE_END
#define IN_WRITE_END_NOTHROW

-Typedefs

typedef std::map< int32_t,
-InotifyWatch * > 
IN_WATCH_MAP
 Mapping from watch descriptors to watch objects.
typedef std::map< std::string,
-InotifyWatch * > 
IN_WP_MAP
 Mapping from paths to watch objects.

-Enumerations

enum  InotifyCapability_t { IN_MAX_EVENTS = 0, -IN_MAX_INSTANCES = 1, -IN_MAX_WATCHES = 2 - }
 inotify capability/limit identifiers More...
-

Detailed Description

-

inotify C++ interface header

-

inotify C++ interface

-

Copyright (C) 2006, 2007, 2008 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can redistribute it and/or modify it under the terms of one of the following licenses:

-
    -
  • 1. X11-style license (see LICENSE-X11)
  • -
  • 2. GNU Lesser General Public License, version 2.1 (see LICENSE-LGPL)
  • -
  • 3. GNU General Public License, version 2 (see LICENSE-GPL)
  • -
-

If you want to help with choosing the best license for you, please visit http://www.gnu.org/licenses/license-list.html.

-

Define Documentation

- -
-
- - - - - - - - -
#define IN_EXC_MSG( msg)   (std::string(__PRETTY_FUNCTION__) + ": " + msg)
-
-
- -

Helper macro for creating exception messages.

-

It prepends the message by the function name.

- -
-
- -
-
- - - - -
#define IN_LOCK_DECL
-
-
- -

inotify-cxx thread safety

-

If this symbol is defined you can use this interface safely threaded applications. Remember that it slightly degrades performance.

-

Even if INOTIFY_THREAD_SAFE is defined some classes stay unsafe. If you must use them (must you?) in more than one thread concurrently you need to implement explicite locking.

-

You need not to define INOTIFY_THREAD_SAFE in that cases where the application is multithreaded but all the inotify infrastructure will be managed only in one thread. This is the recommended way.

-

Locking may fail (it is very rare but not impossible). In this case an exception is thrown. But if unlocking fails in case of an error it does nothing (this failure is ignored).

- -
-
- -
-
- - - - -
#define IN_LOCK_DONE
-
-
- -
-
- -
-
- - - - -
#define IN_LOCK_INIT
-
-
- -
-
- -
-
- - - - -
#define IN_READ_BEGIN
-
-
- -
-
- -
-
- - - - -
#define IN_READ_END
-
-
- -
-
- -
-
- - - - -
#define IN_READ_END_NOTHROW
-
-
- -
-
- -
-
- - - - -
#define IN_WRITE_BEGIN
-
-
- -
-
- -
-
- - - - -
#define IN_WRITE_END
-
-
- -
-
- -
-
- - - - -
#define IN_WRITE_END_NOTHROW
-
-
- -
-
- -
-
- - - - -
#define INOTIFY_BUFLEN   (1024 * (INOTIFY_EVENT_SIZE + 16))
-
-
- -

Event buffer length.

- -
-
- -
-
- - - - -
#define INOTIFY_EVENT_SIZE   (sizeof(struct inotify_event))
-
-
- -

Event struct size.

- -
-
-

Typedef Documentation

- -
-
- - - - -
typedef std::map<int32_t, InotifyWatch*> IN_WATCH_MAP
-
-
- -

Mapping from watch descriptors to watch objects.

- -
-
- -
-
- - - - -
typedef std::map<std::string, InotifyWatch*> IN_WP_MAP
-
-
- -

Mapping from paths to watch objects.

- -
-
-

Enumeration Type Documentation

- -
-
- - - - -
enum InotifyCapability_t
-
-
- -

inotify capability/limit identifiers

-
Enumerator:
- - - -
IN_MAX_EVENTS  -

max. events in the kernel queue

-
IN_MAX_INSTANCES  -

max. inotify file descriptors per process

-
IN_MAX_WATCHES  -

max. watches per file descriptor

-
-
-
- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/inotify-cxx_8h_source.html incron-0.5.12/doc/html/inotify-cxx_8h_source.html --- incron-0.5.10/doc/html/inotify-cxx_8h_source.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/inotify-cxx_8h_source.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,549 +0,0 @@ - - - - -incron: inotify-cxx.h Source File - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
inotify-cxx.h
-
-
-Go to the documentation of this file.
00001 
-00003 
-00026 #ifndef _INOTIFYCXX_H_
-00027 #define _INOTIFYCXX_H_
-00028 
-00029 #include <stdint.h>
-00030 #include <string>
-00031 #include <deque>
-00032 #include <map>
-00033 
-00034 // Please ensure that the following headers take the right place
-00035 #include <sys/syscall.h>
-00036 #include <sys/inotify.h>
-00037 
-00038 // Use this if syscalls not defined
-00039 #ifndef __NR_inotify_init
-00040 #include <sys/inotify-syscalls.h>
-00041 #endif // __NR_inotify_init
-00042 
-00044 #define INOTIFY_EVENT_SIZE (sizeof(struct inotify_event))
-00045 
-00047 #define INOTIFY_BUFLEN (1024 * (INOTIFY_EVENT_SIZE + 16))
-00048 
-00050 
-00053 #define IN_EXC_MSG(msg) (std::string(__PRETTY_FUNCTION__) + ": " + msg)
-00054 
-00056 typedef enum
-00057 {
-00058   IN_MAX_EVENTS     = 0,  
-00059   IN_MAX_INSTANCES  = 1,  
-00060   IN_MAX_WATCHES    = 2   
-00061 } InotifyCapability_t;
-00062 
-00064 
-00082 #ifdef INOTIFY_THREAD_SAFE
-00083 
-00084 #include <pthread.h>
-00085 
-00086 #define IN_LOCK_DECL mutable pthread_rwlock_t __m_lock;
-00087 
-00088 #define IN_LOCK_INIT \
-00089   { \
-00090     pthread_rwlockattr_t attr; \
-00091     int res = 0; \
-00092     if ((res = pthread_rwlockattr_init(&attr)) != 0) \
-00093       throw InotifyException(IN_EXC_MSG("cannot initialize lock attributes"), res, this); \
-00094     if ((res = pthread_rwlockattr_setkind_np(&attr, PTHREAD_RWLOCK_PREFER_WRITER_NP)) != 0) \
-00095       throw InotifyException(IN_EXC_MSG("cannot set lock kind"), res, this); \
-00096     if ((res = pthread_rwlock_init(&__m_lock, &attr)) != 0) \
-00097       throw InotifyException(IN_EXC_MSG("cannot initialize lock"), res, this); \
-00098     pthread_rwlockattr_destroy(&attr); \
-00099   }
-00100  
-00101 #define IN_LOCK_DONE pthread_rwlock_destroy(&__m_lock);
-00102 
-00103 #define IN_READ_BEGIN \
-00104   { \
-00105     int res = pthread_rwlock_rdlock(&__m_lock); \
-00106     if (res != 0) \
-00107       throw InotifyException(IN_EXC_MSG("locking for reading failed"), res, (void*) this); \
-00108   }
-00109   
-00110 #define IN_READ_END \
-00111   { \
-00112     int res = pthread_rwlock_unlock(&__m_lock); \
-00113     if (res != 0) \
-00114       throw InotifyException(IN_EXC_MSG("unlocking failed"), res, (void*) this); \
-00115   }
-00116   
-00117 #define IN_READ_END_NOTHROW pthread_rwlock_unlock(&__m_lock);
-00118   
-00119 #define IN_WRITE_BEGIN \
-00120   { \
-00121     int res = pthread_rwlock_wrlock(&__m_lock); \
-00122     if (res != 0) \
-00123       throw InotifyException(IN_EXC_MSG("locking for writing failed"), res, (void*) this); \
-00124   }
-00125   
-00126 #define IN_WRITE_END IN_READ_END
-00127 #define IN_WRITE_END_NOTHROW IN_READ_END_NOTHROW
-00128 
-00129 #else // INOTIFY_THREAD_SAFE
-00130 
-00131 #define IN_LOCK_DECL
-00132 #define IN_LOCK_INIT
-00133 #define IN_LOCK_DONE
-00134 #define IN_READ_BEGIN
-00135 #define IN_READ_END
-00136 #define IN_READ_END_NOTHROW
-00137 #define IN_WRITE_BEGIN
-00138 #define IN_WRITE_END
-00139 #define IN_WRITE_END_NOTHROW
-00140 
-00141 #endif // INOTIFY_THREAD_SAFE
-00142 
-00143 
-00144 
-00145 
-00146 // forward declaration
-00147 class InotifyWatch;
-00148 class Inotify;
-00149 
-00150 
-00152 
-00160 class InotifyException
-00161 {
-00162 public:
-00164 
-00169   InotifyException(const std::string& rMsg = "", int iErr = 0, void* pSrc = NULL)
-00170   : m_msg(rMsg),
-00171     m_err(iErr)
-00172   {
-00173     m_pSrc = pSrc;
-00174   }
-00175   
-00177 
-00180   inline const std::string& GetMessage() const
-00181   {
-00182     return m_msg;
-00183   }
-00184   
-00186 
-00191   inline int GetErrorNumber() const
-00192   {
-00193     return m_err;
-00194   } 
-00195   
-00197 
-00200   inline void* GetSource() const
-00201   {
-00202     return m_pSrc;
-00203   }
-00204 
-00205 protected:
-00206   std::string m_msg;      
-00207   int m_err;              
-00208   mutable void* m_pSrc;   
-00209 };
-00210 
-00211 
-00213 
-00221 class InotifyEvent
-00222 {
-00223 public:
-00225 
-00228   InotifyEvent()
-00229   : m_uMask(0),
-00230     m_uCookie(0)
-00231   {
-00232     m_pWatch = NULL;
-00233   }
-00234   
-00236 
-00243   InotifyEvent(const struct inotify_event* pEvt, InotifyWatch* pWatch)
-00244   : m_uMask(0),
-00245     m_uCookie(0)
-00246   {
-00247     if (pEvt != NULL) {
-00248       m_uMask = (uint32_t) pEvt->mask;
-00249       m_uCookie = (uint32_t) pEvt->cookie;
-00250       if (pEvt->name != NULL) {
-00251         m_name = pEvt->len > 0
-00252             ? pEvt->name
-00253             : "";
-00254       }
-00255       m_pWatch = pWatch;
-00256     }
-00257     else {
-00258       m_pWatch = NULL;
-00259     }
-00260   }
-00261   
-00263   ~InotifyEvent() {}
-00264   
-00266 
-00271   int32_t GetDescriptor() const;
-00272   
-00274 
-00279   inline uint32_t GetMask() const
-00280   {
-00281     return m_uMask;
-00282   }
-00283   
-00285 
-00290   inline static bool IsType(uint32_t uValue, uint32_t uType)
-00291   {
-00292     return ((uValue & uType) != 0) && ((~uValue & uType) == 0);
-00293   }
-00294   
-00296 
-00300   inline bool IsType(uint32_t uType) const
-00301   {
-00302     return IsType(m_uMask, uType);
-00303   }
-00304   
-00306 
-00309   inline uint32_t GetCookie() const
-00310   {
-00311     return m_uCookie;
-00312   }
-00313   
-00315 
-00318   inline uint32_t GetLength() const
-00319   {
-00320     return (uint32_t) m_name.length();
-00321   }
-00322   
-00324 
-00327   inline const std::string& GetName() const
-00328   {
-00329     return m_name;
-00330   }
-00331   
-00333 
-00336   inline void GetName(std::string& rName) const
-00337   {
-00338     rName = GetName();
-00339   }
-00340   
-00342 
-00345   inline InotifyWatch* GetWatch()
-00346   {
-00347     return m_pWatch;
-00348   }
-00349   
-00351 
-00355   static uint32_t GetMaskByName(const std::string& rName);
-00356   
-00358 
-00362   static void DumpTypes(uint32_t uValue, std::string& rStr);
-00363   
-00365 
-00368   void DumpTypes(std::string& rStr) const;
-00369   
-00370 private:
-00371   uint32_t m_uMask;           
-00372   uint32_t m_uCookie;         
-00373   std::string m_name;         
-00374   InotifyWatch* m_pWatch;     
-00375 };
-00376 
-00377 
-00378 
-00380 
-00386 class InotifyWatch
-00387 {
-00388 public:
-00390 
-00398   InotifyWatch(const std::string& rPath, int32_t uMask, bool fEnabled = true)
-00399   : m_path(rPath),
-00400     m_uMask(uMask),
-00401     m_wd((int32_t) -1),
-00402     m_fEnabled(fEnabled)
-00403   {
-00404     IN_LOCK_INIT
-00405   }
-00406   
-00408   ~InotifyWatch()
-00409   {
-00410     IN_LOCK_DONE
-00411   }
-00412   
-00414 
-00417   inline int32_t GetDescriptor() const
-00418   {
-00419     return m_wd;
-00420   }
-00421   
-00423 
-00426   inline const std::string& GetPath() const
-00427   {
-00428     return m_path;
-00429   }
-00430   
-00432 
-00435   inline uint32_t GetMask() const
-00436   {
-00437     return (uint32_t) m_uMask;
-00438   }
-00439   
-00441 
-00450   void SetMask(uint32_t uMask) throw (InotifyException);   
-00451   
-00453 
-00456   inline Inotify* GetInotify()
-00457   {
-00458     return m_pInotify;
-00459   }
-00460   
-00462 
-00473   void SetEnabled(bool fEnabled) throw (InotifyException);
-00474   
-00476 
-00479   inline bool IsEnabled() const
-00480   {
-00481     return m_fEnabled;
-00482   }
-00483   
-00485 
-00494   inline bool IsRecursive() const
-00495   {
-00496     return false;    
-00497   }
-00498   
-00499 private:
-00500   friend class Inotify;
-00501 
-00502   std::string m_path;   
-00503   uint32_t m_uMask;     
-00504   int32_t m_wd;         
-00505   Inotify* m_pInotify;  
-00506   bool m_fEnabled;      
-00507   
-00508   IN_LOCK_DECL
-00509   
-00511 
-00516   void __Disable();
-00517 };
-00518 
-00519 
-00521 typedef std::map<int32_t, InotifyWatch*> IN_WATCH_MAP;
-00522 
-00524 typedef std::map<std::string, InotifyWatch*> IN_WP_MAP;
-00525 
-00526 
-00528 
-00534 class Inotify
-00535 {
-00536 public:
-00538 
-00544   Inotify() throw (InotifyException);
-00545   
-00547 
-00550   ~Inotify();
-00551   
-00553   void Close();
-00554     
-00556 
-00561   void Add(InotifyWatch* pWatch) throw (InotifyException);
-00562   
-00564 
-00569   inline void Add(InotifyWatch& rWatch) throw (InotifyException)
-00570   {
-00571     Add(&rWatch);
-00572   }
-00573   
-00575 
-00582   void Remove(InotifyWatch* pWatch) throw (InotifyException);
-00583   
-00585 
-00592   inline void Remove(InotifyWatch& rWatch) throw (InotifyException)
-00593   {
-00594     Remove(&rWatch);
-00595   }
-00596   
-00598   void RemoveAll();
-00599   
-00601 
-00609   inline size_t GetWatchCount() const
-00610   {
-00611     IN_READ_BEGIN
-00612     size_t n = (size_t) m_paths.size();
-00613     IN_READ_END
-00614     return n;
-00615   }
-00616   
-00618 
-00623   inline size_t GetEnabledCount() const
-00624   {
-00625     IN_READ_BEGIN
-00626     size_t n = (size_t) m_watches.size();
-00627     IN_READ_END
-00628     return n;
-00629   }
-00630   
-00632 
-00643   void WaitForEvents(bool fNoIntr = false) throw (InotifyException);
-00644   
-00646 
-00652   inline size_t GetEventCount()
-00653   {
-00654     IN_READ_BEGIN
-00655     size_t n = (size_t) m_events.size();
-00656     IN_READ_END
-00657     return n;
-00658   }
-00659   
-00661 
-00669   bool GetEvent(InotifyEvent* pEvt) throw (InotifyException);
-00670   
-00672 
-00679   bool GetEvent(InotifyEvent& rEvt) throw (InotifyException)
-00680   {
-00681     return GetEvent(&rEvt);
-00682   }
-00683   
-00685 
-00693   bool PeekEvent(InotifyEvent* pEvt) throw (InotifyException);
-00694   
-00696 
-00703   bool PeekEvent(InotifyEvent& rEvt) throw (InotifyException)
-00704   {
-00705     return PeekEvent(&rEvt);
-00706   }
-00707   
-00709 
-00715   InotifyWatch* FindWatch(int iDescriptor);
-00716   
-00718 
-00728    InotifyWatch* FindWatch(const std::string& rPath);
-00729   
-00731 
-00739   inline int GetDescriptor() const
-00740   {
-00741     return m_fd;
-00742   }
-00743   
-00745 
-00758   void SetNonBlock(bool fNonBlock) throw (InotifyException);
-00759   
-00761 
-00774   void SetCloseOnExec(bool fClOnEx) throw (InotifyException);
-00775   
-00777 
-00782   static uint32_t GetCapability(InotifyCapability_t cap) throw (InotifyException);
-00783   
-00785 
-00793   static void SetCapability(InotifyCapability_t cap, uint32_t val) throw (InotifyException);
-00794   
-00796 
-00800   inline static uint32_t GetMaxEvents() throw (InotifyException)
-00801   {
-00802     return GetCapability(IN_MAX_EVENTS);
-00803   }
-00804   
-00806 
-00814   inline static void SetMaxEvents(uint32_t val) throw (InotifyException)
-00815   {
-00816     SetCapability(IN_MAX_EVENTS, val);
-00817   }
-00818   
-00820 
-00827   inline static uint32_t GetMaxInstances() throw (InotifyException)
-00828   {
-00829     return GetCapability(IN_MAX_INSTANCES);
-00830   }
-00831   
-00833 
-00841   inline static void SetMaxInstances(uint32_t val) throw (InotifyException)
-00842   {
-00843     SetCapability(IN_MAX_INSTANCES, val);
-00844   }
-00845   
-00847 
-00854   inline static uint32_t GetMaxWatches() throw (InotifyException)
-00855   {
-00856     return GetCapability(IN_MAX_WATCHES);
-00857   }
-00858   
-00860 
-00868   inline static void SetMaxWatches(uint32_t val) throw (InotifyException)
-00869   {
-00870     SetCapability(IN_MAX_WATCHES, val);
-00871   }
-00872 
-00873 private: 
-00874   int m_fd;                             
-00875   IN_WATCH_MAP m_watches;               
-00876   IN_WP_MAP m_paths;                    
-00877   unsigned char m_buf[INOTIFY_BUFLEN];  
-00878   std::deque<InotifyEvent> m_events;    
-00879   
-00880   IN_LOCK_DECL
-00881   
-00882   friend class InotifyWatch;
-00883   
-00884   static std::string GetCapabilityPath(InotifyCapability_t cap) throw (InotifyException);
-00885 };
-00886 
-00887 
-00888 #endif //_INOTIFYCXX_H_
-00889 
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/jquery.js incron-0.5.12/doc/html/jquery.js --- incron-0.5.10/doc/html/jquery.js 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/jquery.js 1970-01-01 00:00:00.000000000 +0000 @@ -1,54 +0,0 @@ -/* - * jQuery JavaScript Library v1.3.2 - * http://jquery.com/ - * - * Copyright (c) 2009 John Resig - * Dual licensed under the MIT and GPL licenses. - * http://docs.jquery.com/License - * - * Date: 2009-02-19 17:34:21 -0500 (Thu, 19 Feb 2009) - * Revision: 6246 - */ -(function(){var l=this,g,y=l.jQuery,p=l.$,o=l.jQuery=l.$=function(E,F){return new o.fn.init(E,F)},D=/^[^<]*(<(.|\s)+>)[^>]*$|^#([\w-]+)$/,f=/^.[^:#\[\.,]*$/;o.fn=o.prototype={init:function(E,H){E=E||document;if(E.nodeType){this[0]=E;this.length=1;this.context=E;return this}if(typeof E==="string"){var G=D.exec(E);if(G&&(G[1]||!H)){if(G[1]){E=o.clean([G[1]],H)}else{var I=document.getElementById(G[3]);if(I&&I.id!=G[3]){return o().find(E)}var F=o(I||[]);F.context=document;F.selector=E;return F}}else{return o(H).find(E)}}else{if(o.isFunction(E)){return o(document).ready(E)}}if(E.selector&&E.context){this.selector=E.selector;this.context=E.context}return this.setArray(o.isArray(E)?E:o.makeArray(E))},selector:"",jquery:"1.3.2",size:function(){return this.length},get:function(E){return E===g?Array.prototype.slice.call(this):this[E]},pushStack:function(F,H,E){var G=o(F);G.prevObject=this;G.context=this.context;if(H==="find"){G.selector=this.selector+(this.selector?" ":"")+E}else{if(H){G.selector=this.selector+"."+H+"("+E+")"}}return G},setArray:function(E){this.length=0;Array.prototype.push.apply(this,E);return this},each:function(F,E){return o.each(this,F,E)},index:function(E){return o.inArray(E&&E.jquery?E[0]:E,this)},attr:function(F,H,G){var E=F;if(typeof F==="string"){if(H===g){return this[0]&&o[G||"attr"](this[0],F)}else{E={};E[F]=H}}return this.each(function(I){for(F in E){o.attr(G?this.style:this,F,o.prop(this,E[F],G,I,F))}})},css:function(E,F){if((E=="width"||E=="height")&&parseFloat(F)<0){F=g}return this.attr(E,F,"curCSS")},text:function(F){if(typeof F!=="object"&&F!=null){return this.empty().append((this[0]&&this[0].ownerDocument||document).createTextNode(F))}var E="";o.each(F||this,function(){o.each(this.childNodes,function(){if(this.nodeType!=8){E+=this.nodeType!=1?this.nodeValue:o.fn.text([this])}})});return E},wrapAll:function(E){if(this[0]){var F=o(E,this[0].ownerDocument).clone();if(this[0].parentNode){F.insertBefore(this[0])}F.map(function(){var G=this;while(G.firstChild){G=G.firstChild}return G}).append(this)}return this},wrapInner:function(E){return this.each(function(){o(this).contents().wrapAll(E)})},wrap:function(E){return this.each(function(){o(this).wrapAll(E)})},append:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.appendChild(E)}})},prepend:function(){return this.domManip(arguments,true,function(E){if(this.nodeType==1){this.insertBefore(E,this.firstChild)}})},before:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this)})},after:function(){return this.domManip(arguments,false,function(E){this.parentNode.insertBefore(E,this.nextSibling)})},end:function(){return this.prevObject||o([])},push:[].push,sort:[].sort,splice:[].splice,find:function(E){if(this.length===1){var F=this.pushStack([],"find",E);F.length=0;o.find(E,this[0],F);return F}else{return this.pushStack(o.unique(o.map(this,function(G){return o.find(E,G)})),"find",E)}},clone:function(G){var E=this.map(function(){if(!o.support.noCloneEvent&&!o.isXMLDoc(this)){var I=this.outerHTML;if(!I){var J=this.ownerDocument.createElement("div");J.appendChild(this.cloneNode(true));I=J.innerHTML}return o.clean([I.replace(/ jQuery\d+="(?:\d+|null)"/g,"").replace(/^\s*/,"")])[0]}else{return this.cloneNode(true)}});if(G===true){var H=this.find("*").andSelf(),F=0;E.find("*").andSelf().each(function(){if(this.nodeName!==H[F].nodeName){return}var I=o.data(H[F],"events");for(var K in I){for(var J in I[K]){o.event.add(this,K,I[K][J],I[K][J].data)}}F++})}return E},filter:function(E){return this.pushStack(o.isFunction(E)&&o.grep(this,function(G,F){return E.call(G,F)})||o.multiFilter(E,o.grep(this,function(F){return F.nodeType===1})),"filter",E)},closest:function(E){var G=o.expr.match.POS.test(E)?o(E):null,F=0;return this.map(function(){var H=this;while(H&&H.ownerDocument){if(G?G.index(H)>-1:o(H).is(E)){o.data(H,"closest",F);return H}H=H.parentNode;F++}})},not:function(E){if(typeof E==="string"){if(f.test(E)){return this.pushStack(o.multiFilter(E,this,true),"not",E)}else{E=o.multiFilter(E,this)}}var F=E.length&&E[E.length-1]!==g&&!E.nodeType;return this.filter(function(){return F?o.inArray(this,E)<0:this!=E})},add:function(E){return this.pushStack(o.unique(o.merge(this.get(),typeof E==="string"?o(E):o.makeArray(E))))},is:function(E){return !!E&&o.multiFilter(E,this).length>0},hasClass:function(E){return !!E&&this.is("."+E)},val:function(K){if(K===g){var E=this[0];if(E){if(o.nodeName(E,"option")){return(E.attributes.value||{}).specified?E.value:E.text}if(o.nodeName(E,"select")){var I=E.selectedIndex,L=[],M=E.options,H=E.type=="select-one";if(I<0){return null}for(var F=H?I:0,J=H?I+1:M.length;F=0||o.inArray(this.name,K)>=0)}else{if(o.nodeName(this,"select")){var N=o.makeArray(K);o("option",this).each(function(){this.selected=(o.inArray(this.value,N)>=0||o.inArray(this.text,N)>=0)});if(!N.length){this.selectedIndex=-1}}else{this.value=K}}})},html:function(E){return E===g?(this[0]?this[0].innerHTML.replace(/ jQuery\d+="(?:\d+|null)"/g,""):null):this.empty().append(E)},replaceWith:function(E){return this.after(E).remove()},eq:function(E){return this.slice(E,+E+1)},slice:function(){return this.pushStack(Array.prototype.slice.apply(this,arguments),"slice",Array.prototype.slice.call(arguments).join(","))},map:function(E){return this.pushStack(o.map(this,function(G,F){return E.call(G,F,G)}))},andSelf:function(){return this.add(this.prevObject)},domManip:function(J,M,L){if(this[0]){var I=(this[0].ownerDocument||this[0]).createDocumentFragment(),F=o.clean(J,(this[0].ownerDocument||this[0]),I),H=I.firstChild;if(H){for(var G=0,E=this.length;G1||G>0?I.cloneNode(true):I)}}if(F){o.each(F,z)}}return this;function K(N,O){return M&&o.nodeName(N,"table")&&o.nodeName(O,"tr")?(N.getElementsByTagName("tbody")[0]||N.appendChild(N.ownerDocument.createElement("tbody"))):N}}};o.fn.init.prototype=o.fn;function z(E,F){if(F.src){o.ajax({url:F.src,async:false,dataType:"script"})}else{o.globalEval(F.text||F.textContent||F.innerHTML||"")}if(F.parentNode){F.parentNode.removeChild(F)}}function e(){return +new Date}o.extend=o.fn.extend=function(){var J=arguments[0]||{},H=1,I=arguments.length,E=false,G;if(typeof J==="boolean"){E=J;J=arguments[1]||{};H=2}if(typeof J!=="object"&&!o.isFunction(J)){J={}}if(I==H){J=this;--H}for(;H-1}},swap:function(H,G,I){var E={};for(var F in G){E[F]=H.style[F];H.style[F]=G[F]}I.call(H);for(var F in G){H.style[F]=E[F]}},css:function(H,F,J,E){if(F=="width"||F=="height"){var L,G={position:"absolute",visibility:"hidden",display:"block"},K=F=="width"?["Left","Right"]:["Top","Bottom"];function I(){L=F=="width"?H.offsetWidth:H.offsetHeight;if(E==="border"){return}o.each(K,function(){if(!E){L-=parseFloat(o.curCSS(H,"padding"+this,true))||0}if(E==="margin"){L+=parseFloat(o.curCSS(H,"margin"+this,true))||0}else{L-=parseFloat(o.curCSS(H,"border"+this+"Width",true))||0}})}if(H.offsetWidth!==0){I()}else{o.swap(H,G,I)}return Math.max(0,Math.round(L))}return o.curCSS(H,F,J)},curCSS:function(I,F,G){var L,E=I.style;if(F=="opacity"&&!o.support.opacity){L=o.attr(E,"opacity");return L==""?"1":L}if(F.match(/float/i)){F=w}if(!G&&E&&E[F]){L=E[F]}else{if(q.getComputedStyle){if(F.match(/float/i)){F="float"}F=F.replace(/([A-Z])/g,"-$1").toLowerCase();var M=q.getComputedStyle(I,null);if(M){L=M.getPropertyValue(F)}if(F=="opacity"&&L==""){L="1"}}else{if(I.currentStyle){var J=F.replace(/\-(\w)/g,function(N,O){return O.toUpperCase()});L=I.currentStyle[F]||I.currentStyle[J];if(!/^\d+(px)?$/i.test(L)&&/^\d/.test(L)){var H=E.left,K=I.runtimeStyle.left;I.runtimeStyle.left=I.currentStyle.left;E.left=L||0;L=E.pixelLeft+"px";E.left=H;I.runtimeStyle.left=K}}}}return L},clean:function(F,K,I){K=K||document;if(typeof K.createElement==="undefined"){K=K.ownerDocument||K[0]&&K[0].ownerDocument||document}if(!I&&F.length===1&&typeof F[0]==="string"){var H=/^<(\w+)\s*\/?>$/.exec(F[0]);if(H){return[K.createElement(H[1])]}}var G=[],E=[],L=K.createElement("div");o.each(F,function(P,S){if(typeof S==="number"){S+=""}if(!S){return}if(typeof S==="string"){S=S.replace(/(<(\w+)[^>]*?)\/>/g,function(U,V,T){return T.match(/^(abbr|br|col|img|input|link|meta|param|hr|area|embed)$/i)?U:V+">"});var O=S.replace(/^\s+/,"").substring(0,10).toLowerCase();var Q=!O.indexOf("",""]||!O.indexOf("",""]||O.match(/^<(thead|tbody|tfoot|colg|cap)/)&&[1,"","
"]||!O.indexOf("",""]||(!O.indexOf("",""]||!O.indexOf("",""]||!o.support.htmlSerialize&&[1,"div
","
"]||[0,"",""];L.innerHTML=Q[1]+S+Q[2];while(Q[0]--){L=L.lastChild}if(!o.support.tbody){var R=/"&&!R?L.childNodes:[];for(var M=N.length-1;M>=0;--M){if(o.nodeName(N[M],"tbody")&&!N[M].childNodes.length){N[M].parentNode.removeChild(N[M])}}}if(!o.support.leadingWhitespace&&/^\s/.test(S)){L.insertBefore(K.createTextNode(S.match(/^\s*/)[0]),L.firstChild)}S=o.makeArray(L.childNodes)}if(S.nodeType){G.push(S)}else{G=o.merge(G,S)}});if(I){for(var J=0;G[J];J++){if(o.nodeName(G[J],"script")&&(!G[J].type||G[J].type.toLowerCase()==="text/javascript")){E.push(G[J].parentNode?G[J].parentNode.removeChild(G[J]):G[J])}else{if(G[J].nodeType===1){G.splice.apply(G,[J+1,0].concat(o.makeArray(G[J].getElementsByTagName("script"))))}I.appendChild(G[J])}}return E}return G},attr:function(J,G,K){if(!J||J.nodeType==3||J.nodeType==8){return g}var H=!o.isXMLDoc(J),L=K!==g;G=H&&o.props[G]||G;if(J.tagName){var F=/href|src|style/.test(G);if(G=="selected"&&J.parentNode){J.parentNode.selectedIndex}if(G in J&&H&&!F){if(L){if(G=="type"&&o.nodeName(J,"input")&&J.parentNode){throw"type property can't be changed"}J[G]=K}if(o.nodeName(J,"form")&&J.getAttributeNode(G)){return J.getAttributeNode(G).nodeValue}if(G=="tabIndex"){var I=J.getAttributeNode("tabIndex");return I&&I.specified?I.value:J.nodeName.match(/(button|input|object|select|textarea)/i)?0:J.nodeName.match(/^(a|area)$/i)&&J.href?0:g}return J[G]}if(!o.support.style&&H&&G=="style"){return o.attr(J.style,"cssText",K)}if(L){J.setAttribute(G,""+K)}var E=!o.support.hrefNormalized&&H&&F?J.getAttribute(G,2):J.getAttribute(G);return E===null?g:E}if(!o.support.opacity&&G=="opacity"){if(L){J.zoom=1;J.filter=(J.filter||"").replace(/alpha\([^)]*\)/,"")+(parseInt(K)+""=="NaN"?"":"alpha(opacity="+K*100+")")}return J.filter&&J.filter.indexOf("opacity=")>=0?(parseFloat(J.filter.match(/opacity=([^)]*)/)[1])/100)+"":""}G=G.replace(/-([a-z])/ig,function(M,N){return N.toUpperCase()});if(L){J[G]=K}return J[G]},trim:function(E){return(E||"").replace(/^\s+|\s+$/g,"")},makeArray:function(G){var E=[];if(G!=null){var F=G.length;if(F==null||typeof G==="string"||o.isFunction(G)||G.setInterval){E[0]=G}else{while(F){E[--F]=G[F]}}}return E},inArray:function(G,H){for(var E=0,F=H.length;E0?this.clone(true):this).get();o.fn[F].apply(o(L[K]),I);J=J.concat(I)}return this.pushStack(J,E,G)}});o.each({removeAttr:function(E){o.attr(this,E,"");if(this.nodeType==1){this.removeAttribute(E)}},addClass:function(E){o.className.add(this,E)},removeClass:function(E){o.className.remove(this,E)},toggleClass:function(F,E){if(typeof E!=="boolean"){E=!o.className.has(this,F)}o.className[E?"add":"remove"](this,F)},remove:function(E){if(!E||o.filter(E,[this]).length){o("*",this).add([this]).each(function(){o.event.remove(this);o.removeData(this)});if(this.parentNode){this.parentNode.removeChild(this)}}},empty:function(){o(this).children().remove();while(this.firstChild){this.removeChild(this.firstChild)}}},function(E,F){o.fn[E]=function(){return this.each(F,arguments)}});function j(E,F){return E[0]&&parseInt(o.curCSS(E[0],F,true),10)||0}var h="jQuery"+e(),v=0,A={};o.extend({cache:{},data:function(F,E,G){F=F==l?A:F;var H=F[h];if(!H){H=F[h]=++v}if(E&&!o.cache[H]){o.cache[H]={}}if(G!==g){o.cache[H][E]=G}return E?o.cache[H][E]:H},removeData:function(F,E){F=F==l?A:F;var H=F[h];if(E){if(o.cache[H]){delete o.cache[H][E];E="";for(E in o.cache[H]){break}if(!E){o.removeData(F)}}}else{try{delete F[h]}catch(G){if(F.removeAttribute){F.removeAttribute(h)}}delete o.cache[H]}},queue:function(F,E,H){if(F){E=(E||"fx")+"queue";var G=o.data(F,E);if(!G||o.isArray(H)){G=o.data(F,E,o.makeArray(H))}else{if(H){G.push(H)}}}return G},dequeue:function(H,G){var E=o.queue(H,G),F=E.shift();if(!G||G==="fx"){F=E[0]}if(F!==g){F.call(H)}}});o.fn.extend({data:function(E,G){var H=E.split(".");H[1]=H[1]?"."+H[1]:"";if(G===g){var F=this.triggerHandler("getData"+H[1]+"!",[H[0]]);if(F===g&&this.length){F=o.data(this[0],E)}return F===g&&H[1]?this.data(H[0]):F}else{return this.trigger("setData"+H[1]+"!",[H[0],G]).each(function(){o.data(this,E,G)})}},removeData:function(E){return this.each(function(){o.removeData(this,E)})},queue:function(E,F){if(typeof E!=="string"){F=E;E="fx"}if(F===g){return o.queue(this[0],E)}return this.each(function(){var G=o.queue(this,E,F);if(E=="fx"&&G.length==1){G[0].call(this)}})},dequeue:function(E){return this.each(function(){o.dequeue(this,E)})}}); -/* - * Sizzle CSS Selector Engine - v0.9.3 - * Copyright 2009, The Dojo Foundation - * Released under the MIT, BSD, and GPL Licenses. - * More information: http://sizzlejs.com/ - */ -(function(){var R=/((?:\((?:\([^()]+\)|[^()]+)+\)|\[(?:\[[^[\]]*\]|['"][^'"]*['"]|[^[\]'"]+)+\]|\\.|[^ >+~,(\[\\]+)+|[>+~])(\s*,\s*)?/g,L=0,H=Object.prototype.toString;var F=function(Y,U,ab,ac){ab=ab||[];U=U||document;if(U.nodeType!==1&&U.nodeType!==9){return[]}if(!Y||typeof Y!=="string"){return ab}var Z=[],W,af,ai,T,ad,V,X=true;R.lastIndex=0;while((W=R.exec(Y))!==null){Z.push(W[1]);if(W[2]){V=RegExp.rightContext;break}}if(Z.length>1&&M.exec(Y)){if(Z.length===2&&I.relative[Z[0]]){af=J(Z[0]+Z[1],U)}else{af=I.relative[Z[0]]?[U]:F(Z.shift(),U);while(Z.length){Y=Z.shift();if(I.relative[Y]){Y+=Z.shift()}af=J(Y,af)}}}else{var ae=ac?{expr:Z.pop(),set:E(ac)}:F.find(Z.pop(),Z.length===1&&U.parentNode?U.parentNode:U,Q(U));af=F.filter(ae.expr,ae.set);if(Z.length>0){ai=E(af)}else{X=false}while(Z.length){var ah=Z.pop(),ag=ah;if(!I.relative[ah]){ah=""}else{ag=Z.pop()}if(ag==null){ag=U}I.relative[ah](ai,ag,Q(U))}}if(!ai){ai=af}if(!ai){throw"Syntax error, unrecognized expression: "+(ah||Y)}if(H.call(ai)==="[object Array]"){if(!X){ab.push.apply(ab,ai)}else{if(U.nodeType===1){for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&(ai[aa]===true||ai[aa].nodeType===1&&K(U,ai[aa]))){ab.push(af[aa])}}}else{for(var aa=0;ai[aa]!=null;aa++){if(ai[aa]&&ai[aa].nodeType===1){ab.push(af[aa])}}}}}else{E(ai,ab)}if(V){F(V,U,ab,ac);if(G){hasDuplicate=false;ab.sort(G);if(hasDuplicate){for(var aa=1;aa":function(Z,U,aa){var X=typeof U==="string";if(X&&!/\W/.test(U)){U=aa?U:U.toUpperCase();for(var V=0,T=Z.length;V=0)){if(!V){T.push(Y)}}else{if(V){U[X]=false}}}}return false},ID:function(T){return T[1].replace(/\\/g,"")},TAG:function(U,T){for(var V=0;T[V]===false;V++){}return T[V]&&Q(T[V])?U[1]:U[1].toUpperCase()},CHILD:function(T){if(T[1]=="nth"){var U=/(-?)(\d*)n((?:\+|-)?\d*)/.exec(T[2]=="even"&&"2n"||T[2]=="odd"&&"2n+1"||!/\D/.test(T[2])&&"0n+"+T[2]||T[2]);T[2]=(U[1]+(U[2]||1))-0;T[3]=U[3]-0}T[0]=L++;return T},ATTR:function(X,U,V,T,Y,Z){var W=X[1].replace(/\\/g,"");if(!Z&&I.attrMap[W]){X[1]=I.attrMap[W]}if(X[2]==="~="){X[4]=" "+X[4]+" "}return X},PSEUDO:function(X,U,V,T,Y){if(X[1]==="not"){if(X[3].match(R).length>1||/^\w/.test(X[3])){X[3]=F(X[3],null,null,U)}else{var W=F.filter(X[3],U,V,true^Y);if(!V){T.push.apply(T,W)}return false}}else{if(I.match.POS.test(X[0])||I.match.CHILD.test(X[0])){return true}}return X},POS:function(T){T.unshift(true);return T}},filters:{enabled:function(T){return T.disabled===false&&T.type!=="hidden"},disabled:function(T){return T.disabled===true},checked:function(T){return T.checked===true},selected:function(T){T.parentNode.selectedIndex;return T.selected===true},parent:function(T){return !!T.firstChild},empty:function(T){return !T.firstChild},has:function(V,U,T){return !!F(T[3],V).length},header:function(T){return/h\d/i.test(T.nodeName)},text:function(T){return"text"===T.type},radio:function(T){return"radio"===T.type},checkbox:function(T){return"checkbox"===T.type},file:function(T){return"file"===T.type},password:function(T){return"password"===T.type},submit:function(T){return"submit"===T.type},image:function(T){return"image"===T.type},reset:function(T){return"reset"===T.type},button:function(T){return"button"===T.type||T.nodeName.toUpperCase()==="BUTTON"},input:function(T){return/input|select|textarea|button/i.test(T.nodeName)}},setFilters:{first:function(U,T){return T===0},last:function(V,U,T,W){return U===W.length-1},even:function(U,T){return T%2===0},odd:function(U,T){return T%2===1},lt:function(V,U,T){return UT[3]-0},nth:function(V,U,T){return T[3]-0==U},eq:function(V,U,T){return T[3]-0==U}},filter:{PSEUDO:function(Z,V,W,aa){var U=V[1],X=I.filters[U];if(X){return X(Z,W,V,aa)}else{if(U==="contains"){return(Z.textContent||Z.innerText||"").indexOf(V[3])>=0}else{if(U==="not"){var Y=V[3];for(var W=0,T=Y.length;W=0)}}},ID:function(U,T){return U.nodeType===1&&U.getAttribute("id")===T},TAG:function(U,T){return(T==="*"&&U.nodeType===1)||U.nodeName===T},CLASS:function(U,T){return(" "+(U.className||U.getAttribute("class"))+" ").indexOf(T)>-1},ATTR:function(Y,W){var V=W[1],T=I.attrHandle[V]?I.attrHandle[V](Y):Y[V]!=null?Y[V]:Y.getAttribute(V),Z=T+"",X=W[2],U=W[4];return T==null?X==="!=":X==="="?Z===U:X==="*="?Z.indexOf(U)>=0:X==="~="?(" "+Z+" ").indexOf(U)>=0:!U?Z&&T!==false:X==="!="?Z!=U:X==="^="?Z.indexOf(U)===0:X==="$="?Z.substr(Z.length-U.length)===U:X==="|="?Z===U||Z.substr(0,U.length+1)===U+"-":false},POS:function(X,U,V,Y){var T=U[2],W=I.setFilters[T];if(W){return W(X,V,U,Y)}}}};var M=I.match.POS;for(var O in I.match){I.match[O]=RegExp(I.match[O].source+/(?![^\[]*\])(?![^\(]*\))/.source)}var E=function(U,T){U=Array.prototype.slice.call(U);if(T){T.push.apply(T,U);return T}return U};try{Array.prototype.slice.call(document.documentElement.childNodes)}catch(N){E=function(X,W){var U=W||[];if(H.call(X)==="[object Array]"){Array.prototype.push.apply(U,X)}else{if(typeof X.length==="number"){for(var V=0,T=X.length;V";var T=document.documentElement;T.insertBefore(U,T.firstChild);if(!!document.getElementById(V)){I.find.ID=function(X,Y,Z){if(typeof Y.getElementById!=="undefined"&&!Z){var W=Y.getElementById(X[1]);return W?W.id===X[1]||typeof W.getAttributeNode!=="undefined"&&W.getAttributeNode("id").nodeValue===X[1]?[W]:g:[]}};I.filter.ID=function(Y,W){var X=typeof Y.getAttributeNode!=="undefined"&&Y.getAttributeNode("id");return Y.nodeType===1&&X&&X.nodeValue===W}}T.removeChild(U)})();(function(){var T=document.createElement("div");T.appendChild(document.createComment(""));if(T.getElementsByTagName("*").length>0){I.find.TAG=function(U,Y){var X=Y.getElementsByTagName(U[1]);if(U[1]==="*"){var W=[];for(var V=0;X[V];V++){if(X[V].nodeType===1){W.push(X[V])}}X=W}return X}}T.innerHTML="";if(T.firstChild&&typeof T.firstChild.getAttribute!=="undefined"&&T.firstChild.getAttribute("href")!=="#"){I.attrHandle.href=function(U){return U.getAttribute("href",2)}}})();if(document.querySelectorAll){(function(){var T=F,U=document.createElement("div");U.innerHTML="

";if(U.querySelectorAll&&U.querySelectorAll(".TEST").length===0){return}F=function(Y,X,V,W){X=X||document;if(!W&&X.nodeType===9&&!Q(X)){try{return E(X.querySelectorAll(Y),V)}catch(Z){}}return T(Y,X,V,W)};F.find=T.find;F.filter=T.filter;F.selectors=T.selectors;F.matches=T.matches})()}if(document.getElementsByClassName&&document.documentElement.getElementsByClassName){(function(){var T=document.createElement("div");T.innerHTML="
";if(T.getElementsByClassName("e").length===0){return}T.lastChild.className="e";if(T.getElementsByClassName("e").length===1){return}I.order.splice(1,0,"CLASS");I.find.CLASS=function(U,V,W){if(typeof V.getElementsByClassName!=="undefined"&&!W){return V.getElementsByClassName(U[1])}}})()}function P(U,Z,Y,ad,aa,ac){var ab=U=="previousSibling"&&!ac;for(var W=0,V=ad.length;W0){X=T;break}}}T=T[U]}ad[W]=X}}}var K=document.compareDocumentPosition?function(U,T){return U.compareDocumentPosition(T)&16}:function(U,T){return U!==T&&(U.contains?U.contains(T):true)};var Q=function(T){return T.nodeType===9&&T.documentElement.nodeName!=="HTML"||!!T.ownerDocument&&Q(T.ownerDocument)};var J=function(T,aa){var W=[],X="",Y,V=aa.nodeType?[aa]:aa;while((Y=I.match.PSEUDO.exec(T))){X+=Y[0];T=T.replace(I.match.PSEUDO,"")}T=I.relative[T]?T+"*":T;for(var Z=0,U=V.length;Z0||T.offsetHeight>0};F.selectors.filters.animated=function(T){return o.grep(o.timers,function(U){return T===U.elem}).length};o.multiFilter=function(V,T,U){if(U){V=":not("+V+")"}return F.matches(V,T)};o.dir=function(V,U){var T=[],W=V[U];while(W&&W!=document){if(W.nodeType==1){T.push(W)}W=W[U]}return T};o.nth=function(X,T,V,W){T=T||1;var U=0;for(;X;X=X[V]){if(X.nodeType==1&&++U==T){break}}return X};o.sibling=function(V,U){var T=[];for(;V;V=V.nextSibling){if(V.nodeType==1&&V!=U){T.push(V)}}return T};return;l.Sizzle=F})();o.event={add:function(I,F,H,K){if(I.nodeType==3||I.nodeType==8){return}if(I.setInterval&&I!=l){I=l}if(!H.guid){H.guid=this.guid++}if(K!==g){var G=H;H=this.proxy(G);H.data=K}var E=o.data(I,"events")||o.data(I,"events",{}),J=o.data(I,"handle")||o.data(I,"handle",function(){return typeof o!=="undefined"&&!o.event.triggered?o.event.handle.apply(arguments.callee.elem,arguments):g});J.elem=I;o.each(F.split(/\s+/),function(M,N){var O=N.split(".");N=O.shift();H.type=O.slice().sort().join(".");var L=E[N];if(o.event.specialAll[N]){o.event.specialAll[N].setup.call(I,K,O)}if(!L){L=E[N]={};if(!o.event.special[N]||o.event.special[N].setup.call(I,K,O)===false){if(I.addEventListener){I.addEventListener(N,J,false)}else{if(I.attachEvent){I.attachEvent("on"+N,J)}}}}L[H.guid]=H;o.event.global[N]=true});I=null},guid:1,global:{},remove:function(K,H,J){if(K.nodeType==3||K.nodeType==8){return}var G=o.data(K,"events"),F,E;if(G){if(H===g||(typeof H==="string"&&H.charAt(0)==".")){for(var I in G){this.remove(K,I+(H||""))}}else{if(H.type){J=H.handler;H=H.type}o.each(H.split(/\s+/),function(M,O){var Q=O.split(".");O=Q.shift();var N=RegExp("(^|\\.)"+Q.slice().sort().join(".*\\.")+"(\\.|$)");if(G[O]){if(J){delete G[O][J.guid]}else{for(var P in G[O]){if(N.test(G[O][P].type)){delete G[O][P]}}}if(o.event.specialAll[O]){o.event.specialAll[O].teardown.call(K,Q)}for(F in G[O]){break}if(!F){if(!o.event.special[O]||o.event.special[O].teardown.call(K,Q)===false){if(K.removeEventListener){K.removeEventListener(O,o.data(K,"handle"),false)}else{if(K.detachEvent){K.detachEvent("on"+O,o.data(K,"handle"))}}}F=null;delete G[O]}}})}for(F in G){break}if(!F){var L=o.data(K,"handle");if(L){L.elem=null}o.removeData(K,"events");o.removeData(K,"handle")}}},trigger:function(I,K,H,E){var G=I.type||I;if(!E){I=typeof I==="object"?I[h]?I:o.extend(o.Event(G),I):o.Event(G);if(G.indexOf("!")>=0) -{I.type=G=G.slice(0,-1);I.exclusive=true}if(!H){I.stopPropagation();if(this.global[G]){o.each(o.cache,function(){if(this.events&&this.events[G]){o.event.trigger(I,K,this.handle.elem)}})}}if(!H||H.nodeType==3||H.nodeType==8){return g}I.result=g;I.target=H;K=o.makeArray(K);K.unshift(I)}I.currentTarget=H;var J=o.data(H,"handle");if(J){J.apply(H,K)}if((!H[G]||(o.nodeName(H,"a")&&G=="click"))&&H["on"+G]&&H["on"+G].apply(H,K)===false){I.result=false}if(!E&&H[G]&&!I.isDefaultPrevented()&&!(o.nodeName(H,"a")&&G=="click")){this.triggered=true;try{H[G]()}catch(L){}}this.triggered=false;if(!I.isPropagationStopped()){var F=H.parentNode||H.ownerDocument;if(F){o.event.trigger(I,K,F,true)}}},handle:function(K){var J,E;K=arguments[0]=o.event.fix(K||l.event);K.currentTarget=this;var L=K.type.split(".");K.type=L.shift();J=!L.length&&!K.exclusive;var I=RegExp("(^|\\.)"+L.slice().sort().join(".*\\.")+"(\\.|$)");E=(o.data(this,"events")||{})[K.type];for(var G in E){var H=E[G];if(J||I.test(H.type)){K.handler=H;K.data=H.data;var F=H.apply(this,arguments);if(F!==g){K.result=F;if(F===false){K.preventDefault();K.stopPropagation()}}if(K.isImmediatePropagationStopped()){break}}}},props:"altKey attrChange attrName bubbles button cancelable charCode clientX clientY ctrlKey currentTarget data detail eventPhase fromElement handler keyCode metaKey newValue originalTarget pageX pageY prevValue relatedNode relatedTarget screenX screenY shiftKey srcElement target toElement view wheelDelta which".split(" "),fix:function(H){if(H[h]){return H}var F=H;H=o.Event(F);for(var G=this.props.length,J;G;){J=this.props[--G];H[J]=F[J]}if(!H.target){H.target=H.srcElement||document}if(H.target.nodeType==3){H.target=H.target.parentNode}if(!H.relatedTarget&&H.fromElement){H.relatedTarget=H.fromElement==H.target?H.toElement:H.fromElement}if(H.pageX==null&&H.clientX!=null){var I=document.documentElement,E=document.body;H.pageX=H.clientX+(I&&I.scrollLeft||E&&E.scrollLeft||0)-(I.clientLeft||0);H.pageY=H.clientY+(I&&I.scrollTop||E&&E.scrollTop||0)-(I.clientTop||0)}if(!H.which&&((H.charCode||H.charCode===0)?H.charCode:H.keyCode)){H.which=H.charCode||H.keyCode}if(!H.metaKey&&H.ctrlKey){H.metaKey=H.ctrlKey}if(!H.which&&H.button){H.which=(H.button&1?1:(H.button&2?3:(H.button&4?2:0)))}return H},proxy:function(F,E){E=E||function(){return F.apply(this,arguments)};E.guid=F.guid=F.guid||E.guid||this.guid++;return E},special:{ready:{setup:B,teardown:function(){}}},specialAll:{live:{setup:function(E,F){o.event.add(this,F[0],c)},teardown:function(G){if(G.length){var E=0,F=RegExp("(^|\\.)"+G[0]+"(\\.|$)");o.each((o.data(this,"events").live||{}),function(){if(F.test(this.type)){E++}});if(E<1){o.event.remove(this,G[0],c)}}}}}};o.Event=function(E){if(!this.preventDefault){return new o.Event(E)}if(E&&E.type){this.originalEvent=E;this.type=E.type}else{this.type=E}this.timeStamp=e();this[h]=true};function k(){return false}function u(){return true}o.Event.prototype={preventDefault:function(){this.isDefaultPrevented=u;var E=this.originalEvent;if(!E){return}if(E.preventDefault){E.preventDefault()}E.returnValue=false},stopPropagation:function(){this.isPropagationStopped=u;var E=this.originalEvent;if(!E){return}if(E.stopPropagation){E.stopPropagation()}E.cancelBubble=true},stopImmediatePropagation:function(){this.isImmediatePropagationStopped=u;this.stopPropagation()},isDefaultPrevented:k,isPropagationStopped:k,isImmediatePropagationStopped:k};var a=function(F){var E=F.relatedTarget;while(E&&E!=this){try{E=E.parentNode}catch(G){E=this}}if(E!=this){F.type=F.data;o.event.handle.apply(this,arguments)}};o.each({mouseover:"mouseenter",mouseout:"mouseleave"},function(F,E){o.event.special[E]={setup:function(){o.event.add(this,F,a,E)},teardown:function(){o.event.remove(this,F,a)}}});o.fn.extend({bind:function(F,G,E){return F=="unload"?this.one(F,G,E):this.each(function(){o.event.add(this,F,E||G,E&&G)})},one:function(G,H,F){var E=o.event.proxy(F||H,function(I){o(this).unbind(I,E);return(F||H).apply(this,arguments)});return this.each(function(){o.event.add(this,G,E,F&&H)})},unbind:function(F,E){return this.each(function(){o.event.remove(this,F,E)})},trigger:function(E,F){return this.each(function(){o.event.trigger(E,F,this)})},triggerHandler:function(E,G){if(this[0]){var F=o.Event(E);F.preventDefault();F.stopPropagation();o.event.trigger(F,G,this[0]);return F.result}},toggle:function(G){var E=arguments,F=1;while(F=0){var E=G.slice(I,G.length);G=G.slice(0,I)}var H="GET";if(J){if(o.isFunction(J)){K=J;J=null}else{if(typeof J==="object"){J=o.param(J);H="POST"}}}var F=this;o.ajax({url:G,type:H,dataType:"html",data:J,complete:function(M,L){if(L=="success"||L=="notmodified"){F.html(E?o("
").append(M.responseText.replace(//g,"")).find(E):M.responseText)}if(K){F.each(K,[M.responseText,L,M])}}});return this},serialize:function(){return o.param(this.serializeArray())},serializeArray:function(){return this.map(function(){return this.elements?o.makeArray(this.elements):this}).filter(function(){return this.name&&!this.disabled&&(this.checked||/select|textarea/i.test(this.nodeName)||/text|hidden|password|search/i.test(this.type))}).map(function(E,F){var G=o(this).val();return G==null?null:o.isArray(G)?o.map(G,function(I,H){return{name:F.name,value:I}}):{name:F.name,value:G}}).get()}});o.each("ajaxStart,ajaxStop,ajaxComplete,ajaxError,ajaxSuccess,ajaxSend".split(","),function(E,F){o.fn[F]=function(G){return this.bind(F,G)}});var r=e();o.extend({get:function(E,G,H,F){if(o.isFunction(G)){H=G;G=null}return o.ajax({type:"GET",url:E,data:G,success:H,dataType:F})},getScript:function(E,F){return o.get(E,null,F,"script")},getJSON:function(E,F,G){return o.get(E,F,G,"json")},post:function(E,G,H,F){if(o.isFunction(G)){H=G;G={}}return o.ajax({type:"POST",url:E,data:G,success:H,dataType:F})},ajaxSetup:function(E){o.extend(o.ajaxSettings,E)},ajaxSettings:{url:location.href,global:true,type:"GET",contentType:"application/x-www-form-urlencoded",processData:true,async:true,xhr:function(){return l.ActiveXObject?new ActiveXObject("Microsoft.XMLHTTP"):new XMLHttpRequest()},accepts:{xml:"application/xml, text/xml",html:"text/html",script:"text/javascript, application/javascript",json:"application/json, text/javascript",text:"text/plain",_default:"*/*"}},lastModified:{},ajax:function(M){M=o.extend(true,M,o.extend(true,{},o.ajaxSettings,M));var W,F=/=\?(&|$)/g,R,V,G=M.type.toUpperCase();if(M.data&&M.processData&&typeof M.data!=="string"){M.data=o.param(M.data)}if(M.dataType=="jsonp"){if(G=="GET"){if(!M.url.match(F)){M.url+=(M.url.match(/\?/)?"&":"?")+(M.jsonp||"callback")+"=?"}}else{if(!M.data||!M.data.match(F)){M.data=(M.data?M.data+"&":"")+(M.jsonp||"callback")+"=?"}}M.dataType="json"}if(M.dataType=="json"&&(M.data&&M.data.match(F)||M.url.match(F))){W="jsonp"+r++;if(M.data){M.data=(M.data+"").replace(F,"="+W+"$1")}M.url=M.url.replace(F,"="+W+"$1");M.dataType="script";l[W]=function(X){V=X;I();L();l[W]=g;try{delete l[W]}catch(Y){}if(H){H.removeChild(T)}}}if(M.dataType=="script"&&M.cache==null){M.cache=false}if(M.cache===false&&G=="GET"){var E=e();var U=M.url.replace(/(\?|&)_=.*?(&|$)/,"$1_="+E+"$2");M.url=U+((U==M.url)?(M.url.match(/\?/)?"&":"?")+"_="+E:"")}if(M.data&&G=="GET"){M.url+=(M.url.match(/\?/)?"&":"?")+M.data;M.data=null}if(M.global&&!o.active++){o.event.trigger("ajaxStart")}var Q=/^(\w+:)?\/\/([^\/?#]+)/.exec(M.url);if(M.dataType=="script"&&G=="GET"&&Q&&(Q[1]&&Q[1]!=location.protocol||Q[2]!=location.host)){var H=document.getElementsByTagName("head")[0];var T=document.createElement("script");T.src=M.url;if(M.scriptCharset){T.charset=M.scriptCharset}if(!W){var O=false;T.onload=T.onreadystatechange=function(){if(!O&&(!this.readyState||this.readyState=="loaded"||this.readyState=="complete")){O=true;I();L();T.onload=T.onreadystatechange=null;H.removeChild(T)}}}H.appendChild(T);return g}var K=false;var J=M.xhr();if(M.username){J.open(G,M.url,M.async,M.username,M.password)}else{J.open(G,M.url,M.async)}try{if(M.data){J.setRequestHeader("Content-Type",M.contentType)}if(M.ifModified){J.setRequestHeader("If-Modified-Since",o.lastModified[M.url]||"Thu, 01 Jan 1970 00:00:00 GMT")}J.setRequestHeader("X-Requested-With","XMLHttpRequest");J.setRequestHeader("Accept",M.dataType&&M.accepts[M.dataType]?M.accepts[M.dataType]+", */*":M.accepts._default)}catch(S){}if(M.beforeSend&&M.beforeSend(J,M)===false){if(M.global&&!--o.active){o.event.trigger("ajaxStop")}J.abort();return false}if(M.global){o.event.trigger("ajaxSend",[J,M])}var N=function(X){if(J.readyState==0){if(P){clearInterval(P);P=null;if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}}else{if(!K&&J&&(J.readyState==4||X=="timeout")){K=true;if(P){clearInterval(P);P=null}R=X=="timeout"?"timeout":!o.httpSuccess(J)?"error":M.ifModified&&o.httpNotModified(J,M.url)?"notmodified":"success";if(R=="success"){try{V=o.httpData(J,M.dataType,M)}catch(Z){R="parsererror"}}if(R=="success"){var Y;try{Y=J.getResponseHeader("Last-Modified")}catch(Z){}if(M.ifModified&&Y){o.lastModified[M.url]=Y}if(!W){I()}}else{o.handleError(M,J,R)}L();if(X){J.abort()}if(M.async){J=null}}}};if(M.async){var P=setInterval(N,13);if(M.timeout>0){setTimeout(function(){if(J&&!K){N("timeout")}},M.timeout)}}try{J.send(M.data)}catch(S){o.handleError(M,J,null,S)}if(!M.async){N()}function I(){if(M.success){M.success(V,R)}if(M.global){o.event.trigger("ajaxSuccess",[J,M])}}function L(){if(M.complete){M.complete(J,R)}if(M.global){o.event.trigger("ajaxComplete",[J,M])}if(M.global&&!--o.active){o.event.trigger("ajaxStop")}}return J},handleError:function(F,H,E,G){if(F.error){F.error(H,E,G)}if(F.global){o.event.trigger("ajaxError",[H,F,G])}},active:0,httpSuccess:function(F){try{return !F.status&&location.protocol=="file:"||(F.status>=200&&F.status<300)||F.status==304||F.status==1223}catch(E){}return false},httpNotModified:function(G,E){try{var H=G.getResponseHeader("Last-Modified");return G.status==304||H==o.lastModified[E]}catch(F){}return false},httpData:function(J,H,G){var F=J.getResponseHeader("content-type"),E=H=="xml"||!H&&F&&F.indexOf("xml")>=0,I=E?J.responseXML:J.responseText;if(E&&I.documentElement.tagName=="parsererror"){throw"parsererror"}if(G&&G.dataFilter){I=G.dataFilter(I,H)}if(typeof I==="string"){if(H=="script"){o.globalEval(I)}if(H=="json"){I=l["eval"]("("+I+")")}}return I},param:function(E){var G=[];function H(I,J){G[G.length]=encodeURIComponent(I)+"="+encodeURIComponent(J)}if(o.isArray(E)||E.jquery){o.each(E,function(){H(this.name,this.value)})}else{for(var F in E){if(o.isArray(E[F])){o.each(E[F],function(){H(F,this)})}else{H(F,o.isFunction(E[F])?E[F]():E[F])}}}return G.join("&").replace(/%20/g,"+")}});var m={},n,d=[["height","marginTop","marginBottom","paddingTop","paddingBottom"],["width","marginLeft","marginRight","paddingLeft","paddingRight"],["opacity"]];function t(F,E){var G={};o.each(d.concat.apply([],d.slice(0,E)),function() -{G[this]=F});return G}o.fn.extend({show:function(J,L){if(J){return this.animate(t("show",3),J,L)}else{for(var H=0,F=this.length;H").appendTo("body");K=I.css("display");if(K==="none"){K="block"}I.remove();m[G]=K}o.data(this[H],"olddisplay",K)}}for(var H=0,F=this.length;H=0;H--){if(G[H].elem==this){if(E){G[H](true)}G.splice(H,1)}}});if(!E){this.dequeue()}return this}});o.each({slideDown:t("show",1),slideUp:t("hide",1),slideToggle:t("toggle",1),fadeIn:{opacity:"show"},fadeOut:{opacity:"hide"}},function(E,F){o.fn[E]=function(G,H){return this.animate(F,G,H)}});o.extend({speed:function(G,H,F){var E=typeof G==="object"?G:{complete:F||!F&&H||o.isFunction(G)&&G,duration:G,easing:F&&H||H&&!o.isFunction(H)&&H};E.duration=o.fx.off?0:typeof E.duration==="number"?E.duration:o.fx.speeds[E.duration]||o.fx.speeds._default;E.old=E.complete;E.complete=function(){if(E.queue!==false){o(this).dequeue()}if(o.isFunction(E.old)){E.old.call(this)}};return E},easing:{linear:function(G,H,E,F){return E+F*G},swing:function(G,H,E,F){return((-Math.cos(G*Math.PI)/2)+0.5)*F+E}},timers:[],fx:function(F,E,G){this.options=E;this.elem=F;this.prop=G;if(!E.orig){E.orig={}}}});o.fx.prototype={update:function(){if(this.options.step){this.options.step.call(this.elem,this.now,this)}(o.fx.step[this.prop]||o.fx.step._default)(this);if((this.prop=="height"||this.prop=="width")&&this.elem.style){this.elem.style.display="block"}},cur:function(F){if(this.elem[this.prop]!=null&&(!this.elem.style||this.elem.style[this.prop]==null)){return this.elem[this.prop]}var E=parseFloat(o.css(this.elem,this.prop,F));return E&&E>-10000?E:parseFloat(o.curCSS(this.elem,this.prop))||0},custom:function(I,H,G){this.startTime=e();this.start=I;this.end=H;this.unit=G||this.unit||"px";this.now=this.start;this.pos=this.state=0;var E=this;function F(J){return E.step(J)}F.elem=this.elem;if(F()&&o.timers.push(F)&&!n){n=setInterval(function(){var K=o.timers;for(var J=0;J=this.options.duration+this.startTime){this.now=this.end;this.pos=this.state=1;this.update();this.options.curAnim[this.prop]=true;var E=true;for(var F in this.options.curAnim){if(this.options.curAnim[F]!==true){E=false}}if(E){if(this.options.display!=null){this.elem.style.overflow=this.options.overflow;this.elem.style.display=this.options.display;if(o.css(this.elem,"display")=="none"){this.elem.style.display="block"}}if(this.options.hide){o(this.elem).hide()}if(this.options.hide||this.options.show){for(var I in this.options.curAnim){o.attr(this.elem.style,I,this.options.orig[I])}}this.options.complete.call(this.elem)}return false}else{var J=G-this.startTime;this.state=J/this.options.duration;this.pos=o.easing[this.options.easing||(o.easing.swing?"swing":"linear")](this.state,J,0,1,this.options.duration);this.now=this.start+((this.end-this.start)*this.pos);this.update()}return true}};o.extend(o.fx,{speeds:{slow:600,fast:200,_default:400},step:{opacity:function(E){o.attr(E.elem.style,"opacity",E.now)},_default:function(E){if(E.elem.style&&E.elem.style[E.prop]!=null){E.elem.style[E.prop]=E.now+E.unit}else{E.elem[E.prop]=E.now}}}});if(document.documentElement.getBoundingClientRect){o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}var G=this[0].getBoundingClientRect(),J=this[0].ownerDocument,F=J.body,E=J.documentElement,L=E.clientTop||F.clientTop||0,K=E.clientLeft||F.clientLeft||0,I=G.top+(self.pageYOffset||o.boxModel&&E.scrollTop||F.scrollTop)-L,H=G.left+(self.pageXOffset||o.boxModel&&E.scrollLeft||F.scrollLeft)-K;return{top:I,left:H}}}else{o.fn.offset=function(){if(!this[0]){return{top:0,left:0}}if(this[0]===this[0].ownerDocument.body){return o.offset.bodyOffset(this[0])}o.offset.initialized||o.offset.initialize();var J=this[0],G=J.offsetParent,F=J,O=J.ownerDocument,M,H=O.documentElement,K=O.body,L=O.defaultView,E=L.getComputedStyle(J,null),N=J.offsetTop,I=J.offsetLeft;while((J=J.parentNode)&&J!==K&&J!==H){M=L.getComputedStyle(J,null);N-=J.scrollTop,I-=J.scrollLeft;if(J===G){N+=J.offsetTop,I+=J.offsetLeft;if(o.offset.doesNotAddBorder&&!(o.offset.doesAddBorderForTableAndCells&&/^t(able|d|h)$/i.test(J.tagName))){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}F=G,G=J.offsetParent}if(o.offset.subtractsBorderForOverflowNotVisible&&M.overflow!=="visible"){N+=parseInt(M.borderTopWidth,10)||0,I+=parseInt(M.borderLeftWidth,10)||0}E=M}if(E.position==="relative"||E.position==="static"){N+=K.offsetTop,I+=K.offsetLeft}if(E.position==="fixed"){N+=Math.max(H.scrollTop,K.scrollTop),I+=Math.max(H.scrollLeft,K.scrollLeft)}return{top:N,left:I}}}o.offset={initialize:function(){if(this.initialized){return}var L=document.body,F=document.createElement("div"),H,G,N,I,M,E,J=L.style.marginTop,K='
';M={position:"absolute",top:0,left:0,margin:0,border:0,width:"1px",height:"1px",visibility:"hidden"};for(E in M){F.style[E]=M[E]}F.innerHTML=K;L.insertBefore(F,L.firstChild);H=F.firstChild,G=H.firstChild,I=H.nextSibling.firstChild.firstChild;this.doesNotAddBorder=(G.offsetTop!==5);this.doesAddBorderForTableAndCells=(I.offsetTop===5);H.style.overflow="hidden",H.style.position="relative";this.subtractsBorderForOverflowNotVisible=(G.offsetTop===-5);L.style.marginTop="1px";this.doesNotIncludeMarginInBodyOffset=(L.offsetTop===0);L.style.marginTop=J;L.removeChild(F);this.initialized=true},bodyOffset:function(E){o.offset.initialized||o.offset.initialize();var G=E.offsetTop,F=E.offsetLeft;if(o.offset.doesNotIncludeMarginInBodyOffset){G+=parseInt(o.curCSS(E,"marginTop",true),10)||0,F+=parseInt(o.curCSS(E,"marginLeft",true),10)||0}return{top:G,left:F}}};o.fn.extend({position:function(){var I=0,H=0,F;if(this[0]){var G=this.offsetParent(),J=this.offset(),E=/^body|html$/i.test(G[0].tagName)?{top:0,left:0}:G.offset();J.top-=j(this,"marginTop");J.left-=j(this,"marginLeft");E.top+=j(G,"borderTopWidth");E.left+=j(G,"borderLeftWidth");F={top:J.top-E.top,left:J.left-E.left}}return F},offsetParent:function(){var E=this[0].offsetParent||document.body;while(E&&(!/^body|html$/i.test(E.tagName)&&o.css(E,"position")=="static")){E=E.offsetParent}return o(E)}});o.each(["Left","Top"],function(F,E){var G="scroll"+E;o.fn[G]=function(H){if(!this[0]){return null}return H!==g?this.each(function(){this==l||this==document?l.scrollTo(!F?H:o(l).scrollLeft(),F?H:o(l).scrollTop()):this[G]=H}):this[0]==l||this[0]==document?self[F?"pageYOffset":"pageXOffset"]||o.boxModel&&document.documentElement[G]||document.body[G]:this[0][G]}});o.each(["Height","Width"],function(I,G){var E=I?"Left":"Top",H=I?"Right":"Bottom",F=G.toLowerCase();o.fn["inner"+G]=function(){return this[0]?o.css(this[0],F,false,"padding"):null};o.fn["outer"+G]=function(K){return this[0]?o.css(this[0],F,false,K?"margin":"border"):null};var J=G.toLowerCase();o.fn[J]=function(K){return this[0]==l?document.compatMode=="CSS1Compat"&&document.documentElement["client"+G]||document.body["client"+G]:this[0]==document?Math.max(document.documentElement["client"+G],document.body["scroll"+G],document.documentElement["scroll"+G],document.body["offset"+G],document.documentElement["offset"+G]):K===g?(this.length?o.css(this[0],J):null):this.css(J,typeof K==="string"?K:K+"px")}})})(); -/* - * jQuery UI 1.7.2 - * - * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) - * Dual licensed under the MIT (MIT-LICENSE.txt) - * and GPL (GPL-LICENSE.txt) licenses. - * - * http://docs.jquery.com/UI - */ -jQuery.ui||(function(c){var i=c.fn.remove,d=c.browser.mozilla&&(parseFloat(c.browser.version)<1.9);c.ui={version:"1.7.2",plugin:{add:function(k,l,n){var m=c.ui[k].prototype;for(var j in n){m.plugins[j]=m.plugins[j]||[];m.plugins[j].push([l,n[j]])}},call:function(j,l,k){var n=j.plugins[l];if(!n||!j.element[0].parentNode){return}for(var m=0;m0){return true}m[j]=1;l=(m[j]>0);m[j]=0;return l},isOverAxis:function(k,j,l){return(k>j)&&(k<(j+l))},isOver:function(o,k,n,m,j,l){return c.ui.isOverAxis(o,n,j)&&c.ui.isOverAxis(k,m,l)},keyCode:{BACKSPACE:8,CAPS_LOCK:20,COMMA:188,CONTROL:17,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,INSERT:45,LEFT:37,NUMPAD_ADD:107,NUMPAD_DECIMAL:110,NUMPAD_DIVIDE:111,NUMPAD_ENTER:108,NUMPAD_MULTIPLY:106,NUMPAD_SUBTRACT:109,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SHIFT:16,SPACE:32,TAB:9,UP:38}};if(d){var f=c.attr,e=c.fn.removeAttr,h="http://www.w3.org/2005/07/aaa",a=/^aria-/,b=/^wairole:/;c.attr=function(k,j,l){var m=l!==undefined;return(j=="role"?(m?f.call(this,k,j,"wairole:"+l):(f.apply(this,arguments)||"").replace(b,"")):(a.test(j)?(m?k.setAttributeNS(h,j.replace(a,"aaa:"),l):f.call(this,k,j.replace(a,"aaa:"))):f.apply(this,arguments)))};c.fn.removeAttr=function(j){return(a.test(j)?this.each(function(){this.removeAttributeNS(h,j.replace(a,""))}):e.call(this,j))}}c.fn.extend({remove:function(){c("*",this).add(this).each(function(){c(this).triggerHandler("remove")});return i.apply(this,arguments)},enableSelection:function(){return this.attr("unselectable","off").css("MozUserSelect","").unbind("selectstart.ui")},disableSelection:function(){return this.attr("unselectable","on").css("MozUserSelect","none").bind("selectstart.ui",function(){return false})},scrollParent:function(){var j;if((c.browser.msie&&(/(static|relative)/).test(this.css("position")))||(/absolute/).test(this.css("position"))){j=this.parents().filter(function(){return(/(relative|absolute|fixed)/).test(c.curCSS(this,"position",1))&&(/(auto|scroll)/).test(c.curCSS(this,"overflow",1)+c.curCSS(this,"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0)}else{j=this.parents().filter(function(){return(/(auto|scroll)/).test(c.curCSS(this,"overflow",1)+c.curCSS(this,"overflow-y",1)+c.curCSS(this,"overflow-x",1))}).eq(0)}return(/fixed/).test(this.css("position"))||!j.length?c(document):j}});c.extend(c.expr[":"],{data:function(l,k,j){return !!c.data(l,j[3])},focusable:function(k){var l=k.nodeName.toLowerCase(),j=c.attr(k,"tabindex");return(/input|select|textarea|button|object/.test(l)?!k.disabled:"a"==l||"area"==l?k.href||!isNaN(j):!isNaN(j))&&!c(k)["area"==l?"parents":"closest"](":hidden").length},tabbable:function(k){var j=c.attr(k,"tabindex");return(isNaN(j)||j>=0)&&c(k).is(":focusable")}});function g(m,n,o,l){function k(q){var p=c[m][n][q]||[];return(typeof p=="string"?p.split(/,?\s+/):p)}var j=k("getter");if(l.length==1&&typeof l[0]=="string"){j=j.concat(k("getterSetter"))}return(c.inArray(o,j)!=-1)}c.widget=function(k,j){var l=k.split(".")[0];k=k.split(".")[1];c.fn[k]=function(p){var n=(typeof p=="string"),o=Array.prototype.slice.call(arguments,1);if(n&&p.substring(0,1)=="_"){return this}if(n&&g(l,k,p,o)){var m=c.data(this[0],k);return(m?m[p].apply(m,o):undefined)}return this.each(function(){var q=c.data(this,k);(!q&&!n&&c.data(this,k,new c[l][k](this,p))._init());(q&&n&&c.isFunction(q[p])&&q[p].apply(q,o))})};c[l]=c[l]||{};c[l][k]=function(o,n){var m=this;this.namespace=l;this.widgetName=k;this.widgetEventPrefix=c[l][k].eventPrefix||k;this.widgetBaseClass=l+"-"+k;this.options=c.extend({},c.widget.defaults,c[l][k].defaults,c.metadata&&c.metadata.get(o)[k],n);this.element=c(o).bind("setData."+k,function(q,p,r){if(q.target==o){return m._setData(p,r)}}).bind("getData."+k,function(q,p){if(q.target==o){return m._getData(p)}}).bind("remove",function(){return m.destroy()})};c[l][k].prototype=c.extend({},c.widget.prototype,j);c[l][k].getterSetter="option"};c.widget.prototype={_init:function(){},destroy:function(){this.element.removeData(this.widgetName).removeClass(this.widgetBaseClass+"-disabled "+this.namespace+"-state-disabled").removeAttr("aria-disabled")},option:function(l,m){var k=l,j=this;if(typeof l=="string"){if(m===undefined){return this._getData(l)}k={};k[l]=m}c.each(k,function(n,o){j._setData(n,o)})},_getData:function(j){return this.options[j]},_setData:function(j,k){this.options[j]=k;if(j=="disabled"){this.element[k?"addClass":"removeClass"](this.widgetBaseClass+"-disabled "+this.namespace+"-state-disabled").attr("aria-disabled",k)}},enable:function(){this._setData("disabled",false)},disable:function(){this._setData("disabled",true)},_trigger:function(l,m,n){var p=this.options[l],j=(l==this.widgetEventPrefix?l:this.widgetEventPrefix+l);m=c.Event(m);m.type=j;if(m.originalEvent){for(var k=c.event.props.length,o;k;){o=c.event.props[--k];m[o]=m.originalEvent[o]}}this.element.trigger(m,n);return !(c.isFunction(p)&&p.call(this.element[0],m,n)===false||m.isDefaultPrevented())}};c.widget.defaults={disabled:false};c.ui.mouse={_mouseInit:function(){var j=this;this.element.bind("mousedown."+this.widgetName,function(k){return j._mouseDown(k)}).bind("click."+this.widgetName,function(k){if(j._preventClickEvent){j._preventClickEvent=false;k.stopImmediatePropagation();return false}});if(c.browser.msie){this._mouseUnselectable=this.element.attr("unselectable");this.element.attr("unselectable","on")}this.started=false},_mouseDestroy:function(){this.element.unbind("."+this.widgetName);(c.browser.msie&&this.element.attr("unselectable",this._mouseUnselectable))},_mouseDown:function(l){l.originalEvent=l.originalEvent||{};if(l.originalEvent.mouseHandled){return}(this._mouseStarted&&this._mouseUp(l));this._mouseDownEvent=l;var k=this,m=(l.which==1),j=(typeof this.options.cancel=="string"?c(l.target).parents().add(l.target).filter(this.options.cancel).length:false);if(!m||j||!this._mouseCapture(l)){return true}this.mouseDelayMet=!this.options.delay;if(!this.mouseDelayMet){this._mouseDelayTimer=setTimeout(function(){k.mouseDelayMet=true},this.options.delay)}if(this._mouseDistanceMet(l)&&this._mouseDelayMet(l)){this._mouseStarted=(this._mouseStart(l)!==false);if(!this._mouseStarted){l.preventDefault();return true}}this._mouseMoveDelegate=function(n){return k._mouseMove(n)};this._mouseUpDelegate=function(n){return k._mouseUp(n)};c(document).bind("mousemove."+this.widgetName,this._mouseMoveDelegate).bind("mouseup."+this.widgetName,this._mouseUpDelegate);(c.browser.safari||l.preventDefault());l.originalEvent.mouseHandled=true;return true},_mouseMove:function(j){if(c.browser.msie&&!j.button){return this._mouseUp(j)}if(this._mouseStarted){this._mouseDrag(j);return j.preventDefault()}if(this._mouseDistanceMet(j)&&this._mouseDelayMet(j)){this._mouseStarted=(this._mouseStart(this._mouseDownEvent,j)!==false);(this._mouseStarted?this._mouseDrag(j):this._mouseUp(j))}return !this._mouseStarted},_mouseUp:function(j){c(document).unbind("mousemove."+this.widgetName,this._mouseMoveDelegate).unbind("mouseup."+this.widgetName,this._mouseUpDelegate);if(this._mouseStarted){this._mouseStarted=false;this._preventClickEvent=(j.target==this._mouseDownEvent.target);this._mouseStop(j)}return false},_mouseDistanceMet:function(j){return(Math.max(Math.abs(this._mouseDownEvent.pageX-j.pageX),Math.abs(this._mouseDownEvent.pageY-j.pageY))>=this.options.distance)},_mouseDelayMet:function(j){return this.mouseDelayMet},_mouseStart:function(j){},_mouseDrag:function(j){},_mouseStop:function(j){},_mouseCapture:function(j){return true}};c.ui.mouse.defaults={cancel:null,distance:1,delay:0}})(jQuery);;/* * jQuery UI Resizable 1.7.2 - * - * Copyright (c) 2009 AUTHORS.txt (http://jqueryui.com/about) - * Dual licensed under the MIT (MIT-LICENSE.txt) - * and GPL (GPL-LICENSE.txt) licenses. - * - * http://docs.jquery.com/UI/Resizables - * - * Depends: - * ui.core.js - */ -(function(c){c.widget("ui.resizable",c.extend({},c.ui.mouse,{_init:function(){var e=this,j=this.options;this.element.addClass("ui-resizable");c.extend(this,{_aspectRatio:!!(j.aspectRatio),aspectRatio:j.aspectRatio,originalElement:this.element,_proportionallyResizeElements:[],_helper:j.helper||j.ghost||j.animate?j.helper||"ui-resizable-helper":null});if(this.element[0].nodeName.match(/canvas|textarea|input|select|button|img/i)){if(/relative/.test(this.element.css("position"))&&c.browser.opera){this.element.css({position:"relative",top:"auto",left:"auto"})}this.element.wrap(c('
').css({position:this.element.css("position"),width:this.element.outerWidth(),height:this.element.outerHeight(),top:this.element.css("top"),left:this.element.css("left")}));this.element=this.element.parent().data("resizable",this.element.data("resizable"));this.elementIsWrapper=true;this.element.css({marginLeft:this.originalElement.css("marginLeft"),marginTop:this.originalElement.css("marginTop"),marginRight:this.originalElement.css("marginRight"),marginBottom:this.originalElement.css("marginBottom")});this.originalElement.css({marginLeft:0,marginTop:0,marginRight:0,marginBottom:0});this.originalResizeStyle=this.originalElement.css("resize");this.originalElement.css("resize","none");this._proportionallyResizeElements.push(this.originalElement.css({position:"static",zoom:1,display:"block"}));this.originalElement.css({margin:this.originalElement.css("margin")});this._proportionallyResize()}this.handles=j.handles||(!c(".ui-resizable-handle",this.element).length?"e,s,se":{n:".ui-resizable-n",e:".ui-resizable-e",s:".ui-resizable-s",w:".ui-resizable-w",se:".ui-resizable-se",sw:".ui-resizable-sw",ne:".ui-resizable-ne",nw:".ui-resizable-nw"});if(this.handles.constructor==String){if(this.handles=="all"){this.handles="n,e,s,w,se,sw,ne,nw"}var k=this.handles.split(",");this.handles={};for(var f=0;f
');if(/sw|se|ne|nw/.test(h)){g.css({zIndex:++j.zIndex})}if("se"==h){g.addClass("ui-icon ui-icon-gripsmall-diagonal-se")}this.handles[h]=".ui-resizable-"+h;this.element.append(g)}}this._renderAxis=function(p){p=p||this.element;for(var m in this.handles){if(this.handles[m].constructor==String){this.handles[m]=c(this.handles[m],this.element).show()}if(this.elementIsWrapper&&this.originalElement[0].nodeName.match(/textarea|input|select|button/i)){var n=c(this.handles[m],this.element),o=0;o=/sw|ne|nw|se|n|s/.test(m)?n.outerHeight():n.outerWidth();var l=["padding",/ne|nw|n/.test(m)?"Top":/se|sw|s/.test(m)?"Bottom":/^e$/.test(m)?"Right":"Left"].join("");p.css(l,o);this._proportionallyResize()}if(!c(this.handles[m]).length){continue}}};this._renderAxis(this.element);this._handles=c(".ui-resizable-handle",this.element).disableSelection();this._handles.mouseover(function(){if(!e.resizing){if(this.className){var i=this.className.match(/ui-resizable-(se|sw|ne|nw|n|e|s|w)/i)}e.axis=i&&i[1]?i[1]:"se"}});if(j.autoHide){this._handles.hide();c(this.element).addClass("ui-resizable-autohide").hover(function(){c(this).removeClass("ui-resizable-autohide");e._handles.show()},function(){if(!e.resizing){c(this).addClass("ui-resizable-autohide");e._handles.hide()}})}this._mouseInit()},destroy:function(){this._mouseDestroy();var d=function(f){c(f).removeClass("ui-resizable ui-resizable-disabled ui-resizable-resizing").removeData("resizable").unbind(".resizable").find(".ui-resizable-handle").remove()};if(this.elementIsWrapper){d(this.element);var e=this.element;e.parent().append(this.originalElement.css({position:e.css("position"),width:e.outerWidth(),height:e.outerHeight(),top:e.css("top"),left:e.css("left")})).end().remove()}this.originalElement.css("resize",this.originalResizeStyle);d(this.originalElement)},_mouseCapture:function(e){var f=false;for(var d in this.handles){if(c(this.handles[d])[0]==e.target){f=true}}return this.options.disabled||!!f},_mouseStart:function(f){var i=this.options,e=this.element.position(),d=this.element;this.resizing=true;this.documentScroll={top:c(document).scrollTop(),left:c(document).scrollLeft()};if(d.is(".ui-draggable")||(/absolute/).test(d.css("position"))){d.css({position:"absolute",top:e.top,left:e.left})}if(c.browser.opera&&(/relative/).test(d.css("position"))){d.css({position:"relative",top:"auto",left:"auto"})}this._renderProxy();var j=b(this.helper.css("left")),g=b(this.helper.css("top"));if(i.containment){j+=c(i.containment).scrollLeft()||0;g+=c(i.containment).scrollTop()||0}this.offset=this.helper.offset();this.position={left:j,top:g};this.size=this._helper?{width:d.outerWidth(),height:d.outerHeight()}:{width:d.width(),height:d.height()};this.originalSize=this._helper?{width:d.outerWidth(),height:d.outerHeight()}:{width:d.width(),height:d.height()};this.originalPosition={left:j,top:g};this.sizeDiff={width:d.outerWidth()-d.width(),height:d.outerHeight()-d.height()};this.originalMousePosition={left:f.pageX,top:f.pageY};this.aspectRatio=(typeof i.aspectRatio=="number")?i.aspectRatio:((this.originalSize.width/this.originalSize.height)||1);var h=c(".ui-resizable-"+this.axis).css("cursor");c("body").css("cursor",h=="auto"?this.axis+"-resize":h);d.addClass("ui-resizable-resizing");this._propagate("start",f);return true},_mouseDrag:function(d){var g=this.helper,f=this.options,l={},p=this,i=this.originalMousePosition,m=this.axis;var q=(d.pageX-i.left)||0,n=(d.pageY-i.top)||0;var h=this._change[m];if(!h){return false}var k=h.apply(this,[d,q,n]),j=c.browser.msie&&c.browser.version<7,e=this.sizeDiff;if(this._aspectRatio||d.shiftKey){k=this._updateRatio(k,d)}k=this._respectSize(k,d);this._propagate("resize",d);g.css({top:this.position.top+"px",left:this.position.left+"px",width:this.size.width+"px",height:this.size.height+"px"});if(!this._helper&&this._proportionallyResizeElements.length){this._proportionallyResize()}this._updateCache(k);this._trigger("resize",d,this.ui());return false},_mouseStop:function(g){this.resizing=false;var h=this.options,l=this;if(this._helper){var f=this._proportionallyResizeElements,d=f.length&&(/textarea/i).test(f[0].nodeName),e=d&&c.ui.hasScroll(f[0],"left")?0:l.sizeDiff.height,j=d?0:l.sizeDiff.width;var m={width:(l.size.width-j),height:(l.size.height-e)},i=(parseInt(l.element.css("left"),10)+(l.position.left-l.originalPosition.left))||null,k=(parseInt(l.element.css("top"),10)+(l.position.top-l.originalPosition.top))||null;if(!h.animate){this.element.css(c.extend(m,{top:k,left:i}))}l.helper.height(l.size.height);l.helper.width(l.size.width);if(this._helper&&!h.animate){this._proportionallyResize()}}c("body").css("cursor","auto");this.element.removeClass("ui-resizable-resizing");this._propagate("stop",g);if(this._helper){this.helper.remove()}return false},_updateCache:function(d){var e=this.options;this.offset=this.helper.offset();if(a(d.left)){this.position.left=d.left}if(a(d.top)){this.position.top=d.top}if(a(d.height)){this.size.height=d.height}if(a(d.width)){this.size.width=d.width}},_updateRatio:function(g,f){var h=this.options,i=this.position,e=this.size,d=this.axis;if(g.height){g.width=(e.height*this.aspectRatio)}else{if(g.width){g.height=(e.width/this.aspectRatio)}}if(d=="sw"){g.left=i.left+(e.width-g.width);g.top=null}if(d=="nw"){g.top=i.top+(e.height-g.height);g.left=i.left+(e.width-g.width)}return g},_respectSize:function(k,f){var i=this.helper,h=this.options,q=this._aspectRatio||f.shiftKey,p=this.axis,s=a(k.width)&&h.maxWidth&&(h.maxWidthk.width),r=a(k.height)&&h.minHeight&&(h.minHeight>k.height);if(g){k.width=h.minWidth}if(r){k.height=h.minHeight}if(s){k.width=h.maxWidth}if(l){k.height=h.maxHeight}var e=this.originalPosition.left+this.originalSize.width,n=this.position.top+this.size.height;var j=/sw|nw|w/.test(p),d=/nw|ne|n/.test(p);if(g&&j){k.left=e-h.minWidth}if(s&&j){k.left=e-h.maxWidth}if(r&&d){k.top=n-h.minHeight}if(l&&d){k.top=n-h.maxHeight}var m=!k.width&&!k.height;if(m&&!k.left&&k.top){k.top=null}else{if(m&&!k.top&&k.left){k.left=null}}return k},_proportionallyResize:function(){var j=this.options;if(!this._proportionallyResizeElements.length){return}var f=this.helper||this.element;for(var e=0;e');var d=c.browser.msie&&c.browser.version<7,f=(d?1:0),g=(d?2:-1);this.helper.addClass(this._helper).css({width:this.element.outerWidth()+g,height:this.element.outerHeight()+g,position:"absolute",left:this.elementOffset.left-f+"px",top:this.elementOffset.top-f+"px",zIndex:++h.zIndex});this.helper.appendTo("body").disableSelection()}else{this.helper=this.element}},_change:{e:function(f,e,d){return{width:this.originalSize.width+e}},w:function(g,e,d){var i=this.options,f=this.originalSize,h=this.originalPosition;return{left:h.left+e,width:f.width-e}},n:function(g,e,d){var i=this.options,f=this.originalSize,h=this.originalPosition;return{top:h.top+d,height:f.height-d}},s:function(f,e,d){return{height:this.originalSize.height+d}},se:function(f,e,d){return c.extend(this._change.s.apply(this,arguments),this._change.e.apply(this,[f,e,d]))},sw:function(f,e,d){return c.extend(this._change.s.apply(this,arguments),this._change.w.apply(this,[f,e,d]))},ne:function(f,e,d){return c.extend(this._change.n.apply(this,arguments),this._change.e.apply(this,[f,e,d]))},nw:function(f,e,d){return c.extend(this._change.n.apply(this,arguments),this._change.w.apply(this,[f,e,d]))}},_propagate:function(e,d){c.ui.plugin.call(this,e,[d,this.ui()]);(e!="resize"&&this._trigger(e,d,this.ui()))},plugins:{},ui:function(){return{originalElement:this.originalElement,element:this.element,helper:this.helper,position:this.position,size:this.size,originalSize:this.originalSize,originalPosition:this.originalPosition}}}));c.extend(c.ui.resizable,{version:"1.7.2",eventPrefix:"resize",defaults:{alsoResize:false,animate:false,animateDuration:"slow",animateEasing:"swing",aspectRatio:false,autoHide:false,cancel:":input,option",containment:false,delay:0,distance:1,ghost:false,grid:false,handles:"e,s,se",helper:false,maxHeight:null,maxWidth:null,minHeight:10,minWidth:10,zIndex:1000}});c.ui.plugin.add("resizable","alsoResize",{start:function(e,f){var d=c(this).data("resizable"),g=d.options;_store=function(h){c(h).each(function(){c(this).data("resizable-alsoresize",{width:parseInt(c(this).width(),10),height:parseInt(c(this).height(),10),left:parseInt(c(this).css("left"),10),top:parseInt(c(this).css("top"),10)})})};if(typeof(g.alsoResize)=="object"&&!g.alsoResize.parentNode){if(g.alsoResize.length){g.alsoResize=g.alsoResize[0];_store(g.alsoResize)}else{c.each(g.alsoResize,function(h,i){_store(h)})}}else{_store(g.alsoResize)}},resize:function(f,h){var e=c(this).data("resizable"),i=e.options,g=e.originalSize,k=e.originalPosition;var j={height:(e.size.height-g.height)||0,width:(e.size.width-g.width)||0,top:(e.position.top-k.top)||0,left:(e.position.left-k.left)||0},d=function(l,m){c(l).each(function(){var p=c(this),q=c(this).data("resizable-alsoresize"),o={},n=m&&m.length?m:["width","height","top","left"];c.each(n||["width","height","top","left"],function(r,t){var s=(q[t]||0)+(j[t]||0);if(s&&s>=0){o[t]=s||null}});if(/relative/.test(p.css("position"))&&c.browser.opera){e._revertToRelativePosition=true;p.css({position:"absolute",top:"auto",left:"auto"})}p.css(o)})};if(typeof(i.alsoResize)=="object"&&!i.alsoResize.nodeType){c.each(i.alsoResize,function(l,m){d(l,m)})}else{d(i.alsoResize)}},stop:function(e,f){var d=c(this).data("resizable");if(d._revertToRelativePosition&&c.browser.opera){d._revertToRelativePosition=false;el.css({position:"relative"})}c(this).removeData("resizable-alsoresize-start")}});c.ui.plugin.add("resizable","animate",{stop:function(h,m){var n=c(this).data("resizable"),i=n.options;var g=n._proportionallyResizeElements,d=g.length&&(/textarea/i).test(g[0].nodeName),e=d&&c.ui.hasScroll(g[0],"left")?0:n.sizeDiff.height,k=d?0:n.sizeDiff.width;var f={width:(n.size.width-k),height:(n.size.height-e)},j=(parseInt(n.element.css("left"),10)+(n.position.left-n.originalPosition.left))||null,l=(parseInt(n.element.css("top"),10)+(n.position.top-n.originalPosition.top))||null;n.element.animate(c.extend(f,l&&j?{top:l,left:j}:{}),{duration:i.animateDuration,easing:i.animateEasing,step:function(){var o={width:parseInt(n.element.css("width"),10),height:parseInt(n.element.css("height"),10),top:parseInt(n.element.css("top"),10),left:parseInt(n.element.css("left"),10)};if(g&&g.length){c(g[0]).css({width:o.width,height:o.height})}n._updateCache(o);n._propagate("resize",h)}})}});c.ui.plugin.add("resizable","containment",{start:function(e,q){var s=c(this).data("resizable"),i=s.options,k=s.element;var f=i.containment,j=(f instanceof c)?f.get(0):(/parent/.test(f))?k.parent().get(0):f;if(!j){return}s.containerElement=c(j);if(/document/.test(f)||f==document){s.containerOffset={left:0,top:0};s.containerPosition={left:0,top:0};s.parentData={element:c(document),left:0,top:0,width:c(document).width(),height:c(document).height()||document.body.parentNode.scrollHeight}}else{var m=c(j),h=[];c(["Top","Right","Left","Bottom"]).each(function(p,o){h[p]=b(m.css("padding"+o))});s.containerOffset=m.offset();s.containerPosition=m.position();s.containerSize={height:(m.innerHeight()-h[3]),width:(m.innerWidth()-h[1])};var n=s.containerOffset,d=s.containerSize.height,l=s.containerSize.width,g=(c.ui.hasScroll(j,"left")?j.scrollWidth:l),r=(c.ui.hasScroll(j)?j.scrollHeight:d);s.parentData={element:j,left:n.left,top:n.top,width:g,height:r}}},resize:function(f,p){var s=c(this).data("resizable"),h=s.options,e=s.containerSize,n=s.containerOffset,l=s.size,m=s.position,q=s._aspectRatio||f.shiftKey,d={top:0,left:0},g=s.containerElement;if(g[0]!=document&&(/static/).test(g.css("position"))){d=n}if(m.left<(s._helper?n.left:0)){s.size.width=s.size.width+(s._helper?(s.position.left-n.left):(s.position.left-d.left));if(q){s.size.height=s.size.width/h.aspectRatio}s.position.left=h.helper?n.left:0}if(m.top<(s._helper?n.top:0)) -{s.size.height=s.size.height+(s._helper?(s.position.top-n.top):s.position.top);if(q){s.size.width=s.size.height*h.aspectRatio}s.position.top=s._helper?n.top:0}s.offset.left=s.parentData.left+s.position.left;s.offset.top=s.parentData.top+s.position.top;var k=Math.abs((s._helper?s.offset.left-d.left:(s.offset.left-d.left))+s.sizeDiff.width),r=Math.abs((s._helper?s.offset.top-d.top:(s.offset.top-n.top))+s.sizeDiff.height);var j=s.containerElement.get(0)==s.element.parent().get(0),i=/relative|absolute/.test(s.containerElement.css("position"));if(j&&i){k-=s.parentData.left}if(k+s.size.width>=s.parentData.width){s.size.width=s.parentData.width-k;if(q){s.size.height=s.size.width/s.aspectRatio}}if(r+s.size.height>=s.parentData.height){s.size.height=s.parentData.height-r;if(q){s.size.width=s.size.height*s.aspectRatio}}},stop:function(e,m){var p=c(this).data("resizable"),f=p.options,k=p.position,l=p.containerOffset,d=p.containerPosition,g=p.containerElement;var i=c(p.helper),q=i.offset(),n=i.outerWidth()-p.sizeDiff.width,j=i.outerHeight()-p.sizeDiff.height;if(p._helper&&!f.animate&&(/relative/).test(g.css("position"))){c(this).css({left:q.left-d.left-l.left,width:n,height:j})}if(p._helper&&!f.animate&&(/static/).test(g.css("position"))){c(this).css({left:q.left-d.left-l.left,width:n,height:j})}}});c.ui.plugin.add("resizable","ghost",{start:function(f,g){var d=c(this).data("resizable"),h=d.options,e=d.size;d.ghost=d.originalElement.clone();d.ghost.css({opacity:0.25,display:"block",position:"relative",height:e.height,width:e.width,margin:0,left:0,top:0}).addClass("ui-resizable-ghost").addClass(typeof h.ghost=="string"?h.ghost:"");d.ghost.appendTo(d.helper)},resize:function(e,f){var d=c(this).data("resizable"),g=d.options;if(d.ghost){d.ghost.css({position:"relative",height:d.size.height,width:d.size.width})}},stop:function(e,f){var d=c(this).data("resizable"),g=d.options;if(d.ghost&&d.helper){d.helper.get(0).removeChild(d.ghost.get(0))}}});c.ui.plugin.add("resizable","grid",{resize:function(d,l){var n=c(this).data("resizable"),g=n.options,j=n.size,h=n.originalSize,i=n.originalPosition,m=n.axis,k=g._aspectRatio||d.shiftKey;g.grid=typeof g.grid=="number"?[g.grid,g.grid]:g.grid;var f=Math.round((j.width-h.width)/(g.grid[0]||1))*(g.grid[0]||1),e=Math.round((j.height-h.height)/(g.grid[1]||1))*(g.grid[1]||1);if(/^(se|s|e)$/.test(m)){n.size.width=h.width+f;n.size.height=h.height+e}else{if(/^(ne)$/.test(m)){n.size.width=h.width+f;n.size.height=h.height+e;n.position.top=i.top-e}else{if(/^(sw)$/.test(m)){n.size.width=h.width+f;n.size.height=h.height+e;n.position.left=i.left-f}else{n.size.width=h.width+f;n.size.height=h.height+e;n.position.top=i.top-e;n.position.left=i.left-f}}}}});var b=function(d){return parseInt(d,10)||0};var a=function(d){return !isNaN(parseInt(d,10))}})(jQuery);; -/** - * jQuery.ScrollTo - Easy element scrolling using jQuery. - * Copyright (c) 2008 Ariel Flesler - aflesler(at)gmail(dot)com - * Licensed under GPL license (http://www.opensource.org/licenses/gpl-license.php). - * Date: 2/8/2008 - * @author Ariel Flesler - * @version 1.3.2 - */ -;(function($){var o=$.scrollTo=function(a,b,c){o.window().scrollTo(a,b,c)};o.defaults={axis:'y',duration:1};o.window=function(){return $($.browser.safari?'body':'html')};$.fn.scrollTo=function(l,m,n){if(typeof m=='object'){n=m;m=0}n=$.extend({},o.defaults,n);m=m||n.speed||n.duration;n.queue=n.queue&&n.axis.length>1;if(n.queue)m/=2;n.offset=j(n.offset);n.over=j(n.over);return this.each(function(){var a=this,b=$(a),t=l,c,d={},w=b.is('html,body');switch(typeof t){case'number':case'string':if(/^([+-]=)?\d+(px)?$/.test(t)){t=j(t);break}t=$(t,this);case'object':if(t.is||t.style)c=(t=$(t)).offset()}$.each(n.axis.split(''),function(i,f){var P=f=='x'?'Left':'Top',p=P.toLowerCase(),k='scroll'+P,e=a[k],D=f=='x'?'Width':'Height';if(c){d[k]=c[p]+(w?0:e-b.offset()[p]);if(n.margin){d[k]-=parseInt(t.css('margin'+P))||0;d[k]-=parseInt(t.css('border'+P+'Width'))||0}d[k]+=n.offset[p]||0;if(n.over[p])d[k]+=t[D.toLowerCase()]()*n.over[p]}else d[k]=t[p];if(/^\d+$/.test(d[k]))d[k]=d[k]<=0?0:Math.min(d[k],h(D));if(!i&&n.queue){if(e!=d[k])g(n.onAfterFirst);delete d[k]}});g(n.onAfter);function g(a){b.animate(d,m,n.easing,a&&function(){a.call(this,l)})};function h(D){var b=w?$.browser.opera?document.body:document.documentElement:a;return b['scroll'+D]-b['client'+D]}})};function j(a){return typeof a=='object'?a:{top:a,left:a}}})(jQuery); - Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/nav_f.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/nav_f.png differ Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/nav_h.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/nav_h.png differ Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/open.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/open.png differ diff -Nru incron-0.5.10/doc/html/strtok_8cpp.html incron-0.5.12/doc/html/strtok_8cpp.html --- incron-0.5.10/doc/html/strtok_8cpp.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/strtok_8cpp.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,83 +0,0 @@ - - - - -incron: strtok.cpp File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
strtok.cpp File Reference
-
-
- -

string tokenizer implementation -More...

-
#include <sstream>
-#include "strtok.h"
-

Detailed Description

-

string tokenizer implementation

-

string tokenizer

-

Copyright (C) 2006, 2007, 2008 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can redistribute it and/or modify it under the terms of one of the following licenses:

-
    -
  • 1. X11-style license (see LICENSE-X11)
  • -
  • 2. GNU Lesser General Public License, version 2.1 (see LICENSE-LGPL)
  • -
  • 3. GNU General Public License, version 2 (see LICENSE-GPL)
  • -
-

If you want to help with choosing the best license for you, please visit http://www.gnu.org/licenses/license-list.html.

-
- - - - - - diff -Nru incron-0.5.10/doc/html/strtok_8h.html incron-0.5.12/doc/html/strtok_8h.html --- incron-0.5.10/doc/html/strtok_8h.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/strtok_8h.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,110 +0,0 @@ - - - - -incron: strtok.h File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
strtok.h File Reference
-
-
- -

string tokenizer header -More...

-
#include <string>
-
-

Go to the source code of this file.

- - - - - - -

-Classes

class  StringTokenizer
 Simple string tokenizer class. More...

-Typedefs

typedef std::string::size_type SIZE
-

Detailed Description

-

string tokenizer header

-

string tokenizer

-

Copyright (C) 2006, 2007, 2008 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can redistribute it and/or modify it under the terms of one of the following licenses:

-
    -
  • 1. X11-style license (see LICENSE-X11)
  • -
  • 2. GNU Lesser General Public License, version 2.1 (see LICENSE-LGPL)
  • -
  • 3. GNU General Public License, version 2 (see LICENSE-GPL)
  • -
-

If you want to help with choosing the best license for you, please visit http://www.gnu.org/licenses/license-list.html.

-

Typedef Documentation

- -
-
- - - - -
typedef std::string::size_type SIZE
-
-
- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/strtok_8h_source.html incron-0.5.12/doc/html/strtok_8h_source.html --- incron-0.5.10/doc/html/strtok_8h_source.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/strtok_8h_source.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,159 +0,0 @@ - - - - -incron: strtok.h Source File - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
strtok.h
-
-
-Go to the documentation of this file.
00001 
-00003 
-00023 #ifndef _STRTOK_H_
-00024 #define _STRTOK_H_
-00025 
-00026 
-00027 #include <string>
-00028 
-00029 typedef std::string::size_type SIZE;
-00030 
-00032 
-00054 class StringTokenizer
-00055 {
-00056 public:
-00058 
-00066   StringTokenizer(const std::string& rStr, char cDelim = ',', char cPrefix = '\0');
-00067   
-00069   ~StringTokenizer() {}
-00070   
-00072 
-00075   inline bool HasMoreTokens() const
-00076   {
-00077     return m_pos < m_len;
-00078   }
-00079   
-00081 
-00091   std::string GetNextToken(bool fSkipEmpty = false);
-00092   
-00094 
-00103   std::string GetNextTokenRaw(bool fSkipEmpty = false);
-00104   
-00106 
-00116   std::string GetRemainder();
-00117     
-00119 
-00128   inline void SetDelimiter(char cDelim)
-00129   {
-00130     m_cDelim = cDelim;
-00131   }
-00132   
-00134 
-00137   inline char GetDelimiter() const
-00138   {
-00139     return m_cDelim;
-00140   }
-00141   
-00143 
-00151   inline void SetPrefix(char cPrefix)
-00152   {
-00153     m_cPrefix = cPrefix;
-00154   }
-00155   
-00157 
-00160   inline char GetPrefix() const
-00161   {
-00162     return m_cPrefix;
-00163   }
-00164   
-00166 
-00171   inline void SetNoPrefix()
-00172   {
-00173     SetPrefix('\0');
-00174   }
-00175   
-00177 
-00180   inline void Reset()
-00181   {
-00182     m_pos = 0;
-00183   }
-00184   
-00185 private:
-00186   std::string m_str;            
-00187   char m_cDelim;                
-00188   char m_cPrefix;               
-00189   std::string::size_type m_pos; 
-00190   std::string::size_type m_len; 
-00191   
-00193 
-00198   std::string StripPrefix(const char* s, SIZE cnt);
-00199   
-00201 
-00207   void _GetNextToken(std::string& rToken, bool fStripPrefix);
-00208   
-00210 
-00217   void _GetNextTokenNoPrefix(std::string& rToken);
-00218   
-00220 
-00227   void _GetNextTokenWithPrefix(std::string& rToken);
-00228 };
-00229 
-00230 
-00231 #endif //_STRTOK_H_
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/structAppArgOption__t.html incron-0.5.12/doc/html/structAppArgOption__t.html --- incron-0.5.10/doc/html/structAppArgOption__t.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/structAppArgOption__t.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,171 +0,0 @@ - - - - -incron: AppArgOption_t Struct Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
AppArgOption_t Struct Reference
-
-
- -

Argument option type. - More...

- -

#include <appargs.h>

- -

List of all members.

- - - - - - - - - - - - -

-Public Attributes

AppArgType_t type
 argument type
bool mand
 mandatory yes/no
bool found
 found in argument vector
std::string val
 value
bool hasVal
 value is set
-

Detailed Description

-

Argument option type.

-

Member Data Documentation

- -
-
- - - - -
bool AppArgOption_t::found
-
-
- -

found in argument vector

- -
-
- -
-
- - - - -
bool AppArgOption_t::hasVal
-
-
- -

value is set

- -
-
- -
-
- - - - -
bool AppArgOption_t::mand
-
-
- -

mandatory yes/no

- -
-
- -
- -
- -

argument type

- -
-
- -
-
- - - - -
std::string AppArgOption_t::val
-
-
- -

value

- -
-
-
The documentation for this struct was generated from the following file: -
- - - - - - diff -Nru incron-0.5.10/doc/html/structAppArgOption__t-members.html incron-0.5.12/doc/html/structAppArgOption__t-members.html --- incron-0.5.10/doc/html/structAppArgOption__t-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/structAppArgOption__t-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,73 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
AppArgOption_t Member List
-
-
-This is the complete list of members for AppArgOption_t, including all inherited members. - - - - - -
foundAppArgOption_t
hasValAppArgOption_t
mandAppArgOption_t
typeAppArgOption_t
valAppArgOption_t
- - - - - - diff -Nru incron-0.5.10/doc/html/structProcData__t.html incron-0.5.12/doc/html/structProcData__t.html --- incron-0.5.10/doc/html/structProcData__t.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/structProcData__t.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,120 +0,0 @@ - - - - -incron: ProcData_t Struct Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
ProcData_t Struct Reference
-
-
- -

Child process data. - More...

- -

#include <usertable.h>

- -

List of all members.

- - - - - - -

-Public Attributes

proc_done_cb onDone
 function called after process finishes
InotifyWatchpWatch
 related watch
-

Detailed Description

-

Child process data.

-

Member Data Documentation

- -
- -
- -

function called after process finishes

- -
-
- -
- -
- -

related watch

- -
-
-
The documentation for this struct was generated from the following file: -
- - - - - - diff -Nru incron-0.5.10/doc/html/structProcData__t-members.html incron-0.5.12/doc/html/structProcData__t-members.html --- incron-0.5.10/doc/html/structProcData__t-members.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/structProcData__t-members.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,70 +0,0 @@ - - - - -incron: Member List - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
-
ProcData_t Member List
-
-
-This is the complete list of members for ProcData_t, including all inherited members. - - -
onDoneProcData_t
pWatchProcData_t
- - - - - - Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/tab_a.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/tab_a.png differ Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/tab_b.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/tab_b.png differ Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/tab_h.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/tab_h.png differ diff -Nru incron-0.5.10/doc/html/tabs.css incron-0.5.12/doc/html/tabs.css --- incron-0.5.10/doc/html/tabs.css 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/tabs.css 1970-01-01 00:00:00.000000000 +0000 @@ -1,59 +0,0 @@ -.tabs, .tabs2, .tabs3 { - background-image: url('tab_b.png'); - width: 100%; - z-index: 101; - font-size: 13px; -} - -.tabs2 { - font-size: 10px; -} -.tabs3 { - font-size: 9px; -} - -.tablist { - margin: 0; - padding: 0; - display: table; -} - -.tablist li { - float: left; - display: table-cell; - background-image: url('tab_b.png'); - line-height: 36px; - list-style: none; -} - -.tablist a { - display: block; - padding: 0 20px; - font-weight: bold; - background-image:url('tab_s.png'); - background-repeat:no-repeat; - background-position:right; - color: #283A5D; - text-shadow: 0px 1px 1px rgba(255, 255, 255, 0.9); - text-decoration: none; - outline: none; -} - -.tabs3 .tablist a { - padding: 0 10px; -} - -.tablist a:hover { - background-image: url('tab_h.png'); - background-repeat:repeat-x; - color: #fff; - text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); - text-decoration: none; -} - -.tablist li.current a { - background-image: url('tab_a.png'); - background-repeat:repeat-x; - color: #fff; - text-shadow: 0px 1px 1px rgba(0, 0, 0, 1.0); -} Binary files /tmp/tmpjzweAf/Kdwq0NB7ed/incron-0.5.10/doc/html/tab_s.png and /tmp/tmpjzweAf/MZQ6uBSS35/incron-0.5.12/doc/html/tab_s.png differ diff -Nru incron-0.5.10/doc/html/usertable_8cpp.html incron-0.5.12/doc/html/usertable_8cpp.html --- incron-0.5.10/doc/html/usertable_8cpp.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/usertable_8cpp.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,188 +0,0 @@ - - - - -incron: usertable.cpp File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
usertable.cpp File Reference
-
-
- -

inotify cron daemon user tables implementation -More...

-
#include <pwd.h>
-#include <syslog.h>
-#include <errno.h>
-#include <sys/wait.h>
-#include <unistd.h>
-#include <grp.h>
-#include <stdlib.h>
-#include <sys/stat.h>
-#include <cstdio>
-#include <cstring>
-#include "usertable.h"
-#include "incroncfg.h"
-#include "incrontab.h"
-
- - - - - - - - - - -

-Defines

#define DONT_FOLLOW(mask)   (false)
#define DEFAULT_PATH   "/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin"

-Functions

void on_proc_done (InotifyWatch *pW)

-Variables

volatile bool g_fFinish
 Finish program yes/no.
SUT_MAP g_ut
 User name to user table mapping table.
-

Detailed Description

-

inotify cron daemon user tables implementation

-

inotify cron system

-

Copyright (C) 2006, 2007, 2008, 2012 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can use it, redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL).

-

Credits: David Santinoli (supplementary groups) Boris Lechner (spaces in event-related file names) Christian Ruppert (new include to build with GCC 4.4+)

-

Define Documentation

- -
-
- - - - -
#define DEFAULT_PATH   "/usr/local/bin:/usr/bin:/bin:/usr/X11R6/bin"
-
-
- -
-
- -
-
- - - - - - - - -
#define DONT_FOLLOW( mask)   (false)
-
-
- -
-
-

Function Documentation

- -
-
- - - - - - - - -
void on_proc_done (InotifyWatchpW)
-
-
- -
-
-

Variable Documentation

- -
-
- - - - -
volatile bool g_fFinish
-
-
- -

Finish program yes/no.

- -
-
- -
-
- - - - -
SUT_MAP g_ut
-
-
- -

User name to user table mapping table.

- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/usertable_8h.html incron-0.5.12/doc/html/usertable_8h.html --- incron-0.5.10/doc/html/usertable_8h.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/usertable_8h.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,187 +0,0 @@ - - - - -incron: usertable.h File Reference - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
- -
-
usertable.h File Reference
-
-
- -

inotify cron daemon user tables header -More...

-
#include <map>
-#include <deque>
-#include <sys/poll.h>
-#include "inotify-cxx.h"
-#include "incrontab.h"
-
-

Go to the source code of this file.

- - - - - - - - - - - - - - - - - - - -

-Classes

struct  ProcData_t
 Child process data. More...
class  EventDispatcher
 Event dispatcher class. More...
class  UserTable
 User table class. More...

-Typedefs

typedef std::map< std::string,
-UserTable * > 
SUT_MAP
 User name to user table mapping definition.
typedef void(* proc_done_cb )(InotifyWatch *)
 Callback for calling after a process finishes.
typedef std::map< int,
-UserTable * > 
FDUT_MAP
 fd-to-usertable mapping
typedef std::map< InotifyWatch
-*, IncronTabEntry * > 
IWCE_MAP
 Watch-to-tableentry mapping.
typedef std::map< pid_t,
-ProcData_t
PROC_MAP
 Child process list.
-

Detailed Description

-

inotify cron daemon user tables header

-

inotify cron system

-

Copyright (C) 2006, 2007, 2008 Lukas Jelinek, <lukas@aiken.cz>

-

This program is free software; you can use it, redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL).

-

Typedef Documentation

- -
-
- - - - -
typedef std::map<int, UserTable*> FDUT_MAP
-
-
- -

fd-to-usertable mapping

- -
-
- -
-
- - - - -
typedef std::map<InotifyWatch*, IncronTabEntry*> IWCE_MAP
-
-
- -

Watch-to-tableentry mapping.

- -
-
- -
-
- - - - -
typedef void(* proc_done_cb)(InotifyWatch *)
-
-
- -

Callback for calling after a process finishes.

- -
-
- -
-
- - - - -
typedef std::map<pid_t, ProcData_t> PROC_MAP
-
-
- -

Child process list.

- -
-
- -
-
- - - - -
typedef std::map<std::string, UserTable*> SUT_MAP
-
-
- -

User name to user table mapping definition.

- -
-
-
- - - - - - diff -Nru incron-0.5.10/doc/html/usertable_8h_source.html incron-0.5.12/doc/html/usertable_8h_source.html --- incron-0.5.10/doc/html/usertable_8h_source.html 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/doc/html/usertable_8h_source.html 1970-01-01 00:00:00.000000000 +0000 @@ -1,218 +0,0 @@ - - - - -incron: usertable.h Source File - - - - - - - - -
- - -
- - - - - - - - - - - -
-
incron -  0.5.10 -
- -
-
- - - - -
-
-
usertable.h
-
-
-Go to the documentation of this file.
00001 
-00003 
-00016 #ifndef _USERTABLE_H_
-00017 #define _USERTABLE_H_
-00018 
-00019 #include <map>
-00020 #include <deque>
-00021 #include <sys/poll.h>
-00022 
-00023 #include "inotify-cxx.h"
-00024 #include "incrontab.h"
-00025 
-00026 
-00027 class UserTable;
-00028 
-00030 typedef std::map<std::string, UserTable*> SUT_MAP;
-00031 
-00033 typedef void (*proc_done_cb)(InotifyWatch*);
-00034 
-00036 typedef struct
-00037 {
-00038   proc_done_cb onDone;  
-00039   InotifyWatch* pWatch; 
-00040 } ProcData_t;
-00041 
-00043 typedef std::map<int, UserTable*> FDUT_MAP;
-00044 
-00046 typedef std::map<InotifyWatch*, IncronTabEntry*> IWCE_MAP;
-00047 
-00049 typedef std::map<pid_t, ProcData_t> PROC_MAP;
-00050 
-00052 
-00055 class EventDispatcher
-00056 {
-00057 public:
-00059 
-00065   EventDispatcher(int iPipeFd, Inotify* pIn, InotifyWatch* pSys, InotifyWatch* pUser);
-00066   
-00068   ~EventDispatcher();
-00069 
-00071 
-00074   bool ProcessEvents();
-00075   
-00077 
-00080   void Register(UserTable* pTab);
-00081   
-00083 
-00086   void Unregister(UserTable* pTab);
-00087   
-00089 
-00092   inline size_t GetSize() const
-00093   {
-00094     return m_size;
-00095   }
-00096   
-00098 
-00101   inline struct pollfd* GetPollData()
-00102   {
-00103     return m_pPoll;
-00104   }
-00105   
-00107   void Rebuild();
-00108   
-00110 
-00113   inline void Clear()
-00114   {
-00115     m_maps.clear();
-00116   }
-00117   
-00118 private:
-00119   int m_iPipeFd;    
-00120   int m_iMgmtFd;    
-00121   Inotify* m_pIn;   
-00122   InotifyWatch* m_pSys;   
-00123   InotifyWatch* m_pUser;  
-00124   FDUT_MAP m_maps;  
-00125   size_t m_size;    
-00126   struct pollfd* m_pPoll; 
-00127   
-00129   void ProcessMgmtEvents();
-00130 };
-00131 
-00132 
-00134 
-00139 class UserTable
-00140 {
-00141 public:
-00143 
-00148   UserTable(EventDispatcher* pEd, const std::string& rUser, bool fSysTable);
-00149   
-00151   virtual ~UserTable();
-00152   
-00154 
-00159   void Load();
-00160   
-00162 
-00166   void Dispose();
-00167   
-00169 
-00172   void OnEvent(InotifyEvent& rEvt);
-00173   
-00175 
-00179   static void FinishDone();
-00180   
-00182 
-00189   bool MayAccess(const std::string& rPath, bool fNoFollow) const;
-00190   
-00192 
-00195   bool IsSystem() const;
-00196   
-00198 
-00201   Inotify* GetInotify()
-00202   {
-00203     return &m_in;
-00204   }
-00205   
-00207 
-00217   inline static bool CheckUser(const char* user)
-00218   {
-00219     struct passwd* pw = getpwnam(user);
-00220     if (pw == NULL)
-00221       return false;
-00222       
-00223     return IncronTab::CheckUser(user);
-00224   }
-00225   
-00227 
-00230   void RunAsUser(char* const* argv) const;
-00231   
-00232 private:
-00233   Inotify m_in;           
-00234   EventDispatcher* m_pEd; 
-00235   std::string m_user;     
-00236   bool m_fSysTable;       
-00237   IncronTab m_tab;        
-00238   IWCE_MAP m_map;         
-00239 
-00240   static PROC_MAP s_procMap;  
-00241   
-00243 
-00247   IncronTabEntry* FindEntry(InotifyWatch* pWatch);
-00248   
-00250 
-00256   bool PrepareArgs(const std::string& rCmd, int& argc, char**& argv);
-00257   
-00259 
-00263   void CleanupArgs(int argc, char** argv);
-00264   
-00265 };
-00266 
-00267 #endif //_USERTABLE_H_
-
-
- - - - - - diff -Nru incron-0.5.10/Doxyfile incron-0.5.12/Doxyfile --- incron-0.5.10/Doxyfile 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/Doxyfile 2019-02-18 12:34:17.000000000 +0000 @@ -0,0 +1,1356 @@ +# Doxyfile 1.5.5 + +# This file describes the settings to be used by the documentation system +# doxygen (www.doxygen.org) for a project +# +# All text after a hash (#) is considered a comment and will be ignored +# The format is: +# TAG = value [value, ...] +# For lists items can also be appended using: +# TAG += value [value, ...] +# Values that contain spaces should be placed between quotes (" ") + +#--------------------------------------------------------------------------- +# Project related configuration options +#--------------------------------------------------------------------------- + +# This tag specifies the encoding used for all characters in the config file +# that follow. The default is UTF-8 which is also the encoding used for all +# text before the first occurrence of this tag. Doxygen uses libiconv (or the +# iconv built into libc) for the transcoding. See +# http://www.gnu.org/software/libiconv for the list of possible encodings. + +DOXYFILE_ENCODING = UTF-8 + +# The PROJECT_NAME tag is a single word (or a sequence of words surrounded +# by quotes) that should identify the project. + +PROJECT_NAME = incron + +# The PROJECT_NUMBER tag can be used to enter a project or revision number. +# This could be handy for archiving the generated documentation or +# if some version control system is used. + +PROJECT_NUMBER = 0.5.12 + +# The OUTPUT_DIRECTORY tag is used to specify the (relative or absolute) +# base path where the generated documentation will be put. +# If a relative path is entered, it will be relative to the location +# where doxygen was started. If left blank the current directory will be used. + +OUTPUT_DIRECTORY = doc + +# If the CREATE_SUBDIRS tag is set to YES, then doxygen will create +# 4096 sub-directories (in 2 levels) under the output directory of each output +# format and will distribute the generated files over these directories. +# Enabling this option can be useful when feeding doxygen a huge amount of +# source files, where putting all generated files in the same directory would +# otherwise cause performance problems for the file system. + +CREATE_SUBDIRS = NO + +# The OUTPUT_LANGUAGE tag is used to specify the language in which all +# documentation generated by doxygen is written. Doxygen will use this +# information to generate all constant output in the proper language. +# The default language is English, other supported languages are: +# Afrikaans, Arabic, Brazilian, Catalan, Chinese, Chinese-Traditional, +# Croatian, Czech, Danish, Dutch, Farsi, Finnish, French, German, Greek, +# Hungarian, Italian, Japanese, Japanese-en (Japanese with English messages), +# Korean, Korean-en, Lithuanian, Norwegian, Macedonian, Persian, Polish, +# Portuguese, Romanian, Russian, Serbian, Slovak, Slovene, Spanish, Swedish, +# and Ukrainian. + +OUTPUT_LANGUAGE = English + +# If the BRIEF_MEMBER_DESC tag is set to YES (the default) Doxygen will +# include brief member descriptions after the members that are listed in +# the file and class documentation (similar to JavaDoc). +# Set to NO to disable this. + +BRIEF_MEMBER_DESC = YES + +# If the REPEAT_BRIEF tag is set to YES (the default) Doxygen will prepend +# the brief description of a member or function before the detailed description. +# Note: if both HIDE_UNDOC_MEMBERS and BRIEF_MEMBER_DESC are set to NO, the +# brief descriptions will be completely suppressed. + +REPEAT_BRIEF = YES + +# This tag implements a quasi-intelligent brief description abbreviator +# that is used to form the text in various listings. Each string +# in this list, if found as the leading text of the brief description, will be +# stripped from the text and the result after processing the whole list, is +# used as the annotated text. Otherwise, the brief description is used as-is. +# If left blank, the following values are used ("$name" is automatically +# replaced with the name of the entity): "The $name class" "The $name widget" +# "The $name file" "is" "provides" "specifies" "contains" +# "represents" "a" "an" "the" + +ABBREVIATE_BRIEF = + +# If the ALWAYS_DETAILED_SEC and REPEAT_BRIEF tags are both set to YES then +# Doxygen will generate a detailed section even if there is only a brief +# description. + +ALWAYS_DETAILED_SEC = NO + +# If the INLINE_INHERITED_MEMB tag is set to YES, doxygen will show all +# inherited members of a class in the documentation of that class as if those +# members were ordinary class members. Constructors, destructors and assignment +# operators of the base classes will not be shown. + +INLINE_INHERITED_MEMB = NO + +# If the FULL_PATH_NAMES tag is set to YES then Doxygen will prepend the full +# path before files name in the file list and in the header files. If set +# to NO the shortest path that makes the file name unique will be used. + +FULL_PATH_NAMES = YES + +# If the FULL_PATH_NAMES tag is set to YES then the STRIP_FROM_PATH tag +# can be used to strip a user-defined part of the path. Stripping is +# only done if one of the specified strings matches the left-hand part of +# the path. The tag can be used to show relative paths in the file list. +# If left blank the directory from which doxygen is run is used as the +# path to strip. + +STRIP_FROM_PATH = + +# The STRIP_FROM_INC_PATH tag can be used to strip a user-defined part of +# the path mentioned in the documentation of a class, which tells +# the reader which header file to include in order to use a class. +# If left blank only the name of the header file containing the class +# definition is used. Otherwise one should specify the include paths that +# are normally passed to the compiler using the -I flag. + +STRIP_FROM_INC_PATH = + +# If the SHORT_NAMES tag is set to YES, doxygen will generate much shorter +# (but less readable) file names. This can be useful is your file systems +# doesn't support long names like on DOS, Mac, or CD-ROM. + +SHORT_NAMES = NO + +# If the JAVADOC_AUTOBRIEF tag is set to YES then Doxygen +# will interpret the first line (until the first dot) of a JavaDoc-style +# comment as the brief description. If set to NO, the JavaDoc +# comments will behave just like regular Qt-style comments +# (thus requiring an explicit @brief command for a brief description.) + +JAVADOC_AUTOBRIEF = NO + +# If the QT_AUTOBRIEF tag is set to YES then Doxygen will +# interpret the first line (until the first dot) of a Qt-style +# comment as the brief description. If set to NO, the comments +# will behave just like regular Qt-style comments (thus requiring +# an explicit \brief command for a brief description.) + +QT_AUTOBRIEF = NO + +# The MULTILINE_CPP_IS_BRIEF tag can be set to YES to make Doxygen +# treat a multi-line C++ special comment block (i.e. a block of //! or /// +# comments) as a brief description. This used to be the default behaviour. +# The new default is to treat a multi-line C++ comment block as a detailed +# description. Set this tag to YES if you prefer the old behaviour instead. + +MULTILINE_CPP_IS_BRIEF = NO + +# If the DETAILS_AT_TOP tag is set to YES then Doxygen +# will output the detailed description near the top, like JavaDoc. +# If set to NO, the detailed description appears after the member +# documentation. + +DETAILS_AT_TOP = NO + +# If the INHERIT_DOCS tag is set to YES (the default) then an undocumented +# member inherits the documentation from any documented member that it +# re-implements. + +INHERIT_DOCS = YES + +# If the SEPARATE_MEMBER_PAGES tag is set to YES, then doxygen will produce +# a new page for each member. If set to NO, the documentation of a member will +# be part of the file/class/namespace that contains it. + +SEPARATE_MEMBER_PAGES = NO + +# The TAB_SIZE tag can be used to set the number of spaces in a tab. +# Doxygen uses this value to replace tabs by spaces in code fragments. + +TAB_SIZE = 2 + +# This tag can be used to specify a number of aliases that acts +# as commands in the documentation. An alias has the form "name=value". +# For example adding "sideeffect=\par Side Effects:\n" will allow you to +# put the command \sideeffect (or @sideeffect) in the documentation, which +# will result in a user-defined paragraph with heading "Side Effects:". +# You can put \n's in the value part of an alias to insert newlines. + +ALIASES = + +# Set the OPTIMIZE_OUTPUT_FOR_C tag to YES if your project consists of C +# sources only. Doxygen will then generate output that is more tailored for C. +# For instance, some of the names that are used will be different. The list +# of all members will be omitted, etc. + +OPTIMIZE_OUTPUT_FOR_C = NO + +# Set the OPTIMIZE_OUTPUT_JAVA tag to YES if your project consists of Java +# sources only. Doxygen will then generate output that is more tailored for +# Java. For instance, namespaces will be presented as packages, qualified +# scopes will look different, etc. + +OPTIMIZE_OUTPUT_JAVA = NO + +# Set the OPTIMIZE_FOR_FORTRAN tag to YES if your project consists of Fortran +# sources only. Doxygen will then generate output that is more tailored for +# Fortran. + +OPTIMIZE_FOR_FORTRAN = NO + +# Set the OPTIMIZE_OUTPUT_VHDL tag to YES if your project consists of VHDL +# sources. Doxygen will then generate output that is tailored for +# VHDL. + +OPTIMIZE_OUTPUT_VHDL = NO + +# If you use STL classes (i.e. std::string, std::vector, etc.) but do not want +# to include (a tag file for) the STL sources as input, then you should +# set this tag to YES in order to let doxygen match functions declarations and +# definitions whose arguments contain STL classes (e.g. func(std::string); v.s. +# func(std::string) {}). This also make the inheritance and collaboration +# diagrams that involve STL classes more complete and accurate. + +BUILTIN_STL_SUPPORT = NO + +# If you use Microsoft's C++/CLI language, you should set this option to YES to +# enable parsing support. + +CPP_CLI_SUPPORT = NO + +# Set the SIP_SUPPORT tag to YES if your project consists of sip sources only. +# Doxygen will parse them like normal C++ but will assume all classes use public +# instead of private inheritance when no explicit protection keyword is present. + +SIP_SUPPORT = NO + +# If member grouping is used in the documentation and the DISTRIBUTE_GROUP_DOC +# tag is set to YES, then doxygen will reuse the documentation of the first +# member in the group (if any) for the other members of the group. By default +# all members of a group must be documented explicitly. + +DISTRIBUTE_GROUP_DOC = NO + +# Set the SUBGROUPING tag to YES (the default) to allow class member groups of +# the same type (for instance a group of public functions) to be put as a +# subgroup of that type (e.g. under the Public Functions section). Set it to +# NO to prevent subgrouping. Alternatively, this can be done per class using +# the \nosubgrouping command. + +SUBGROUPING = YES + +# When TYPEDEF_HIDES_STRUCT is enabled, a typedef of a struct, union, or enum +# is documented as struct, union, or enum with the name of the typedef. So +# typedef struct TypeS {} TypeT, will appear in the documentation as a struct +# with name TypeT. When disabled the typedef will appear as a member of a file, +# namespace, or class. And the struct will be named TypeS. This can typically +# be useful for C code in case the coding convention dictates that all compound +# types are typedef'ed and only the typedef is referenced, never the tag name. + +TYPEDEF_HIDES_STRUCT = NO + +#--------------------------------------------------------------------------- +# Build related configuration options +#--------------------------------------------------------------------------- + +# If the EXTRACT_ALL tag is set to YES doxygen will assume all entities in +# documentation are documented, even if no documentation was available. +# Private class members and static file members will be hidden unless +# the EXTRACT_PRIVATE and EXTRACT_STATIC tags are set to YES + +EXTRACT_ALL = YES + +# If the EXTRACT_PRIVATE tag is set to YES all private members of a class +# will be included in the documentation. + +EXTRACT_PRIVATE = NO + +# If the EXTRACT_STATIC tag is set to YES all static members of a file +# will be included in the documentation. + +EXTRACT_STATIC = YES + +# If the EXTRACT_LOCAL_CLASSES tag is set to YES classes (and structs) +# defined locally in source files will be included in the documentation. +# If set to NO only classes defined in header files are included. + +EXTRACT_LOCAL_CLASSES = YES + +# This flag is only useful for Objective-C code. When set to YES local +# methods, which are defined in the implementation section but not in +# the interface are included in the documentation. +# If set to NO (the default) only methods in the interface are included. + +EXTRACT_LOCAL_METHODS = NO + +# If this flag is set to YES, the members of anonymous namespaces will be +# extracted and appear in the documentation as a namespace called +# 'anonymous_namespace{file}', where file will be replaced with the base +# name of the file that contains the anonymous namespace. By default +# anonymous namespace are hidden. + +EXTRACT_ANON_NSPACES = NO + +# If the HIDE_UNDOC_MEMBERS tag is set to YES, Doxygen will hide all +# undocumented members of documented classes, files or namespaces. +# If set to NO (the default) these members will be included in the +# various overviews, but no documentation section is generated. +# This option has no effect if EXTRACT_ALL is enabled. + +HIDE_UNDOC_MEMBERS = NO + +# If the HIDE_UNDOC_CLASSES tag is set to YES, Doxygen will hide all +# undocumented classes that are normally visible in the class hierarchy. +# If set to NO (the default) these classes will be included in the various +# overviews. This option has no effect if EXTRACT_ALL is enabled. + +HIDE_UNDOC_CLASSES = NO + +# If the HIDE_FRIEND_COMPOUNDS tag is set to YES, Doxygen will hide all +# friend (class|struct|union) declarations. +# If set to NO (the default) these declarations will be included in the +# documentation. + +HIDE_FRIEND_COMPOUNDS = NO + +# If the HIDE_IN_BODY_DOCS tag is set to YES, Doxygen will hide any +# documentation blocks found inside the body of a function. +# If set to NO (the default) these blocks will be appended to the +# function's detailed documentation block. + +HIDE_IN_BODY_DOCS = NO + +# The INTERNAL_DOCS tag determines if documentation +# that is typed after a \internal command is included. If the tag is set +# to NO (the default) then the documentation will be excluded. +# Set it to YES to include the internal documentation. + +INTERNAL_DOCS = NO + +# If the CASE_SENSE_NAMES tag is set to NO then Doxygen will only generate +# file names in lower-case letters. If set to YES upper-case letters are also +# allowed. This is useful if you have classes or files whose names only differ +# in case and if your file system supports case sensitive file names. Windows +# and Mac users are advised to set this option to NO. + +CASE_SENSE_NAMES = YES + +# If the HIDE_SCOPE_NAMES tag is set to NO (the default) then Doxygen +# will show members with their full class and namespace scopes in the +# documentation. If set to YES the scope will be hidden. + +HIDE_SCOPE_NAMES = NO + +# If the SHOW_INCLUDE_FILES tag is set to YES (the default) then Doxygen +# will put a list of the files that are included by a file in the documentation +# of that file. + +SHOW_INCLUDE_FILES = YES + +# If the INLINE_INFO tag is set to YES (the default) then a tag [inline] +# is inserted in the documentation for inline members. + +INLINE_INFO = YES + +# If the SORT_MEMBER_DOCS tag is set to YES (the default) then doxygen +# will sort the (detailed) documentation of file and class members +# alphabetically by member name. If set to NO the members will appear in +# declaration order. + +SORT_MEMBER_DOCS = YES + +# If the SORT_BRIEF_DOCS tag is set to YES then doxygen will sort the +# brief documentation of file, namespace and class members alphabetically +# by member name. If set to NO (the default) the members will appear in +# declaration order. + +SORT_BRIEF_DOCS = NO + +# If the SORT_GROUP_NAMES tag is set to YES then doxygen will sort the +# hierarchy of group names into alphabetical order. If set to NO (the default) +# the group names will appear in their defined order. + +SORT_GROUP_NAMES = NO + +# If the SORT_BY_SCOPE_NAME tag is set to YES, the class list will be +# sorted by fully-qualified names, including namespaces. If set to +# NO (the default), the class list will be sorted only by class name, +# not including the namespace part. +# Note: This option is not very useful if HIDE_SCOPE_NAMES is set to YES. +# Note: This option applies only to the class list, not to the +# alphabetical list. + +SORT_BY_SCOPE_NAME = NO + +# The GENERATE_TODOLIST tag can be used to enable (YES) or +# disable (NO) the todo list. This list is created by putting \todo +# commands in the documentation. + +GENERATE_TODOLIST = YES + +# The GENERATE_TESTLIST tag can be used to enable (YES) or +# disable (NO) the test list. This list is created by putting \test +# commands in the documentation. + +GENERATE_TESTLIST = YES + +# The GENERATE_BUGLIST tag can be used to enable (YES) or +# disable (NO) the bug list. This list is created by putting \bug +# commands in the documentation. + +GENERATE_BUGLIST = YES + +# The GENERATE_DEPRECATEDLIST tag can be used to enable (YES) or +# disable (NO) the deprecated list. This list is created by putting +# \deprecated commands in the documentation. + +GENERATE_DEPRECATEDLIST= YES + +# The ENABLED_SECTIONS tag can be used to enable conditional +# documentation sections, marked by \if sectionname ... \endif. + +ENABLED_SECTIONS = + +# The MAX_INITIALIZER_LINES tag determines the maximum number of lines +# the initial value of a variable or define consists of for it to appear in +# the documentation. If the initializer consists of more lines than specified +# here it will be hidden. Use a value of 0 to hide initializers completely. +# The appearance of the initializer of individual variables and defines in the +# documentation can be controlled using \showinitializer or \hideinitializer +# command in the documentation regardless of this setting. + +MAX_INITIALIZER_LINES = 30 + +# Set the SHOW_USED_FILES tag to NO to disable the list of files generated +# at the bottom of the documentation of classes and structs. If set to YES the +# list will mention the files that were used to generate the documentation. + +SHOW_USED_FILES = YES + +# If the sources in your project are distributed over multiple directories +# then setting the SHOW_DIRECTORIES tag to YES will show the directory hierarchy +# in the documentation. The default is NO. + +SHOW_DIRECTORIES = NO + +# The FILE_VERSION_FILTER tag can be used to specify a program or script that +# doxygen should invoke to get the current version for each file (typically from +# the version control system). Doxygen will invoke the program by executing (via +# popen()) the command , where is the value of +# the FILE_VERSION_FILTER tag, and is the name of an input file +# provided by doxygen. Whatever the program writes to standard output +# is used as the file version. See the manual for examples. + +FILE_VERSION_FILTER = + +#--------------------------------------------------------------------------- +# configuration options related to warning and progress messages +#--------------------------------------------------------------------------- + +# The QUIET tag can be used to turn on/off the messages that are generated +# by doxygen. Possible values are YES and NO. If left blank NO is used. + +QUIET = NO + +# The WARNINGS tag can be used to turn on/off the warning messages that are +# generated by doxygen. Possible values are YES and NO. If left blank +# NO is used. + +WARNINGS = YES + +# If WARN_IF_UNDOCUMENTED is set to YES, then doxygen will generate warnings +# for undocumented members. If EXTRACT_ALL is set to YES then this flag will +# automatically be disabled. + +WARN_IF_UNDOCUMENTED = YES + +# If WARN_IF_DOC_ERROR is set to YES, doxygen will generate warnings for +# potential errors in the documentation, such as not documenting some +# parameters in a documented function, or documenting parameters that +# don't exist or using markup commands wrongly. + +WARN_IF_DOC_ERROR = YES + +# This WARN_NO_PARAMDOC option can be abled to get warnings for +# functions that are documented, but have no documentation for their parameters +# or return value. If set to NO (the default) doxygen will only warn about +# wrong or incomplete parameter documentation, but not about the absence of +# documentation. + +WARN_NO_PARAMDOC = NO + +# The WARN_FORMAT tag determines the format of the warning messages that +# doxygen can produce. The string should contain the $file, $line, and $text +# tags, which will be replaced by the file and line number from which the +# warning originated and the warning text. Optionally the format may contain +# $version, which will be replaced by the version of the file (if it could +# be obtained via FILE_VERSION_FILTER) + +WARN_FORMAT = "$file:$line: $text" + +# The WARN_LOGFILE tag can be used to specify a file to which warning +# and error messages should be written. If left blank the output is written +# to stderr. + +WARN_LOGFILE = + +#--------------------------------------------------------------------------- +# configuration options related to the input files +#--------------------------------------------------------------------------- + +# The INPUT tag can be used to specify the files and/or directories that contain +# documented source files. You may enter file names like "myfile.cpp" or +# directories like "/usr/src/myproject". Separate the files or directories +# with spaces. + +INPUT = + +# This tag can be used to specify the character encoding of the source files +# that doxygen parses. Internally doxygen uses the UTF-8 encoding, which is +# also the default input encoding. Doxygen uses libiconv (or the iconv built +# into libc) for the transcoding. See http://www.gnu.org/software/libiconv for +# the list of possible encodings. + +INPUT_ENCODING = UTF-8 + +# If the value of the INPUT tag contains directories, you can use the +# FILE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp +# and *.h) to filter out the source-files in the directories. If left +# blank the following patterns are tested: +# *.c *.cc *.cxx *.cpp *.c++ *.java *.ii *.ixx *.ipp *.i++ *.inl *.h *.hh *.hxx +# *.hpp *.h++ *.idl *.odl *.cs *.php *.php3 *.inc *.m *.mm *.py *.f90 + +FILE_PATTERNS = + +# The RECURSIVE tag can be used to turn specify whether or not subdirectories +# should be searched for input files as well. Possible values are YES and NO. +# If left blank NO is used. + +RECURSIVE = NO + +# The EXCLUDE tag can be used to specify files and/or directories that should +# excluded from the INPUT source files. This way you can easily exclude a +# subdirectory from a directory tree whose root is specified with the INPUT tag. + +EXCLUDE = + +# The EXCLUDE_SYMLINKS tag can be used select whether or not files or +# directories that are symbolic links (a Unix filesystem feature) are excluded +# from the input. + +EXCLUDE_SYMLINKS = NO + +# If the value of the INPUT tag contains directories, you can use the +# EXCLUDE_PATTERNS tag to specify one or more wildcard patterns to exclude +# certain files from those directories. Note that the wildcards are matched +# against the file with absolute path, so to exclude all test directories +# for example use the pattern */test/* + +EXCLUDE_PATTERNS = + +# The EXCLUDE_SYMBOLS tag can be used to specify one or more symbol names +# (namespaces, classes, functions, etc.) that should be excluded from the +# output. The symbol name can be a fully qualified name, a word, or if the +# wildcard * is used, a substring. Examples: ANamespace, AClass, +# AClass::ANamespace, ANamespace::*Test + +EXCLUDE_SYMBOLS = + +# The EXAMPLE_PATH tag can be used to specify one or more files or +# directories that contain example code fragments that are included (see +# the \include command). + +EXAMPLE_PATH = + +# If the value of the EXAMPLE_PATH tag contains directories, you can use the +# EXAMPLE_PATTERNS tag to specify one or more wildcard pattern (like *.cpp +# and *.h) to filter out the source-files in the directories. If left +# blank all files are included. + +EXAMPLE_PATTERNS = + +# If the EXAMPLE_RECURSIVE tag is set to YES then subdirectories will be +# searched for input files to be used with the \include or \dontinclude +# commands irrespective of the value of the RECURSIVE tag. +# Possible values are YES and NO. If left blank NO is used. + +EXAMPLE_RECURSIVE = NO + +# The IMAGE_PATH tag can be used to specify one or more files or +# directories that contain image that are included in the documentation (see +# the \image command). + +IMAGE_PATH = + +# The INPUT_FILTER tag can be used to specify a program that doxygen should +# invoke to filter for each input file. Doxygen will invoke the filter program +# by executing (via popen()) the command , where +# is the value of the INPUT_FILTER tag, and is the name of an +# input file. Doxygen will then use the output that the filter program writes +# to standard output. If FILTER_PATTERNS is specified, this tag will be +# ignored. + +INPUT_FILTER = + +# The FILTER_PATTERNS tag can be used to specify filters on a per file pattern +# basis. Doxygen will compare the file name with each pattern and apply the +# filter if there is a match. The filters are a list of the form: +# pattern=filter (like *.cpp=my_cpp_filter). See INPUT_FILTER for further +# info on how filters are used. If FILTER_PATTERNS is empty, INPUT_FILTER +# is applied to all files. + +FILTER_PATTERNS = + +# If the FILTER_SOURCE_FILES tag is set to YES, the input filter (if set using +# INPUT_FILTER) will be used to filter the input files when producing source +# files to browse (i.e. when SOURCE_BROWSER is set to YES). + +FILTER_SOURCE_FILES = NO + +#--------------------------------------------------------------------------- +# configuration options related to source browsing +#--------------------------------------------------------------------------- + +# If the SOURCE_BROWSER tag is set to YES then a list of source files will +# be generated. Documented entities will be cross-referenced with these sources. +# Note: To get rid of all source code in the generated output, make sure also +# VERBATIM_HEADERS is set to NO. + +SOURCE_BROWSER = NO + +# Setting the INLINE_SOURCES tag to YES will include the body +# of functions and classes directly in the documentation. + +INLINE_SOURCES = NO + +# Setting the STRIP_CODE_COMMENTS tag to YES (the default) will instruct +# doxygen to hide any special comment blocks from generated source code +# fragments. Normal C and C++ comments will always remain visible. + +STRIP_CODE_COMMENTS = YES + +# If the REFERENCED_BY_RELATION tag is set to YES (the default) +# then for each documented function all documented +# functions referencing it will be listed. + +REFERENCED_BY_RELATION = NO + +# If the REFERENCES_RELATION tag is set to YES (the default) +# then for each documented function all documented entities +# called/used by that function will be listed. + +REFERENCES_RELATION = NO + +# If the REFERENCES_LINK_SOURCE tag is set to YES (the default) +# and SOURCE_BROWSER tag is set to YES, then the hyperlinks from +# functions in REFERENCES_RELATION and REFERENCED_BY_RELATION lists will +# link to the source code. Otherwise they will link to the documentstion. + +REFERENCES_LINK_SOURCE = YES + +# If the USE_HTAGS tag is set to YES then the references to source code +# will point to the HTML generated by the htags(1) tool instead of doxygen +# built-in source browser. The htags tool is part of GNU's global source +# tagging system (see http://www.gnu.org/software/global/global.html). You +# will need version 4.8.6 or higher. + +USE_HTAGS = NO + +# If the VERBATIM_HEADERS tag is set to YES (the default) then Doxygen +# will generate a verbatim copy of the header file for each class for +# which an include is specified. Set to NO to disable this. + +VERBATIM_HEADERS = YES + +#--------------------------------------------------------------------------- +# configuration options related to the alphabetical class index +#--------------------------------------------------------------------------- + +# If the ALPHABETICAL_INDEX tag is set to YES, an alphabetical index +# of all compounds will be generated. Enable this if the project +# contains a lot of classes, structs, unions or interfaces. + +ALPHABETICAL_INDEX = NO + +# If the alphabetical index is enabled (see ALPHABETICAL_INDEX) then +# the COLS_IN_ALPHA_INDEX tag can be used to specify the number of columns +# in which this list will be split (can be a number in the range [1..20]) + +COLS_IN_ALPHA_INDEX = 5 + +# In case all classes in a project start with a common prefix, all +# classes will be put under the same header in the alphabetical index. +# The IGNORE_PREFIX tag can be used to specify one or more prefixes that +# should be ignored while generating the index headers. + +IGNORE_PREFIX = + +#--------------------------------------------------------------------------- +# configuration options related to the HTML output +#--------------------------------------------------------------------------- + +# If the GENERATE_HTML tag is set to YES (the default) Doxygen will +# generate HTML output. + +GENERATE_HTML = YES + +# The HTML_OUTPUT tag is used to specify where the HTML docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `html' will be used as the default path. + +HTML_OUTPUT = html + +# The HTML_FILE_EXTENSION tag can be used to specify the file extension for +# each generated HTML page (for example: .htm,.php,.asp). If it is left blank +# doxygen will generate files with .html extension. + +HTML_FILE_EXTENSION = .html + +# The HTML_HEADER tag can be used to specify a personal HTML header for +# each generated HTML page. If it is left blank doxygen will generate a +# standard header. + +HTML_HEADER = + +# The HTML_FOOTER tag can be used to specify a personal HTML footer for +# each generated HTML page. If it is left blank doxygen will generate a +# standard footer. + +HTML_FOOTER = + +# The HTML_STYLESHEET tag can be used to specify a user-defined cascading +# style sheet that is used by each HTML page. It can be used to +# fine-tune the look of the HTML output. If the tag is left blank doxygen +# will generate a default style sheet. Note that doxygen will try to copy +# the style sheet file to the HTML output directory, so don't put your own +# stylesheet in the HTML output directory as well, or it will be erased! + +HTML_STYLESHEET = + +# If the HTML_ALIGN_MEMBERS tag is set to YES, the members of classes, +# files or namespaces will be aligned in HTML using tables. If set to +# NO a bullet list will be used. + +HTML_ALIGN_MEMBERS = YES + +# If the GENERATE_HTMLHELP tag is set to YES, additional index files +# will be generated that can be used as input for tools like the +# Microsoft HTML help workshop to generate a compiled HTML help file (.chm) +# of the generated HTML documentation. + +GENERATE_HTMLHELP = NO + +# If the GENERATE_DOCSET tag is set to YES, additional index files +# will be generated that can be used as input for Apple's Xcode 3 +# integrated development environment, introduced with OSX 10.5 (Leopard). +# To create a documentation set, doxygen will generate a Makefile in the +# HTML output directory. Running make will produce the docset in that +# directory and running "make install" will install the docset in +# ~/Library/Developer/Shared/Documentation/DocSets so that Xcode will find +# it at startup. + +GENERATE_DOCSET = NO + +# When GENERATE_DOCSET tag is set to YES, this tag determines the name of the +# feed. A documentation feed provides an umbrella under which multiple +# documentation sets from a single provider (such as a company or product suite) +# can be grouped. + +DOCSET_FEEDNAME = "Doxygen generated docs" + +# When GENERATE_DOCSET tag is set to YES, this tag specifies a string that +# should uniquely identify the documentation set bundle. This should be a +# reverse domain-name style string, e.g. com.mycompany.MyDocSet. Doxygen +# will append .docset to the name. + +DOCSET_BUNDLE_ID = org.doxygen.Project + +# If the HTML_DYNAMIC_SECTIONS tag is set to YES then the generated HTML +# documentation will contain sections that can be hidden and shown after the +# page has loaded. For this to work a browser that supports +# JavaScript and DHTML is required (for instance Mozilla 1.0+, Firefox +# Netscape 6.0+, Internet explorer 5.0+, Konqueror, or Safari). + +HTML_DYNAMIC_SECTIONS = NO + +# If the GENERATE_HTMLHELP tag is set to YES, the CHM_FILE tag can +# be used to specify the file name of the resulting .chm file. You +# can add a path in front of the file if the result should not be +# written to the html output directory. + +CHM_FILE = + +# If the GENERATE_HTMLHELP tag is set to YES, the HHC_LOCATION tag can +# be used to specify the location (absolute path including file name) of +# the HTML help compiler (hhc.exe). If non-empty doxygen will try to run +# the HTML help compiler on the generated index.hhp. + +HHC_LOCATION = + +# If the GENERATE_HTMLHELP tag is set to YES, the GENERATE_CHI flag +# controls if a separate .chi index file is generated (YES) or that +# it should be included in the master .chm file (NO). + +GENERATE_CHI = NO + +# If the GENERATE_HTMLHELP tag is set to YES, the BINARY_TOC flag +# controls whether a binary table of contents is generated (YES) or a +# normal table of contents (NO) in the .chm file. + +BINARY_TOC = NO + +# The TOC_EXPAND flag can be set to YES to add extra items for group members +# to the contents of the HTML help documentation and to the tree view. + +TOC_EXPAND = NO + +# The DISABLE_INDEX tag can be used to turn on/off the condensed index at +# top of each HTML page. The value NO (the default) enables the index and +# the value YES disables it. + +DISABLE_INDEX = NO + +# This tag can be used to set the number of enum values (range [1..20]) +# that doxygen will group on one line in the generated HTML documentation. + +ENUM_VALUES_PER_LINE = 4 + +# If the GENERATE_TREEVIEW tag is set to YES, a side panel will be +# generated containing a tree-like index structure (just like the one that +# is generated for HTML Help). For this to work a browser that supports +# JavaScript, DHTML, CSS and frames is required (for instance Mozilla 1.0+, +# Netscape 6.0+, Internet explorer 5.0+, or Konqueror). Windows users are +# probably better off using the HTML help feature. + +GENERATE_TREEVIEW = NO + +# If the treeview is enabled (see GENERATE_TREEVIEW) then this tag can be +# used to set the initial width (in pixels) of the frame in which the tree +# is shown. + +TREEVIEW_WIDTH = 250 + +#--------------------------------------------------------------------------- +# configuration options related to the LaTeX output +#--------------------------------------------------------------------------- + +# If the GENERATE_LATEX tag is set to YES (the default) Doxygen will +# generate Latex output. + +GENERATE_LATEX = NO + +# The LATEX_OUTPUT tag is used to specify where the LaTeX docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `latex' will be used as the default path. + +LATEX_OUTPUT = latex + +# The LATEX_CMD_NAME tag can be used to specify the LaTeX command name to be +# invoked. If left blank `latex' will be used as the default command name. + +LATEX_CMD_NAME = latex + +# The MAKEINDEX_CMD_NAME tag can be used to specify the command name to +# generate index for LaTeX. If left blank `makeindex' will be used as the +# default command name. + +MAKEINDEX_CMD_NAME = makeindex + +# If the COMPACT_LATEX tag is set to YES Doxygen generates more compact +# LaTeX documents. This may be useful for small projects and may help to +# save some trees in general. + +COMPACT_LATEX = NO + +# The PAPER_TYPE tag can be used to set the paper type that is used +# by the printer. Possible values are: a4, a4wide, letter, legal and +# executive. If left blank a4wide will be used. + +PAPER_TYPE = a4wide + +# The EXTRA_PACKAGES tag can be to specify one or more names of LaTeX +# packages that should be included in the LaTeX output. + +EXTRA_PACKAGES = + +# The LATEX_HEADER tag can be used to specify a personal LaTeX header for +# the generated latex document. The header should contain everything until +# the first chapter. If it is left blank doxygen will generate a +# standard header. Notice: only use this tag if you know what you are doing! + +LATEX_HEADER = + +# If the PDF_HYPERLINKS tag is set to YES, the LaTeX that is generated +# is prepared for conversion to pdf (using ps2pdf). The pdf file will +# contain links (just like the HTML output) instead of page references +# This makes the output suitable for online browsing using a pdf viewer. + +PDF_HYPERLINKS = YES + +# If the USE_PDFLATEX tag is set to YES, pdflatex will be used instead of +# plain latex in the generated Makefile. Set this option to YES to get a +# higher quality PDF documentation. + +USE_PDFLATEX = YES + +# If the LATEX_BATCHMODE tag is set to YES, doxygen will add the \\batchmode. +# command to the generated LaTeX files. This will instruct LaTeX to keep +# running if errors occur, instead of asking the user for help. +# This option is also used when generating formulas in HTML. + +LATEX_BATCHMODE = NO + +# If LATEX_HIDE_INDICES is set to YES then doxygen will not +# include the index chapters (such as File Index, Compound Index, etc.) +# in the output. + +LATEX_HIDE_INDICES = NO + +#--------------------------------------------------------------------------- +# configuration options related to the RTF output +#--------------------------------------------------------------------------- + +# If the GENERATE_RTF tag is set to YES Doxygen will generate RTF output +# The RTF output is optimized for Word 97 and may not look very pretty with +# other RTF readers or editors. + +GENERATE_RTF = NO + +# The RTF_OUTPUT tag is used to specify where the RTF docs will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `rtf' will be used as the default path. + +RTF_OUTPUT = rtf + +# If the COMPACT_RTF tag is set to YES Doxygen generates more compact +# RTF documents. This may be useful for small projects and may help to +# save some trees in general. + +COMPACT_RTF = NO + +# If the RTF_HYPERLINKS tag is set to YES, the RTF that is generated +# will contain hyperlink fields. The RTF file will +# contain links (just like the HTML output) instead of page references. +# This makes the output suitable for online browsing using WORD or other +# programs which support those fields. +# Note: wordpad (write) and others do not support links. + +RTF_HYPERLINKS = NO + +# Load stylesheet definitions from file. Syntax is similar to doxygen's +# config file, i.e. a series of assignments. You only have to provide +# replacements, missing definitions are set to their default value. + +RTF_STYLESHEET_FILE = + +# Set optional variables used in the generation of an rtf document. +# Syntax is similar to doxygen's config file. + +RTF_EXTENSIONS_FILE = + +#--------------------------------------------------------------------------- +# configuration options related to the man page output +#--------------------------------------------------------------------------- + +# If the GENERATE_MAN tag is set to YES (the default) Doxygen will +# generate man pages + +GENERATE_MAN = YES + +# The MAN_OUTPUT tag is used to specify where the man pages will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `man' will be used as the default path. + +MAN_OUTPUT = man + +# The MAN_EXTENSION tag determines the extension that is added to +# the generated man pages (default is the subroutine's section .3) + +MAN_EXTENSION = .3 + +# If the MAN_LINKS tag is set to YES and Doxygen generates man output, +# then it will generate one additional man file for each entity +# documented in the real man page(s). These additional files +# only source the real man page, but without them the man command +# would be unable to find the correct page. The default is NO. + +MAN_LINKS = NO + +#--------------------------------------------------------------------------- +# configuration options related to the XML output +#--------------------------------------------------------------------------- + +# If the GENERATE_XML tag is set to YES Doxygen will +# generate an XML file that captures the structure of +# the code including all documentation. + +GENERATE_XML = NO + +# The XML_OUTPUT tag is used to specify where the XML pages will be put. +# If a relative path is entered the value of OUTPUT_DIRECTORY will be +# put in front of it. If left blank `xml' will be used as the default path. + +XML_OUTPUT = xml + +# The XML_SCHEMA tag can be used to specify an XML schema, +# which can be used by a validating XML parser to check the +# syntax of the XML files. + +XML_SCHEMA = + +# The XML_DTD tag can be used to specify an XML DTD, +# which can be used by a validating XML parser to check the +# syntax of the XML files. + +XML_DTD = + +# If the XML_PROGRAMLISTING tag is set to YES Doxygen will +# dump the program listings (including syntax highlighting +# and cross-referencing information) to the XML output. Note that +# enabling this will significantly increase the size of the XML output. + +XML_PROGRAMLISTING = YES + +#--------------------------------------------------------------------------- +# configuration options for the AutoGen Definitions output +#--------------------------------------------------------------------------- + +# If the GENERATE_AUTOGEN_DEF tag is set to YES Doxygen will +# generate an AutoGen Definitions (see autogen.sf.net) file +# that captures the structure of the code including all +# documentation. Note that this feature is still experimental +# and incomplete at the moment. + +GENERATE_AUTOGEN_DEF = NO + +#--------------------------------------------------------------------------- +# configuration options related to the Perl module output +#--------------------------------------------------------------------------- + +# If the GENERATE_PERLMOD tag is set to YES Doxygen will +# generate a Perl module file that captures the structure of +# the code including all documentation. Note that this +# feature is still experimental and incomplete at the +# moment. + +GENERATE_PERLMOD = NO + +# If the PERLMOD_LATEX tag is set to YES Doxygen will generate +# the necessary Makefile rules, Perl scripts and LaTeX code to be able +# to generate PDF and DVI output from the Perl module output. + +PERLMOD_LATEX = NO + +# If the PERLMOD_PRETTY tag is set to YES the Perl module output will be +# nicely formatted so it can be parsed by a human reader. This is useful +# if you want to understand what is going on. On the other hand, if this +# tag is set to NO the size of the Perl module output will be much smaller +# and Perl will parse it just the same. + +PERLMOD_PRETTY = YES + +# The names of the make variables in the generated doxyrules.make file +# are prefixed with the string contained in PERLMOD_MAKEVAR_PREFIX. +# This is useful so different doxyrules.make files included by the same +# Makefile don't overwrite each other's variables. + +PERLMOD_MAKEVAR_PREFIX = + +#--------------------------------------------------------------------------- +# Configuration options related to the preprocessor +#--------------------------------------------------------------------------- + +# If the ENABLE_PREPROCESSING tag is set to YES (the default) Doxygen will +# evaluate all C-preprocessor directives found in the sources and include +# files. + +ENABLE_PREPROCESSING = YES + +# If the MACRO_EXPANSION tag is set to YES Doxygen will expand all macro +# names in the source code. If set to NO (the default) only conditional +# compilation will be performed. Macro expansion can be done in a controlled +# way by setting EXPAND_ONLY_PREDEF to YES. + +MACRO_EXPANSION = NO + +# If the EXPAND_ONLY_PREDEF and MACRO_EXPANSION tags are both set to YES +# then the macro expansion is limited to the macros specified with the +# PREDEFINED and EXPAND_AS_DEFINED tags. + +EXPAND_ONLY_PREDEF = NO + +# If the SEARCH_INCLUDES tag is set to YES (the default) the includes files +# in the INCLUDE_PATH (see below) will be search if a #include is found. + +SEARCH_INCLUDES = YES + +# The INCLUDE_PATH tag can be used to specify one or more directories that +# contain include files that are not input files but should be processed by +# the preprocessor. + +INCLUDE_PATH = + +# You can use the INCLUDE_FILE_PATTERNS tag to specify one or more wildcard +# patterns (like *.h and *.hpp) to filter out the header-files in the +# directories. If left blank, the patterns specified with FILE_PATTERNS will +# be used. + +INCLUDE_FILE_PATTERNS = + +# The PREDEFINED tag can be used to specify one or more macro names that +# are defined before the preprocessor is started (similar to the -D option of +# gcc). The argument of the tag is a list of macros of the form: name +# or name=definition (no spaces). If the definition and the = are +# omitted =1 is assumed. To prevent a macro definition from being +# undefined via #undef or recursively expanded use the := operator +# instead of the = operator. + +PREDEFINED = + +# If the MACRO_EXPANSION and EXPAND_ONLY_PREDEF tags are set to YES then +# this tag can be used to specify a list of macro names that should be expanded. +# The macro definition that is found in the sources will be used. +# Use the PREDEFINED tag if you want to use a different macro definition. + +EXPAND_AS_DEFINED = + +# If the SKIP_FUNCTION_MACROS tag is set to YES (the default) then +# doxygen's preprocessor will remove all function-like macros that are alone +# on a line, have an all uppercase name, and do not end with a semicolon. Such +# function macros are typically used for boiler-plate code, and will confuse +# the parser if not removed. + +SKIP_FUNCTION_MACROS = YES + +#--------------------------------------------------------------------------- +# Configuration::additions related to external references +#--------------------------------------------------------------------------- + +# The TAGFILES option can be used to specify one or more tagfiles. +# Optionally an initial location of the external documentation +# can be added for each tagfile. The format of a tag file without +# this location is as follows: +# TAGFILES = file1 file2 ... +# Adding location for the tag files is done as follows: +# TAGFILES = file1=loc1 "file2 = loc2" ... +# where "loc1" and "loc2" can be relative or absolute paths or +# URLs. If a location is present for each tag, the installdox tool +# does not have to be run to correct the links. +# Note that each tag file must have a unique name +# (where the name does NOT include the path) +# If a tag file is not located in the directory in which doxygen +# is run, you must also specify the path to the tagfile here. + +TAGFILES = + +# When a file name is specified after GENERATE_TAGFILE, doxygen will create +# a tag file that is based on the input files it reads. + +GENERATE_TAGFILE = + +# If the ALLEXTERNALS tag is set to YES all external classes will be listed +# in the class index. If set to NO only the inherited external classes +# will be listed. + +ALLEXTERNALS = NO + +# If the EXTERNAL_GROUPS tag is set to YES all external groups will be listed +# in the modules index. If set to NO, only the current project's groups will +# be listed. + +EXTERNAL_GROUPS = YES + +# The PERL_PATH should be the absolute path and name of the perl script +# interpreter (i.e. the result of `which perl'). + +PERL_PATH = /usr/bin/perl + +#--------------------------------------------------------------------------- +# Configuration options related to the dot tool +#--------------------------------------------------------------------------- + +# If the CLASS_DIAGRAMS tag is set to YES (the default) Doxygen will +# generate a inheritance diagram (in HTML, RTF and LaTeX) for classes with base +# or super classes. Setting the tag to NO turns the diagrams off. Note that +# this option is superseded by the HAVE_DOT option below. This is only a +# fallback. It is recommended to install and use dot, since it yields more +# powerful graphs. + +CLASS_DIAGRAMS = YES + +# You can define message sequence charts within doxygen comments using the \msc +# command. Doxygen will then run the mscgen tool (see +# http://www.mcternan.me.uk/mscgen/) to produce the chart and insert it in the +# documentation. The MSCGEN_PATH tag allows you to specify the directory where +# the mscgen tool resides. If left empty the tool is assumed to be found in the +# default search path. + +MSCGEN_PATH = + +# If set to YES, the inheritance and collaboration graphs will hide +# inheritance and usage relations if the target is undocumented +# or is not a class. + +HIDE_UNDOC_RELATIONS = YES + +# If you set the HAVE_DOT tag to YES then doxygen will assume the dot tool is +# available from the path. This tool is part of Graphviz, a graph visualization +# toolkit from AT&T and Lucent Bell Labs. The other options in this section +# have no effect if this option is set to NO (the default) + +HAVE_DOT = NO + +# If the CLASS_GRAPH and HAVE_DOT tags are set to YES then doxygen +# will generate a graph for each documented class showing the direct and +# indirect inheritance relations. Setting this tag to YES will force the +# the CLASS_DIAGRAMS tag to NO. + +CLASS_GRAPH = YES + +# If the COLLABORATION_GRAPH and HAVE_DOT tags are set to YES then doxygen +# will generate a graph for each documented class showing the direct and +# indirect implementation dependencies (inheritance, containment, and +# class references variables) of the class with other documented classes. + +COLLABORATION_GRAPH = YES + +# If the GROUP_GRAPHS and HAVE_DOT tags are set to YES then doxygen +# will generate a graph for groups, showing the direct groups dependencies + +GROUP_GRAPHS = YES + +# If the UML_LOOK tag is set to YES doxygen will generate inheritance and +# collaboration diagrams in a style similar to the OMG's Unified Modeling +# Language. + +UML_LOOK = NO + +# If set to YES, the inheritance and collaboration graphs will show the +# relations between templates and their instances. + +TEMPLATE_RELATIONS = NO + +# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDE_GRAPH, and HAVE_DOT +# tags are set to YES then doxygen will generate a graph for each documented +# file showing the direct and indirect include dependencies of the file with +# other documented files. + +INCLUDE_GRAPH = YES + +# If the ENABLE_PREPROCESSING, SEARCH_INCLUDES, INCLUDED_BY_GRAPH, and +# HAVE_DOT tags are set to YES then doxygen will generate a graph for each +# documented header file showing the documented files that directly or +# indirectly include this file. + +INCLUDED_BY_GRAPH = YES + +# If the CALL_GRAPH and HAVE_DOT options are set to YES then +# doxygen will generate a call dependency graph for every global function +# or class method. Note that enabling this option will significantly increase +# the time of a run. So in most cases it will be better to enable call graphs +# for selected functions only using the \callgraph command. + +CALL_GRAPH = NO + +# If the CALLER_GRAPH and HAVE_DOT tags are set to YES then +# doxygen will generate a caller dependency graph for every global function +# or class method. Note that enabling this option will significantly increase +# the time of a run. So in most cases it will be better to enable caller +# graphs for selected functions only using the \callergraph command. + +CALLER_GRAPH = NO + +# If the GRAPHICAL_HIERARCHY and HAVE_DOT tags are set to YES then doxygen +# will graphical hierarchy of all classes instead of a textual one. + +GRAPHICAL_HIERARCHY = YES + +# If the DIRECTORY_GRAPH, SHOW_DIRECTORIES and HAVE_DOT tags are set to YES +# then doxygen will show the dependencies a directory has on other directories +# in a graphical way. The dependency relations are determined by the #include +# relations between the files in the directories. + +DIRECTORY_GRAPH = YES + +# The DOT_IMAGE_FORMAT tag can be used to set the image format of the images +# generated by dot. Possible values are png, jpg, or gif +# If left blank png will be used. + +DOT_IMAGE_FORMAT = png + +# The tag DOT_PATH can be used to specify the path where the dot tool can be +# found. If left blank, it is assumed the dot tool can be found in the path. + +DOT_PATH = + +# The DOTFILE_DIRS tag can be used to specify one or more directories that +# contain dot files that are included in the documentation (see the +# \dotfile command). + +DOTFILE_DIRS = + +# The MAX_DOT_GRAPH_MAX_NODES tag can be used to set the maximum number of +# nodes that will be shown in the graph. If the number of nodes in a graph +# becomes larger than this value, doxygen will truncate the graph, which is +# visualized by representing a node as a red box. Note that doxygen if the +# number of direct children of the root node in a graph is already larger than +# DOT_GRAPH_MAX_NODES then the graph will not be shown at all. Also note +# that the size of a graph can be further restricted by MAX_DOT_GRAPH_DEPTH. + +DOT_GRAPH_MAX_NODES = 50 + +# The MAX_DOT_GRAPH_DEPTH tag can be used to set the maximum depth of the +# graphs generated by dot. A depth value of 3 means that only nodes reachable +# from the root by following a path via at most 3 edges will be shown. Nodes +# that lay further from the root node will be omitted. Note that setting this +# option to 1 or 2 may greatly reduce the computation time needed for large +# code bases. Also note that the size of a graph can be further restricted by +# DOT_GRAPH_MAX_NODES. Using a depth of 0 means no depth restriction. + +MAX_DOT_GRAPH_DEPTH = 0 + +# Set the DOT_TRANSPARENT tag to YES to generate images with a transparent +# background. This is enabled by default, which results in a transparent +# background. Warning: Depending on the platform used, enabling this option +# may lead to badly anti-aliased labels on the edges of a graph (i.e. they +# become hard to read). + +DOT_TRANSPARENT = YES + +# Set the DOT_MULTI_TARGETS tag to YES allow dot to generate multiple output +# files in one run (i.e. multiple -o and -T options on the command line). This +# makes dot run faster, but since only newer versions of dot (>1.8.10) +# support this, this feature is disabled by default. + +DOT_MULTI_TARGETS = NO + +# If the GENERATE_LEGEND tag is set to YES (the default) Doxygen will +# generate a legend page explaining the meaning of the various boxes and +# arrows in the dot generated graphs. + +GENERATE_LEGEND = YES + +# If the DOT_CLEANUP tag is set to YES (the default) Doxygen will +# remove the intermediate dot files that are used to generate +# the various graphs. + +DOT_CLEANUP = YES + +#--------------------------------------------------------------------------- +# Configuration::additions related to the search engine +#--------------------------------------------------------------------------- + +# The SEARCHENGINE tag specifies whether or not a search engine should be +# used. If set to NO the values of all tags below this one will be ignored. + +SEARCHENGINE = NO diff -Nru incron-0.5.10/executor.h incron-0.5.12/executor.h --- incron-0.5.10/executor.h 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/executor.h 2019-02-18 12:34:17.000000000 +0000 @@ -0,0 +1,126 @@ +#ifndef _EXECUTOR_H_ +#define _EXECUTOR_H_ +/** + * \file executor.h + * + * Copyright (C) 2015 Andreas Altair Redmer, + * + * This program is free software; you can redistribute it and/or + * modify it under the terms of one of the following licenses: + * + * \li 1. GNU Lesser General Public License, version 2.1 (see LICENSE-LGPL) + * \li 2. GNU General Public License, version 2 (see LICENSE-GPL) + * + * If you want to help with choosing the best license for you, + * please visit http://www.gnu.org/licenses/license-list.html. + * + */ + +#include +#include +#include +#include + +class Executor +{ + private: + + inline static std::string trim_right_copy( + const std::string& s, + const std::string& delimiters = " \f\n\r\t\v" ) + { + //cout << "trc" << endl; + if (s.length()==0) + return ""; + //cout << "trc" < execBashVec (string script); +// static const string execBash (string script); + + static const std::vector execBashVec (std::string script) + { + std::string s = execBash (script); + // from split + std::vector elems; + std::stringstream ss(s); + std::string item; + while (std::getline(ss, item, '\n')) { + elems.push_back(item); + } + return elems; + } + + static const std::string execBash (std::string script) + { + //cout << "execBash: " << script << endl; + std::string ret = plain_exec ((char*) script.c_str()); + return ret; + } + + // TODO make not stupid: no boost, no cli dependeny, no c++14 (for now) + // suppression of warning for not existign directories added + /** + *Returns all subdirectories of the dirctory 'dir' as vector of strings. + */ + static const std::vector getSubDirVec (std::string dir, bool includeDotDirs=false) + { + return execBashVec("find "+dir+" -type d "+ (includeDotDirs?std::string():std::string("! -path '*/.*' ")) +"2>/dev/null"); + } + + /** + *Returns all files in case the file decriptor contains a star. + */ + static const std::vector getAllFilesByDescriptor (std::string dir, bool includeDotDirs=false) + { + return execBashVec("find "+dir+" "+ (includeDotDirs?std::string():std::string("! -path '*/.*' ")) +"2>/dev/null"); + } +}; + +#endif //_EXECUTOR_H_ diff -Nru incron-0.5.10/.gitignore incron-0.5.12/.gitignore --- incron-0.5.10/.gitignore 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/.gitignore 2019-02-18 12:34:17.000000000 +0000 @@ -0,0 +1,31 @@ +# Compiled Object files +*.slo +*.lo +*.o +*.obj + +# Precompiled Headers +*.gch +*.pch + +# Compiled Dynamic libraries +*.so +*.dylib +*.dll + +# Fortran module files +*.mod + +# Compiled Static libraries +*.lai +*.la +*.a +*.lib + +# Executables +*.exe +*.out +*.app +incrond +incrontab + diff -Nru incron-0.5.10/icd-main.cpp incron-0.5.12/icd-main.cpp --- incron-0.5.10/icd-main.cpp 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/icd-main.cpp 2019-02-18 12:34:17.000000000 +0000 @@ -6,6 +6,7 @@ * inotify cron system * * Copyright (C) 2006, 2007, 2008, 2012 Lukas Jelinek, + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can use it, redistribute * it and/or modify it under the terms of the GNU General Public @@ -24,6 +25,7 @@ #include #include #include +#include #include #include #include @@ -38,7 +40,6 @@ #include "usertable.h" #include "incroncfg.h" - /// Logging options (console as fallback, log PID) #define INCRON_LOG_OPTS (LOG_CONS | LOG_PID) @@ -63,7 +64,7 @@ " -k, --kill terminates running instance of incrond\n" \ " -f , --config= overrides default configuration file (requires root privileges)\n" \ " -V, --version prints program version\n\n" \ - "For reporting bugs please use http://bts.aiken.cz\n" + "For reporting bugs please use https://github.com/ar-/incron/issues\n" @@ -151,6 +152,9 @@ } if (ok) { + // ignore files that start with a dot + if (pDe->d_name[0] == '.') + continue; syslog(LOG_INFO, "loading table %s", pDe->d_name); UserTable* pUt = new UserTable(pEd, un, true); g_ut.insert(SUT_MAP::value_type(path, pUt)); @@ -451,8 +455,7 @@ int res = poll(ed.GetPollData(), ed.GetSize(), -1); if (res > 0) { - if (ed.ProcessEvents()) - UserTable::FinishDone(); + ed.ProcessEvents(); } else if (res < 0) { switch (errno) { @@ -467,6 +470,9 @@ } } + // TODO try to do the finish thing all the time (there is a race condition somewhere + // it seem ProcessEvents returns too ealy sometimes + //UserTable::FinishDone(); } free_tables(&ed); diff -Nru incron-0.5.10/ict-main.cpp incron-0.5.12/ict-main.cpp --- incron-0.5.10/ict-main.cpp 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/ict-main.cpp 2019-02-18 12:34:17.000000000 +0000 @@ -6,6 +6,7 @@ * inotify cron system * * Copyright (C) 2006, 2007, 2008, 2012 Lukas Jelinek, + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can use it, redistribute * it and/or modify it under the terms of the GNU General Public @@ -69,7 +70,7 @@ "These options may be used:\n" \ " -u , --user= overrides current user (requires root privileges)\n" \ " -f , --config= overrides default configuration file (requires root privileges)\n\n" \ - "For reporting bugs please use http://bts.aiken.cz\n" + "For reporting bugs please use https://github.com/ar-/incron/issues\n" @@ -99,6 +100,16 @@ return false; } + struct passwd* ppwd = getpwnam(rUser.c_str()); + if (ppwd == NULL) { + fprintf(stderr, "cannot find user '%s': %s\n", rUser.c_str(), strerror(errno)); + return false; + } + if (chown(out.c_str(), ppwd->pw_uid, -1) != 0) { + fprintf(stderr, "cannot set owner '%s' to table '%s': %s\n", rUser.c_str(), out.c_str(), strerror(errno)); + return false; + } + return true; } diff -Nru incron-0.5.10/incron.conf incron-0.5.12/incron.conf --- incron-0.5.10/incron.conf 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/incron.conf 2019-02-18 12:34:17.000000000 +0000 @@ -0,0 +1,15 @@ +# incron - event based background program processing daemon +# +# incron is a program that runs user-specified programs at +# filesystem events + +description "event based background program processing daemon" +author "Andreas Altair Redmer " + +start on runlevel [2345] +stop on runlevel [!2345] + +expect fork +respawn + +exec incrond diff -Nru incron-0.5.10/incron.conf.5 incron-0.5.12/incron.conf.5 --- incron-0.5.10/incron.conf.5 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/incron.conf.5 2019-02-18 12:34:17.000000000 +0000 @@ -1,4 +1,4 @@ -.TH "incron.conf" "5" "0.5.10" "Lukas Jelinek" "incron documentation" +.TH "incron.conf" "5" "0.5.12" "Lukas Jelinek" "incron documentation" .SH "NAME" /etc/incron.conf \- main config file for inotify cron (incron) .SH "DESCRIPTION" @@ -39,6 +39,7 @@ .SH "SEE ALSO" incrond(8), incrontab(1), incrontab(5) .SH "AUTHOR" -Lukas Jelinek (please report bugs to http://bts.aiken.cz or ). +Andreas Altair Redmer (please report bugs to https://github.com/ar-/incron/issues ). +Lukas Jelinek . .SH "COPYING" This program is free software. It can be used, redistributed and/or modified under the terms of the GNU General Public License, version 2. diff -Nru incron-0.5.10/incrond.8 incron-0.5.12/incrond.8 --- incron-0.5.10/incrond.8 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/incrond.8 2019-02-18 12:34:17.000000000 +0000 @@ -1,4 +1,4 @@ -.TH "incrond" "8" "0.5.10" "Lukas Jelinek" "incron documentation" +.TH "incrond" "8" "0.5.12" "Lukas Jelinek" "incron documentation" .SH "NAME" incrond \- inotify cron (incron) daemon @@ -17,7 +17,7 @@ There are two files determining whether an user is allowed to use incron. These files have very simple syntax \- one user name per line. If /etc/incron.allow exists the user must be noted there to be allowed to use incron. Otherwise if /etc/incron.deny exists the user must not be noted there to use incron. If none of these files exists there is no other restriction whether anybody may use incron. Location of these files can be changed in the configuration. -The daemon itself is currently not protected against looping. If a command executed due to an event causes the same event it leads to an infinite loop unless a flag mask containing IN_NO_LOOP is specified. Please beware of this and do not allow permission for use incron to unreliable users. +The daemon itself is currently not protected against looping. If a command executed due to an event causes the same event it leads to an infinite loop unless a flag mask containing loopable=true is specified. Please beware of this and do not allow permission for use incron to unreliable users. \fB\-n\fR (or \fB\-\-foreground\fR) option causes running on foreground. This is useful especially for testing, debugging and optimization. @@ -30,8 +30,9 @@ .SH "SEE ALSO" incrontab(1), incrontab(5), incron.conf(5) .SH "BUGS" -incrond is currently not resistent against looping. Recursive monitoring (whole subtrees) has not been implemented yet. +incrond is currently not resistent against looping. .SH "AUTHOR" -Lukas Jelinek (please report bugs to http://bts.aiken.cz or ). +Andreas Altair Redmer (please report bugs to https://github.com/ar-/incron/issues ). +Lukas Jelinek . .SH "COPYING" This program is free software. It can be used, redistributed and/or modified under the terms of the GNU General Public License, version 2. diff -Nru incron-0.5.10/incron.h incron-0.5.12/incron.h --- incron-0.5.10/incron.h 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/incron.h 2019-02-18 12:34:17.000000000 +0000 @@ -6,6 +6,7 @@ * inotify cron system * * Copyright (C) 2006, 2007, 2008, 2009 Lukas Jelinek, + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can use it, redistribute * it and/or modify it under the terms of the GNU General Public @@ -27,10 +28,7 @@ #define INCRONTAB_NAME "incrontab" /// Application version (release) -#define INCRON_VERSION "0.5.10" - -/// Address for sending bugs -#define INCRON_BUG_ADDRESS "" +#define INCRON_VERSION "0.5.12" /// Default configuration file #define INCRON_CONFIG "/etc/incron.conf" diff -Nru incron-0.5.10/incrontab.1 incron-0.5.12/incrontab.1 --- incron-0.5.10/incrontab.1 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/incrontab.1 2019-02-18 12:34:17.000000000 +0000 @@ -1,4 +1,4 @@ -.TH "incrontab" "1" "0.5.10" "Lukas Jelinek" "incron documentation" +.TH "incrontab" "1" "0.5.12" "Lukas Jelinek" "incron documentation" .SH "NAME" incrontab \- table manipulator for inotify cron (incron) .SH "SYNOPSIS" @@ -8,7 +8,7 @@ .SH "DESCRIPTION" incrontab is a table manipulator for the inotify cron (incron) system. It creates, removes, modifies and lists user tables (\fIincrontab\fR(5)). -Each user (including system users even they haven't home directories) has an incron table which can't be manipulated directly (only root can effectively change these tables and is NOT recommended to do so). +Each user (including even system users without home directories) has an incron table which can't be manipulated directly (only root can effectively change these tables and is NOT recommended to do so). All informational messages of this program are printed to the standard error output (stderr). @@ -48,6 +48,7 @@ .SH "SEE ALSO" incrond(8), incrontab(5), incron.conf(5) .SH "AUTHOR" -Lukas Jelinek (please report bugs to http://bts.aiken.cz or ). +Andreas Altair Redmer (please report bugs to https://github.com/ar-/incron/issues ). +Lukas Jelinek . .SH "COPYING" This program is free software. It can be used, redistributed and/or modified under the terms of the GNU General Public License, version 2. diff -Nru incron-0.5.10/incrontab.5 incron-0.5.12/incrontab.5 --- incron-0.5.10/incrontab.5 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/incrontab.5 2019-02-18 12:34:17.000000000 +0000 @@ -1,4 +1,4 @@ -.TH "incrontab" "5" "0.5.10" "Lukas Jelinek" "incron documentation" +.TH "incrontab" "5" "0.5.12" "Lukas Jelinek" "incron documentation" .SH "NAME" incrontab \- tables for driving inotify cron (incron) .SH "DESCRIPTION" @@ -17,6 +17,8 @@ Where \fIpath\fR is an absolute filesystem path, \fImask\fR is an event mask (in symbolic or numeric form) and \fIcommand\fR is an executable file (or a script) with its arguments. See bellow for event mask symbols. The executable file may be noted as an absolute path or only as the name itself (PATH locations are examined). Please remember that the same path may occur only once per table (otherwise only the first occurrence takes effect and an error message is emitted to the system log). +Please not that the * wildcard is allowed to observe a range of files. + .SH "EVENT SYMBOLS" These basic event mask symbols are defined: @@ -56,7 +58,9 @@ .br \fBIN_ONLYDIR\fR Only watch pathname if it is a directory -Additionaly, there is a symbol which doesn't appear in the inotify symbol set. It it \fBIN_NO_LOOP\fR. This symbol disables monitoring events until the current one is completely handled (until its child process exits). +Additionally, there is a symbol which doesn't appear in the inotify symbol set. It is \fBloopable=true\fR. This symbol disables monitoring events until the current one is completely handled (until its child process exits). +Also, there is the symbol \fBrecursive=false\fR. This symbol limits the observation on the specified directory and does not include subdirectories. +Finally, there is also the symbol \fBdotdirs=true\fR. This symbol will include the hidden directories (where the names starts with a dot) in the observation. .SH "WILDCARDS" The following wildards may be used inside command specification: @@ -76,10 +80,14 @@ \fB/tmp IN_ALL_EVENTS abcd $@/$# $%\fR -\fB/usr/bin IN_ACCESS,IN_NO_LOOP abcd $#\fR +\fB/usr/bin IN_ACCESS,loopable=true abcd $#\fR \fB/home IN_CREATE /usr/local/bin/abcd $#\fR +\fB/home IN_CREATE,dotdirs=true /usr/local/bin/abcd $#\fR + +\fB/home IN_CREATE,recursive=false /usr/local/bin/abcd $#\fR + \fB/var/log 12 abcd $@/$#\fR The first line monitors all events on the /tmp directory. When an event occurs it runs a application called 'abcd' with the full path of the file as the first arguments and the event flags as the second one. @@ -88,11 +96,16 @@ The third example is used for monitoring the /home directory for newly create files or directories (it practically means an event is sent when a new user is added). This event is processed by a program specified by an absolute path. +The fourth example is the third example, but it will include hidden directories in the observation. + +The fifth example is the third example, but it will exclude sub-directories from the observation. + And the final line shows how to use numeric event mask instead of textual one. The value 12 is exactly the same as IN_ATTRIB,IN_CLOSE_WRITE. .SH "SEE ALSO" incrond(8), incrontab(1), incron.conf(5) .SH "AUTHOR" -Lukas Jelinek (please report bugs to http://bts.aiken.cz or ). +Andreas Altair Redmer (please report bugs to https://github.com/ar-/incron/issues ). +Lukas Jelinek . .SH "COPYING" This program is free software. It can be used, redistributed and/or modified under the terms of the GNU General Public License, version 2. diff -Nru incron-0.5.10/incrontab.cpp incron-0.5.12/incrontab.cpp --- incron-0.5.10/incrontab.cpp 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/incrontab.cpp 2019-02-18 12:34:17.000000000 +0000 @@ -6,6 +6,7 @@ * inotify cron system * * Copyright (C) 2006, 2007, 2008, 2012 Lukas Jelinek, + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can use it, redistribute * it and/or modify it under the terms of the GNU General Public @@ -20,19 +21,18 @@ #include #include #include +//#include // TODO remove #include "inotify-cxx.h" #include "incrontab.h" #include "incroncfg.h" -/* -/// Allowed users -#define INCRON_ALLOW_PATH "/etc/incron.allow" +#define IN_NO_LOOP_OLD "IN_NO_LOOP" // depricated from original version: no loop is now default +#define CT_LOOPABLE "loopable=true" // no loop is default. loopable must be set +#define CT_NORECURSION "recursive=false" // recursive is default, no recusion must be set +#define CT_DOTDIRS "dotdirs=true" // exclude dotdirs is default, include dotdirs must be set -/// Denied users -#define INCRON_DENY_PATH "/etc/incron.deny" -*/ /* * ALLOW/DENY SEMANTICS @@ -51,7 +51,9 @@ IncronTabEntry::IncronTabEntry() : m_uMask(0), - m_fNoLoop(false) + m_fNoLoop(true), + m_fNoRecursion(false), + m_fDotDirs(false) { } @@ -71,15 +73,35 @@ std::string m; InotifyEvent::DumpTypes(m_uMask, m); - if (m.empty()) { - m = m_fNoLoop ? "IN_NO_LOOP" : "0"; - } - else { - if (m_fNoLoop) - m.append(",IN_NO_LOOP"); - } + // don't write IN_NO_LOOP anymore +// if (m.empty()) +// m = m_fNoLoop ? IN_NO_LOOP_OLD : m; +// else +// if (m_fNoLoop) m.append(std::string(","+IN_NO_LOOP_OLD); + + // add CT_NORECURSION artificially + if (m.empty()) + m = m_fNoRecursion ? CT_NORECURSION : m; + else + if (m_fNoRecursion) m.append(std::string(",")+CT_NORECURSION); + + // add CT_LOOPABLE artificially + if (m.empty()) + m = !m_fNoLoop ? CT_LOOPABLE : m; + else + if (!m_fNoLoop) m.append(std::string(",")+CT_LOOPABLE); + + // add CT_DOTDIRS artificially + if (m.empty()) + m = m_fDotDirs ? CT_DOTDIRS : m; + else + if (m_fDotDirs) m.append(std::string(",")+CT_DOTDIRS); + + // fill a default value for broken lines + if (m.empty()) + m = "IN_ALL_EVENTS"; - ss << GetSafePath(m_path) << " " << m << " " << m_cmd; + ss << GetSafePath(m_path) << "\t" << m << "\t" << m_cmd; return ss.str(); } @@ -88,7 +110,7 @@ unsigned long u; std::string s1, s2, s3; - StringTokenizer tok(rStr, ' ', '\\'); + StringTokenizer tok(rStr, " \t", '\\'); if (!tok.HasMoreTokens()) return false; @@ -109,17 +131,25 @@ rEntry.m_path = s1; rEntry.m_cmd = s3; rEntry.m_uMask = 0; - rEntry.m_fNoLoop = false; + rEntry.m_fNoLoop = true; + rEntry.m_fNoRecursion = false; + rEntry.m_fDotDirs = false; if (sscanf(s2.c_str(), "%lu", &u) == 1) { rEntry.m_uMask = (uint32_t) u; } else { - StringTokenizer tok(s2); - while (tok.HasMoreTokens()) { - std::string s(tok.GetNextToken()); - if (s == "IN_NO_LOOP") + StringTokenizer tok2(s2); + while (tok2.HasMoreTokens()) { + std::string s(tok2.GetNextToken()); + if (s == IN_NO_LOOP_OLD) rEntry.m_fNoLoop = true; + else if (s == CT_LOOPABLE) + rEntry.m_fNoLoop = false; + else if (s == CT_NORECURSION) + rEntry.m_fNoRecursion = true; + else if (s == CT_DOTDIRS) + rEntry.m_fDotDirs = true; else rEntry.m_uMask |= InotifyEvent::GetMaskByName(s); } diff -Nru incron-0.5.10/incrontab.h incron-0.5.12/incrontab.h --- incron-0.5.10/incrontab.h 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/incrontab.h 2019-02-18 12:34:17.000000000 +0000 @@ -6,6 +6,7 @@ * inotify cron system * * Copyright (C) 2006, 2007, 2008 Lukas Jelinek, + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can use it, redistribute * it and/or modify it under the terms of the GNU General Public @@ -22,14 +23,6 @@ #include "strtok.h" -/* -/// Incron user table base directory -#define INCRON_USER_TABLE_BASE "/var/spool/incron/" - -/// Incron system table base directory -#define INCRON_SYS_TABLE_BASE "/etc/incron.d/" -*/ - /// Incron table entry class. class IncronTabEntry { @@ -107,6 +100,24 @@ return m_fNoLoop; } + /// Checks whether this entry has set recursion-avoidance. + /** + * \return true = no recursion, false = recursion allowed + */ + inline bool IsNoRecursion() const + { + return m_fNoRecursion; + } + + /// Checks whether this entry has set dotdir-avoidance. true = dotdirs are included; false = dotdirs are excluded + /** + * \return true = no recursion, false = recursion allowed + */ + inline bool IsDotDirs() const + { + return m_fDotDirs; + } + /// Add backslashes before spaces in the source path. /** * It also adds backslashes before all original backslashes @@ -127,6 +138,8 @@ uint32_t m_uMask; ///< event mask std::string m_cmd; ///< command string bool m_fNoLoop; ///< no loop yes/no + bool m_fNoRecursion;///< no recursion yes/no + bool m_fDotDirs; ///< dotdir included yes/no }; diff -Nru incron-0.5.10/inotify-cxx.cpp incron-0.5.12/inotify-cxx.cpp --- incron-0.5.10/inotify-cxx.cpp 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/inotify-cxx.cpp 2019-02-18 12:34:17.000000000 +0000 @@ -27,8 +27,10 @@ #include #include #include +//#include // TODO remove #include "inotify-cxx.h" +#pragma GCC diagnostic ignored "-Wpedantic" // inotify-cxx is not pedantic /// procfs inotify base path #define PROCFS_INOTIFY_BASE "/proc/sys/fs/inotify/" @@ -243,8 +245,9 @@ void InotifyWatch::SetEnabled(bool fEnabled) throw (InotifyException) { + //syslog(LOG_INFO, "(SetEnabled) NOW (%i)", fEnabled); IN_WRITE_BEGIN - + if (fEnabled == m_fEnabled) { IN_WRITE_END_NOTHROW return; @@ -272,6 +275,7 @@ m_fEnabled = fEnabled; IN_WRITE_END + //syslog(LOG_INFO, "(SetEnabled) END (%i)", fEnabled); } void InotifyWatch::__Disable() @@ -632,3 +636,4 @@ return path; } +#pragma GCC diagnostic warning "-Wpedantic" diff -Nru incron-0.5.10/inotify-cxx.h incron-0.5.12/inotify-cxx.h --- incron-0.5.10/inotify-cxx.h 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/inotify-cxx.h 2019-02-18 12:34:17.000000000 +0000 @@ -36,7 +36,7 @@ #include // Use this if syscalls not defined -#ifndef __NR_inotify_init +#if not defined(__NR_inotify_init) && not defined(__NR_inotify_init1) #include #endif // __NR_inotify_init diff -Nru incron-0.5.10/Makefile incron-0.5.12/Makefile --- incron-0.5.10/Makefile 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/Makefile 2019-02-18 12:34:17.000000000 +0000 @@ -2,6 +2,7 @@ PREFIX = /usr/local USERDATADIR = /var/spool/incron SYSDATADIR = /etc/incron.d +INITDIR = /etc/init CFGDIR = /etc MANPATH = $(PREFIX)/share/man RELEASE = incron-`cat VERSION` @@ -13,9 +14,12 @@ CXX ?= g++ INSTALL = install -OPTIMIZE = -O2 +#OPTIMIZE = -O2 -pedantic -std=c++11 +OPTIMIZE = -O2 -pedantic -std=c++11 DEBUG = -g0 -WARNINGS = -Wall +#DEBUG = -g +WARNINGS = -Wall -W -Wshadow -Wpointer-arith -Wwrite-strings -ffor-scope +#WARNINGS = -Wall -W CXXAUX = -pipe CXXFLAGS ?= $(OPTIMIZE) $(DEBUG) $(CXXAUX) @@ -52,6 +56,7 @@ $(INSTALL) -m 0755 incrond $(DESTDIR)$(PREFIX)/sbin/ $(INSTALL) -m 0755 -o $(USER) -d $(DESTDIR)$(USERDATADIR) $(INSTALL) -m 0755 -o $(USER) -d $(DESTDIR)$(SYSDATADIR) + $(INSTALL) -m 0644 incron.conf $(DESTDIR)$(INITDIR) $(INSTALL) -m 0644 incron.conf.example $(DESTDIR)$(DOCDIR)/ install-man: incrontab.1 incrontab.5 incrond.8 incron.conf.5 diff -Nru incron-0.5.10/README incron-0.5.12/README --- incron-0.5.10/README 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/README 2019-02-18 12:34:17.000000000 +0000 @@ -1,27 +1,49 @@ - inotify cron system +=================== -(c) Lukas Jelinek, 2006, 2007, 2008, 2009, 2012 +(c) Andreas Altair Redmer, 2014, 2015 + Lukas Jelinek, 2006, 2007, 2008, 2009, 2012 +Content +======= 1. About -2. Requirements -3. How to use -4. Bugs, suggestions -5. Licensing -6. Documentation - - -======================================================================== - +2. Install a binary version +3. Obtain the source code +4. Requirements +5. How to build +6. How to use +7. Bugs, suggestions +8. Licensing 1. About +======== This program is the "inotify cron" system. It consist of a daemon and a table manipulator. You can use it a similar way as the regular cron. The difference is that the inotify cron handles filesystem events rather than time periods. +This project was kicked off by Lukas Jelinek in 2006 and then +unfortunatally abandoned in 2012. Upstream development and +bug-tracking/fixing continued in 2014 on GitHub: +https://github.com/ar-/incron . + +2. Install a binary version +=========================== +On Debian and Ubuntu based systems you can install this software with +sudo apt-get install incron + +On all other Linux based systems you have to build it from source. + +3. Obtain the source code +========================= +You can download the latest stable version from +https://github.com/ar-/incron/archive/master.tar.gz -2. Requirements +You can download older versions from +https://github.com/ar-/incron/releases + +4. Requirements +=============== * Linux kernel 2.6.13 or later (with inotify compiled in) * inotify headers (inotify.h, sometimes inotify-syscalls.h) installed in /sys. The most common place is /usr/include/sys. @@ -29,9 +51,15 @@ older versions too) -3. How to build -Because this version is very early it does not contain a standard -portable build mechanism. There is only a Makefile which must be +5. How to build +=============== +Short: + +make -j8 && sudo make install + +Long: +This software does not contain a standard +portable build mechanism. There is only a Makefile which may be modified manually. On many Linux systems you need not to change anything. @@ -53,7 +81,8 @@ created for generating the API documentation. -4. How to use +6. How to use +============= The incron daemon (incrond) must be run under root (typically from runlevel script etc.). It loads the current user tables and hooks them for later changes. @@ -81,10 +110,13 @@ $% - the event flags (textually) $& - the event flags (numerically) -The mask may additionaly contain a special symbol IN_NO_LOOP which +The mask may additionaly contain a special symbol loopable=true which disables events occurred during the event handling (to avoid loops). +It also may contain recursive=false to ignore sub-directories. +The mask can also be extended by dotdirs=true which will include +dotdirectories (hidden directories and hidden files) into the search. -Example 1: You need to run program 'abc' with the full file path as +**Example 1**: You need to run program 'abc' with the full file path as an argument every time a file is changed in /var/mail. One of the solutions follows: @@ -103,16 +135,43 @@ Some parameters of both incrontab and incrond can be changed by the configuration. See the example file for more information. +Example 3: You need to run program 'playmp3' with the full file path as +an argument every time a MP3 file is moved to in /home/u1/Music. One of +the solutions follows: + +/home/u1/Music/*.mp3 IN_MOVED_TO playmp3 $@/$# + +Example 4: You need to observe the directory /etc/ +recursively and report every change in the syslog. One of +the solutions follows: + +/etc/ IN_CLOSE_WRITE echo $@/$# | logger + +Example 5: You need to observe the directory /etc/apache +but exclude the sub-directories and report every change in the syslog. +One of the solutions follows: + +/etc/apache IN_CLOSE_WRITE,recursive=false echo $@/$# | logger + +Example 6: You need to observe the directory /home/user1 +recursively, including all the hidden sub-directories and hidden files +(dotfiles/dotdirectories) and report every change in the syslog. +One of the solutions follows: + +/home/user1 IN_CLOSE_WRITE,dotdirs=true echo $@/$# | logger + -5. Bugs, suggestions -THIS PROGRAM IS AN ALPHA VERSION. IT PROBABLY CONTAINS BUGS AND -THEREFORE IT IS NOT INTENDED FOR PRODUCTION USE. +7. Bugs, suggestions +==================== +incrond is currently not resistent against looping. If you find a bug or have a suggestion how to improve the program, -please use the bug tracking system at http://bts.aiken.cz. +please use the bug tracking system at +https://github.com/ar-/incron/issues. -6. Licensing +8. Licensing +============ This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License, version 2 (see LICENSE-GPL). diff -Nru incron-0.5.10/README.md incron-0.5.12/README.md --- incron-0.5.10/README.md 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/README.md 2019-02-18 12:34:17.000000000 +0000 @@ -0,0 +1,217 @@ +inotify cron system +=================== + +[![Build Status](https://travis-ci.org/ar-/incron.svg)](https://travis-ci.org/ar-/incron) + +(c) Andreas Altair Redmer, 2014, 2015 + Lukas Jelinek, 2006, 2007, 2008, 2009, 2012 + +Content +======= +1. About +2. Install a binary version +3. Obtain the source code +4. Requirements +5. How to build +6. How to use +7. Bugs, suggestions +8. Licensing + +1. About +======== +This program is the "inotify cron" system. It consist of a daemon and +a table manipulator. You can use it a similar way as the regular cron. +The difference is that the inotify cron handles filesystem events +rather than time periods. + +This project was kicked off by Lukas Jelinek in 2006 and then +unfortunatally abandoned in 2012. Upstream development and +bug-tracking/fixing continued in 2014 on GitHub: +https://github.com/ar-/incron . + +2. Install a binary version +=========================== +On Debian and Ubuntu based systems you can install this software +(the version maintained by Debian) with +sudo apt-get install incron + +There is a daily build running on Launchpad. You can install that +build from a PPA in Ubuntu, to have always an up-to-date build. + + + sudo add-apt-repository ppa:altair-ibn-la-ahad/incron + sudo apt-get update + sudo apt-get install incron + + +For more information follow the link to the PPA: +https://code.launchpad.net/~altair-ibn-la-ahad/+archive/ubuntu/incron + +The build logs are available here: +https://code.launchpad.net/~altair-ibn-la-ahad/+recipe/incron-daily + +On all other Linux based systems you have to build it from source. +If you would like to add a build script for other linux flavors +(Gentoo, Suse, Ret Hat, ...) please send me a pull request. I will +be happy to include it. + +3. Obtain the source code +========================= +You can download the latest stable version from +https://github.com/ar-/incron/archive/master.tar.gz + +You can download older versions from +https://github.com/ar-/incron/releases + +4. Requirements +=============== +* Linux kernel 2.6.13 or later (with inotify compiled in) +* inotify headers (inotify.h, sometimes inotify-syscalls.h) installed in + /sys. The most common place is /usr/include/sys. +* GCC 4.x compiler (probably works also with GCC 3.4, possibly with + older versions too) + + +5. How to build +=============== +Short: +------ + +` +make -j8 && sudo make install +` + +Long: +----- +This software does not contain a standard +portable build mechanism. There is only a Makefile which may be +modified manually. On many Linux systems you need not to change +anything. + +Please review the Makefile BEFORE you type 'make'. Especially +check the PREFIX and other common variables. If done you can +now build the files ('make'). + +The binaries must be of course installed as root. + +If you want to use (after editing) the example configuration +file simply rename it from /etc/incron.conf.example to +/etc/incron.conf (you can also use -f for one-time +use of a custom configuration file). + +Making a release of the source tree relies on the 'VERSION' file. +The file should contain only a simple version string such as '0.5.9' +or (if you wish) something more comlex (e.g. '0.5.9-improved'). +The doxygen program must be installed and its control file 'Doxygen' +created for generating the API documentation. + + +6. How to use +============= +The incron daemon (incrond) must be run under root (typically from +runlevel script etc.). It loads the current user tables and hooks +them for later changes. + +The incron table manipulator may be run under any regular user +since it SUIDs. For manipulation with the tables use basically +the same syntax as for the crontab program. You can import a table, +remove and edit the current table. + +The user table rows have the following syntax: + + +Where: + + is a filesystem path (currently avoid whitespaces!) + is a symbolic (see inotify.h; use commas for separating + symbols) or numeric mask for events + is an application or script to run on the events + +The command may contain these wildcards: + +* $$ - a dollar sign +* $@ - the watched filesystem path (see above) +* $# - the event-related file name +* $% - the event flags (textually) +* $& - the event flags (numerically) + +The mask may additionaly contain a special symbol loopable=true which +disables events occurred during the event handling (to avoid loops). +It also may contain recursive=false to ignore sub-directories. +The mask can also be extended by dotdirs=true which will include +dotdirectories (hidden directories and hidden files) into the search. + +**Example 1**: You need to run program 'abc' with the full file path as +an argument every time a file is changed in /var/mail. One of +the solutions follows: + +` +/var/mail IN_CLOSE_WRITE abc $@/$# +` + +**Example 2**: You need to run program 'efg' with the full file path as +the first argument and the numeric event flags as the second one. +It have to monitor all events on files in /tmp. Here is it: + +` +/tmp IN_ALL_EVENTS efg $@/$# $& +` + +Since 0.4.0 also system tables are supported. They are located in +/etc/incron.d and their commands use root privileges. System tables +are intended to be changed directly (without incrontab). + +Some parameters of both incrontab and incrond can be changed by +the configuration. See the example file for more information. + +**Example 3**: You need to run program 'playmp3' with the full file path as +an argument every time a MP3 file is moved to in /home/u1/Music. One of +the solutions follows: + +` +/home/u1/Music/*.mp3 IN_MOVED_TO playmp3 $@/$# +` + +**Example 4**: You need to observe the directory /etc/ +recursively and report every change in the syslog. One of +the solutions follows: + +` +/etc/ IN_CLOSE_WRITE echo $@/$# | logger +` + +**Example 5**: You need to observe the directory /etc/apache +but exclude the sub-directories and report every change in the syslog. +One of the solutions follows: + +` +/etc/apache IN_CLOSE_WRITE,recursive=false echo $@/$# | logger +` + +**Example 6**: You need to observe the directory /home/user1 +recursively, including all the hidden sub-directories and hidden files +(dotfiles/dotdirectories) and report every change in the syslog. +One of the solutions follows: + +` +/home/user1 IN_CLOSE_WRITE,dotdirs=true echo $@/$# | logger +` + +7. Bugs, suggestions +==================== +incrond is currently not resistent against looping. + +If you find a bug or have a suggestion how to improve the program, +please use the bug tracking system at +https://github.com/ar-/incron/issues. + + +8. Licensing +============ +This program is free software; you can redistribute it and/or +modify it under the terms of the GNU General Public License, +version 2 (see LICENSE-GPL). + +Some parts may be also covered by other licenses. +Please look into the source files for detailed information. + diff -Nru incron-0.5.10/strtok.cpp incron-0.5.12/strtok.cpp --- incron-0.5.10/strtok.cpp 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/strtok.cpp 2019-02-18 12:34:17.000000000 +0000 @@ -6,6 +6,7 @@ * string tokenizer * * Copyright (C) 2006, 2007, 2008 Lukas Jelinek, + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can redistribute it and/or * modify it under the terms of one of the following licenses: @@ -24,7 +25,7 @@ #include "strtok.h" -StringTokenizer::StringTokenizer(const std::string& rStr, char cDelim, char cPrefix) +StringTokenizer::StringTokenizer(const std::string& rStr, const std::string& cDelim, char cPrefix) { m_str = rStr; m_cDelim = cDelim; @@ -99,10 +100,13 @@ { const char* s = m_str.c_str(); for (SIZE i=m_pos; i + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can redistribute it and/or * modify it under the terms of one of the following licenses: @@ -63,7 +64,7 @@ * \param[in] cPrefix character which is prepended if a * character must not separate tokens */ - StringTokenizer(const std::string& rStr, char cDelim = ',', char cPrefix = '\0'); + StringTokenizer(const std::string& rStr, const std::string& cDelim = ",", char cPrefix = '\0'); /// Destructor. ~StringTokenizer() {} @@ -125,7 +126,7 @@ * * \param[in] cDelim delimiter character */ - inline void SetDelimiter(char cDelim) + inline void SetDelimiter(std::string cDelim) { m_cDelim = cDelim; } @@ -134,7 +135,7 @@ /** * \return delimiter character */ - inline char GetDelimiter() const + inline std::string GetDelimiter() const { return m_cDelim; } @@ -184,7 +185,7 @@ private: std::string m_str; ///< tokenized string - char m_cDelim; ///< delimiter character + std::string m_cDelim; ///< delimiter character char m_cPrefix; ///< prefix character std::string::size_type m_pos; ///< current position std::string::size_type m_len; ///< string length diff -Nru incron-0.5.10/.travis.yml incron-0.5.12/.travis.yml --- incron-0.5.10/.travis.yml 1970-01-01 00:00:00.000000000 +0000 +++ incron-0.5.12/.travis.yml 2019-02-18 12:34:17.000000000 +0000 @@ -0,0 +1,24 @@ +language: cpp +compiler: + - gcc + - clang + +before_install: + # g++4.8.1 + - if [ "$CXX" == "g++" ]; then sudo add-apt-repository -y ppa:ubuntu-toolchain-r/test; fi + + # clang 3.4 + - if [ "$CXX" == "clang++" ]; then sudo add-apt-repository -y ppa:h-rayflood/llvm; fi + + - sudo apt-get update -qq + +install: + # g++4.8.1 + - if [ "$CXX" = "g++" ]; then sudo apt-get install -qq g++-4.8; fi + - if [ "$CXX" = "g++" ]; then export CXX="g++-4.8"; fi + + # clang 3.4 + - if [ "$CXX" == "clang++" ]; then sudo apt-get install --allow-unauthenticated -qq clang-3.4; fi + - if [ "$CXX" == "clang++" ]; then export CXX="clang++-3.4"; fi + +script: make diff -Nru incron-0.5.10/usertable.cpp incron-0.5.12/usertable.cpp --- incron-0.5.10/usertable.cpp 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/usertable.cpp 2019-02-18 12:34:17.000000000 +0000 @@ -6,6 +6,7 @@ * inotify cron system * * Copyright (C) 2006, 2007, 2008, 2012 Lukas Jelinek, + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can use it, redistribute * it and/or modify it under the terms of the GNU General Public @@ -29,10 +30,12 @@ #include #include #include +#include #include "usertable.h" #include "incroncfg.h" #include "incrontab.h" +#include "executor.h" #ifdef IN_DONT_FOLLOW #define DONT_FOLLOW(mask) InotifyEvent::IsType(mask, IN_DONT_FOLLOW) @@ -50,10 +53,12 @@ extern SUT_MAP g_ut; +#ifdef LOOPER void on_proc_done(InotifyWatch* pW) { pW->SetEnabled(true); } +#endif EventDispatcher::EventDispatcher(int iPipeFd, Inotify* pIn, InotifyWatch* pSys, InotifyWatch* pUser) @@ -177,6 +182,12 @@ g_fFinish = true; } else if (!e.GetName().empty()) { + //ignore all names that start with a dot + const std::string eventName = e.GetName(); + if (eventName[0] == '.') + continue; + + //start the actual process here SUT_MAP::iterator it = g_ut.find(IncronCfg::BuildPath(m_pSys->GetPath(), e.GetName())); if (it != g_ut.end()) { UserTable* pUt = (*it).second; @@ -257,8 +268,57 @@ : IncronTab::GetUserTablePath(m_user)); int cnt = m_tab.GetCount(); + + // add all subdirectories (recursively) as new tab entries with same events for (int i=0; i ssvec = Executor::getSubDirVec (rE.GetPath(),rE.IsDotDirs()); + if (rE.GetPath().find("*") != std::string::npos) + { + std::vector allfilesvec = Executor::getAllFilesByDescriptor (rE.GetPath(),rE.IsDotDirs()); + + // add to ssvec but without duplicates - in case user defined a dirctory with subdirectories via star descriptor + for (unsigned int j=0; jRegister(this); +} + +void UserTable::AddTabEntry(IncronTabEntry& rE) +{ + //syslog(LOG_INFO, "registering inotify for (%s)", rE.GetPath().c_str()); // TODO is this log spamming too much ? InotifyWatch* pW = new InotifyWatch(rE.GetPath(), rE.GetMask()); // warning only - permissions may change later @@ -274,12 +334,10 @@ else syslog(LOG_ERR, "cannot create watch for user %s: (%i) %s", m_user.c_str(), e.GetErrorNumber(), strerror(e.GetErrorNumber())); delete pW; - } - } - - m_pEd->Register(this); + } } + void UserTable::Dispose() { m_pEd->Unregister(this); @@ -320,6 +378,34 @@ // discard event if user has no access rights to watch path if (!(m_fSysTable || MayAccess(pW->GetPath(), DONT_FOLLOW(rEvt.GetMask())))) return; + + //#if 0 + // log output for each dir + file + event + std::string events; + rEvt.DumpTypes(events); + syslog(LOG_INFO, "PATH (%s) FILE (%s) EVENT (%s)", pW->GetPath().c_str() , IncronTabEntry::GetSafePath(rEvt.GetName()).c_str() , events.c_str()); + //#endif + + // add new watch for newly created subdirs + if ( rEvt.IsType(IN_ISDIR) && (rEvt.IsType(IN_CREATE) || rEvt.IsType(IN_MOVED_TO)) ) + { + Dispose(); + sleep (1); + Load(); + // this is the fast way of registering new subsirs, but it + // misses new sub-sub dirs if they are created too fast in a row + // eg by : mkdir -p /tmp/a/b/c/d/e + // so the reload is for now the better way to go + // the complete reload also happens if the incrontab file changes + /* + m_pEd->Unregister(this); + std::string * pECmd = new std::string(pE->GetCmd().c_str()); + IncronTabEntry * newEntry = new IncronTabEntry(completeFile, pE->GetMask(), *pECmd); + m_tab.Add(*newEntry); + AddTabEntry(*newEntry); + m_pEd->Register(this); + */ + } std::string cmd; const std::string& cs = pE->GetCmd(); @@ -336,7 +422,7 @@ else { cmd.append(cs.substr(oldpos, pos-oldpos)); if (cs[px] == '@') { // base path - cmd.append(pW->GetPath()); + cmd.append(IncronTabEntry::GetSafePath(pW->GetPath())); oldpos = pos + 2; } else if (cs[px] == '#') { // file name @@ -351,7 +437,9 @@ } else if (cs[px] == '&') { // numeric mask char* s; +#pragma GCC diagnostic ignored "-Wunused-result" asprintf(&s, "%u", (unsigned) rEvt.GetMask()); +#pragma GCC diagnostic warning "-Wunused-result" cmd.append(s); free(s); oldpos = pos + 2; @@ -368,27 +456,22 @@ } cmd.append(cs.substr(oldpos)); - int argc; - char** argv; - if (!PrepareArgs(cmd, argc, argv)) { - syslog(LOG_ERR, "cannot prepare command arguments"); - return; - } - if (m_fSysTable) syslog(LOG_INFO, "(system::%s) CMD (%s)", m_user.c_str(), cmd.c_str()); else syslog(LOG_INFO, "(%s) CMD (%s)", m_user.c_str(), cmd.c_str()); - + +#ifdef LOOPER if (pE->IsNoLoop()) pW->SetEnabled(false); +#endif pid_t pid = fork(); if (pid == 0) { // for system table if (m_fSysTable) { - if (execvp(argv[0], argv) != 0) // exec failed + if (system(cmd.c_str()) != 0) // exec failed { syslog(LOG_ERR, "cannot exec process: %s", strerror(errno)); _exit(1); @@ -396,10 +479,15 @@ } else { // for user table - RunAsUser(argv); + RunAsUser(cmd); +#ifdef LOOPER + if (pE->IsNoLoop()) + pW->SetEnabled(true); +#endif } } else if (pid > 0) { +#ifdef LOOPER ProcData_t pd; if (pE->IsNoLoop()) { pd.onDone = on_proc_done; @@ -411,15 +499,17 @@ } s_procMap.insert(PROC_MAP::value_type(pid, pd)); +#endif } else { +#ifdef LOOPER if (pE->IsNoLoop()) pW->SetEnabled(true); +#endif syslog(LOG_ERR, "cannot fork process: %s", strerror(errno)); } - CleanupArgs(argc, argv); } IncronTabEntry* UserTable::FindEntry(InotifyWatch* pWatch) @@ -431,58 +521,6 @@ return (*it).second; } -bool UserTable::PrepareArgs(const std::string& rCmd, int& argc, char**& argv) -{ - if (rCmd.empty()) - return false; - - StringTokenizer tok(rCmd, ' ', '\\'); - std::deque args; - while (tok.HasMoreTokens()) { - args.push_back(tok.GetNextToken()); - } - - if (args.empty()) - return false; - - argc = (int) args.size(); - argv = new char*[argc+1]; - argv[argc] = NULL; - - for (int i=0; i 0) { - PROC_MAP::iterator it = s_procMap.find(res); - if (it != s_procMap.end()) { - ProcData_t pd = (*it).second; - if (pd.onDone != NULL) - (*pd.onDone)(pd.pWatch); - s_procMap.erase(it); - } - } -} - bool UserTable::MayAccess(const std::string& rPath, bool fNoFollow) const { // first, retrieve file permissions @@ -533,7 +571,7 @@ return false; // no access right found } -void UserTable::RunAsUser(char* const* argv) const +void UserTable::RunAsUser(std::string cmd) const { struct passwd* pwd = getpwnam(m_user.c_str()); if ( pwd == NULL // check query result @@ -558,8 +596,8 @@ goto failed; } } - - execvp(argv[0], argv); // this may return only on failure + + execlp("/bin/bash","/bin/bash", "-c", cmd.c_str(), (char *)NULL); failed: diff -Nru incron-0.5.10/usertable.h incron-0.5.12/usertable.h --- incron-0.5.10/usertable.h 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/usertable.h 2019-02-18 12:34:17.000000000 +0000 @@ -6,6 +6,7 @@ * inotify cron system * * Copyright (C) 2006, 2007, 2008 Lukas Jelinek, + * Copyright (C) 2014, 2015 Andreas Altair Redmer, * * This program is free software; you can use it, redistribute * it and/or modify it under the terms of the GNU General Public @@ -158,6 +159,8 @@ */ void Load(); + void AddTabEntry(IncronTabEntry& rE); + /// Removes all entries from the table. /** * All entries are unregistered from the event dispatcher and @@ -170,14 +173,7 @@ * \param[in] rEvt inotify event */ void OnEvent(InotifyEvent& rEvt); - - /// Cleans-up all zombie child processes and enables disabled watches. - /** - * \attention This method must be called AFTER processing all events - * which has been caused by the processes. - */ - static void FinishDone(); - + /// Checks whether the user may access a file. /** * Any access right (RWX) is sufficient. @@ -227,7 +223,7 @@ /** * \attention Don't call from the main process (before forking)! */ - void RunAsUser(char* const* argv) const; + void RunAsUser(std::string cmd) const; private: Inotify m_in; ///< inotify object @@ -245,23 +241,7 @@ * \return pointer to the appropriate entry; NULL if no such entry exists */ IncronTabEntry* FindEntry(InotifyWatch* pWatch); - - /// Prepares arguments for creating a child process. - /** - * \param[in] rCmd command string - * \param[out] argc argument count - * \param[out] argv argument array - * \return true = success, false = failure - */ - bool PrepareArgs(const std::string& rCmd, int& argc, char**& argv); - - /// Frees memory allocated for arguments. - /** - * \param[in] argc argument count - * \param[in] argv argument array - */ - void CleanupArgs(int argc, char** argv); - + }; #endif //_USERTABLE_H_ diff -Nru incron-0.5.10/VERSION incron-0.5.12/VERSION --- incron-0.5.10/VERSION 2012-04-06 22:19:27.000000000 +0000 +++ incron-0.5.12/VERSION 2019-02-18 12:34:17.000000000 +0000 @@ -1 +1 @@ -0.5.10 \ No newline at end of file +0.5.12