Class SynopsisHelpGenerator

  • All Implemented Interfaces:
    io.bootique.help.HelpGenerator

    public class SynopsisHelpGenerator
    extends io.bootique.help.DefaultHelpGenerator
    A generator of command-line help that displays the synopsis in addition to the other sections provided by DefaultHelpGenerator.
    Since:
    15.0
    Version:
    17.0 2020-01-04 14:41:57
    Author:
    Stéphane GALLAND
    Maven Group Id:
    org.arakhne.afc.bootique
    Maven Artifact Id:
    bootique-synopsishelp
    • Constructor Detail

      • SynopsisHelpGenerator

        public SynopsisHelpGenerator​(io.bootique.meta.application.ApplicationMetadata metadata,
                                     String argumentSynopsis,
                                     String detailedDescription,
                                     int lineWidth)
        Constructor.
        Parameters:
        metadata - the metadata of the application.
        argumentSynopsis - the synopsis of the arguments. If null, the default description is used. If it is an empty string, no argument description is displayed.
        detailedDescription - the detailed description of the application.
        lineWidth - the width of a console line.
    • Method Detail

      • getApplicationMetadata

        protected io.bootique.meta.application.ApplicationMetadata getApplicationMetadata()
        Replies the description of the application.
        Returns:
        the metadata.
      • append

        public void append​(Appendable out)
        Specified by:
        append in interface io.bootique.help.HelpGenerator
        Overrides:
        append in class io.bootique.help.DefaultHelpGenerator
      • printSynopsis

        protected void printSynopsis​(io.bootique.help.HelpAppender out,
                                     String name,
                                     String argumentSynopsis)
        Print the synopsis of the command.
        Parameters:
        out - the output receiver.
        name - the name of the command.
        argumentSynopsis - the synopsis of the arguments.
      • printDetailedDescription

        protected void printDetailedDescription​(SynopsisHelpGenerator.SynopsisHelpAppender out,
                                                String detailedDescription)
        Print the detailed description of the command.
        Parameters:
        out - the output receiver.
        detailedDescription - the detailed description of the application.