summaryrefslogtreecommitdiffstats
path: root/doc/development/cfg.txt
diff options
context:
space:
mode:
authorChris St. Pierre <chris.a.st.pierre@gmail.com>2012-09-11 10:32:30 -0400
committerChris St. Pierre <chris.a.st.pierre@gmail.com>2012-09-11 10:32:30 -0400
commit71c679e1a0105490bd5845a15de5e8f1a32e2166 (patch)
treec528e62098b599d7ae74ea53908a045ccf2ffb63 /doc/development/cfg.txt
parentb682d9e3c11f94a9a9dc254a6d53e44f953a74bf (diff)
downloadbcfg2-71c679e1a0105490bd5845a15de5e8f1a32e2166.tar.gz
bcfg2-71c679e1a0105490bd5845a15de5e8f1a32e2166.tar.bz2
bcfg2-71c679e1a0105490bd5845a15de5e8f1a32e2166.zip
Cfg: documented all Cfg modules, added development docs
Diffstat (limited to 'doc/development/cfg.txt')
-rw-r--r--doc/development/cfg.txt100
1 files changed, 100 insertions, 0 deletions
diff --git a/doc/development/cfg.txt b/doc/development/cfg.txt
new file mode 100644
index 000000000..7d27efb12
--- /dev/null
+++ b/doc/development/cfg.txt
@@ -0,0 +1,100 @@
+.. -*- mode: rst -*-
+
+.. _development-cfg:
+
+=========================
+ Cfg Handler Development
+=========================
+
+The :ref:`server-plugins-generators-cfg` plugin offers multiple
+handlers to handle different entries in different ways. Writing a new
+Cfg handler is a relatively simple way to add significant new features
+to Cfg.
+
+Each new Cfg handler must be contained in its own module in
+``Bcfg2.Server.Plugins.Cfg``, and the module and class name must be
+identical. The name should start with ``Cfg``, and should clearly
+indicate which of the handler types it is. A handler class may
+implement more than one handler type.a
+
+Cfg Handler Types
+=================
+
+There are four different types of Cfg handlers. A new handler must
+inherit either from one of these classes, or from an existing handler.
+
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgGenerator
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgFilter
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgInfo
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgVerifier
+
+Cfg Handler Base Class
+======================
+
+In addition to the interfaces defined above, all Cfg handlers inherit
+from CfgBaseFileMatcher.
+
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgBaseFileMatcher
+
+
+Cfg Exceptions
+==============
+
+Cfg handlers may produce the following exceptions:
+
+.. autoexception:: Bcfg2.Server.Plugins.Cfg.CfgVerificationError
+
+In addition, Cfg handlers may produce the following base plugin
+exceptions:
+
+.. autoexception:: Bcfg2.Server.Plugin.exceptions.PluginExecutionError
+ :noindex:
+
+.. autoexception:: Bcfg2.Server.Plugin.exceptions.PluginInitError
+ :noindex:
+
+Accessing Configuration Options
+===============================
+
+.. autoattribute:: Bcfg2.Server.Plugins.Cfg.SETUP
+
+Existing Cfg Handlers
+=====================
+
+Generators
+----------
+
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgPlaintextGenerator.CfgPlaintextGenerator
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgGenshiGenerator.CfgGenshiGenerator
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgCheetahGenerator.CfgCheetahGenerator
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgEncryptedGenerator.CfgEncryptedGenerator
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgEncryptedGenshiGenerator.CfgEncryptedGenshiGenerator
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgEncryptedCheetahGenerator.CfgEncryptedCheetahGenerator
+
+Filters
+-------
+
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgCatFilter.CfgCatFilter
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgDiffFilter.CfgDiffFilter
+
+Info Handlers
+-------------
+
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgDefaultInfo
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgInfoXML.CfgInfoXML
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgLegacyInfo.CfgLegacyInfo
+
+Verifiers
+---------
+
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgExternalCommandVerifier.CfgExternalCommandVerifier
+
+Other Cfg Objects
+=================
+
+These other objects comprise the remainder of the Cfg plugin, and are
+included for completeness.
+
+.. autoattribute:: Bcfg2.Server.Plugins.Cfg.DEFAULT_INFO
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.CfgEntrySet
+.. autoclass:: Bcfg2.Server.Plugins.Cfg.Cfg