Class WorkflowFileNaming


  • public class WorkflowFileNaming
    extends FileNaming
    This class contains methods to create workflow data file names.
    Since:
    2.0
    Author:
    Laurent Jourdren
    • Method Detail

      • filePrefix

        public static String filePrefix​(fr.ens.biologie.genomique.eoulsan.core.workflow.StepOutputPort port)
        Create the prefix of a filename.
        Parameters:
        port - output port that generate the file
        Returns:
        a String with the prefix of the file
      • glob

        public static String glob​(fr.ens.biologie.genomique.eoulsan.core.workflow.StepOutputPort port)
        Create the glob for the port.
        Returns:
        a glob in a string
      • fileMiddle

        public static String fileMiddle​(fr.ens.biologie.genomique.eoulsan.core.workflow.StepOutputPort port,
                                        fr.ens.biologie.genomique.eoulsan.core.workflow.DataElement data,
                                        int fileIndex)
        Create the middle of a filename.
        Parameters:
        port - output port that generate the file
        data - the data
        fileIndex - file index
        Returns:
        a String with the suffix of a file
      • fileMiddle

        public static String fileMiddle​(fr.ens.biologie.genomique.eoulsan.core.workflow.StepOutputPort port,
                                        String dataName,
                                        int fileIndex,
                                        int part)
        Create the middle of a filename.
        Parameters:
        port - output port that generate the file
        fileIndex - file index
        part - file part
        Returns:
        a String with the suffix of a file
      • fileSuffix

        public static String fileSuffix​(fr.ens.biologie.genomique.eoulsan.core.workflow.StepOutputPort port)
        Create the suffix of a filename.
        Parameters:
        port - a workflow port
        Returns:
        a string with the suffix that correspond to the filename
      • filename

        public static String filename​(fr.ens.biologie.genomique.eoulsan.core.workflow.StepOutputPort port,
                                      fr.ens.biologie.genomique.eoulsan.core.workflow.DataElement data,
                                      int fileIndex)
        Create the name of a data file of the workflow.
        Parameters:
        port - port that generate the data
        data - data
        fileIndex - file index
        Returns:
        a String with the name of the file
      • file

        public static DataFile file​(fr.ens.biologie.genomique.eoulsan.core.workflow.StepOutputPort port,
                                    fr.ens.biologie.genomique.eoulsan.core.workflow.DataElement data,
                                    int fileIndex)
        Create a DataFile object for a file of the workflow.
        Parameters:
        port - port that generate the data
        data - data
        fileIndex - file index
        Returns:
        a DataFile object