Class PeptideShakerCLI

All Implemented Interfaces:
AutoCloseable, Callable

public class PeptideShakerCLI extends PsdbParent implements Callable
A command line interface to run PeptideShaker.
Author:
Marc Vaudel, Harald Barsnes
  • Constructor Details

    • PeptideShakerCLI

      public PeptideShakerCLI()
      Construct a new PeptideShakerCLI runnable. When initialization is successful and the PeptideShakerCLIInputBean is set, calling "run" will start PeptideShaker and write the output files when finished.
  • Method Details

    • setPeptideShakerCLIInputBean

      public void setPeptideShakerCLIInputBean(PeptideShakerCLIInputBean cliInputBean)
      Set the PeptideShakerCLIInputBean.
      Parameters:
      cliInputBean - the PeptideShakerCLIInputBean
    • call

      public Object call()
      Specified by:
      call in interface Callable
    • createProject

      public void createProject() throws IOException, InterruptedException, TimeoutException
      Creates the PeptideShaker project based on the identification files provided in the command line input
      Throws:
      IOException - exception thrown if an error occurs while reading or writing a file
      InterruptedException - exception thrown if a thread is interrupted
      TimeoutException - exception thrown if a process times out
    • closePeptideShaker

      public static void closePeptideShaker(com.compomics.util.experiment.identification.Identification identification) throws IOException, SQLException
      Close the PeptideShaker instance. Closes file connections and deletes temporary files.
      Parameters:
      identification - the identification to close
      Throws:
      IOException - exception thrown whenever an error occurred while writing the object
      SQLException - exception thrown whenever an error occurred while closing the database connection
    • redirectErrorStream

      public static void redirectErrorStream(File aLogFolder)
      Redirects the error stream to the PeptideShaker.log of a given folder.
      Parameters:
      aLogFolder - the folder where to save the log
    • getLogFileMessage

      public static String getLogFileMessage()
      Returns the "see the log file" message. With the path if available.
      Returns:
      the "see the log file" message
    • main

      public static void main(String[] args)
      Starts the launcher by calling the launch method. Use this as the main class in the jar file.
      Parameters:
      args - the command line arguments
    • toString

      public String toString()
      Overrides:
      toString in class Object