[ Home | Main Table Of Contents | Table Of Contents | Keyword Index ]

# cmdr-spec-dsl-private(n) 1.2 doc "Cmdr, a framework for command line parsing and dispatch"

## Name

cmdr-spec-dsl-private - Cmdr - Private Specification Language

## Table Of Contents

## Synopsis

- description text
- input name help script
- interactive
- option name help script
- section word...
- state name help script
- undocumented
- use name

## Description

Welcome to the Cmdr project, written by Andreas Kupries.

For availability please read Cmdr - How To Get The Sources.

This document is for users of the cmdr framework. It introduces the domain-specific language for the specification of privates in detail.

## Related Specification Documents

1. Cmdr - Introduction to the Specification Language

2. Cmdr - Officer Specification Language

3. Cmdr - Private Specification Language

4. Cmdr - Parameter Specification Language

5. Cmdr - Runtime Processing Flow

## Language Reference

The specification of privates is quite easy, with only seven commands. The important parts are found in the parameter specifications, explained in Cmdr - Parameter Specification Language.

description text

  This command declares the help text for the private.

input name help script

  This command adds an input (i.e. positional) parameter to the private, with description help and its specification script of parameter commands as described in Cmdr - Parameter Specification Language.

interactive

  This command activates a mini-shell for this private which will be invoked when required parameters do not have a value after argument extraction and matching.

  By default the only interactive command line shells are associated with the officers.

  The command cmdr::config interactive provided by the package cmdr::config can be used to globally activate this type of shell for all privates.

option name help script

  This command adds an option (i.e. named) parameter to the private, with description help and its specification script of parameter commands as described in Cmdr - Parameter Specification Language.

section word...

  This command places the private into a help section/category, for use by the standard help format by-category (See Cmdr - (Internal) Utilities for help text formatting and setup).

  The section/category is specified as a list of words, each denoting part of the path to the section. This means that the last word is the section of the private, with the preceding words the sections it is nested in.

  Multiple calls are possible and accumulate. In other words, the private can be placed in more than one section/category.

  Note further that privates not put into any section are automatically placed into a generated section named Miscellaneous.

state name help script

  This command adds a state (i.e. hidden) parameter to the private, with description help and its specification script of parameter commands as described in Cmdr - Parameter Specification Language.

undocumented

  This command excludes the private from the generated help.

use name

  This command is the counterpart to common of officers (See Cmdr - Officer Specification Language). It inserts the named block into the specification, executing it in place. As such it expects the contents to be a script of private commands as described in this section.

Please continue reading with Cmdr - Parameter Specification Language.

## Related Documents

1. Cmdr - Introduction to the project

2. Cmdr - License

3. Cmdr - Log of Changes

4. Cmdr - How To Get The Sources

5. Cmdr - The Installer's Guide

6. Cmdr - The Developer's Guide

## Bugs, Ideas, Feedback

Both the package(s) and this documentation will undoubtedly contain bugs and other problems. Please report such at Cmdr Tickets.

Please also report any ideas you may have for enhancements of either package(s) and/or documentation.

## Keywords

arguments, command hierarchy, command line completion, command line handling, command tree, editing command line, help for command line, hierarchy of commands, interactive command shell, optional arguments, options, parameters, processing command line, tree of commands

## Copyright

Copyright © 2013-2016 Andreas Kupries
Copyright © 2013-2016 Documentation, Andreas Kupries