class CloneImagesOrVideos extends Job implements ShouldQueue

Traits

InteractsWithQueue
SerializesModels
Queueable
Dispatchable

Properties

Project $project

The target project.

Volume $copy
Volume $volume

The volume to clone.

array $onlyFiles

Array containing file ids.

bool $cloneAnnotations

Boolean for cloning annotation labels.

array $onlyAnnotationLabels

Array containing annotation label ids.

bool $cloneFileLabels

Boolean for cloning file labels.

array $onlyFileLabels

Array containing file label ids.

protected array $uuidMap

Array mapping original image uuids to cloned image uuids

protected bool $deleteWhenMissingModels

Ignore this job if the project or volume does not exist any more.

Methods

void
__construct(CloneVolume|Request $request, $copy)

Create a new job instance.

handle()

No description

copyImages(Volume $volume, Volume $copy, int[] $selectedImageIds)

Copies (selected) images from given volume to volume copy.

copyImageAnnotation(Volume $volume, Volume $copy, int[] $selectedFileIds, int[] $selectedLabelIds)

Copies (selected) image annotation and annotation labels from volume to volume copy.

copyImageLabels(Volume $volume, Volume $copy, int[] $selectedFileIds, int[] $selectedLabelIds)

Copies (selected) image labels from given volume to volume copy.

copyVideos(Volume $volume, Volume $copy, int[] $selectedVideoIds)

Copies (selected) videos from given volume to volume copy.

copyVideoAnnotation(Volume $volume, Volume $copy, int[] $selectedFileIds, int[] $selectedLabelIds)

Copies (selected) video annotations and annotation labels from given volume to volume copy.

copyVideoLabels(Volume $volume, Volume $copy, int[] $selectedFileIds, int[] $selectedLabelIds)

Copies (selected) video labels from volume to volume copy.

void
copyMetadataFile(Volume $source, Volume $target)

No description

Details

at line 100
void __construct(CloneVolume|Request $request, $copy)

Create a new job instance.

Parameters

CloneVolume|Request $request

containing the project, volume, new volume name and ids of files and labels.

$copy

Return Value

void

at line 114
handle()

No description

at line 166
private copyImages(Volume $volume, Volume $copy, int[] $selectedImageIds)

Copies (selected) images from given volume to volume copy.

Parameters

Volume $volume
Volume $copy
int[] $selectedImageIds

at line 195
private copyImageAnnotation(Volume $volume, Volume $copy, int[] $selectedFileIds, int[] $selectedLabelIds)

Copies (selected) image annotation and annotation labels from volume to volume copy.

Parameters

Volume $volume
Volume $copy
int[] $selectedFileIds
int[] $selectedLabelIds

at line 277
private copyImageLabels(Volume $volume, Volume $copy, int[] $selectedFileIds, int[] $selectedLabelIds)

Copies (selected) image labels from given volume to volume copy.

Parameters

Volume $volume
Volume $copy
int[] $selectedFileIds
int[] $selectedLabelIds

at line 312
private copyVideos(Volume $volume, Volume $copy, int[] $selectedVideoIds)

Copies (selected) videos from given volume to volume copy.

Parameters

Volume $volume
Volume $copy
int[] $selectedVideoIds

at line 341
private copyVideoAnnotation(Volume $volume, Volume $copy, int[] $selectedFileIds, int[] $selectedLabelIds)

Copies (selected) video annotations and annotation labels from given volume to volume copy.

Parameters

Volume $volume
Volume $copy
int[] $selectedFileIds
int[] $selectedLabelIds

at line 423
private copyVideoLabels(Volume $volume, Volume $copy, int[] $selectedFileIds, int[] $selectedLabelIds)

Copies (selected) video labels from volume to volume copy.

Parameters

Volume $volume
Volume $copy
int[] $selectedFileIds
int[] $selectedLabelIds

at line 452
private void copyMetadataFile(Volume $source, Volume $target)

No description

Parameters

Volume $source
Volume $target

Return Value

void