## thunar-io-jobs-util thunar-io-jobs-util |

## Functions

GFile * | thunar_io_jobs_util_next_duplicate_file ()
GFile * | thunar_io_jobs_util_next_renamed_file ()

## Description

## Functions

### thunar_io_jobs_util_next_duplicate_file ()

    GFile *
    thunar_io_jobs_util_next_duplicate_file
                                   (ThunarJob *job,
                                    GFile *file,
                                    ThunarNextFileNameMode name_mode,
                                    GError **error);

Determines the GFile for the next copy/link of/to `file` .

Copies of a file called X are named "X (copy 1)"

Links follow have a bit different scheme, since the first link is renamed to "link to #" and after that "link Y to X".

If there are errors or the job was cancelled, the return value will be `NULL` and `error` will be set.

#### Parameters

job | a ThunarJob. |
file | the source GFile. |
name_mode | the naming mode to use (copy/link). |
error | return location for errors or `NULL`. |

#### Returns

the GFile referencing the `n` th copy or link of `file` or `NULL` on error/cancellation.

### thunar_io_jobs_util_next_renamed_file ()

    GFile *
    thunar_io_jobs_util_next_renamed_file (ThunarJob *job,
                                           GFile *src_file,
                                           GFile *tgt_file,
                                           guint n,
                                           GError **error);

Determines the GFile for the next copy/move to `tgt_file` .

File named X will be renamed to "X (copy 1)".

If there are errors or the job was cancelled, the return value will be `NULL` and `error` will be set.

#### Parameters

job | a ThunarJob. |
src_file | the source GFile. |
tgt_file | the target GFile. |
n | the `n` th copy/move to create the GFile for. |
error | return location for errors or `NULL`. |

#### Returns

the GFile referencing the `n` th copy/move of `tgt_file` or `NULL` on error/cancellation.