Class OutputPortsBuilder


  • public class OutputPortsBuilder
    extends Object
    This class allow to easily create input ports for a step.
    Since:
    2.0
    Author:
    Laurent Jourdren
    • Field Detail

      • DEFAULT_SINGLE_OUTPUT_PORT_NAME

        public static final String DEFAULT_SINGLE_OUTPUT_PORT_NAME
        Default single output port name.
        See Also:
        Constant Field Values
    • Constructor Detail

      • OutputPortsBuilder

        public OutputPortsBuilder()
    • Method Detail

      • addPort

        public OutputPortsBuilder addPort​(String name,
                                          boolean list,
                                          DataFormat format)
        Add an output port.
        Parameters:
        name - name of the port
        list - true if a list is excepted as port value
        format - format of the port
      • addPort

        public OutputPortsBuilder addPort​(String name,
                                          DataFormat format,
                                          fr.ens.biologie.genomique.kenetre.io.CompressionType compression)
        Add an output port.
        Parameters:
        name - name of the port
        format - format of the port
        compression - compression of the output
      • addPort

        public OutputPortsBuilder addPort​(String name,
                                          boolean list,
                                          DataFormat format,
                                          fr.ens.biologie.genomique.kenetre.io.CompressionType compression)
        Add an output port.
        Parameters:
        name - name of the port
        list - true if a list is excepted as port value
        format - format of the port
        compression - compression of the output
      • create

        public OutputPorts create()
        Create the ports.
        Returns:
        new OutputPorts object
      • noOutputPort

        public static OutputPorts noOutputPort()
        Create the ports with no ports.
        Returns:
        a new OutputPorts object
      • singleOutputPort

        public static OutputPorts singleOutputPort​(DataFormat format)
        Convenient method to create the ports with only one port.
        Returns:
        a new OutputPorts object
      • singleOutputPort

        public static OutputPorts singleOutputPort​(String name,
                                                   DataFormat format)
        Convenient method to create the ports with only one port.
        Returns:
        a new OutputPorts object
      • copy

        public static OutputPorts copy​(OutputPorts ports)
        Convenient method to create a defensive copy of an OutputPorts object.
        Parameters:
        ports - an existing OutputPorts object
        Returns:
        a new OutputPorts object or null if the ports parameter is null