Executes the dinosaur tool on Windows operating systems.

    :param filelocation: either a single mgf file path or a list of file paths.
    :param outpath: path of the output file, file must not exist
    :param executable: must specify the complete file path of the
        spectra-cluster-cli.jar file, supported version is 1.0.2 BETA.
    :param args: list of arguments containing a value, for details see the
        spectra-cluster-cli help. Arguments should be added as tuples or a list.
        For example: [('precursor_tolerance', '0.5'), ('rounds', '3')]
    :param switchArgs: list of arguments not containing a value, for details see
        the spectra-cluster-cli help. Arguments should be added as strings.
        For example: ['fast_mode', 'keep_binary_files']

def execute(filelocation, outpath, executable, args=None, switchArgs=None):
    """Executes the dinosaur tool on Windows operating systems.

    :param filelocation: either a single mgf file path or a list of file paths.
    :param outpath: path of the output file, file must not exist
    :param executable: must specify the complete file path of the
        spectra-cluster-cli.jar file, supported version is 1.0.2 BETA.
    :param args: list of arguments containing a value, for details see the
        spectra-cluster-cli help. Arguments should be added as tuples or a list.
        For example: [('precursor_tolerance', '0.5'), ('rounds', '3')]
    :param switchArgs: list of arguments not containing a value, for details see
        the spectra-cluster-cli help. Arguments should be added as strings.
        For example: ['fast_mode', 'keep_binary_files']
    """
    procArgs = ['java', '-jar', executable]
    procArgs.extend(['-output_path', outpath])
    if args is not None:
        for arg in args:
            procArgs.extend(['-'+arg[0], arg[1]])
    if switchArgs is not None:
        procArgs.extend(['-'+arg for arg in switchArgs])

    procArgs.extend(aux.toList(filelocation))

    ## run it ##
    proc = subprocess.Popen(procArgs, stderr=subprocess.PIPE)

    ## But do not wait till netstat finish, start displaying output immediately ##
    while True:
        out = proc.stderr.read(1)
        if out == '' and proc.poll() != None:
            break
        if out != '':
            sys.stdout.write(out)
            sys.stdout.flush()