NAME
Daje::Workflow::Activities::Files::Save - It's a tool to save an array of files
SYNOPSIS
use Daje::Workflow::Activities::Files::Save;
"activity_data": {
"file" : {
"target_dir_tag": "sql_target_dir",
"filetype": ".sql",
"file_list_tag": "sql"
}
}
Mandatory meta data
file contains file name or name an path
data content to write to disk
Possible meta data
path if set to 1 the file tag contains full path
new_only if set to 1 dont replace existing file
# Producer
for(Bla; Bla; Ble) {
if (my $sql = $self->_process_sql(@{$files_list}[$i])) {
my $data->{data} = $sql;
$data->{file} = Mojo::File->new(@{$files_list}[$i])->basename;
$data->{file} =~ s/.json//g;
push(@data, $data);
}
}
$self->context->{context}->{sql} = \@data;
DESCRIPTION
Daje::Workflow::Activities::Files::Save is a file saver
REQUIRES
Daje::Workflow::Savefile::Activity
METHODS
save($self)
save($self)();
AUTHOR
janeskil1525 <janeskil1525@gmail.com>
LICENSE
Copyright (C) janeskil1525.
This library is free software; you can redistribute it and/or modify it under the same terms as Perl itself.