h$j      !"#$%&'()*+,-./0123456789:;<=>?@ABC9Application library for building interactive console CLIs(c) Erick Gonzalez, 2017-2018BSD3erick@codemonkeylabs.deNone #$>?%structured-cliAn alias type for the case where CommandsT wraps IO only (i.e. no state, etc)structured-cliThe  transformer monad is the key to building a CLI tree. It is meant to be used as a transformer wrapping an application specific "user" monad (for example, a D monad encapsulating application state). This monad is executed _once_ upon calling 8 to build the command tree. Keep in mind however that any parsers or actions used in any given command all run in the "user" monad and unlike the process of building the command tree, they will be called multiple times as the user navigates the CLI at runtime. Each  monadic action corresponds to a single "node" (a.k.a. command) in the CLI. Succesive actions simply add commands to the current "level". It is possible to "nest" a new level to a command by using the + operator. When properly indented (see example code above) it provides a pretty self explanatory way to build the CLI tree. structured-cliCLI Settings provided upon launching the CLI. It is recommended to modify the settings provided by the E instance: i.e:  def { getBanner = "My CLI" }  that way you can use for example the default exception handler which should suit usual needs, etc. structured-cliAn optional filename to activate and store the CLI command history functionstructured-cli1Text to display upon start of the CLI applicationstructured-cliPrompt characters to display to the right of the current command "stack"structured-cli)Disable prompt for use with batch scriptsstructured-cliException handlerstructured-cli-There is no need to concern oneself with the  type unless one is writing a custom parser, which should actually be rarer than not.structured-cliParsing provided input doesnt match this command. The difference between  and  is a fine but important one. Failure should be used for example when a command keyword is correct but a required parameter is invalid or contains an error for example. A  should be exclusively used when a command keyword does not correspond to the given inputstructured-cli=Output (parsed) value to be fed to the command action handlerstructured-cli6Part of the string matched during parsing of a commandstructured-cliRemaining input datastructured-cliList of possible completions along with a corresponding help stringstructured-cliRemaining input datastructured-cli>A message string containing a possible hint for correct useagestructured-cliRemaining input datastructured-cliA  is a function to which a parsed string is given in order to perform any checks for validity that may be applicable, or even transforming the argument if necessary. Note that the validator runs in the "user" monad structured-cliThe   type contains the internal representation of a command. Normally there is no need to be concerned with it other than perhaps passing it opaquely to any utility parsers (like 5+ for example), when writing a custom parser!structured-cliAn ! is returned as the result of a command handler provided by the user and it instructs the CLI of any changes in the CLI state"structured-cliThe command executed is "entered" into, creating a new CLI level.#structured-cliDo not enter a new level.$structured-cli3Reset the CLI state up to a given number of levels.%structured-cli4Go back up all the way to the top (root) of the CLI.+structured-clithe CommandsT "nest" operation. It adds a new deeper CLI level to the command on the left side with the commands on the right side, for example: ' activate >+ do foo bar baz 6 Would result in the following CLI command structure: > activate activate > ?- foo ..- bar ..- baz ..,structured-cliBuild a command node that is always active and takes no parameters-structured-cliA variation of , that allows for "disabling" the command at runtime by running the given "enable" monadic action (as always in the "user" monad) to check if the command should be displayed as an option and/or accepted or not..structured-cliBuild a command node that takes one parameter (delimited by space). The parsed parameter is fed to the validator monadic function (in the "user" monad) and the resulting value if any is fed in turn as an argument to the handler action (also in the "user" monad)./structured-cliA variation of . that allows for "disabling" the command at runtime by running the given "enable" monadic action (as always in the "user" monad) to check if the command should be displayed as an option and/or accepted or not.0structured-cliCreate a command using a custom parser, providing thus complete flexibility1structured-cliA utility action to reset the CLI tree to the root node . Equivalent to  return ToRoot2structured-cliA utility action to "leave" the current CLI level. Equivalent to return $ LevelUp 13structured-cli?A utility action to "nest" into a new CLI level. Equivalent to return NewLevel4structured-cliA utility action to leave the current CLI level untouched. Equivalent to return NoAction5structured-cliA utility parser that reads an input and parses a command label. It can be used as part of custom parsers to first read the command keyword before parsing any arguments etc.6structured-cliA utility parser that reads an input and parses any of the provided possibilities as a parameter for the command node using this parser (see provided example.hs)8structured-cliLaunches the CLI application. It doesn't normally return unless an exception is thrown or if it runs out of input in batch mode. Normal return value is that returned by the CommandsT action that built the tree. Remember that   is an instance of E,structured-cliCommand keywordstructured-cliHelp text for this commandstructured-cli!Action in the "user" monad (i.e. return NewLevel)-structured-cliCommand keywordstructured-cliHelp text for this commandstructured-cli!Enable action in the "user" monadstructured-cli!Action in the "user" monad (i.e. return NewLevel).structured-cliCommand keywordstructured-cli;Help text for this command (including argument description)structured-cli'Monadic validator (in the "user" monad)structured-cli7Handling action. Takes the validator output as argument/structured-cliCommand keywordstructured-cli;Help text for this command (including argument description)structured-cli'Monadic validator (in the "user" monad)structured-cli!Enable action in the "user" monadstructured-cli7Handling action. Takes the validator output as argument0structured-cliCommand keywordstructured-cliHelp text for this commandstructured-cli(Custom parser (runs in the "user" monad)structured-cli!Enable action in the "user" monadstructured-cli7Handling action. Takes the validator output as argument9  !"#$%&'()*+,-./0123456789!"#$% &  +,-02'()*534./7681F9        !"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGH-structured-cli-2.7.0.1-BuJaStTAvA86cth8GXELlDSystem.Console.StructuredCLICommands CommandsT runCommandsT CLIExceptionExit InternalError SyntaxErrorUndecisiveInput HelpRequestedInvalidOperationSettings getHistory getBanner getPromptisBatchhandleException ParseResultDonePartialFailNoMatch getOutputgetDoneMatchedgetDoneRemaininggetPartialHintsgetPartialRemaininggetFailMessagegetFailRemaining ValidatorParserNodeActionNewLevelNoActionLevelUpToRootHandler isCompleted isIncomplete isNoResultisFailed>+commandcommand'paramparam'customtopexitnewLevelnoAction labelParser parseOneOf paramParserrunCLI $fDefault-> $fDefault->0$fDefaultSettings$fMonadIOCommandsT$fMonadTransCommandsT$fMonadCommandsT$fApplicativeCommandsT$fFunctorCommandsT$fShowCLIException$fShowParseResult $fShowActionState1data-default-class-0.1.2.0-IIN1s3V8yfYEDHe5yjxXHVData.Default.ClassDefault-.-