* Renamed clixon-clispec.yang to clixon-autocli.yang

* First version of clixon-autocli.yang semantics
   * Default rules for module exclusion, list-keywords, completion, treeref-state
   * Specialized rules for compress and exclusion of modules
   * See [autocli documentation](https://clixon-docs.readthedocs.io/en/latest/cli.html#autocli)
* Obsoleted and moved autocli config options from clixon-config.yang to clixon-autocli.yang as follows:
   * `CLICON_CLI_GENMODEL`, use: `autocli/module-default=false` instead
      * Removed `clicon_cli_genmodel()`
   * `CLICON_CLI_GENMODEL_TYPE`, use `autocli/list-keyword-default` and compress rules instead)
      * Removed `clicon_cli_genmodel_type()`
   * `CLICON_CLI_GENMODEL_COMPLETION`, use `autocli/completion-default` instead
      * Removed `clicon_cli_genmodel_completion()`
   * `CLICON_CLI_AUTOCLI_EXCLUDE`, use `autocli/rule/operation=exclude` instead
   * `CLICON_CLI_MODEL_TREENAME`, use constant `AUTOCLI_TREENAME` instead
     * Removed `clicon_cli_model_treename()`
* New YANG functions: yang_single_child_type, yang_find_namespace_by_prefix, yang_str2key
* Changed return values of yang_find_prefix_by_namespace
* Merged `cli_cli2xml()` into `cli2xml()`
This commit is contained in:
Olof hagsand 2021-12-28 19:21:52 +01:00
parent dec05e2cae
commit 081e6871b3
45 changed files with 1804 additions and 900 deletions

View file

@ -477,22 +477,22 @@ clicon_conf_restconf(clicon_handle h)
return NULL;
}
/*! Get local YANG specification for Clixon-clispec.yang tree
/*! Get clixon-autocli.yang part of the clixon config tree
*
* That is, get the XML of clixon-config/clispec container of clixon-config.yang
* That is, get the XML of clixon-config/autocli container of clixon-config.yang
* @param[in] h Clicon handle
* @retval x XML tree containing clispec xml node from clixon-clispec.yang
* @retval x XML tree containing clispec xml node from clixon-autoclu.yang
* @code
* cxobj *xclispec = clicon_conf_clispec(h);
* cxobj *xautocli = clicon_conf_autocli(h);
* @endcode
*/
cxobj *
clicon_conf_clispec(clicon_handle h)
clicon_conf_autocli(clicon_handle h)
{
cxobj *xconfig = NULL;
if ((xconfig = clicon_conf_xml(h)) != NULL) /* Get local config */
return xpath_first(xconfig, NULL, "clispec");
return xpath_first(xconfig, NULL, "autocli");
return NULL;
}