diff --git a/Makefile b/Makefile new file mode 100644 index 0000000..48741f1 --- /dev/null +++ b/Makefile @@ -0,0 +1,14 @@ + +all: + +clean: + rm -rf docs + rm -rf log + find . -type f -name "*.pyc" -exec rm -f {} \; + +docs: + epydoc --html -o docs ./lib + +docs-pdf: + epydoc --pdf -o docs ./lib + diff --git a/docs/api-objects.txt b/docs/api-objects.txt new file mode 100644 index 0000000..1b012fb --- /dev/null +++ b/docs/api-objects.txt @@ -0,0 +1,115 @@ +lib lib-module.html +lib.__package__ lib-module.html#__package__ +lib.config lib.config-module.html +lib.config.__package__ lib.config-module.html#__package__ +lib.config.config lib.config.config-module.html +lib.config.config.parsePeriodList lib.config.periods-module.html#parsePeriodList +lib.config.config.serviceList lib.config.services-module.html#serviceList +lib.config.config.parseMemberList lib.config.members-module.html#parseMemberList +lib.config.config.parseHostList lib.config.hosts-module.html#parseHostList +lib.config.config.__package__ lib.config.config-module.html#__package__ +lib.config.config.parseFilterList lib.config.filters-module.html#parseFilterList +lib.config.config.parseHostGroupList lib.config.hostgroups-module.html#parseHostGroupList +lib.config.filters lib.config.filters-module.html +lib.config.filters.parseFilterList lib.config.filters-module.html#parseFilterList +lib.config.filters.__package__ lib.config.filters-module.html#__package__ +lib.config.hostgroups lib.config.hostgroups-module.html +lib.config.hostgroups.parseHostGroupList lib.config.hostgroups-module.html#parseHostGroupList +lib.config.hostgroups.__package__ lib.config.hostgroups-module.html#__package__ +lib.config.hosts lib.config.hosts-module.html +lib.config.hosts.parseHostList lib.config.hosts-module.html#parseHostList +lib.config.hosts.__package__ lib.config.hosts-module.html#__package__ +lib.config.layouts lib.config.layouts-module.html +lib.config.members lib.config.members-module.html +lib.config.members.parseMemberList lib.config.members-module.html#parseMemberList +lib.config.members.__package__ lib.config.members-module.html#__package__ +lib.config.periods lib.config.periods-module.html +lib.config.periods.parsePeriodList lib.config.periods-module.html#parsePeriodList +lib.config.periods.__package__ lib.config.periods-module.html#__package__ +lib.config.services lib.config.services-module.html +lib.config.services.serviceList lib.config.services-module.html#serviceList +lib.config.services.__package__ lib.config.services-module.html#__package__ +lib.core lib.core-module.html +lib.core.__package__ lib.core-module.html#__package__ +lib.core.command lib.core.command-module.html +lib.core.command.__package__ lib.core.command-module.html#__package__ +lib.core.daemon lib.core.daemon-module.html +lib.core.daemon.__package__ lib.core.daemon-module.html#__package__ +lib.core.job lib.core.job-module.html +lib.core.job.__package__ lib.core.job-module.html#__package__ +lib.core.linspector_daemon lib.core.linspector_daemon-module.html +lib.core.linspector_daemon.__package__ lib.core.linspector_daemon-module.html#__package__ +lib.core.logger lib.core.logger-module.html +lib.core.logger.__package__ lib.core.logger-module.html#__package__ +lib.config.config.Config lib.config.config.Config-class.html +lib.config.config.Config.__init__ lib.config.config.Config-class.html#__init__ +lib.config.filters.Filter lib.config.filters.Filter-class.html +lib.config.filters.Filter.clone lib.config.filters.Filter-class.html#clone +lib.config.filters.Filter.__str__ lib.config.filters.Filter-class.html#__str__ +lib.config.filters.Filter.__init__ lib.config.filters.Filter-class.html#__init__ +lib.config.hostgroups.HostGroup lib.config.hostgroups.HostGroup-class.html +lib.config.hostgroups.HostGroup.__str__ lib.config.hostgroups.HostGroup-class.html#__str__ +lib.config.hostgroups.HostGroup.__init__ lib.config.hostgroups.HostGroup-class.html#__init__ +lib.config.hostgroups.HostGroupService lib.config.hostgroups.HostGroupService-class.html +lib.config.hostgroups.HostGroupService.__str__ lib.config.hostgroups.HostGroupService-class.html#__str__ +lib.config.hostgroups.HostGroupService.__init__ lib.config.hostgroups.HostGroupService-class.html#__init__ +lib.config.hosts.Host lib.config.hosts.Host-class.html +lib.config.hosts.Host.__str__ lib.config.hosts.Host-class.html#__str__ +lib.config.hosts.Host.__init__ lib.config.hosts.Host-class.html#__init__ +lib.config.hosts.HostService lib.config.hosts.HostService-class.html +lib.config.hosts.HostService.setCommand lib.config.hosts.HostService-class.html#setCommand +lib.config.hosts.HostService.__str__ lib.config.hosts.HostService-class.html#__str__ +lib.config.hosts.HostService.getCommand lib.config.hosts.HostService-class.html#getCommand +lib.config.hosts.HostService.__init__ lib.config.hosts.HostService-class.html#__init__ +lib.config.layouts.Layout lib.config.layouts.Layout-class.html +lib.config.layouts.Layout.__str__ lib.config.layouts.Layout-class.html#__str__ +lib.config.layouts.Layout.__init__ lib.config.layouts.Layout-class.html#__init__ +lib.config.layouts.LayoutList lib.config.layouts.LayoutList-class.html +lib.config.layouts.LayoutList.__str__ lib.config.layouts.LayoutList-class.html#__str__ +lib.config.layouts.LayoutList.__init__ lib.config.layouts.LayoutList-class.html#__init__ +lib.config.members.Member lib.config.members.Member-class.html +lib.config.members.Member.__str__ lib.config.members.Member-class.html#__str__ +lib.config.members.Member.__init__ lib.config.members.Member-class.html#__init__ +lib.config.members.MemberFilter lib.config.members.MemberFilter-class.html +lib.config.members.MemberFilter.__str__ lib.config.members.MemberFilter-class.html#__str__ +lib.config.members.MemberFilter.__init__ lib.config.members.MemberFilter-class.html#__init__ +lib.config.periods.Period lib.config.periods.Period-class.html +lib.config.periods.Period.__str__ lib.config.periods.Period-class.html#__str__ +lib.config.periods.Period.__init__ lib.config.periods.Period-class.html#__init__ +lib.config.services.Service lib.config.services.Service-class.html +lib.config.services.Service.clone lib.config.services.Service-class.html#clone +lib.config.services.Service.__str__ lib.config.services.Service-class.html#__str__ +lib.config.services.Service.__init__ lib.config.services.Service-class.html#__init__ +lib.core.command.Command lib.core.command.Command-class.html +lib.core.command.Command.getError lib.core.command.Command-class.html#getError +lib.core.command.Command.__str__ lib.core.command.Command-class.html#__str__ +lib.core.command.Command.getOutput lib.core.command.Command-class.html#getOutput +lib.core.command.Command.hasProcessed lib.core.command.Command-class.html#hasProcessed +lib.core.command.Command.doProcess lib.core.command.Command-class.html#doProcess +lib.core.command.Command.__init__ lib.core.command.Command-class.html#__init__ +lib.core.daemon.Daemon lib.core.daemon.Daemon-class.html +lib.core.daemon.Daemon.delpid lib.core.daemon.Daemon-class.html#delpid +lib.core.daemon.Daemon.run lib.core.daemon.Daemon-class.html#run +lib.core.daemon.Daemon.stop lib.core.daemon.Daemon-class.html#stop +lib.core.daemon.Daemon.start lib.core.daemon.Daemon-class.html#start +lib.core.daemon.Daemon.daemonize lib.core.daemon.Daemon-class.html#daemonize +lib.core.daemon.Daemon.__init__ lib.core.daemon.Daemon-class.html#__init__ +lib.core.daemon.Daemon.restart lib.core.daemon.Daemon-class.html#restart +lib.core.job.Job lib.core.job.Job-class.html +lib.core.job.Job.__init__ lib.core.job.Job-class.html#__init__ +lib.core.linspector_daemon.LinspectorDaemon lib.core.linspector_daemon.LinspectorDaemon-class.html +lib.core.daemon.Daemon.delpid lib.core.daemon.Daemon-class.html#delpid +lib.core.linspector_daemon.LinspectorDaemon.run lib.core.linspector_daemon.LinspectorDaemon-class.html#run +lib.core.daemon.Daemon.stop lib.core.daemon.Daemon-class.html#stop +lib.core.daemon.Daemon.start lib.core.daemon.Daemon-class.html#start +lib.core.daemon.Daemon.daemonize lib.core.daemon.Daemon-class.html#daemonize +lib.core.daemon.Daemon.restart lib.core.daemon.Daemon-class.html#restart +lib.core.daemon.Daemon.__init__ lib.core.daemon.Daemon-class.html#__init__ +lib.core.logger.Logger lib.core.logger.Logger-class.html +lib.core.logger.Logger.c lib.core.logger.Logger-class.html#c +lib.core.logger.Logger.e lib.core.logger.Logger-class.html#e +lib.core.logger.Logger.d lib.core.logger.Logger-class.html#d +lib.core.logger.Logger.i lib.core.logger.Logger-class.html#i +lib.core.logger.Logger.w lib.core.logger.Logger-class.html#w +lib.core.logger.Logger.close lib.core.logger.Logger-class.html#close +lib.core.logger.Logger.__init__ lib.core.logger.Logger-class.html#__init__ diff --git a/docs/class-tree.html b/docs/class-tree.html new file mode 100644 index 0000000..072a723 --- /dev/null +++ b/docs/class-tree.html @@ -0,0 +1,143 @@ + + + + + Class Hierarchy + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
  + + + + +
[hide private]
[frames] | no frames]
+
+
+ [ Module Hierarchy + | Class Hierarchy ] +

+

Class Hierarchy

+ + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/crarr.png b/docs/crarr.png new file mode 100644 index 0000000..26b43c5 Binary files /dev/null and b/docs/crarr.png differ diff --git a/docs/epydoc.css b/docs/epydoc.css new file mode 100644 index 0000000..86d4170 --- /dev/null +++ b/docs/epydoc.css @@ -0,0 +1,322 @@ + + +/* Epydoc CSS Stylesheet + * + * This stylesheet can be used to customize the appearance of epydoc's + * HTML output. + * + */ + +/* Default Colors & Styles + * - Set the default foreground & background color with 'body'; and + * link colors with 'a:link' and 'a:visited'. + * - Use bold for decision list terms. + * - The heading styles defined here are used for headings *within* + * docstring descriptions. All headings used by epydoc itself use + * either class='epydoc' or class='toc' (CSS styles for both + * defined below). + */ +body { background: #ffffff; color: #000000; } +p { margin-top: 0.5em; margin-bottom: 0.5em; } +a:link { color: #0000ff; } +a:visited { color: #204080; } +dt { font-weight: bold; } +h1 { font-size: +140%; font-style: italic; + font-weight: bold; } +h2 { font-size: +125%; font-style: italic; + font-weight: bold; } +h3 { font-size: +110%; font-style: italic; + font-weight: normal; } +code { font-size: 100%; } +/* N.B.: class, not pseudoclass */ +a.link { font-family: monospace; } + +/* Page Header & Footer + * - The standard page header consists of a navigation bar (with + * pointers to standard pages such as 'home' and 'trees'); a + * breadcrumbs list, which can be used to navigate to containing + * classes or modules; options links, to show/hide private + * variables and to show/hide frames; and a page title (using + *

). The page title may be followed by a link to the + * corresponding source code (using 'span.codelink'). + * - The footer consists of a navigation bar, a timestamp, and a + * pointer to epydoc's homepage. + */ +h1.epydoc { margin: 0; font-size: +140%; font-weight: bold; } +h2.epydoc { font-size: +130%; font-weight: bold; } +h3.epydoc { font-size: +115%; font-weight: bold; + margin-top: 0.2em; } +td h3.epydoc { font-size: +115%; font-weight: bold; + margin-bottom: 0; } +table.navbar { background: #a0c0ff; color: #000000; + border: 2px groove #c0d0d0; } +table.navbar table { color: #000000; } +th.navbar-select { background: #70b0ff; + color: #000000; } +table.navbar a { text-decoration: none; } +table.navbar a:link { color: #0000ff; } +table.navbar a:visited { color: #204080; } +span.breadcrumbs { font-size: 85%; font-weight: bold; } +span.options { font-size: 70%; } +span.codelink { font-size: 85%; } +td.footer { font-size: 85%; } + +/* Table Headers + * - Each summary table and details section begins with a 'header' + * row. This row contains a section title (marked by + * 'span.table-header') as well as a show/hide private link + * (marked by 'span.options', defined above). + * - Summary tables that contain user-defined groups mark those + * groups using 'group header' rows. + */ +td.table-header { background: #70b0ff; color: #000000; + border: 1px solid #608090; } +td.table-header table { color: #000000; } +td.table-header table a:link { color: #0000ff; } +td.table-header table a:visited { color: #204080; } +span.table-header { font-size: 120%; font-weight: bold; } +th.group-header { background: #c0e0f8; color: #000000; + text-align: left; font-style: italic; + font-size: 115%; + border: 1px solid #608090; } + +/* Summary Tables (functions, variables, etc) + * - Each object is described by a single row of the table with + * two cells. The left cell gives the object's type, and is + * marked with 'code.summary-type'. The right cell gives the + * object's name and a summary description. + * - CSS styles for the table's header and group headers are + * defined above, under 'Table Headers' + */ +table.summary { border-collapse: collapse; + background: #e8f0f8; color: #000000; + border: 1px solid #608090; + margin-bottom: 0.5em; } +td.summary { border: 1px solid #608090; } +code.summary-type { font-size: 85%; } +table.summary a:link { color: #0000ff; } +table.summary a:visited { color: #204080; } + + +/* Details Tables (functions, variables, etc) + * - Each object is described in its own div. + * - A single-row summary table w/ table-header is used as + * a header for each details section (CSS style for table-header + * is defined above, under 'Table Headers'). + */ +table.details { border-collapse: collapse; + background: #e8f0f8; color: #000000; + border: 1px solid #608090; + margin: .2em 0 0 0; } +table.details table { color: #000000; } +table.details a:link { color: #0000ff; } +table.details a:visited { color: #204080; } + +/* Fields */ +dl.fields { margin-left: 2em; margin-top: 1em; + margin-bottom: 1em; } +dl.fields dd ul { margin-left: 0em; padding-left: 0em; } +dl.fields dd ul li ul { margin-left: 2em; padding-left: 0em; } +div.fields { margin-left: 2em; } +div.fields p { margin-bottom: 0.5em; } + +/* Index tables (identifier index, term index, etc) + * - link-index is used for indices containing lists of links + * (namely, the identifier index & term index). + * - index-where is used in link indices for the text indicating + * the container/source for each link. + * - metadata-index is used for indices containing metadata + * extracted from fields (namely, the bug index & todo index). + */ +table.link-index { border-collapse: collapse; + background: #e8f0f8; color: #000000; + border: 1px solid #608090; } +td.link-index { border-width: 0px; } +table.link-index a:link { color: #0000ff; } +table.link-index a:visited { color: #204080; } +span.index-where { font-size: 70%; } +table.metadata-index { border-collapse: collapse; + background: #e8f0f8; color: #000000; + border: 1px solid #608090; + margin: .2em 0 0 0; } +td.metadata-index { border-width: 1px; border-style: solid; } +table.metadata-index a:link { color: #0000ff; } +table.metadata-index a:visited { color: #204080; } + +/* Function signatures + * - sig* is used for the signature in the details section. + * - .summary-sig* is used for the signature in the summary + * table, and when listing property accessor functions. + * */ +.sig-name { color: #006080; } +.sig-arg { color: #008060; } +.sig-default { color: #602000; } +.summary-sig { font-family: monospace; } +.summary-sig-name { color: #006080; font-weight: bold; } +table.summary a.summary-sig-name:link + { color: #006080; font-weight: bold; } +table.summary a.summary-sig-name:visited + { color: #006080; font-weight: bold; } +.summary-sig-arg { color: #006040; } +.summary-sig-default { color: #501800; } + +/* Subclass list + */ +ul.subclass-list { display: inline; } +ul.subclass-list li { display: inline; } + +/* To render variables, classes etc. like functions */ +table.summary .summary-name { color: #006080; font-weight: bold; + font-family: monospace; } +table.summary + a.summary-name:link { color: #006080; font-weight: bold; + font-family: monospace; } +table.summary + a.summary-name:visited { color: #006080; font-weight: bold; + font-family: monospace; } + +/* Variable values + * - In the 'variable details' sections, each varaible's value is + * listed in a 'pre.variable' box. The width of this box is + * restricted to 80 chars; if the value's repr is longer than + * this it will be wrapped, using a backslash marked with + * class 'variable-linewrap'. If the value's repr is longer + * than 3 lines, the rest will be ellided; and an ellipsis + * marker ('...' marked with 'variable-ellipsis') will be used. + * - If the value is a string, its quote marks will be marked + * with 'variable-quote'. + * - If the variable is a regexp, it is syntax-highlighted using + * the re* CSS classes. + */ +pre.variable { padding: .5em; margin: 0; + background: #dce4ec; color: #000000; + border: 1px solid #708890; } +.variable-linewrap { color: #604000; font-weight: bold; } +.variable-ellipsis { color: #604000; font-weight: bold; } +.variable-quote { color: #604000; font-weight: bold; } +.variable-group { color: #008000; font-weight: bold; } +.variable-op { color: #604000; font-weight: bold; } +.variable-string { color: #006030; } +.variable-unknown { color: #a00000; font-weight: bold; } +.re { color: #000000; } +.re-char { color: #006030; } +.re-op { color: #600000; } +.re-group { color: #003060; } +.re-ref { color: #404040; } + +/* Base tree + * - Used by class pages to display the base class hierarchy. + */ +pre.base-tree { font-size: 80%; margin: 0; } + +/* Frames-based table of contents headers + * - Consists of two frames: one for selecting modules; and + * the other listing the contents of the selected module. + * - h1.toc is used for each frame's heading + * - h2.toc is used for subheadings within each frame. + */ +h1.toc { text-align: center; font-size: 105%; + margin: 0; font-weight: bold; + padding: 0; } +h2.toc { font-size: 100%; font-weight: bold; + margin: 0.5em 0 0 -0.3em; } + +/* Syntax Highlighting for Source Code + * - doctest examples are displayed in a 'pre.py-doctest' block. + * If the example is in a details table entry, then it will use + * the colors specified by the 'table pre.py-doctest' line. + * - Source code listings are displayed in a 'pre.py-src' block. + * Each line is marked with 'span.py-line' (used to draw a line + * down the left margin, separating the code from the line + * numbers). Line numbers are displayed with 'span.py-lineno'. + * The expand/collapse block toggle button is displayed with + * 'a.py-toggle' (Note: the CSS style for 'a.py-toggle' should not + * modify the font size of the text.) + * - If a source code page is opened with an anchor, then the + * corresponding code block will be highlighted. The code + * block's header is highlighted with 'py-highlight-hdr'; and + * the code block's body is highlighted with 'py-highlight'. + * - The remaining py-* classes are used to perform syntax + * highlighting (py-string for string literals, py-name for names, + * etc.) + */ +pre.py-doctest { padding: .5em; margin: 1em; + background: #e8f0f8; color: #000000; + border: 1px solid #708890; } +table pre.py-doctest { background: #dce4ec; + color: #000000; } +pre.py-src { border: 2px solid #000000; + background: #f0f0f0; color: #000000; } +.py-line { border-left: 2px solid #000000; + margin-left: .2em; padding-left: .4em; } +.py-lineno { font-style: italic; font-size: 90%; + padding-left: .5em; } +a.py-toggle { text-decoration: none; } +div.py-highlight-hdr { border-top: 2px solid #000000; + border-bottom: 2px solid #000000; + background: #d8e8e8; } +div.py-highlight { border-bottom: 2px solid #000000; + background: #d0e0e0; } +.py-prompt { color: #005050; font-weight: bold;} +.py-more { color: #005050; font-weight: bold;} +.py-string { color: #006030; } +.py-comment { color: #003060; } +.py-keyword { color: #600000; } +.py-output { color: #404040; } +.py-name { color: #000050; } +.py-name:link { color: #000050 !important; } +.py-name:visited { color: #000050 !important; } +.py-number { color: #005000; } +.py-defname { color: #000060; font-weight: bold; } +.py-def-name { color: #000060; font-weight: bold; } +.py-base-class { color: #000060; } +.py-param { color: #000060; } +.py-docstring { color: #006030; } +.py-decorator { color: #804020; } +/* Use this if you don't want links to names underlined: */ +/*a.py-name { text-decoration: none; }*/ + +/* Graphs & Diagrams + * - These CSS styles are used for graphs & diagrams generated using + * Graphviz dot. 'img.graph-without-title' is used for bare + * diagrams (to remove the border created by making the image + * clickable). + */ +img.graph-without-title { border: none; } +img.graph-with-title { border: 1px solid #000000; } +span.graph-title { font-weight: bold; } +span.graph-caption { } + +/* General-purpose classes + * - 'p.indent-wrapped-lines' defines a paragraph whose first line + * is not indented, but whose subsequent lines are. + * - The 'nomargin-top' class is used to remove the top margin (e.g. + * from lists). The 'nomargin' class is used to remove both the + * top and bottom margin (but not the left or right margin -- + * for lists, that would cause the bullets to disappear.) + */ +p.indent-wrapped-lines { padding: 0 0 0 7em; text-indent: -7em; + margin: 0; } +.nomargin-top { margin-top: 0; } +.nomargin { margin-top: 0; margin-bottom: 0; } + +/* HTML Log */ +div.log-block { padding: 0; margin: .5em 0 .5em 0; + background: #e8f0f8; color: #000000; + border: 1px solid #000000; } +div.log-error { padding: .1em .3em .1em .3em; margin: 4px; + background: #ffb0b0; color: #000000; + border: 1px solid #000000; } +div.log-warning { padding: .1em .3em .1em .3em; margin: 4px; + background: #ffffb0; color: #000000; + border: 1px solid #000000; } +div.log-info { padding: .1em .3em .1em .3em; margin: 4px; + background: #b0ffb0; color: #000000; + border: 1px solid #000000; } +h2.log-hdr { background: #70b0ff; color: #000000; + margin: 0; padding: 0em 0.5em 0em 0.5em; + border-bottom: 1px solid #000000; font-size: 110%; } +p.log { font-weight: bold; margin: .5em 0 .5em 0; } +tr.opt-changed { color: #000000; font-weight: bold; } +tr.opt-default { color: #606060; } +pre.log { margin: 0; padding: 0; padding-left: 1em; } diff --git a/docs/epydoc.js b/docs/epydoc.js new file mode 100644 index 0000000..e787dbc --- /dev/null +++ b/docs/epydoc.js @@ -0,0 +1,293 @@ +function toggle_private() { + // Search for any private/public links on this page. Store + // their old text in "cmd," so we will know what action to + // take; and change their text to the opposite action. + var cmd = "?"; + var elts = document.getElementsByTagName("a"); + for(var i=0; i...
"; + elt.innerHTML = s; + } +} + +function toggle(id) { + elt = document.getElementById(id+"-toggle"); + if (elt.innerHTML == "-") + collapse(id); + else + expand(id); + return false; +} + +function highlight(id) { + var elt = document.getElementById(id+"-def"); + if (elt) elt.className = "py-highlight-hdr"; + var elt = document.getElementById(id+"-expanded"); + if (elt) elt.className = "py-highlight"; + var elt = document.getElementById(id+"-collapsed"); + if (elt) elt.className = "py-highlight"; +} + +function num_lines(s) { + var n = 1; + var pos = s.indexOf("\n"); + while ( pos > 0) { + n += 1; + pos = s.indexOf("\n", pos+1); + } + return n; +} + +// Collapse all blocks that mave more than `min_lines` lines. +function collapse_all(min_lines) { + var elts = document.getElementsByTagName("div"); + for (var i=0; i 0) + if (elt.id.substring(split, elt.id.length) == "-expanded") + if (num_lines(elt.innerHTML) > min_lines) + collapse(elt.id.substring(0, split)); + } +} + +function expandto(href) { + var start = href.indexOf("#")+1; + if (start != 0 && start != href.length) { + if (href.substring(start, href.length) != "-") { + collapse_all(4); + pos = href.indexOf(".", start); + while (pos != -1) { + var id = href.substring(start, pos); + expand(id); + pos = href.indexOf(".", pos+1); + } + var id = href.substring(start, href.length); + expand(id); + highlight(id); + } + } +} + +function kill_doclink(id) { + var parent = document.getElementById(id); + parent.removeChild(parent.childNodes.item(0)); +} +function auto_kill_doclink(ev) { + if (!ev) var ev = window.event; + if (!this.contains(ev.toElement)) { + var parent = document.getElementById(this.parentID); + parent.removeChild(parent.childNodes.item(0)); + } +} + +function doclink(id, name, targets_id) { + var elt = document.getElementById(id); + + // If we already opened the box, then destroy it. + // (This case should never occur, but leave it in just in case.) + if (elt.childNodes.length > 1) { + elt.removeChild(elt.childNodes.item(0)); + } + else { + // The outer box: relative + inline positioning. + var box1 = document.createElement("div"); + box1.style.position = "relative"; + box1.style.display = "inline"; + box1.style.top = 0; + box1.style.left = 0; + + // A shadow for fun + var shadow = document.createElement("div"); + shadow.style.position = "absolute"; + shadow.style.left = "-1.3em"; + shadow.style.top = "-1.3em"; + shadow.style.background = "#404040"; + + // The inner box: absolute positioning. + var box2 = document.createElement("div"); + box2.style.position = "relative"; + box2.style.border = "1px solid #a0a0a0"; + box2.style.left = "-.2em"; + box2.style.top = "-.2em"; + box2.style.background = "white"; + box2.style.padding = ".3em .4em .3em .4em"; + box2.style.fontStyle = "normal"; + box2.onmouseout=auto_kill_doclink; + box2.parentID = id; + + // Get the targets + var targets_elt = document.getElementById(targets_id); + var targets = targets_elt.getAttribute("targets"); + var links = ""; + target_list = targets.split(","); + for (var i=0; i" + + target[0] + ""; + } + + // Put it all together. + elt.insertBefore(box1, elt.childNodes.item(0)); + //box1.appendChild(box2); + box1.appendChild(shadow); + shadow.appendChild(box2); + box2.innerHTML = + "Which "+name+" do you want to see documentation for?" + + ""; + } + return false; +} + +function get_anchor() { + var href = location.href; + var start = href.indexOf("#")+1; + if ((start != 0) && (start != href.length)) + return href.substring(start, href.length); + } +function redirect_url(dottedName) { + // Scan through each element of the "pages" list, and check + // if "name" matches with any of them. + for (var i=0; i-m" or "-c"; + // extract the portion & compare it to dottedName. + var pagename = pages[i].substring(0, pages[i].length-2); + if (pagename == dottedName.substring(0,pagename.length)) { + + // We've found a page that matches `dottedName`; + // construct its URL, using leftover `dottedName` + // content to form an anchor. + var pagetype = pages[i].charAt(pages[i].length-1); + var url = pagename + ((pagetype=="m")?"-module.html": + "-class.html"); + if (dottedName.length > pagename.length) + url += "#" + dottedName.substring(pagename.length+1, + dottedName.length); + return url; + } + } + } diff --git a/docs/frames.html b/docs/frames.html new file mode 100644 index 0000000..e3706f9 --- /dev/null +++ b/docs/frames.html @@ -0,0 +1,17 @@ + + + + + API Documentation + + + + + + + + + diff --git a/docs/help.html b/docs/help.html new file mode 100644 index 0000000..b6dac75 --- /dev/null +++ b/docs/help.html @@ -0,0 +1,268 @@ + + + + + Help + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
  + + + + +
[hide private]
[frames] | no frames]
+
+ +

API Documentation

+ +

This document contains the API (Application Programming Interface) +documentation for this project. Documentation for the Python +objects defined by the project is divided into separate pages for each +package, module, and class. The API documentation also includes two +pages containing information about the project as a whole: a trees +page, and an index page.

+ +

Object Documentation

+ +

Each Package Documentation page contains:

+
    +
  • A description of the package.
  • +
  • A list of the modules and sub-packages contained by the + package.
  • +
  • A summary of the classes defined by the package.
  • +
  • A summary of the functions defined by the package.
  • +
  • A summary of the variables defined by the package.
  • +
  • A detailed description of each function defined by the + package.
  • +
  • A detailed description of each variable defined by the + package.
  • +
+ +

Each Module Documentation page contains:

+
    +
  • A description of the module.
  • +
  • A summary of the classes defined by the module.
  • +
  • A summary of the functions defined by the module.
  • +
  • A summary of the variables defined by the module.
  • +
  • A detailed description of each function defined by the + module.
  • +
  • A detailed description of each variable defined by the + module.
  • +
+ +

Each Class Documentation page contains:

+
    +
  • A class inheritance diagram.
  • +
  • A list of known subclasses.
  • +
  • A description of the class.
  • +
  • A summary of the methods defined by the class.
  • +
  • A summary of the instance variables defined by the class.
  • +
  • A summary of the class (static) variables defined by the + class.
  • +
  • A detailed description of each method defined by the + class.
  • +
  • A detailed description of each instance variable defined by the + class.
  • +
  • A detailed description of each class (static) variable defined + by the class.
  • +
+ +

Project Documentation

+ +

The Trees page contains the module and class hierarchies:

+
    +
  • The module hierarchy lists every package and module, with + modules grouped into packages. At the top level, and within each + package, modules and sub-packages are listed alphabetically.
  • +
  • The class hierarchy lists every class, grouped by base + class. If a class has more than one base class, then it will be + listed under each base class. At the top level, and under each base + class, classes are listed alphabetically.
  • +
+ +

The Index page contains indices of terms and + identifiers:

+
    +
  • The term index lists every term indexed by any object's + documentation. For each term, the index provides links to each + place where the term is indexed.
  • +
  • The identifier index lists the (short) name of every package, + module, class, method, function, variable, and parameter. For each + identifier, the index provides a short description, and a link to + its documentation.
  • +
+ +

The Table of Contents

+ +

The table of contents occupies the two frames on the left side of +the window. The upper-left frame displays the project +contents, and the lower-left frame displays the module +contents:

+ + + + + + + + + +
+ Project
Contents
...
+ API
Documentation
Frame


+
+ Module
Contents
 
...
  +

+ +

The project contents frame contains a list of all packages +and modules that are defined by the project. Clicking on an entry +will display its contents in the module contents frame. Clicking on a +special entry, labeled "Everything," will display the contents of +the entire project.

+ +

The module contents frame contains a list of every +submodule, class, type, exception, function, and variable defined by a +module or package. Clicking on an entry will display its +documentation in the API documentation frame. Clicking on the name of +the module, at the top of the frame, will display the documentation +for the module itself.

+ +

The "frames" and "no frames" buttons below the top +navigation bar can be used to control whether the table of contents is +displayed or not.

+ +

The Navigation Bar

+ +

A navigation bar is located at the top and bottom of every page. +It indicates what type of page you are currently viewing, and allows +you to go to related pages. The following table describes the labels +on the navigation bar. Note that not some labels (such as +[Parent]) are not displayed on all pages.

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + +
LabelHighlighted when...Links to...
[Parent](never highlighted) the parent of the current package
[Package]viewing a packagethe package containing the current object +
[Module]viewing a modulethe module containing the current object +
[Class]viewing a class the class containing the current object
[Trees]viewing the trees page the trees page
[Index]viewing the index page the index page
[Help]viewing the help page the help page
+ +

The "show private" and "hide private" buttons below +the top navigation bar can be used to control whether documentation +for private objects is displayed. Private objects are usually defined +as objects whose (short) names begin with a single underscore, but do +not end with an underscore. For example, "_x", +"__pprint", and "epydoc.epytext._tokenize" +are private objects; but "re.sub", +"__init__", and "type_" are not. However, +if a module defines the "__all__" variable, then its +contents are used to decide which objects are private.

+ +

A timestamp below the bottom navigation bar indicates when each +page was last updated.

+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/identifier-index.html b/docs/identifier-index.html new file mode 100644 index 0000000..0d384f6 --- /dev/null +++ b/docs/identifier-index.html @@ -0,0 +1,518 @@ + + + + + Identifier Index + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
  + + + + +
[hide private]
[frames] | no frames]
+
+ +
+

Identifier Index

+
+[ + A + B + C + D + E + F + G + H + I + J + K + L + M + N + O + P + Q + R + S + T + U + V + W + X + Y + Z + _ +] +
+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +

C

+ + + + + + + + + + + + + + + + + + + + + + +

D

+ + + + + + + + + + + + +

E

+ + + + + + + + +

F

+ + + + + + + + +

G

+ + + + + + + + +

H

+ + + + + + + + + + + + + + + + + +

I

+ + + + + + + + +

J

+ + + + + + + + +

L

+ + + + + + + + + + + + + + + + + +

M

+ + + + + + + + +

P

+ + + + + + + + + + + + + + + + + +

R

+ + + + + + + + +

S

+ + + + + + + + + + + + +

W

+ + + + + + + + +

_

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+

+ + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/index.html b/docs/index.html new file mode 100644 index 0000000..e3706f9 --- /dev/null +++ b/docs/index.html @@ -0,0 +1,17 @@ + + + + + API Documentation + + + + + + + + + diff --git a/docs/lib-module.html b/docs/lib-module.html new file mode 100644 index 0000000..f2dfa3c --- /dev/null +++ b/docs/lib-module.html @@ -0,0 +1,173 @@ + + + + + lib + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Package lib

source code

+ + + + + + + +
+ + + + + +
Submodules[hide private]
+
+
+ +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = 'lib' +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib-pysrc.html b/docs/lib-pysrc.html new file mode 100644 index 0000000..c003079 --- /dev/null +++ b/docs/lib-pysrc.html @@ -0,0 +1,113 @@ + + + + + lib + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Package lib

+
+1  from config import * 
+2  from core import * 
+3   
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config-module.html b/docs/lib.config-module.html new file mode 100644 index 0000000..ea12c79 --- /dev/null +++ b/docs/lib.config-module.html @@ -0,0 +1,160 @@ + + + + + lib.config + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Package config

source code

+ + + + + + + +
+ + + + + +
Submodules[hide private]
+
+
+ +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = None +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config-pysrc.html b/docs/lib.config-pysrc.html new file mode 100644 index 0000000..211b62c --- /dev/null +++ b/docs/lib.config-pysrc.html @@ -0,0 +1,112 @@ + + + + + lib.config + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Package lib.config

+
+1   
+2   
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.config-module.html b/docs/lib.config.config-module.html new file mode 100644 index 0000000..b720c94 --- /dev/null +++ b/docs/lib.config.config-module.html @@ -0,0 +1,155 @@ + + + + + lib.config.config + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module config + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module config

source code

+ + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Config +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = 'lib.config' +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.config-pysrc.html b/docs/lib.config.config-pysrc.html new file mode 100644 index 0000000..899119a --- /dev/null +++ b/docs/lib.config.config-pysrc.html @@ -0,0 +1,151 @@ + + + + + lib.config.config + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module config + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.config.config

+
+ 1  import json 
+ 2  from services import serviceList 
+ 3  from filters import parseFilterList 
+ 4  from members import parseMemberList 
+ 5  from hosts import parseHostList 
+ 6  from periods import parsePeriodList 
+ 7  from hostgroups import parseHostGroupList 
+ 8  #from layouts import * 
+ 9   
+10   
+
11 -class Config: +
12 - def __init__(self, configFile, log): +
13 self.configfile = configFile +14 f = open(configFile) +15 self.config = f.read() +16 f.close() +17 +18 self.dict = json.loads(self.config) +19 +20 self.services = serviceList(self.dict['services']) +21 +22 self.filters = parseFilterList(self.dict['filters']) +23 +24 self.members = parseMemberList(self.dict['members'], self.filters, log) +25 +26 self.periods = parsePeriodList(self.dict['periods']) +27 +28 self.hosts = parseHostList(self.dict['hosts'], self.services, log) +29 +30 self.hostgroups = parseHostGroupList(self.dict['hostgroups'], +31 self.hosts, +32 self.members, +33 self.periods, +34 self.services, +35 log) +
36 +37 #self.layouts = LayoutList(self.dict['layouts'], self.hostgroups) +38 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.config.Config-class.html b/docs/lib.config.config.Config-class.html new file mode 100644 index 0000000..8eb8efe --- /dev/null +++ b/docs/lib.config.config.Config-class.html @@ -0,0 +1,142 @@ + + + + + lib.config.config.Config + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module config :: + Class Config + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Config

source code

+ + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + configFile, + log) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.filters-module.html b/docs/lib.config.filters-module.html new file mode 100644 index 0000000..7ea556c --- /dev/null +++ b/docs/lib.config.filters-module.html @@ -0,0 +1,189 @@ + + + + + lib.config.filters + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module filters + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module filters

source code

+ + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Filter +
+ + + + + + + + + +
+ + + + + +
Functions[hide private]
+
+   + + + + + + +
parseFilterList(filters) + source code + +
+ +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = None +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.filters-pysrc.html b/docs/lib.config.filters-pysrc.html new file mode 100644 index 0000000..191eda1 --- /dev/null +++ b/docs/lib.config.filters-pysrc.html @@ -0,0 +1,129 @@ + + + + + lib.config.filters + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module filters + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.config.filters

+
+
1 -class Filter: +
2 - def __init__(self, name="", command="", priority=0, comment=""): +
3 self.name = name + 4 self.command = command + 5 self.priority = priority + 6 self.comment = comment +
7 +
8 - def __str__(self): +
9 return "Filter('Name: " + self.name + "', 'Command: " + self.command + "', 'Priority: " + str( +10 self.priority) + "')" +
11 +
12 - def clone(self): +
13 return Filter(self.name, self.command, self.priority, self.comment) +
14 +15 +
16 -def parseFilterList(filters): +
17 return [Filter(name, **values) for name, values in filters.items()] +
18 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.filters.Filter-class.html b/docs/lib.config.filters.Filter-class.html new file mode 100644 index 0000000..6658592 --- /dev/null +++ b/docs/lib.config.filters.Filter-class.html @@ -0,0 +1,176 @@ + + + + + lib.config.filters.Filter + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module filters :: + Class Filter + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Filter

source code

+ + + + + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + name='', + command='', + priority=0, + comment='') + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+   + + + + + + +
clone(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.hostgroups-module.html b/docs/lib.config.hostgroups-module.html new file mode 100644 index 0000000..2ae8381 --- /dev/null +++ b/docs/lib.config.hostgroups-module.html @@ -0,0 +1,201 @@ + + + + + lib.config.hostgroups + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module hostgroups + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module hostgroups

source code

+ + + + + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + HostGroup +
+   + + HostGroupService +
+ + + + + + + + + +
+ + + + + +
Functions[hide private]
+
+   + + + + + + +
parseHostGroupList(hostgroups, + hosts, + members, + periods, + services, + log) + source code + +
+ +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = None +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.hostgroups-pysrc.html b/docs/lib.config.hostgroups-pysrc.html new file mode 100644 index 0000000..adc5cbc --- /dev/null +++ b/docs/lib.config.hostgroups-pysrc.html @@ -0,0 +1,169 @@ + + + + + lib.config.hostgroups + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module hostgroups + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.config.hostgroups

+
+
1 -class HostGroup: +
2 - def __init__(self, name, members="", hosts="", services="", threshold="", parent="", comment=""): +
3 self.name = name + 4 self.interval = 0 + 5 self.members = members + 6 self.hosts = hosts + 7 self.services = services + 8 self.threshold = threshold + 9 self.parent = parent +10 self.comment = comment +
11 +
12 - def __str__(self): +
13 ret = "HostGroup: " + self.name + " threshold: " + str(self.threshold) + " parent: " + self.parent + "\n" +14 ret += "members: {\n" +15 for itm in self.members: +16 ret += str(itm) + "\n" +17 ret += "}\n" +18 ret += "hosts: {\n" +19 for itm in self.hosts: +20 ret += str(itm) + "\n" +21 ret += "}\n" +22 ret += "services: {\n" +23 for itm in self.services: +24 ret += str(itm) + "\n" +25 ret += "}\n" +26 return ret +
27 +28 +
29 -class HostGroupService: +
30 - def __init__(self, service, periods): +
31 self.service = service +32 self.periods = periods +
33 +
34 - def __str__(self): +
35 return "HostgroupService { " + str(self.service) + ", " + str(self.periods) + "}" +
36 +37 +
38 -def parseHostGroupList(hostgroups, hosts, members, periods, services, log): +
39 parsedHostGroups = [] +40 for hgname, hgValues in hostgroups.items(): +41 hostGroup = HostGroup(hgname) +42 hostGroup.members = filter(lambda m: m.nameid in hgValues['members'], members) +43 hostGroup.hosts = filter(lambda h: h.name in hgValues['hosts'], hosts) +44 hostGroup.threshold = hgValues['threshold'] +45 if 'parent' in hgValues: +46 hostGroup.parent = hgValues['parent'] +47 hostGroup.services = [] +48 for serviceName, servicePeriods in hgValues['services'].items(): +49 service = filter(lambda s: s.name in serviceName, services) +50 if len(service) == 0: +51 log.w("Service " + serviceName + " is not defined for Hostgroup " + hgname) +52 continue +53 service = service[0] +54 hostGroupPeriods = filter(lambda p: p.name in servicePeriods, periods) +55 hostGroup.services.append(HostGroupService(service, hostGroupPeriods)) +56 parsedHostGroups.append(hostGroup) +57 return parsedHostGroups +
58 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.hostgroups.HostGroup-class.html b/docs/lib.config.hostgroups.HostGroup-class.html new file mode 100644 index 0000000..50761ac --- /dev/null +++ b/docs/lib.config.hostgroups.HostGroup-class.html @@ -0,0 +1,163 @@ + + + + + lib.config.hostgroups.HostGroup + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module hostgroups :: + Class HostGroup + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class HostGroup

source code

+ + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + name, + members='', + hosts='', + services='', + threshold='', + parent='', + comment='') + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.hostgroups.HostGroupService-class.html b/docs/lib.config.hostgroups.HostGroupService-class.html new file mode 100644 index 0000000..c742868 --- /dev/null +++ b/docs/lib.config.hostgroups.HostGroupService-class.html @@ -0,0 +1,158 @@ + + + + + lib.config.hostgroups.HostGroupService + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module hostgroups :: + Class HostGroupService + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class HostGroupService

source code

+ + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + service, + periods) + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.hosts-module.html b/docs/lib.config.hosts-module.html new file mode 100644 index 0000000..2c562b5 --- /dev/null +++ b/docs/lib.config.hosts-module.html @@ -0,0 +1,199 @@ + + + + + lib.config.hosts + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module hosts + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module hosts

source code

+ + + + + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Host +
+   + + HostService +
+ + + + + + + + + +
+ + + + + +
Functions[hide private]
+
+   + + + + + + +
parseHostList(hosts, + services, + log)
+ parse the HostList and replace any command as nessesary
+ source code + +
+ +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = 'lib.config' +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.hosts-pysrc.html b/docs/lib.config.hosts-pysrc.html new file mode 100644 index 0000000..becb13e --- /dev/null +++ b/docs/lib.config.hosts-pysrc.html @@ -0,0 +1,220 @@ + + + + + lib.config.hosts + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module hosts + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.config.hosts

+
+  1  import re 
+  2   
+  3   
+
4 -class Host: +
5 - def __init__(self, name="", host="", parent="", services=None, comment=""): +
6 self.name = name + 7 self.host = host + 8 self.parent = parent + 9 self.services = services + 10 self.comment = comment +
11 +
12 - def __str__(self): +
13 ret = "Host('Name: " + self.name + "', 'access: " + self.host + "', " + 14 if self.parent != "": + 15 ret += "'parent: " + self.parent + "', " + 16 ret += "'HostServices: {" + 17 for s in self.services: + 18 ret += str(s) + "\n" + 19 ret += "}" + 20 return ret +
21 + 22 +
23 -class HostService: +
24 - def __init__(self, service, warning="", critical=""): +
25 self.service = service + 26 self.warning = warning + 27 self.critical = critical +
28 +
29 - def setCommand(self, command): +
30 self.service.command = command +
31 +
32 - def getCommand(self): +
33 return self.service.command +
34 +
35 - def __str__(self): +
36 ret = str(self.service) + 37 if self.warning: + 38 ret += "warning: " + str(self.warning) + 39 if self.critical: + 40 ret += "critical: " + str(self.critical) + 41 return ret; +
42 + 43 +
44 -def parseHostList(hosts, services, log): +
45 """ + 46 parse the HostList and replace any command as nessesary + 47 """ + 48 #precompiled regexPattern which finds replacements in service strings + 49 pattern = re.compile("@(\w+)") + 50 #get a List of Host Objects and leave services unparsed for this moment + 51 parsedHosts = [Host(name, **values) for name, values in hosts.items()] + 52 #predefined dict to cache service replacements by name + 53 serviceReplacements = {} + 54 for host in parsedHosts: + 55 #list to store HostService Objects + 56 hostServices = [] + 57 #lets start to parse the Service Dict. + 58 for servicename, serviceParams in host.services.items(): + 59 #bool to check if the service is defined. + 60 found = False + 61 #to a real iteration. just pick the right service + 62 for service in services: + 63 if service.name != servicename: + 64 continue + 65 #indicate we found a service + 66 found = True + 67 #check to see if we already regexed our service command + 68 if service.name not in serviceReplacements: + 69 serviceReplacements[service.name] = pattern.findall(service.command) + 70 for params in serviceParams: + 71 #copy replacements from service command + 72 replacements = serviceReplacements[service.name][:] + 73 #for every Host.service.parameter we need a new HostService Object + 74 hostService = HostService(service.clone()) + 75 #check if the ServiceParameter contain warnings or critical values + 76 if 'warning' in params: + 77 hostService.warning = params['warning'] + 78 del params['warning'] + 79 if 'critical' in params: + 80 hostService.critical = params['critical'] + 81 del params['critical'] + 82 #any remainig parm should be a replacement + 83 for parm in params: + 84 if parm not in replacements: + 85 log.w("undefined parameter: " + parm + " in host " + host.name + " from service " + service.name) + 86 continue + 87 #replace our ServiceCommand with the parameter_value (search, replacement, string) + 88 hostService.setCommand(re.sub('@' + parm, params[parm], hostService.getCommand())) + 89 replacements.remove(parm) + 90 #host will not be inside ServiceParameters, so check this also + 91 if 'host' in replacements: + 92 hostService.setCommand(re.sub('@host', host.host, hostService.getCommand())) + 93 replacements.remove('host') + 94 #replacements should be empty now. + 95 #If not we cannot use this command as some values are missing + 96 if replacements: + 97 log.w("Hostservice " + servicename + " from host " + host.name + " is ignored because of missing replacements: " + str( + 98 replacements)) + 99 else: +100 #anything ok! add to our valid hostServices +101 hostServices.append(hostService) +102 #we could't find the service defined in this host. Service ignored! +103 if not found: +104 log.w("Service " + servicename + " not defined in host " + host.name) +105 #replace host.service member by parsed HostService Objects +106 host.services = hostServices +107 return parsedHosts +
108 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.hosts.Host-class.html b/docs/lib.config.hosts.Host-class.html new file mode 100644 index 0000000..51bb92f --- /dev/null +++ b/docs/lib.config.hosts.Host-class.html @@ -0,0 +1,161 @@ + + + + + lib.config.hosts.Host + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module hosts :: + Class Host + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Host

source code

+ + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + name='', + host='', + parent='', + services=None, + comment='') + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.hosts.HostService-class.html b/docs/lib.config.hosts.HostService-class.html new file mode 100644 index 0000000..59cd105 --- /dev/null +++ b/docs/lib.config.hosts.HostService-class.html @@ -0,0 +1,192 @@ + + + + + lib.config.hosts.HostService + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module hosts :: + Class HostService + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class HostService

source code

+ + + + + + + + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + service, + warning='', + critical='') + source code + +
+ +
+   + + + + + + +
setCommand(self, + command) + source code + +
+ +
+   + + + + + + +
getCommand(self) + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.layouts-module.html b/docs/lib.config.layouts-module.html new file mode 100644 index 0000000..6bf88ed --- /dev/null +++ b/docs/lib.config.layouts-module.html @@ -0,0 +1,137 @@ + + + + + lib.config.layouts + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module layouts + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module layouts

source code

+ + + + + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Layout +
+   + + LayoutList +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.layouts-pysrc.html b/docs/lib.config.layouts-pysrc.html new file mode 100644 index 0000000..864517b --- /dev/null +++ b/docs/lib.config.layouts-pysrc.html @@ -0,0 +1,160 @@ + + + + + lib.config.layouts + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module layouts + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.config.layouts

+
+
1 -class Layout: +
2 - def __init__(self, myLayout): +
3 self.name = myLayout + 4 self.enabled = False + 5 self.hostgroups = [] +
6 +
7 - def __str__(self): +
8 ret = "Layout: 'Name:" + str(self.name) + "', 'Enabled: " + str(self.enabled) + " " + 9 for group in self.hostgroups: +10 ret += str(group) +11 return ret +
12 +13 +
14 -class LayoutList: +
15 - def __init__(self, layouts, hostgroups): +
16 self.layouts = [] +17 self.dict = layouts +18 self.plugins = [] +19 for k, v in layouts.items(): +20 if k in ("plugins", "Plugins"): +21 self.plugins = v +22 continue +23 else: +24 l = Layout(k) +25 for k1, v1 in v.items(): +26 if k1 in ("enabled", "Enabled"): +27 l.enabled = v1 +28 elif k1 in ("hostgroups", "Hostgroups"): +29 l.hostgroups = [] +30 for group in v1: +31 h = None +32 for hostg in hostgroups: +33 if hostg.name == group: +34 h = hostg +35 break +36 if h is not None: +37 l.hostgroups.append(h) +38 else: +39 # TODO: replace next line with new logging +40 #logger.logWarningConfig(file="hostgroups", missing=group) +41 self.layouts.append(l) +
42 +
43 - def __str__(self): +
44 ret = "" +45 ret += "Plugins: " + str(self.plugins) + "\n" +46 for layout in self.layouts: +47 ret += str(layout) + "\n" +48 return ret +
49 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.layouts.Layout-class.html b/docs/lib.config.layouts.Layout-class.html new file mode 100644 index 0000000..0ddebe1 --- /dev/null +++ b/docs/lib.config.layouts.Layout-class.html @@ -0,0 +1,157 @@ + + + + + lib.config.layouts.Layout + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module layouts :: + Class Layout + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Layout

source code

+ + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + myLayout) + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.layouts.LayoutList-class.html b/docs/lib.config.layouts.LayoutList-class.html new file mode 100644 index 0000000..9d17fc9 --- /dev/null +++ b/docs/lib.config.layouts.LayoutList-class.html @@ -0,0 +1,158 @@ + + + + + lib.config.layouts.LayoutList + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module layouts :: + Class LayoutList + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class LayoutList

source code

+ + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + layouts, + hostgroups) + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.members-module.html b/docs/lib.config.members-module.html new file mode 100644 index 0000000..3b01742 --- /dev/null +++ b/docs/lib.config.members-module.html @@ -0,0 +1,198 @@ + + + + + lib.config.members + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module members + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module members

source code

+ + + + + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Member +
+   + + MemberFilter +
+ + + + + + + + + +
+ + + + + +
Functions[hide private]
+
+   + + + + + + +
parseMemberList(members, + filters, + log) + source code + +
+ +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = 'lib.config' +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.members-pysrc.html b/docs/lib.config.members-pysrc.html new file mode 100644 index 0000000..78b5edf --- /dev/null +++ b/docs/lib.config.members-pysrc.html @@ -0,0 +1,158 @@ + + + + + lib.config.members + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module members + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.config.members

+
+ 1  import re 
+ 2   
+ 3   
+
4 -class Member: +
5 - def __init__(self, nameid, name="", phone="", comment="", parent="", filters=None): +
6 self.nameid = nameid + 7 self.name = name + 8 self.phone = phone + 9 self.filters = filters +10 self.comment = comment +11 self.parent = parent +
12 +
13 - def __str__(self): +
14 ret = "Member Id: " + self.nameid + " Name: " + self.name + " Filters: " + str(self.phone) +15 for f in self.filters: +16 ret += str(f) +17 return ret +
18 +19 +
20 -class MemberFilter: +
21 - def __init__(self, filt, Value): +
22 self.filt = filt +23 self.value = Value +
24 +
25 - def __str__(self): +
26 return "Filter:" + str(self.filter) + " Value:" + self.value +
27 +28 +
29 -def parseMemberList(members, filters, log): +
30 parsedMembers = [Member(nameid, **values) for nameid, values in members.items()] +31 for member in parsedMembers: +32 mFilter = [] +33 for filtername, replacement in member.filters.items(): +34 found = False +35 for filt in filters: +36 if filt.name != filtername: +37 continue +38 found = True +39 memberFilter = filt.clone() +40 memberFilter.command = re.sub('@member', replacement, filt.command) +41 mFilter.append(memberFilter) +42 if not found: +43 log.w("filter: " + filtername + " is not defined in member " + member.name) +44 member.filters = mFilter +45 return parsedMembers +
46 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.members.Member-class.html b/docs/lib.config.members.Member-class.html new file mode 100644 index 0000000..093495c --- /dev/null +++ b/docs/lib.config.members.Member-class.html @@ -0,0 +1,162 @@ + + + + + lib.config.members.Member + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module members :: + Class Member + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Member

source code

+ + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + nameid, + name='', + phone='', + comment='', + parent='', + filters=None) + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.members.MemberFilter-class.html b/docs/lib.config.members.MemberFilter-class.html new file mode 100644 index 0000000..08f7c63 --- /dev/null +++ b/docs/lib.config.members.MemberFilter-class.html @@ -0,0 +1,158 @@ + + + + + lib.config.members.MemberFilter + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module members :: + Class MemberFilter + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class MemberFilter

source code

+ + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + filt, + Value) + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.periods-module.html b/docs/lib.config.periods-module.html new file mode 100644 index 0000000..cfa660b --- /dev/null +++ b/docs/lib.config.periods-module.html @@ -0,0 +1,189 @@ + + + + + lib.config.periods + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module periods + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module periods

source code

+ + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Period +
+ + + + + + + + + +
+ + + + + +
Functions[hide private]
+
+   + + + + + + +
parsePeriodList(periods) + source code + +
+ +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = None +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.periods-pysrc.html b/docs/lib.config.periods-pysrc.html new file mode 100644 index 0000000..d3c74c8 --- /dev/null +++ b/docs/lib.config.periods-pysrc.html @@ -0,0 +1,135 @@ + + + + + lib.config.periods + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module periods + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.config.periods

+
+
1 -class Period: +
2 - def __init__(self, name="", year="*", month="*", day="*", week="*", + 3 day_of_week=None, hour="*", minute="*", second="0", date=None, + 4 comment=None): +
5 self.name = name + 6 self.year = year # 4-digit year number + 7 self.month = month # month number (1-12) + 8 self.day = day # day of the month (1-31) + 9 self.week = week # ISO week number (1-53) +10 self.day_of_week = day_of_week # number or name of weekday (0-6 or mon,tue,wed,thu,fri,sat,sun) +11 self.hour = hour # hour (0-23) +12 self.minute = minute # minute (0-59) +13 self.second = second # second (0-59) +14 self.comment = comment +15 self.date = date +
16 +
17 - def __str__(self): +
18 ret = "Period(Name: " + self.name + " Year: " + self.year + " Month: " + self.month + ")" +19 return ret +
20 +21 +
22 -def parsePeriodList(periods): +
23 return [Period(name, **values) for name, values in periods.items()] +
24 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.periods.Period-class.html b/docs/lib.config.periods.Period-class.html new file mode 100644 index 0000000..23c3d18 --- /dev/null +++ b/docs/lib.config.periods.Period-class.html @@ -0,0 +1,167 @@ + + + + + lib.config.periods.Period + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module periods :: + Class Period + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Period

source code

+ + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + name='', + year='*', + month='*', + day='*', + week='*', + day_of_week=None, + hour='*', + minute='*', + second='0', + date=None, + comment=None) + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.services-module.html b/docs/lib.config.services-module.html new file mode 100644 index 0000000..240b868 --- /dev/null +++ b/docs/lib.config.services-module.html @@ -0,0 +1,189 @@ + + + + + lib.config.services + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module services + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module services

source code

+ + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Service +
+ + + + + + + + + +
+ + + + + +
Functions[hide private]
+
+   + + + + + + +
serviceList(services) + source code + +
+ +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = None +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.services-pysrc.html b/docs/lib.config.services-pysrc.html new file mode 100644 index 0000000..c2272e9 --- /dev/null +++ b/docs/lib.config.services-pysrc.html @@ -0,0 +1,128 @@ + + + + + lib.config.services + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module services + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.config.services

+
+
1 -class Service: +
2 - def __init__(self, name="", command="", comment="", parser=""): +
3 self.name = name + 4 self.command = command + 5 self.comment = comment + 6 self.parser = parser +
7 +
8 - def __str__(self): +
9 return "Service('Name: " + self.name + "', 'Command: " + self.command + ", 'Parser: " + self.parser + "')" +
10 +
11 - def clone(self): +
12 return Service(self.name, self.command, self.comment) +
13 +14 +
15 -def serviceList(services): +
16 return [Service(name=key, **values) for key, values in services.items()] +
17 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.config.services.Service-class.html b/docs/lib.config.services.Service-class.html new file mode 100644 index 0000000..77d285f --- /dev/null +++ b/docs/lib.config.services.Service-class.html @@ -0,0 +1,176 @@ + + + + + lib.config.services.Service + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package config :: + Module services :: + Class Service + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Service

source code

+ + + + + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + name='', + command='', + comment='', + parser='') + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+   + + + + + + +
clone(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core-module.html b/docs/lib.core-module.html new file mode 100644 index 0000000..e95e04e --- /dev/null +++ b/docs/lib.core-module.html @@ -0,0 +1,158 @@ + + + + + lib.core + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Package core

source code

+ + + + + + + +
+ + + + + +
Submodules[hide private]
+
+
+ +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = None +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core-pysrc.html b/docs/lib.core-pysrc.html new file mode 100644 index 0000000..6aaabc7 --- /dev/null +++ b/docs/lib.core-pysrc.html @@ -0,0 +1,112 @@ + + + + + lib.core + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Package lib.core

+
+1   
+2   
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.command-module.html b/docs/lib.core.command-module.html new file mode 100644 index 0000000..967525a --- /dev/null +++ b/docs/lib.core.command-module.html @@ -0,0 +1,155 @@ + + + + + lib.core.command + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module command + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module command

source code

+ + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Command +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = 'lib.core' +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.command-pysrc.html b/docs/lib.core.command-pysrc.html new file mode 100644 index 0000000..8acca1e --- /dev/null +++ b/docs/lib.core.command-pysrc.html @@ -0,0 +1,140 @@ + + + + + lib.core.command + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module command + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.core.command

+
+ 1  import subprocess 
+ 2   
+ 3   
+
4 -class Command: +
5 - def __init__(self, command): +
6 self.command = command + 7 self.output = "" + 8 self.error = "" +
9 +
10 - def __str__(self): +
11 return command +
12 +
13 - def hasProcessed(self): +
14 return self.output != "" and self.error != "" +
15 +
16 - def doProcess(self): +
17 process = subprocess.Popen([self.command], stdout=subprocess.PIPE) +18 self.output, self.error = process.communicate() +
19 +
20 - def getOutput(self): +
21 if not self.hasProcessed(): +22 self.doProcess() +23 return self.output +
24 +
25 - def getError(self): +
26 if not self.hasProcessed(): +27 self.doProcess() +28 return self.error +
29 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.command.Command-class.html b/docs/lib.core.command.Command-class.html new file mode 100644 index 0000000..fdd924e --- /dev/null +++ b/docs/lib.core.command.Command-class.html @@ -0,0 +1,221 @@ + + + + + lib.core.command.Command + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module command :: + Class Command + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Command

source code

+ + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + command) + source code + +
+ +
+   + + + + + + +
__str__(self) + source code + +
+ +
+   + + + + + + +
hasProcessed(self) + source code + +
+ +
+   + + + + + + +
doProcess(self) + source code + +
+ +
+   + + + + + + +
getOutput(self) + source code + +
+ +
+   + + + + + + +
getError(self) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.daemon-module.html b/docs/lib.core.daemon-module.html new file mode 100644 index 0000000..5d27d4b --- /dev/null +++ b/docs/lib.core.daemon-module.html @@ -0,0 +1,156 @@ + + + + + lib.core.daemon + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module daemon + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module daemon

source code

+ + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Daemon
+ A generic daemon class. +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = 'lib.core' +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.daemon-pysrc.html b/docs/lib.core.daemon-pysrc.html new file mode 100644 index 0000000..010ae36 --- /dev/null +++ b/docs/lib.core.daemon-pysrc.html @@ -0,0 +1,246 @@ + + + + + lib.core.daemon + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module daemon + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.core.daemon

+
+  1  import sys 
+  2  import os 
+  3  import time 
+  4  import atexit 
+  5  from signal import SIGTERM 
+  6   
+  7   
+
8 -class Daemon: +
9 """ + 10 A generic daemon class. + 11 + 12 Usage: subclass the Daemon class and override the run() method + 13 """ + 14 +
15 - def __init__(self, pidfile, stdin='/dev/null', stdout='/dev/null', stderr='/dev/null'): +
16 self.stdin = stdin + 17 self.stdout = stdout + 18 self.stderr = stderr + 19 self.pidfile = pidfile +
20 +
21 - def daemonize(self): +
22 """ + 23 do the UNIX double-fork magic, see Stevens' "Advanced + 24 Programming in the UNIX Environment" for details (ISBN 0201563177) + 25 http://www.erlenstar.demon.co.uk/unix/faq_2.html#SEC16 + 26 """ + 27 try: + 28 pid = os.fork() + 29 if pid > 0: + 30 # exit first parent + 31 sys.exit(0) + 32 except OSError, e: + 33 sys.stderr.write("fork #1 failed: %d (%s)\n" % (e.errno, e.strerror)) + 34 sys.exit(1) + 35 + 36 # decouple from parent environment + 37 os.chdir("/") + 38 os.setsid() + 39 os.umask(0) + 40 + 41 # do second fork + 42 try: + 43 pid = os.fork() + 44 if pid > 0: + 45 # exit from second parent + 46 sys.exit(0) + 47 except OSError, e: + 48 sys.stderr.write("fork #2 failed: %d (%s)\n" % (e.errno, e.strerror)) + 49 sys.exit(1) + 50 + 51 # redirect standard file descriptors + 52 sys.stdout.flush() + 53 sys.stderr.flush() + 54 si = file(self.stdin, 'r') + 55 so = file(self.stdout, 'a+') + 56 se = file(self.stderr, 'a+', 0) + 57 os.dup2(si.fileno(), sys.stdin.fileno()) + 58 os.dup2(so.fileno(), sys.stdout.fileno()) + 59 os.dup2(se.fileno(), sys.stderr.fileno()) + 60 + 61 # write pidfile + 62 atexit.register(self.delpid) + 63 pid = str(os.getpid()) + 64 file(self.pidfile, 'w+').write("%s\n" % pid) +
65 +
66 - def delpid(self): +
67 os.remove(self.pidfile) +
68 +
69 - def start(self): +
70 """ + 71 Start the daemon + 72 """ + 73 # Check for a pidfile to see if the daemon already runs + 74 try: + 75 pf = file(self.pidfile, 'r') + 76 pid = int(pf.read().strip()) + 77 pf.close() + 78 except IOError: + 79 pid = None + 80 + 81 if pid: + 82 message = "pidfile %s already exist. daemon already running?\n" + 83 sys.stderr.write(message % self.pidfile) + 84 sys.exit(1) + 85 + 86 # Start the daemon + 87 self.daemonize() + 88 self.run() +
89 +
90 - def stop(self): +
91 """ + 92 Stop the daemon + 93 """ + 94 # Get the pid from the pidfile + 95 try: + 96 pf = file(self.pidfile, 'r') + 97 pid = int(pf.read().strip()) + 98 pf.close() + 99 except IOError: +100 pid = None +101 +102 if not pid: +103 message = "pidfile %s does not exist. daemon not running?\n" +104 sys.stderr.write(message % self.pidfile) +105 return # not an error in a restart +106 +107 # Try killing the daemon process +108 try: +109 while 1: +110 os.kill(pid, SIGTERM) +111 time.sleep(0.1) +112 except OSError, err: +113 err = str(err) +114 if err.find("No such process") > 0: +115 if os.path.exists(self.pidfile): +116 os.remove(self.pidfile) +117 else: +118 print str(err) +119 sys.exit(1) +
120 +
121 - def restart(self): +
122 """ +123 Restart the daemon +124 """ +125 self.stop() +126 self.start() +
127 +
128 - def run(self): +
129 """ +130 You should override this method when you subclass Daemon. +131 It will be called after the process has been +132 daemonized by start() or restart(). +133 """ +
134 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.daemon.Daemon-class.html b/docs/lib.core.daemon.Daemon-class.html new file mode 100644 index 0000000..21fb330 --- /dev/null +++ b/docs/lib.core.daemon.Daemon-class.html @@ -0,0 +1,296 @@ + + + + + lib.core.daemon.Daemon + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module daemon :: + Class Daemon + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Daemon

source code

+
Known Subclasses:
+
+ +
+ +
+

A generic daemon class.

+

Usage: subclass the Daemon class and override the run() method

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + pidfile, + stdin='/dev/null', + stdout='/dev/null', + stderr='/dev/null') + source code + +
+ +
+   + + + + + + +
daemonize(self)
+ do the UNIX double-fork magic, see Stevens' "Advanced + Programming in the UNIX Environment" for details (ISBN + 0201563177) http://www.erlenstar.demon.co.uk/unix/faq_2.html#SEC16
+ source code + +
+ +
+   + + + + + + +
delpid(self) + source code + +
+ +
+   + + + + + + +
restart(self)
+ Restart the daemon
+ source code + +
+ +
+   + + + + + + +
run(self)
+ You should override this method when you subclass Daemon.
+ source code + +
+ +
+   + + + + + + +
start(self)
+ Start the daemon
+ source code + +
+ +
+   + + + + + + +
stop(self)
+ Stop the daemon
+ source code + +
+ +
+ + + + + + +
+ + + + + +
Method Details[hide private]
+
+ +
+ +
+ + +
+

run(self) +

+
source code  +
+ +

You should override this method when you subclass Daemon. It will be + called after the process has been daemonized by start() or restart().

+
+
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.job-module.html b/docs/lib.core.job-module.html new file mode 100644 index 0000000..eab47d8 --- /dev/null +++ b/docs/lib.core.job-module.html @@ -0,0 +1,158 @@ + + + + + lib.core.job + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module job + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module job

source code

+

This is what job_function needs as parameter for each job to + succesfully execute.

+ + + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Job +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = None +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.job-pysrc.html b/docs/lib.core.job-pysrc.html new file mode 100644 index 0000000..eda75b7 --- /dev/null +++ b/docs/lib.core.job-pysrc.html @@ -0,0 +1,124 @@ + + + + + lib.core.job + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module job + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.core.job

+
+ 1  """ 
+ 2  This is what job_function needs as parameter for each job to succesfully  
+ 3  execute. 
+ 4  """ 
+ 5   
+ 6   
+
7 -class Job: +
8 - def __init__(self, command=None, members=None, host=None, service=None): +
9 self.command = command +10 self.members = members +11 self.host = host +12 self.service = service +
13 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.job.Job-class.html b/docs/lib.core.job.Job-class.html new file mode 100644 index 0000000..b2abbbb --- /dev/null +++ b/docs/lib.core.job.Job-class.html @@ -0,0 +1,144 @@ + + + + + lib.core.job.Job + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module job :: + Class Job + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Job

source code

+ + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + command=None, + members=None, + host=None, + service=None) + source code + +
+ +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.linspector_daemon-module.html b/docs/lib.core.linspector_daemon-module.html new file mode 100644 index 0000000..fb643ca --- /dev/null +++ b/docs/lib.core.linspector_daemon-module.html @@ -0,0 +1,155 @@ + + + + + lib.core.linspector_daemon + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module linspector_daemon + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module linspector_daemon

source code

+ + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + LinspectorDaemon +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = 'lib.core' +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.linspector_daemon-pysrc.html b/docs/lib.core.linspector_daemon-pysrc.html new file mode 100644 index 0000000..89ddb92 --- /dev/null +++ b/docs/lib.core.linspector_daemon-pysrc.html @@ -0,0 +1,128 @@ + + + + + lib.core.linspector_daemon + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module linspector_daemon + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.core.linspector_daemon

+
+ 1  from ..core import logger 
+ 2  from ..core.daemon import Daemon 
+ 3   
+ 4   
+
5 -class LinspectorDaemon(Daemon): +
6 - def run(self): +
7 while True: + 8 try: + 9 a = 2 +10 logger.writeLogToFile(_logfile, "Running!") +11 print "running!" +12 except Exception as err: +13 #logger.writeLogToFile(_logfile, str(err)) +14 print "failed" +15 sys.exit(1) +16 time.sleep(1) +
17 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.linspector_daemon.LinspectorDaemon-class.html b/docs/lib.core.linspector_daemon.LinspectorDaemon-class.html new file mode 100644 index 0000000..4dee5e9 --- /dev/null +++ b/docs/lib.core.linspector_daemon.LinspectorDaemon-class.html @@ -0,0 +1,203 @@ + + + + + lib.core.linspector_daemon.LinspectorDaemon + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module linspector_daemon :: + Class LinspectorDaemon + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class LinspectorDaemon

source code

+
+daemon.Daemon --+
+                |
+               LinspectorDaemon
+
+ +
+ + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
run(self)
+ You should override this method when you subclass Daemon.
+ source code + +
+ +
+

Inherited from daemon.Daemon: + __init__, + daemonize, + delpid, + restart, + start, + stop +

+
+ + + + + + +
+ + + + + +
Method Details[hide private]
+
+ +
+ +
+ + +
+

run(self) +

+
source code  +
+ +

You should override this method when you subclass Daemon. It will be + called after the process has been daemonized by start() or restart().

+
+
Overrides: + daemon.Daemon.run +
(inherited documentation)
+ +
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.logger-module.html b/docs/lib.core.logger-module.html new file mode 100644 index 0000000..2f1c0aa --- /dev/null +++ b/docs/lib.core.logger-module.html @@ -0,0 +1,157 @@ + + + + + lib.core.logger + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module logger + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Module logger

source code

+ + + + + + + + + +
+ + + + + +
Classes[hide private]
+
+   + + Logger
+ Logger class that prints its messages and keeps them also inside a + logfile +
+ + + + + + + + + +
+ + + + + +
Variables[hide private]
+
+   + + __package__ = 'lib.core' +
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.logger-pysrc.html b/docs/lib.core.logger-pysrc.html new file mode 100644 index 0000000..b328128 --- /dev/null +++ b/docs/lib.core.logger-pysrc.html @@ -0,0 +1,171 @@ + + + + + lib.core.logger + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module logger + + + + + + +
[hide private]
[frames] | no frames]
+
+

Source Code for Module lib.core.logger

+
+ 1  import logging 
+ 2  import logging.handlers 
+ 3  import os 
+ 4  import os.path as path 
+ 5   
+ 6   
+
7 -class Logger(): +
8 """ + 9 Logger class that prints its messages and keeps them also inside a logfile +10 """ +11 +
12 - def __init__(self, logfile="./linspector.log", logLevel=logging.DEBUG, logfileLevel=logging.DEBUG): +
13 """ +14 initializes a new Logger object. +15 +16 :param logLevel: the LoggingLevel from the console output (DEBUG default) +17 :param logfile: the file where to log. Logs are rotated by default. +18 :param logfileLevel: the LoggingLevel for the file Logger. (DEBUG default) +19 """ +20 +21 logfile = path.expanduser(logfile) +22 if not path.exists(path.dirname(logfile)): +23 os.makedirs(path.dirname(logfile)) +24 +25 self.log = logging.getLogger("LinspectorLogger") +26 self.log.setLevel(logging.DEBUG) +27 +28 consoleHandler = logging.StreamHandler() +29 consoleHandler.setLevel(logLevel) +30 +31 fileHandler = logging.handlers.RotatingFileHandler(logfile, maxBytes=1024000, backupCount=4) +32 fileHandler.setLevel(logfileLevel) +33 +34 consoleFormatter = logging.Formatter('[%(levelname)s]: %(message)s') +35 fileFormatter = logging.Formatter('%(asctime)s [%(levelname)s]: %(message)s') +36 +37 consoleHandler.setFormatter(consoleFormatter) +38 fileHandler.setFormatter(fileFormatter) +39 +40 self.log.addHandler(consoleHandler) +41 self.log.addHandler(fileHandler) +
42 +
43 - def d(self, message): +
44 self.log.debug(message) +
45 +
46 - def i(self, message): +
47 self.log.info(message) +
48 +
49 - def w(self, message): +
50 self.log.warn(message) +
51 +
52 - def e(self, message): +
53 self.log.error(message) +
54 +
55 - def c(self, message): +
56 self.log.critical(message) +
57 +
58 - def close(self): +
59 logging.shutdown() +
60 +
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/lib.core.logger.Logger-class.html b/docs/lib.core.logger.Logger-class.html new file mode 100644 index 0000000..7e02a37 --- /dev/null +++ b/docs/lib.core.logger.Logger-class.html @@ -0,0 +1,294 @@ + + + + + lib.core.logger.Logger + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + Package lib :: + Package core :: + Module logger :: + Class Logger + + + + + + +
[hide private]
[frames] | no frames]
+
+ +

Class Logger

source code

+

Logger class that prints its messages and keeps them also inside a + logfile

+ + + + + + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + + +
Instance Methods[hide private]
+
+   + + + + + + +
__init__(self, + logfile='./linspector.log', + logLevel=10, + logfileLevel=10)
+ initializes a new Logger object.
+ source code + +
+ +
+   + + + + + + +
d(self, + message) + source code + +
+ +
+   + + + + + + +
i(self, + message) + source code + +
+ +
+   + + + + + + +
w(self, + message) + source code + +
+ +
+   + + + + + + +
e(self, + message) + source code + +
+ +
+   + + + + + + +
c(self, + message) + source code + +
+ +
+   + + + + + + +
close(self) + source code + +
+ +
+ + + + + + +
+ + + + + +
Method Details[hide private]
+
+ +
+ +
+ + +
+

__init__(self, + logfile='./linspector.log', + logLevel=10, + logfileLevel=10) +
(Constructor) +

+
source code  +
+ +

initializes a new Logger object.

+

:param logLevel: the LoggingLevel from the console output (DEBUG + default) :param logfile: the file where to log. Logs are rotated by + default. :param logfileLevel: the LoggingLevel for the file Logger. + (DEBUG default)

+
+
+
+
+
+ + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/module-tree.html b/docs/module-tree.html new file mode 100644 index 0000000..d46cfb0 --- /dev/null +++ b/docs/module-tree.html @@ -0,0 +1,130 @@ + + + + + Module Hierarchy + + + + + + + + + + + + + + + + + + + + + + + + + + + + +
  + + + + +
[hide private]
[frames] | no frames]
+
+
+ [ Module Hierarchy + | Class Hierarchy ] +

+

Module Hierarchy

+ + + + + + + + + + + + + + + + + + + + + + + + +
+ + + + diff --git a/docs/redirect.html b/docs/redirect.html new file mode 100644 index 0000000..7815cd3 --- /dev/null +++ b/docs/redirect.html @@ -0,0 +1,38 @@ +Epydoc Redirect Page + + + + + + + + +

Epydoc Auto-redirect page

+ +

When javascript is enabled, this page will redirect URLs of +the form redirect.html#dotted.name to the +documentation for the object with the given fully-qualified +dotted name.

+

 

+ + + + + diff --git a/docs/toc-everything.html b/docs/toc-everything.html new file mode 100644 index 0000000..b9fecd5 --- /dev/null +++ b/docs/toc-everything.html @@ -0,0 +1,70 @@ + + + + + Everything + + + + + +

Everything

+
+

All Classes

+ lib.config.config.Config
lib.config.filters.Filter
lib.config.hostgroups.HostGroup
lib.config.hostgroups.HostGroupService
lib.config.hosts.Host
lib.config.hosts.HostService
lib.config.layouts.Layout
lib.config.layouts.LayoutList
lib.config.members.Member
lib.config.members.MemberFilter
lib.config.periods.Period
lib.config.services.Service
lib.core.command.Command
lib.core.daemon.Daemon
lib.core.job.Job
lib.core.linspector_daemon.LinspectorDaemon
lib.core.logger.Logger

All Functions

+ lib.config.filters.parseFilterList
lib.config.hostgroups.parseHostGroupList
lib.config.hosts.parseHostList
lib.config.members.parseMemberList
lib.config.periods.parsePeriodList
lib.config.services.serviceList

All Variables

+ lib.__package__
lib.config.__package__
lib.config.config.__package__
lib.config.filters.__package__
lib.config.hostgroups.__package__
lib.config.hosts.__package__
lib.config.members.__package__
lib.config.periods.__package__
lib.config.services.__package__
lib.core.__package__
lib.core.command.__package__
lib.core.daemon.__package__
lib.core.job.__package__
lib.core.linspector_daemon.__package__
lib.core.logger.__package__

+[hide private] + + + + diff --git a/docs/toc-lib-module.html b/docs/toc-lib-module.html new file mode 100644 index 0000000..b993a34 --- /dev/null +++ b/docs/toc-lib-module.html @@ -0,0 +1,31 @@ + + + + + lib + + + + + +

Module lib

+
+

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.config-module.html b/docs/toc-lib.config-module.html new file mode 100644 index 0000000..58e78e5 --- /dev/null +++ b/docs/toc-lib.config-module.html @@ -0,0 +1,31 @@ + + + + + config + + + + + +

Module config

+
+

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.config.config-module.html b/docs/toc-lib.config.config-module.html new file mode 100644 index 0000000..20f1f4f --- /dev/null +++ b/docs/toc-lib.config.config-module.html @@ -0,0 +1,33 @@ + + + + + config + + + + + +

Module config

+
+

Classes

+ Config

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.config.filters-module.html b/docs/toc-lib.config.filters-module.html new file mode 100644 index 0000000..bb4a6bc --- /dev/null +++ b/docs/toc-lib.config.filters-module.html @@ -0,0 +1,35 @@ + + + + + filters + + + + + +

Module filters

+
+

Classes

+ Filter

Functions

+ parseFilterList

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.config.hostgroups-module.html b/docs/toc-lib.config.hostgroups-module.html new file mode 100644 index 0000000..e272519 --- /dev/null +++ b/docs/toc-lib.config.hostgroups-module.html @@ -0,0 +1,36 @@ + + + + + hostgroups + + + + + +

Module hostgroups

+
+

Classes

+ HostGroup
HostGroupService

Functions

+ parseHostGroupList

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.config.hosts-module.html b/docs/toc-lib.config.hosts-module.html new file mode 100644 index 0000000..e410f83 --- /dev/null +++ b/docs/toc-lib.config.hosts-module.html @@ -0,0 +1,36 @@ + + + + + hosts + + + + + +

Module hosts

+
+

Classes

+ Host
HostService

Functions

+ parseHostList

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.config.layouts-module.html b/docs/toc-lib.config.layouts-module.html new file mode 100644 index 0000000..9a35e58 --- /dev/null +++ b/docs/toc-lib.config.layouts-module.html @@ -0,0 +1,32 @@ + + + + + layouts + + + + + +

Module layouts

+
+

Classes

+ Layout
LayoutList

+[hide private] + + + + diff --git a/docs/toc-lib.config.members-module.html b/docs/toc-lib.config.members-module.html new file mode 100644 index 0000000..6fe0859 --- /dev/null +++ b/docs/toc-lib.config.members-module.html @@ -0,0 +1,36 @@ + + + + + members + + + + + +

Module members

+
+

Classes

+ Member
MemberFilter

Functions

+ parseMemberList

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.config.periods-module.html b/docs/toc-lib.config.periods-module.html new file mode 100644 index 0000000..5fcb06f --- /dev/null +++ b/docs/toc-lib.config.periods-module.html @@ -0,0 +1,35 @@ + + + + + periods + + + + + +

Module periods

+
+

Classes

+ Period

Functions

+ parsePeriodList

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.config.services-module.html b/docs/toc-lib.config.services-module.html new file mode 100644 index 0000000..30c598d --- /dev/null +++ b/docs/toc-lib.config.services-module.html @@ -0,0 +1,35 @@ + + + + + services + + + + + +

Module services

+
+

Classes

+ Service

Functions

+ serviceList

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.core-module.html b/docs/toc-lib.core-module.html new file mode 100644 index 0000000..3d54a09 --- /dev/null +++ b/docs/toc-lib.core-module.html @@ -0,0 +1,31 @@ + + + + + core + + + + + +

Module core

+
+

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.core.command-module.html b/docs/toc-lib.core.command-module.html new file mode 100644 index 0000000..ef68910 --- /dev/null +++ b/docs/toc-lib.core.command-module.html @@ -0,0 +1,33 @@ + + + + + command + + + + + +

Module command

+
+

Classes

+ Command

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.core.daemon-module.html b/docs/toc-lib.core.daemon-module.html new file mode 100644 index 0000000..946ac8a --- /dev/null +++ b/docs/toc-lib.core.daemon-module.html @@ -0,0 +1,33 @@ + + + + + daemon + + + + + +

Module daemon

+
+

Classes

+ Daemon

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.core.job-module.html b/docs/toc-lib.core.job-module.html new file mode 100644 index 0000000..262d52c --- /dev/null +++ b/docs/toc-lib.core.job-module.html @@ -0,0 +1,33 @@ + + + + + job + + + + + +

Module job

+
+

Classes

+ Job

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.core.linspector_daemon-module.html b/docs/toc-lib.core.linspector_daemon-module.html new file mode 100644 index 0000000..1f25114 --- /dev/null +++ b/docs/toc-lib.core.linspector_daemon-module.html @@ -0,0 +1,33 @@ + + + + + linspector_daemon + + + + + +

Module linspector_daemon

+
+

Classes

+ LinspectorDaemon

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc-lib.core.logger-module.html b/docs/toc-lib.core.logger-module.html new file mode 100644 index 0000000..586c53c --- /dev/null +++ b/docs/toc-lib.core.logger-module.html @@ -0,0 +1,33 @@ + + + + + logger + + + + + +

Module logger

+
+

Classes

+ Logger

Variables

+ __package__

+[hide private] + + + + diff --git a/docs/toc.html b/docs/toc.html new file mode 100644 index 0000000..af2d254 --- /dev/null +++ b/docs/toc.html @@ -0,0 +1,48 @@ + + + + + Table of Contents + + + + + +

Table of Contents

+
+ Everything +
+

Modules

+ lib
lib.config
lib.config.config
lib.config.filters
lib.config.hostgroups
lib.config.hosts
lib.config.layouts
lib.config.members
lib.config.periods
lib.config.services
lib.core
lib.core.command
lib.core.daemon
lib.core.job
lib.core.linspector_daemon
lib.core.logger

+ [hide private] + + + +