Class PepperStarter


  • public class PepperStarter
    extends Object
    The main class to start Pepper from the Console.
    Author:
    Florian
    • Field Detail

      • FILE_ENDING_PEPPER

        public static final String FILE_ENDING_PEPPER
        This is the default ending of a Pepper workflow description file.
        See Also:
        Constant Field Values
      • CONSOLE_WIDTH

        public static final int CONSOLE_WIDTH
        The standard width of the output console of Pepper.
        See Also:
        Constant Field Values
      • CONSOLE_WIDTH_120

        public static final int CONSOLE_WIDTH_120
        The width of the output console of Pepper.
        See Also:
        Constant Field Values
      • CONSOLE_WIDTH_80

        public static final int CONSOLE_WIDTH_80
        The width of the output console of Pepper, when os is windows.
        See Also:
        Constant Field Values
    • Constructor Detail

      • PepperStarter

        public PepperStarter​(PepperConnector pepperConnector)
        Initializes an instance of PepperStarter.
        Parameters:
        pepperConnector - a PepperConnector object via which the PepperStarter communicates with a Pepper instance
    • Method Detail

      • help

        public String help()
        Help to all commands for Pepper
        Returns:
      • list

        public String list()
        Returns a String containing a table with information about all available Pepper modules.
        Returns:
      • list

        public String list​(String moduleSelector)
        Returns a String containing a table with information about the passed Pepper module.
        Parameters:
        moduleSelector - either the name of a module or the number of a module
        Returns:
      • start_osgi

        public String start_osgi()
        Starts the OSGi environment.
      • stop_osgi

        public String stop_osgi()
        Stops the OSGi environment.
      • clean

        public String clean()
        Cleans the current Pepper instance and especially removes the OSGi workspace, to set up a new one.
        Returns:
      • debug

        public String debug()
        Switches on/off the debug mode.
        Returns:
      • osgi

        public String osgi()
        Opens the OSGi console via an OSGiConsole object and delegates to it.
      • convert

        public void convert​(String workFlowPath)
        Loads the passed workflow description file and starts the conversion.
        Parameters:
        workFlowPath -
      • installAndStart

        public String installAndStart​(List<String> params)
        Installs and starts a new Pepper module(s).
      • remove

        public String remove​(List<String> params)
        Removes an existing Pepper module(s).
      • selfTest

        @Deprecated
        public String selfTest()
        Deprecated.
        Calls PepperModule.isReadyToStart() for all Pepper modules.
        Returns:
      • fitness

        public String fitness()
        Returns a fitness report as a String. This report contains a fitness value for each module and if a module is not fit, the report is expanded for a detailed report containing one value for each fitness feature.
        Returns:
        fitness report
      • conf

        public String conf()
        Returns:
        a String containing all Pepper configurations formatted as table
      • runInteractive

        public void runInteractive()
        Starts the interactive console of Pepper.
      • getVersion

        public static String getVersion()
        Resolves the current Pepper version from a file named version.properties in the pepper-lib jar file.
        Returns:
        the current Pepper version