Purpose: discuss the concept of command ''ensemble'' This concept has also been called "major/minor" commands by some people (like myself) who didn't know the fancier name of ensemble. Tcl has several kinds of commands. The first, a simple command like '''[set]''', provides a very simple interface. One passes either one or two arguments. Depending on the number of arguments, set either outputs the value of the variable, or it sets the variable to a value. A slightly more complex variation of this is a command that takes arguments. '''[puts]''' for instance has an optional -nonewline flag as well as an optional output channel and an output string. Next in complexity comes the ensemble. An example of this command would be '''[string]'''. What makes it more complex is that string is an ''umbrella'' name for a variety of related functionality. String is the major ''command'' name, the minor ''subcommand'' names are things like ''bytelength'','''compare''', etc. See TIP http://purl.org/tcl/tip/112.html for a TIP to include support for developing this type of command in Tcl. ---- Since every object command is an ensemble, having support for ensembles as part of the language (presumably coded in C) would make pure Tcl object and megawidget frameworks much more efficient. -- [WHD] ---- [LV] So how do you document extendable ensembles? For instance, let's say we create a new command called xtsil. It's designed to be extendable from either script or some API. The original command's documentation would be xtsil in section n. Now assume that J. Random Programmer (''JRP'') comes along with an implementation of '''xtsil stdev'''. Certainly s/he could contribute the code to the original author for integration. But that may not always work - two people might have alternative implmentations (or even different functional implmentations for the same subcommand name). In some languages, each subcommand gets its own reference doc file, which takes care of this problem (but does result in a LOT of reference docs). ---- [Category Tutorial]