Class ExternalExecution

    • Constructor Detail

      • ExternalExecution

        protected ExternalExecution()
    • Method Detail

      • exec

        public static List<String> exec​(org.apache.commons.exec.CommandLine commandLine)
        Execute the given external command into the context defined by a default ExternalExecution.Config (provided by ExternalExecution.Config.init()).
        Parameters:
        commandLine - the external command to execute.
        Returns:
        a List of console lines written by the external command.
      • exec

        public static List<String> exec​(org.apache.commons.exec.CommandLine commandLine,
                                        ExternalExecution.Config config)
        Execute the given external command into the context defined by the given ExternalExecution.Config.
        Parameters:
        commandLine - the external command to execute.
        config - the configuration that permits to perform the execution of the command with some flexibility.
        Returns:
        a List of console lines written by the external command.