-<?xml version="1.0" encoding="iso-8859-1"?>
-<!DOCTYPE html
- PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
-
+<?xml version="1.0" encoding="utf-8"?>
+<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
+ "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
- <title>Class: MCollective::DDL::Base</title>
- <meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />
- <meta http-equiv="Content-Script-Type" content="text/javascript" />
- <link rel="stylesheet" href="../../.././rdoc-style.css" type="text/css" media="screen" />
- <script type="text/javascript">
- // <![CDATA[
-
- function popupCode( url ) {
- window.open(url, "Code", "resizable=yes,scrollbars=yes,toolbar=no,status=no,height=150,width=400")
- }
-
- function toggleCode( id ) {
- if ( document.getElementById )
- elem = document.getElementById( id );
- else if ( document.all )
- elem = eval( "document.all." + id );
- else
- return false;
-
- elemStyle = elem.style;
-
- if ( elemStyle.display != "block" ) {
- elemStyle.display = "block"
- } else {
- elemStyle.display = "none"
- }
-
- return true;
- }
-
- // Make codeblocks hidden by default
- document.writeln( "<style type=\"text/css\">div.method-source-code { display: none }</style>" )
-
- // ]]>
- </script>
-
-</head>
-<body>
-
-
-
- <div id="classHeader">
- <table class="header-table">
- <tr class="top-aligned-row">
- <td><strong>Class</strong></td>
- <td class="class-name-in-header">MCollective::DDL::Base</td>
- </tr>
- <tr class="top-aligned-row">
- <td><strong>In:</strong></td>
- <td>
- <a href="../../../files/lib/mcollective/ddl/base_rb.html">
- lib/mcollective/ddl/base.rb
- </a>
- <br />
- </td>
- </tr>
-
- <tr class="top-aligned-row">
- <td><strong>Parent:</strong></td>
- <td>
- Object
- </td>
- </tr>
- </table>
- </div>
- <!-- banner header -->
-
- <div id="bodyContent">
+ <meta content="text/html; charset=utf-8" http-equiv="Content-Type" />
+ <title>Class: MCollective::DDL::Base</title>
+ <link rel="stylesheet" href="../../rdoc.css" type="text/css" media="screen" />
- <div id="contextContent">
+ <script src="../../js/jquery.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/thickbox-compressed.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/quicksearch.js" type="text/javascript"
+ charset="utf-8"></script>
+ <script src="../../js/darkfish.js" type="text/javascript"
+ charset="utf-8"></script>
- <div id="description">
- <p>
+</head>
+<body class="class">
+
+ <div id="metadata">
+ <div id="file-metadata">
+ <div id="file-list-section" class="section">
+ <h3 class="section-header">In Files</h3>
+ <div class="section-body">
+ <ul>
+
+ <li><a href="../../lib/mcollective/ddl/base_rb.html?TB_iframe=true&height=550&width=785"
+ class="thickbox" title="lib/mcollective/ddl/base.rb">lib/mcollective/ddl/base.rb</a></li>
+
+ </ul>
+ </div>
+ </div>
+
+
+ </div>
+
+ <div id="class-metadata">
+
+ <!-- Parent Class -->
+
+ <div id="parent-class-section" class="section">
+ <h3 class="section-header">Parent</h3>
+
+ <p class="link"><a href="../../Object.html">Object</a></p>
+
+ </div>
+
+
+ <!-- Namespace Contents -->
+
+
+ <!-- Method Quickref -->
+
+ <div id="method-list-section" class="section">
+ <h3 class="section-header">Methods</h3>
+ <ul class="link-list">
+
+ <li><a href="#M000278">::new</a></li>
+
+ <li><a href="#M000283">#findddlfile</a></li>
+
+ <li><a href="#M000279">#help</a></li>
+
+ <li><a href="#M000288">#input</a></li>
+
+ <li><a href="#M000282">#loadddlfile</a></li>
+
+ <li><a href="#M000292">#metadata</a></li>
+
+ <li><a href="#M000290">#output</a></li>
+
+ <li><a href="#M000291">#requires</a></li>
+
+ <li><a href="#M000281">#template_for_plugintype</a></li>
+
+ <li><a href="#M000280">#usage</a></li>
+
+ <li><a href="#M000285">#validate_input_argument</a></li>
+
+ <li><a href="#M000284">#validate_requirements</a></li>
+
+ </ul>
+ </div>
+
+
+ <!-- Included Modules -->
+
+ <div id="includes-section" class="section">
+ <h3 class="section-header">Included Modules</h3>
+ <ul class="link-list">
+
+
+ <li><a class="include" href="../Validator.html">MCollective::Validator</a></li>
+
+
+ </ul>
+ </div>
+
+ </div>
+
+ <div id="project-metadata">
+
+
+ <div id="fileindex-section" class="section project-section">
+ <h3 class="section-header">Files</h3>
+ <ul>
+
+ <li class="file"><a href="../../COPYING.html">COPYING</a></li>
+
+ <li class="file"><a href="../../Gemfile.html">Gemfile</a></li>
+
+ <li class="file"><a href="../../README.html">README</a></li>
+
+ <li class="file"><a href="../../Rakefile.html">Rakefile</a></li>
+
+ <li class="file"><a href="../../etc/client_cfg_dist.html">client.cfg.dist</a></li>
+
+ <li class="file"><a href="../../etc/data-help_erb.html">data-help.erb</a></li>
+
+ <li class="file"><a href="../../etc/discovery-help_erb.html">discovery-help.erb</a></li>
+
+ <li class="file"><a href="../../etc/facts_yaml_dist.html">facts.yaml.dist</a></li>
+
+ <li class="file"><a href="../../etc/metadata-help_erb.html">metadata-help.erb</a></li>
+
+ <li class="file"><a href="../../etc/msg-help_erb.html">msg-help.erb</a></li>
+
+ <li class="file"><a href="../../etc/rpc-help_erb.html">rpc-help.erb</a></li>
+
+ <li class="file"><a href="../../etc/server_cfg_dist.html">server.cfg.dist</a></li>
+
+ <li class="file"><a href="../../etc/ssl/PLACEHOLDER.html">PLACEHOLDER</a></li>
+
+ <li class="file"><a href="../../etc/ssl/clients/PLACEHOLDER.html">PLACEHOLDER</a></li>
+
+ <li class="file"><a href="../../lib/mcollective/generators/templates/action_snippet_erb.html">action_snippet.erb</a></li>
+
+ <li class="file"><a href="../../lib/mcollective/generators/templates/data_input_snippet_erb.html">data_input_snippet.erb</a></li>
+
+ <li class="file"><a href="../../lib/mcollective/generators/templates/ddl_erb.html">ddl.erb</a></li>
+
+ <li class="file"><a href="../../lib/mcollective/generators/templates/plugin_erb.html">plugin.erb</a></li>
+
+ <li class="file"><a href="../../lib/mcollective/locales/en_yml.html">en.yml</a></li>
+
+ <li class="file"><a href="../../mcollective_init.html">mcollective.init</a></li>
+
+ </ul>
+ </div>
+
+
+ <div id="classindex-section" class="section project-section">
+ <h3 class="section-header">Class Index
+ <span class="search-toggle"><img src="../../images/find.png"
+ height="16" width="16" alt="[+]"
+ title="show/hide quicksearch" /></span></h3>
+ <form action="#" method="get" accept-charset="utf-8" class="initially-hidden">
+ <fieldset>
+ <legend>Quicksearch</legend>
+ <input type="text" name="quicksearch" value=""
+ class="quicksearch-field" />
+ </fieldset>
+ </form>
+
+ <ul class="link-list">
+
+ <li><a href="../../MCollective.html">MCollective</a></li>
+
+ <li><a href="../../MCollective/Agent.html">MCollective::Agent</a></li>
+
+ <li><a href="../../MCollective/Agents.html">MCollective::Agents</a></li>
+
+ <li><a href="../../MCollective/Aggregate.html">MCollective::Aggregate</a></li>
+
+ <li><a href="../../MCollective/Aggregate/Base.html">MCollective::Aggregate::Base</a></li>
+
+ <li><a href="../../MCollective/Aggregate/Result.html">MCollective::Aggregate::Result</a></li>
+
+ <li><a href="../../MCollective/Aggregate/Result/Base.html">MCollective::Aggregate::Result::Base</a></li>
+
+ <li><a href="../../MCollective/Aggregate/Result/CollectionResult.html">MCollective::Aggregate::Result::CollectionResult</a></li>
+
+ <li><a href="../../MCollective/Aggregate/Result/NumericResult.html">MCollective::Aggregate::Result::NumericResult</a></li>
+
+ <li><a href="../../MCollective/Application.html">MCollective::Application</a></li>
+
+ <li><a href="../../MCollective/Applications.html">MCollective::Applications</a></li>
+
+ <li><a href="../../MCollective/Cache.html">MCollective::Cache</a></li>
+
+ <li><a href="../../MCollective/Client.html">MCollective::Client</a></li>
+
+ <li><a href="../../MCollective/CodedError.html">MCollective::CodedError</a></li>
+
+ <li><a href="../../MCollective/Config.html">MCollective::Config</a></li>
+
+ <li><a href="../../MCollective/Connector.html">MCollective::Connector</a></li>
+
+ <li><a href="../../MCollective/Connector/Base.html">MCollective::Connector::Base</a></li>
+
+ <li><a href="../../MCollective/DDL.html">MCollective::DDL</a></li>
+
+ <li><a href="../../MCollective/DDL/AgentDDL.html">MCollective::DDL::AgentDDL</a></li>
+
+ <li><a href="../../MCollective/DDL/Base.html">MCollective::DDL::Base</a></li>
+
+ <li><a href="../../MCollective/DDL/DataDDL.html">MCollective::DDL::DataDDL</a></li>
+
+ <li><a href="../../MCollective/DDL/DiscoveryDDL.html">MCollective::DDL::DiscoveryDDL</a></li>
+
+ <li><a href="../../MCollective/DDL/ValidatorDDL.html">MCollective::DDL::ValidatorDDL</a></li>
+
+ <li><a href="../../MCollective/DDLValidationError.html">MCollective::DDLValidationError</a></li>
+
+ <li><a href="../../MCollective/Data.html">MCollective::Data</a></li>
+
+ <li><a href="../../MCollective/Data/Base.html">MCollective::Data::Base</a></li>
+
+ <li><a href="../../MCollective/Data/Result.html">MCollective::Data::Result</a></li>
+
+ <li><a href="../../MCollective/Discovery.html">MCollective::Discovery</a></li>
+
+ <li><a href="../../MCollective/Facts.html">MCollective::Facts</a></li>
+
+ <li><a href="../../MCollective/Facts/Base.html">MCollective::Facts::Base</a></li>
+
+ <li><a href="../../MCollective/Generators.html">MCollective::Generators</a></li>
+
+ <li><a href="../../MCollective/Generators/AgentGenerator.html">MCollective::Generators::AgentGenerator</a></li>
+
+ <li><a href="../../MCollective/Generators/Base.html">MCollective::Generators::Base</a></li>
+
+ <li><a href="../../MCollective/Generators/DataGenerator.html">MCollective::Generators::DataGenerator</a></li>
+
+ <li><a href="../../MCollective/InvalidRPCData.html">MCollective::InvalidRPCData</a></li>
+
+ <li><a href="../../MCollective/Log.html">MCollective::Log</a></li>
+
+ <li><a href="../../MCollective/Logger.html">MCollective::Logger</a></li>
+
+ <li><a href="../../MCollective/Logger/Base.html">MCollective::Logger::Base</a></li>
+
+ <li><a href="../../MCollective/Logger/Console_logger.html">MCollective::Logger::Console_logger</a></li>
+
+ <li><a href="../../MCollective/Logger/File_logger.html">MCollective::Logger::File_logger</a></li>
+
+ <li><a href="../../MCollective/Logger/Syslog_logger.html">MCollective::Logger::Syslog_logger</a></li>
+
+ <li><a href="../../MCollective/Matcher.html">MCollective::Matcher</a></li>
+
+ <li><a href="../../MCollective/Matcher/Parser.html">MCollective::Matcher::Parser</a></li>
+
+ <li><a href="../../MCollective/Matcher/Scanner.html">MCollective::Matcher::Scanner</a></li>
+
+ <li><a href="../../MCollective/Message.html">MCollective::Message</a></li>
+
+ <li><a href="../../MCollective/MissingRPCData.html">MCollective::MissingRPCData</a></li>
+
+ <li><a href="../../MCollective/MsgDoesNotMatchRequestID.html">MCollective::MsgDoesNotMatchRequestID</a></li>
+
+ <li><a href="../../MCollective/MsgTTLExpired.html">MCollective::MsgTTLExpired</a></li>
+
+ <li><a href="../../MCollective/NotTargettedAtUs.html">MCollective::NotTargettedAtUs</a></li>
+
+ <li><a href="../../MCollective/Optionparser.html">MCollective::Optionparser</a></li>
+
+ <li><a href="../../MCollective/PluginManager.html">MCollective::PluginManager</a></li>
+
+ <li><a href="../../MCollective/PluginPackager.html">MCollective::PluginPackager</a></li>
+
+ <li><a href="../../MCollective/PluginPackager/AgentDefinition.html">MCollective::PluginPackager::AgentDefinition</a></li>
+
+ <li><a href="../../MCollective/PluginPackager/StandardDefinition.html">MCollective::PluginPackager::StandardDefinition</a></li>
+
+ <li><a href="../../MCollective/RPC.html">MCollective::RPC</a></li>
+
+ <li><a href="../../MCollective/RPC/ActionRunner.html">MCollective::RPC::ActionRunner</a></li>
+
+ <li><a href="../../MCollective/RPC/Agent.html">MCollective::RPC::Agent</a></li>
+
+ <li><a href="../../MCollective/RPC/Audit.html">MCollective::RPC::Audit</a></li>
+
+ <li><a href="../../MCollective/RPC/Client.html">MCollective::RPC::Client</a></li>
+
+ <li><a href="../../MCollective/RPC/Helpers.html">MCollective::RPC::Helpers</a></li>
+
+ <li><a href="../../MCollective/RPC/Progress.html">MCollective::RPC::Progress</a></li>
+
+ <li><a href="../../MCollective/RPC/Reply.html">MCollective::RPC::Reply</a></li>
+
+ <li><a href="../../MCollective/RPC/Request.html">MCollective::RPC::Request</a></li>
+
+ <li><a href="../../MCollective/RPC/Result.html">MCollective::RPC::Result</a></li>
+
+ <li><a href="../../MCollective/RPC/Stats.html">MCollective::RPC::Stats</a></li>
+
+ <li><a href="../../MCollective/RPCAborted.html">MCollective::RPCAborted</a></li>
+
+ <li><a href="../../MCollective/RPCError.html">MCollective::RPCError</a></li>
+
+ <li><a href="../../MCollective/Registration.html">MCollective::Registration</a></li>
+
+ <li><a href="../../MCollective/Registration/Base.html">MCollective::Registration::Base</a></li>
+
+ <li><a href="../../MCollective/Runner.html">MCollective::Runner</a></li>
+
+ <li><a href="../../MCollective/RunnerStats.html">MCollective::RunnerStats</a></li>
+
+ <li><a href="../../MCollective/SSL.html">MCollective::SSL</a></li>
+
+ <li><a href="../../MCollective/Security.html">MCollective::Security</a></li>
+
+ <li><a href="../../MCollective/Security/Base.html">MCollective::Security::Base</a></li>
+
+ <li><a href="../../MCollective/SecurityValidationFailed.html">MCollective::SecurityValidationFailed</a></li>
+
+ <li><a href="../../MCollective/Shell.html">MCollective::Shell</a></li>
+
+ <li><a href="../../MCollective/Translatable.html">MCollective::Translatable</a></li>
+
+ <li><a href="../../MCollective/UnixDaemon.html">MCollective::UnixDaemon</a></li>
+
+ <li><a href="../../MCollective/UnknownRPCAction.html">MCollective::UnknownRPCAction</a></li>
+
+ <li><a href="../../MCollective/UnknownRPCError.html">MCollective::UnknownRPCError</a></li>
+
+ <li><a href="../../MCollective/Util.html">MCollective::Util</a></li>
+
+ <li><a href="../../MCollective/Validator.html">MCollective::Validator</a></li>
+
+ <li><a href="../../MCollective/ValidatorError.html">MCollective::ValidatorError</a></li>
+
+ <li><a href="../../MCollective/WindowsDaemon.html">MCollective::WindowsDaemon</a></li>
+
+ <li><a href="../../Array.html">Array</a></li>
+
+ <li><a href="../../Dir.html">Dir</a></li>
+
+ <li><a href="../../Object.html">Object</a></li>
+
+ <li><a href="../../String.html">String</a></li>
+
+ <li><a href="../../Symbol.html">Symbol</a></li>
+
+ </ul>
+ <div id="no-class-search-results" style="display: none;">No matching classes.</div>
+ </div>
+
+
+ </div>
+ </div>
+
+ <div id="documentation">
+ <h1 class="class">MCollective::DDL::Base</h1>
+
+ <div id="description">
+ <p>
The base class for all kinds of <a href="../DDL.html">DDL</a> files. <a
href="../DDL.html">DDL</a> files when run gets parsed and builds up a hash
of the basic primitive types, ideally restricted so it can be converted to
</p>
<p>
The Hash being built should be stored in @entities, the format is generally
-not prescribed but there‘s a definite feel to how <a
+not prescribed but there’s a definite feel to how <a
href="../DDL.html">DDL</a> files look so study the agent and discovery ones
to see how the structure applies to very different use cases.
</p>
<p>
For every plugin type you should have a single word name - that corresponds
to the directory in the libdir where these plugins live. If you need
-anything above and beyond ‘<a
-href="Base.html#M000177">metadata</a>’ in your plugin <a
+anything above and beyond ‘metadata’ in your plugin <a
href="../DDL.html">DDL</a> then add a PlugintypeDDL class here and add your
specific behaviors to those.
</p>
- </div>
-
-
- </div>
-
- <div id="method-list">
- <h3 class="section-bar">Methods</h3>
-
- <div class="name-list">
- <a href="#M000171">findddlfile</a>
- <a href="#M000167">help</a>
- <a href="#M000174">input</a>
- <a href="#M000170">loadddlfile</a>
- <a href="#M000177">metadata</a>
- <a href="#M000166">new</a>
- <a href="#M000175">output</a>
- <a href="#M000176">requires</a>
- <a href="#M000169">template_for_plugintype</a>
- <a href="#M000168">usage</a>
- <a href="#M000173">validate_input_argument</a>
- <a href="#M000172">validate_requirements</a>
- </div>
- </div>
-
- </div>
-
-
- <!-- if includes -->
- <div id="includes">
- <h3 class="section-bar">Included Modules</h3>
-
- <div id="includes-list">
- <span class="include-name"><a href="../Translatable.html">Translatable</a></span>
- </div>
- </div>
-
- <div id="section">
-
-
-
-
-
- <div id="attribute-list">
- <h3 class="section-bar">Attributes</h3>
-
- <div class="name-list">
- <table>
- <tr class="top-aligned-row context-row">
- <td class="context-item-name">entities</td>
- <td class="context-item-value"> [R] </td>
- <td class="context-item-desc"></td>
- </tr>
- <tr class="top-aligned-row context-row">
- <td class="context-item-name">meta</td>
- <td class="context-item-value"> [R] </td>
- <td class="context-item-desc"></td>
- </tr>
- <tr class="top-aligned-row context-row">
- <td class="context-item-name">pluginname</td>
- <td class="context-item-value"> [R] </td>
- <td class="context-item-desc"></td>
- </tr>
- <tr class="top-aligned-row context-row">
- <td class="context-item-name">plugintype</td>
- <td class="context-item-value"> [R] </td>
- <td class="context-item-desc"></td>
- </tr>
- <tr class="top-aligned-row context-row">
- <td class="context-item-name">requirements</td>
- <td class="context-item-value"> [R] </td>
- <td class="context-item-desc"></td>
- </tr>
- <tr class="top-aligned-row context-row">
- <td class="context-item-name">usage</td>
- <td class="context-item-value"> [R] </td>
- <td class="context-item-desc"></td>
- </tr>
- </table>
- </div>
- </div>
-
-
-
- <!-- if method_list -->
- <div id="methods">
- <h3 class="section-bar">Public Class methods</h3>
-
- <div id="method-M000166" class="method-detail">
- <a name="M000166"></a>
-
- <div class="method-heading">
- <a href="#M000166" class="method-signature">
- <span class="method-name">new</span><span class="method-args">(plugin, plugintype=:agent, loadddl=true)</span>
- </a>
- </div>
-
- <div class="method-description">
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000166-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000166-source">
+ </div>
+
+ <!-- Constants -->
+
+
+ <!-- Attributes -->
+
+ <div id="attribute-method-details" class="method-section section">
+ <h3 class="section-header">Attributes</h3>
+
+
+ <div id="meta-attribute-method" class="method-detail">
+ <a name="meta"></a>
+
+ <div class="method-heading attribute-method-heading">
+ <span class="method-name">meta</span><span
+ class="attribute-access-type">[R]</span>
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+ </div>
+ </div>
+
+ <div id="entities-attribute-method" class="method-detail">
+ <a name="entities"></a>
+
+ <div class="method-heading attribute-method-heading">
+ <span class="method-name">entities</span><span
+ class="attribute-access-type">[R]</span>
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+ </div>
+ </div>
+
+ <div id="pluginname-attribute-method" class="method-detail">
+ <a name="pluginname"></a>
+
+ <div class="method-heading attribute-method-heading">
+ <span class="method-name">pluginname</span><span
+ class="attribute-access-type">[R]</span>
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+ </div>
+ </div>
+
+ <div id="plugintype-attribute-method" class="method-detail">
+ <a name="plugintype"></a>
+
+ <div class="method-heading attribute-method-heading">
+ <span class="method-name">plugintype</span><span
+ class="attribute-access-type">[R]</span>
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+ </div>
+ </div>
+
+ <div id="usage-attribute-method" class="method-detail">
+ <a name="usage"></a>
+
+ <div class="method-heading attribute-method-heading">
+ <span class="method-name">usage</span><span
+ class="attribute-access-type">[R]</span>
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+ </div>
+ </div>
+
+ <div id="requirements-attribute-method" class="method-detail">
+ <a name="requirements"></a>
+
+ <div class="method-heading attribute-method-heading">
+ <span class="method-name">requirements</span><span
+ class="attribute-access-type">[R]</span>
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+ </div>
+ </div>
+
+ </div>
+
+
+ <!-- Methods -->
+
+ <div id="public-class-method-details" class="method-section section">
+ <h3 class="section-header">Public Class Methods</h3>
+
+
+ <div id="new-method" class="method-detail ">
+ <a name="M000278"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">new</span><span
+ class="method-args">(plugin, plugintype=:agent, loadddl=true)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+
+
+ <div class="method-source-code"
+ id="new-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 24</span>
24: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">initialize</span>(<span class="ruby-identifier">plugin</span>, <span class="ruby-identifier">plugintype</span>=<span class="ruby-identifier">:agent</span>, <span class="ruby-identifier">loadddl</span>=<span class="ruby-keyword kw">true</span>)
31: <span class="ruby-ivar">@requirements</span> = {}
32:
33: <span class="ruby-identifier">loadddlfile</span> <span class="ruby-keyword kw">if</span> <span class="ruby-identifier">loadddl</span>
-34: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <h3 class="section-bar">Public Instance methods</h3>
-
- <div id="method-M000171" class="method-detail">
- <a name="M000171"></a>
-
- <div class="method-heading">
- <a href="#M000171" class="method-signature">
- <span class="method-name">findddlfile</span><span class="method-args">(ddlname=nil, ddltype=nil)</span>
- </a>
- </div>
-
- <div class="method-description">
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000171-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000171-source">
+34: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ </div>
+
+ <div id="public-instance-method-details" class="method-section section">
+ <h3 class="section-header">Public Instance Methods</h3>
+
+
+ <div id="findddlfile-method" class="method-detail ">
+ <a name="M000283"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">findddlfile</span><span
+ class="method-args">(ddlname=nil, ddltype=nil)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+
+
+ <div class="method-source-code"
+ id="findddlfile-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 89</span>
89: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">findddlfile</span>(<span class="ruby-identifier">ddlname</span>=<span class="ruby-keyword kw">nil</span>, <span class="ruby-identifier">ddltype</span>=<span class="ruby-keyword kw">nil</span>)
98: <span class="ruby-keyword kw">end</span>
99: <span class="ruby-keyword kw">end</span>
100: <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">false</span>
-101: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000167" class="method-detail">
- <a name="M000167"></a>
-
- <div class="method-heading">
- <a href="#M000167" class="method-signature">
- <span class="method-name">help</span><span class="method-args">(template=nil)</span>
- </a>
- </div>
-
- <div class="method-description">
- <p>
-Generates <a href="Base.html#M000167">help</a> using the template based on
-the data created with <a href="Base.html#M000177">metadata</a> and <a
-href="Base.html#M000174">input</a>.
+101: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="help-method" class="method-detail ">
+ <a name="M000279"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">help</span><span
+ class="method-args">(template=nil)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Generates help using the template based on the data created with metadata
+and input.
</p>
<p>
If no template name is provided one will be chosen based on the plugin
be loaded either from the config dir and if that does not exist, default to
/etc/mcollective
</p>
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000167-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000167-source">
+
+
+
+ <div class="method-source-code"
+ id="help-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 44</span>
44: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">help</span>(<span class="ruby-identifier">template</span>=<span class="ruby-keyword kw">nil</span>)
58:
59: <span class="ruby-identifier">erb</span> = <span class="ruby-constant">ERB</span>.<span class="ruby-identifier">new</span>(<span class="ruby-identifier">template</span>, <span class="ruby-value">0</span>, <span class="ruby-value str">'%'</span>)
60: <span class="ruby-identifier">erb</span>.<span class="ruby-identifier">result</span>(<span class="ruby-identifier">binding</span>)
-61: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000174" class="method-detail">
- <a name="M000174"></a>
-
- <div class="method-heading">
- <a href="#M000174" class="method-signature">
- <span class="method-name">input</span><span class="method-args">(argument, properties)</span>
- </a>
- </div>
-
- <div class="method-description">
- <p>
-Registers an <a href="Base.html#M000174">input</a> argument for a given
-action
+61: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="input-method" class="method-detail ">
+ <a name="M000288"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">input</span><span
+ class="method-args">(argument, properties)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Registers an input argument for a given action
</p>
<p>
See the documentation for action for how to use this
</p>
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000174-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000174-source">
+
+
+
+ <div class="method-source-code"
+ id="input-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 153</span>
153: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">input</span>(<span class="ruby-identifier">argument</span>, <span class="ruby-identifier">properties</span>)
178:
179: <span class="ruby-ivar">@entities</span>[<span class="ruby-identifier">entity</span>][<span class="ruby-identifier">:input</span>][<span class="ruby-identifier">argument</span>][<span class="ruby-identifier">:list</span>] = <span class="ruby-identifier">properties</span>[<span class="ruby-identifier">:list</span>]
180: <span class="ruby-keyword kw">end</span>
-181: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000170" class="method-detail">
- <a name="M000170"></a>
-
- <div class="method-heading">
- <a href="#M000170" class="method-signature">
- <span class="method-name">loadddlfile</span><span class="method-args">()</span>
- </a>
- </div>
-
- <div class="method-description">
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000170-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000170-source">
+181: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="loadddlfile-method" class="method-detail ">
+ <a name="M000282"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">loadddlfile</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+
+
+ <div class="method-source-code"
+ id="loadddlfile-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 81</span>
81: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">loadddlfile</span>
84: <span class="ruby-keyword kw">else</span>
85: <span class="ruby-identifier">raise_code</span>(<span class="ruby-identifier">:PLMC40</span>, <span class="ruby-value str">"Can't find DDL for %{type} plugin '%{name}'"</span>, <span class="ruby-identifier">:debug</span>, <span class="ruby-identifier">:type</span> =<span class="ruby-operator">></span> <span class="ruby-ivar">@plugintype</span>, <span class="ruby-identifier">:name</span> =<span class="ruby-operator">></span> <span class="ruby-ivar">@pluginname</span>)
86: <span class="ruby-keyword kw">end</span>
-87: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000177" class="method-detail">
- <a name="M000177"></a>
-
- <div class="method-heading">
- <a href="#M000177" class="method-signature">
- <span class="method-name">metadata</span><span class="method-args">(meta)</span>
- </a>
- </div>
-
- <div class="method-description">
- <p>
+87: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="metadata-method" class="method-detail ">
+ <a name="M000292"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">metadata</span><span
+ class="method-args">(meta)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
Registers meta data for the introspection hash
</p>
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000177-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000177-source">
+
+
+
+ <div class="method-source-code"
+ id="metadata-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 215</span>
215: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">metadata</span>(<span class="ruby-identifier">meta</span>)
218: <span class="ruby-keyword kw">end</span>
219:
220: <span class="ruby-ivar">@meta</span> = <span class="ruby-identifier">meta</span>
-221: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000175" class="method-detail">
- <a name="M000175"></a>
-
- <div class="method-heading">
- <a href="#M000175" class="method-signature">
- <span class="method-name">output</span><span class="method-args">(argument, properties)</span>
- </a>
- </div>
-
- <div class="method-description">
- <p>
-Registers an <a href="Base.html#M000175">output</a> argument for a given
-action
+221: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="output-method" class="method-detail ">
+ <a name="M000290"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">output</span><span
+ class="method-args">(argument, properties)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+Registers an output argument for a given action
</p>
<p>
See the documentation for action for how to use this
</p>
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000175-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000175-source">
+
+
+
+ <div class="method-source-code"
+ id="output-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 186</span>
186: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">output</span>(<span class="ruby-identifier">argument</span>, <span class="ruby-identifier">properties</span>)
193: <span class="ruby-ivar">@entities</span>[<span class="ruby-identifier">action</span>][<span class="ruby-identifier">:output</span>][<span class="ruby-identifier">argument</span>] = {<span class="ruby-identifier">:description</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">properties</span>[<span class="ruby-identifier">:description</span>],
194: <span class="ruby-identifier">:display_as</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">properties</span>[<span class="ruby-identifier">:display_as</span>],
195: <span class="ruby-identifier">:default</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">properties</span>[<span class="ruby-identifier">:default</span>]}
-196: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000176" class="method-detail">
- <a name="M000176"></a>
-
- <div class="method-heading">
- <a href="#M000176" class="method-signature">
- <span class="method-name">requires</span><span class="method-args">(requirement)</span>
- </a>
- </div>
-
- <div class="method-description">
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000176-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000176-source">
+196: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="requires-method" class="method-detail ">
+ <a name="M000291"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">requires</span><span
+ class="method-args">(requirement)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+
+
+ <div class="method-source-code"
+ id="requires-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 198</span>
198: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">requires</span>(<span class="ruby-identifier">requirement</span>)
209: <span class="ruby-keyword kw">end</span>
210:
211: <span class="ruby-identifier">validate_requirements</span>
-212: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000169" class="method-detail">
- <a name="M000169"></a>
-
- <div class="method-heading">
- <a href="#M000169" class="method-signature">
- <span class="method-name">template_for_plugintype</span><span class="method-args">()</span>
- </a>
- </div>
-
- <div class="method-description">
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000169-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000169-source">
+212: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="template-for-plugintype-method" class="method-detail ">
+ <a name="M000281"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">template_for_plugintype</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+
+
+ <div class="method-source-code"
+ id="template-for-plugintype-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 67</span>
67: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">template_for_plugintype</span>
76: <span class="ruby-keyword kw">return</span> <span class="ruby-value str">"metadata-help.erb"</span>
77: <span class="ruby-keyword kw">end</span>
78: <span class="ruby-keyword kw">end</span>
-79: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000168" class="method-detail">
- <a name="M000168"></a>
-
- <div class="method-heading">
- <a href="#M000168" class="method-signature">
- <span class="method-name">usage</span><span class="method-args">(usage_text)</span>
- </a>
- </div>
-
- <div class="method-description">
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000168-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000168-source">
+79: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="usage-method" class="method-detail ">
+ <a name="M000280"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">usage</span><span
+ class="method-args">(usage_text)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+
+
+ <div class="method-source-code"
+ id="usage-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 63</span>
63: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">usage</span>(<span class="ruby-identifier">usage_text</span>)
64: <span class="ruby-ivar">@usage</span> = <span class="ruby-identifier">usage_text</span>
-65: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000173" class="method-detail">
- <a name="M000173"></a>
-
- <div class="method-heading">
- <a href="#M000173" class="method-signature">
- <span class="method-name">validate_input_argument</span><span class="method-args">(input, key, argument)</span>
- </a>
- </div>
-
- <div class="method-description">
- <p>
-validate strings, lists and booleans, we‘ll add more types of
+65: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="validate-input-argument-method" class="method-detail ">
+ <a name="M000285"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">validate_input_argument</span><span
+ class="method-args">(input, key, argument)</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p>
+validate strings, lists and booleans, we’ll add more types of
validators when all the use cases are clear
</p>
<p>
:string can have maxlength and regex. A maxlength of 0 will bypasss checks
:list has a array of valid values
</p>
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000173-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000173-source">
+
+
+
+ <div class="method-source-code"
+ id="validate-input-argument-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 127</span>
127: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">validate_input_argument</span>(<span class="ruby-identifier">input</span>, <span class="ruby-identifier">key</span>, <span class="ruby-identifier">argument</span>)
145: <span class="ruby-keyword kw">return</span> <span class="ruby-keyword kw">true</span>
146: <span class="ruby-keyword kw">rescue</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">e</span>
147: <span class="ruby-constant">DDL</span>.<span class="ruby-identifier">validation_fail!</span>(<span class="ruby-identifier">:PLMC21</span>, <span class="ruby-value str">"Cannot validate input '%{input}': %{error}"</span>, <span class="ruby-identifier">:debug</span>, <span class="ruby-identifier">:input</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">key</span>, <span class="ruby-identifier">:error</span> =<span class="ruby-operator">></span> <span class="ruby-identifier">e</span>.<span class="ruby-identifier">to_s</span>)
-148: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
-
- <div id="method-M000172" class="method-detail">
- <a name="M000172"></a>
-
- <div class="method-heading">
- <a href="#M000172" class="method-signature">
- <span class="method-name">validate_requirements</span><span class="method-args">()</span>
- </a>
- </div>
-
- <div class="method-description">
- <p><a class="source-toggle" href="#"
- onclick="toggleCode('M000172-source');return false;">[Source]</a></p>
- <div class="method-source-code" id="M000172-source">
+148: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+
+ </div>
+
+
+ <div id="validate-requirements-method" class="method-detail ">
+ <a name="M000284"></a>
+
+ <div class="method-heading">
+
+ <span class="method-name">validate_requirements</span><span
+ class="method-args">()</span>
+ <span class="method-click-advice">click to toggle source</span>
+
+ </div>
+
+ <div class="method-description">
+
+ <p class="missing-docs">(Not documented)</p>
+
+
+
+ <div class="method-source-code"
+ id="validate-requirements-source">
<pre>
<span class="ruby-comment cmt"># File lib/mcollective/ddl/base.rb, line 103</span>
103: <span class="ruby-keyword kw">def</span> <span class="ruby-identifier">validate_requirements</span>
113: <span class="ruby-keyword kw">end</span>
114:
115: <span class="ruby-keyword kw">true</span>
-116: <span class="ruby-keyword kw">end</span>
-</pre>
- </div>
- </div>
- </div>
+116: <span class="ruby-keyword kw">end</span></pre>
+ </div>
+
+ </div>
+
+ </div>
- </div>
+
+ </div>
+
+ </div>
- </div>
+ <div id="rdoc-debugging-section-dump" class="debugging-section">
+
+ <p>Disabled; run with --debug to generate this.</p>
+
+ </div>
-<div id="validator-badges">
- <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
-</div>
+ <div id="validator-badges">
+ <p><small><a href="http://validator.w3.org/check/referer">[Validate]</a></small></p>
+ <p><small>Generated with the <a href="http://deveiate.org/projects/Darkfish-Rdoc/">Darkfish
+ Rdoc Generator</a> 1.1.6</small>.</p>
+ </div>
</body>
-</html>
\ No newline at end of file
+</html>
+