view release on metacpan or search on metacpan
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
{
my $params = {
'document' => {
data_type => 'File',
description => 'Document data.',
required => '1',
},
'format' => {
data_type => 'string',
description => 'Export format.',
required => '1',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Custom fonts folder.',
required => '0',
},
'slides' => {
data_type => 'int[]',
description => 'The indices of the slides to be converted. If not specified, all slides are converted by default.',
required => '0',
},
'options' => {
data_type => 'ExportOptions',
description => 'Export options.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'convert' } = {
summary => 'Convert presentation from request content to format specified.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub convert {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling convert");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling convert");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Pdf', 'Xps', 'Tiff', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Pot', 'Potx', 'Potm', 'Html', 'Html5', 'Swf', 'Svg', 'Jpeg', 'Png', 'Gif', 'Bmp', 'Fodp', 'Xaml', 'Mpeg4', 'Md', 'Xml', 'Emf' )))...
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/convert/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('multipart/form-data');
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# query params
if (exists $args{'slides'} && defined $args{'slides'}) {
$query_params->{'slides'} = $self->{api_client}->to_query_value($args{'slides'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
if ( exists $args{'document'} && $args{'document'}) {
push(@$files, $args{'document'});
}
# body params
if ( exists $args{'options'} && $args{'options'}) {
$_body_data = $args{'options'};
}
# make the API Call
my $response = $self->{api_client}->call_api($_resource_path, $_method,
$query_params, $form_params,
$header_params, $_body_data, $files);
if (!$response) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '1',
},
'format' => {
data_type => 'string',
description => 'Export format.',
required => '1',
},
'out_path' => {
data_type => 'string',
description => 'Path to save result.',
required => '1',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Custom fonts folder.',
required => '0',
},
'slides' => {
data_type => 'int[]',
description => 'The indices of the slides to be converted. If not specified, all slides are converted by default.',
required => '0',
},
'options' => {
data_type => 'ExportOptions',
description => 'Export options.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'convert_and_save' } = {
summary => 'Convert presentation from request content to format specified.',
params => $params,
returns => undef,
};
}
# @return void
#
sub convert_and_save {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling convert_and_save");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling convert_and_save");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Pdf', 'Xps', 'Tiff', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Pot', 'Potx', 'Potm', 'Html', 'Html5', 'Swf', 'Svg', 'Jpeg', 'Png', 'Gif', 'Bmp', 'Fodp', 'Xaml', 'Mpeg4', 'Md', 'Xml', 'Emf' )))...
croak("Invalid value for 'format': " . $args{'format'});
}
# verify the required parameter 'out_path' is set
unless (exists $args{'out_path'} && defined $args{'out_path'} && $args{'out_path'}) {
croak("Missing the required parameter 'out_path' when calling convert_and_save");
}
# parse inputs
my $_resource_path = '/slides/convert/{format}';
my $_method = 'PUT';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('application/json');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('multipart/form-data');
# query params
if (exists $args{'out_path'} && defined $args{'out_path'}) {
$query_params->{'outPath'} = $self->{api_client}->to_query_value($args{'out_path'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# query params
if (exists $args{'slides'} && defined $args{'slides'}) {
$query_params->{'slides'} = $self->{api_client}->to_query_value($args{'slides'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
if ( exists $args{'document'} && $args{'document'}) {
push(@$files, $args{'document'});
}
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '1',
},
'index' => {
data_type => 'int',
description => 'Image index.',
required => '1',
},
'format' => {
data_type => 'string',
description => 'Export format (png, jpg, gif).',
required => '1',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Document folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'quality' => {
data_type => 'int',
description => 'Image quality (0 to 100; has effect only on Jpeg format).',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_image' } = {
summary => 'Get image in specified format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_image {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling download_image");
}
# verify the required parameter 'index' is set
unless (exists $args{'index'} && defined $args{'index'}) {
croak("Missing the required parameter 'index' when calling download_image");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_image");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/{name}/images/{index}/{format}';
my $_method = 'GET';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'quality'} && defined $args{'quality'}) {
$query_params->{'quality'} = $self->{api_client}->to_query_value($args{'quality'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'name'}) {
my $_base_variable = "{" . "name" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'name'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
# path params
if ( exists $args{'index'}) {
my $_base_variable = "{" . "index" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'index'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
# @param File $document Document data. (required)
# @param int $index Image index. (required)
# @param string $format Export format (png, jpg, gif). (required)
# @param string $password Document password. (optional)
# @param int $quality Image quality (0 to 100; has effect only on Jpeg format). (optional, default to 100)
{
my $params = {
'document' => {
data_type => 'File',
description => 'Document data.',
required => '1',
},
'index' => {
data_type => 'int',
description => 'Image index.',
required => '1',
},
'format' => {
data_type => 'string',
description => 'Export format (png, jpg, gif).',
required => '1',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'quality' => {
data_type => 'int',
description => 'Image quality (0 to 100; has effect only on Jpeg format).',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_image_online' } = {
summary => 'Get image in specified format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_image_online {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling download_image_online");
}
# verify the required parameter 'index' is set
unless (exists $args{'index'} && defined $args{'index'}) {
croak("Missing the required parameter 'index' when calling download_image_online");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_image_online");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/images/{index}/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'quality'} && defined $args{'quality'}) {
$query_params->{'quality'} = $self->{api_client}->to_query_value($args{'quality'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'index'}) {
my $_base_variable = "{" . "index" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'index'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
if ( exists $args{'document'} && $args{'document'}) {
push(@$files, $args{'document'});
}
# make the API Call
my $response = $self->{api_client}->call_api($_resource_path, $_method,
$query_params, $form_params,
$header_params, $_body_data, $files);
if (!$response) {
return;
}
my $_response_object = $self->{api_client}->deserialize('File', $response);
return $_response_object;
}
#
# download_images
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
# @param string $format Export format (png, jpg, gif). (required)
# @param string $password Document password. (optional)
# @param string $folder Document folder. (optional)
# @param string $storage Document storage. (optional)
# @param int $quality Image quality (0 to 100; has effect only on Jpeg format). (optional, default to 100)
{
my $params = {
'name' => {
data_type => 'string',
description => '',
required => '1',
},
'format' => {
data_type => 'string',
description => 'Export format (png, jpg, gif).',
required => '1',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Document folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'quality' => {
data_type => 'int',
description => 'Image quality (0 to 100; has effect only on Jpeg format).',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_images' } = {
summary => 'Get all presentation images in specified format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_images {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling download_images");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_images");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/{name}/images/download/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'quality'} && defined $args{'quality'}) {
$query_params->{'quality'} = $self->{api_client}->to_query_value($args{'quality'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'name'}) {
my $_base_variable = "{" . "name" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'name'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
# make the API Call
my $response = $self->{api_client}->call_api($_resource_path, $_method,
$query_params, $form_params,
$header_params, $_body_data, $files);
if (!$response) {
return;
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
return;
}
my $_response_object = $self->{api_client}->deserialize('File', $response);
return $_response_object;
}
#
# download_images_online
#
# Get all presentation images in specified format.
#
# @param File $document Document data. (required)
# @param string $format Export format (png, jpg, gif). (required)
# @param string $password Document password. (optional)
# @param int $quality Image quality (0 to 100; has effect only on Jpeg format). (optional, default to 100)
{
my $params = {
'document' => {
data_type => 'File',
description => 'Document data.',
required => '1',
},
'format' => {
data_type => 'string',
description => 'Export format (png, jpg, gif).',
required => '1',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'quality' => {
data_type => 'int',
description => 'Image quality (0 to 100; has effect only on Jpeg format).',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_images_online' } = {
summary => 'Get all presentation images in specified format. ',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_images_online {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling download_images_online");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_images_online");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/images/download/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'quality'} && defined $args{'quality'}) {
$query_params->{'quality'} = $self->{api_client}->to_query_value($args{'quality'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
if ( exists $args{'document'} && $args{'document'}) {
push(@$files, $args{'document'});
}
# make the API Call
my $response = $self->{api_client}->call_api($_resource_path, $_method,
$query_params, $form_params,
$header_params, $_body_data, $files);
if (!$response) {
return;
}
my $_response_object = $self->{api_client}->deserialize('File', $response);
return $_response_object;
}
#
# download_math_portion
#
# Convert Mathematical Text to MathML Format
#
# @param string $name Document name. (required)
# @param int $slide_index Slide index. (required)
# @param int $shape_index Shape index. (required)
# @param int $paragraph_index Paragraph index. (required)
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '1',
},
'width' => {
data_type => 'int',
description => 'The width of the slide representation in the output format.',
required => '0',
},
'height' => {
data_type => 'int',
description => 'The height of the slide representation in the output format',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Document folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Storage folder containing custom fonts to be used with the document.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_notes_slide' } = {
summary => 'Convert notes slide to the specified image format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_notes_slide {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling download_notes_slide");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling download_notes_slide");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_notes_slide");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Html', 'Pdf', 'Xps', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Potx', 'Pot', 'Potm', 'Svg', 'Fodp', 'Xaml', 'Html5' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/{name}/slides/{slideIndex}/notesSlide/{format}';
my $_method = 'GET';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'width'} && defined $args{'width'}) {
$query_params->{'width'} = $self->{api_client}->to_query_value($args{'width'});
}
# query params
if (exists $args{'height'} && defined $args{'height'}) {
$query_params->{'height'} = $self->{api_client}->to_query_value($args{'height'});
}
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'name'}) {
my $_base_variable = "{" . "name" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'name'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
# path params
if ( exists $args{'slide_index'}) {
my $_base_variable = "{" . "slideIndex" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'slide_index'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '1',
},
'slide_index' => {
data_type => 'int',
description => 'Slide index.',
required => '1',
},
'format' => {
data_type => 'string',
description => 'Output file format.',
required => '1',
},
'width' => {
data_type => 'int',
description => 'The width of the slide representation in the output format.',
required => '0',
},
'height' => {
data_type => 'int',
description => 'The height of the slide representation in the output format.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Storage folder containing custom fonts to be used with the document.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_notes_slide_online' } = {
summary => 'Convert notes slide to the specified image format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_notes_slide_online {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling download_notes_slide_online");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling download_notes_slide_online");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_notes_slide_online");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Html', 'Pdf', 'Xps', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Potx', 'Pot', 'Potm', 'Svg', 'Fodp', 'Xaml', 'Html5' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/slides/{slideIndex}/notesSlide/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('multipart/form-data');
# query params
if (exists $args{'width'} && defined $args{'width'}) {
$query_params->{'width'} = $self->{api_client}->to_query_value($args{'width'});
}
# query params
if (exists $args{'height'} && defined $args{'height'}) {
$query_params->{'height'} = $self->{api_client}->to_query_value($args{'height'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'slide_index'}) {
my $_base_variable = "{" . "slideIndex" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'slide_index'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
if ( exists $args{'document'} && $args{'document'}) {
push(@$files, $args{'document'});
}
# make the API Call
my $response = $self->{api_client}->call_api($_resource_path, $_method,
$query_params, $form_params,
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '1',
},
'format' => {
data_type => 'string',
description => 'Export format.',
required => '1',
},
'options' => {
data_type => 'ExportOptions',
description => 'Export options.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Document folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Custom fonts folder.',
required => '0',
},
'slides' => {
data_type => 'int[]',
description => 'The indices of the slides to be saved. If not specified, all slides are saved by default.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_presentation' } = {
summary => 'Save a presentation to a specified format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_presentation {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling download_presentation");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_presentation");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Pdf', 'Xps', 'Tiff', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Pot', 'Potx', 'Potm', 'Html', 'Html5', 'Swf', 'Svg', 'Jpeg', 'Png', 'Gif', 'Bmp', 'Fodp', 'Xaml', 'Mpeg4', 'Md', 'Xml', 'Emf' )))...
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/{name}/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# query params
if (exists $args{'slides'} && defined $args{'slides'}) {
$query_params->{'slides'} = $self->{api_client}->to_query_value($args{'slides'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'name'}) {
my $_base_variable = "{" . "name" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'name'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
# body params
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Presentation folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Presentation storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Fonts folder.',
required => '0',
},
'sub_shape' => {
data_type => 'string',
description => 'Sub-shape path (e.g. \"3\", \"3/shapes/2).',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_shape' } = {
summary => 'Render shape to specified picture format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_shape {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling download_shape");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling download_shape");
}
# verify the required parameter 'shape_index' is set
unless (exists $args{'shape_index'} && defined $args{'shape_index'}) {
croak("Missing the required parameter 'shape_index' when calling download_shape");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_shape");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Svg', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# verify enum value
if (exists $args{'bounds'} && $args{'bounds'} && !grep(/^$args{'bounds'}$/i, ( 'Slide', 'Shape', 'Appearance' ))) {
croak("Invalid value for 'bounds': " . $args{'bounds'});
}
# parse inputs
my $_resource_path = '/slides/{name}/slides/{slideIndex}/shapes/{shapeIndex}/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'scale_x'} && defined $args{'scale_x'}) {
$query_params->{'scaleX'} = $self->{api_client}->to_query_value($args{'scale_x'});
}
# query params
if (exists $args{'scale_y'} && defined $args{'scale_y'}) {
$query_params->{'scaleY'} = $self->{api_client}->to_query_value($args{'scale_y'});
}
# query params
if (exists $args{'bounds'} && defined $args{'bounds'}) {
$query_params->{'bounds'} = $self->{api_client}->to_query_value($args{'bounds'});
}
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# query params
if (exists $args{'sub_shape'} && defined $args{'sub_shape'}) {
$query_params->{'subShape'} = $self->{api_client}->to_query_value($args{'sub_shape'});
}
# header params
if ( exists $args{'password'}) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
# body params
if ( exists $args{'options'} && $args{'options'}) {
$_body_data = $args{'options'};
}
# make the API Call
my $response = $self->{api_client}->call_api($_resource_path, $_method,
$query_params, $form_params,
$header_params, $_body_data, $files);
if (!$response) {
return;
}
my $_response_object = $self->{api_client}->deserialize('File', $response);
return $_response_object;
}
#
# download_shape_from_dto
#
# Creates the shape from the DTO and returns the result in the specified format.
#
# @param string $format Export format (required)
# @param ShapeBase $dto Shape DTO. (required)
{
my $params = {
'format' => {
data_type => 'string',
description => 'Export format',
required => '1',
},
'dto' => {
data_type => 'ShapeBase',
description => 'Shape DTO.',
required => '1',
},
};
__PACKAGE__->method_documentation->{ 'download_shape_from_dto' } = {
summary => 'Creates the shape from the DTO and returns the result in the specified format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_shape_from_dto {
my ($self, %args) = @_;
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_shape_from_dto");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Svg', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# verify the required parameter 'dto' is set
unless (exists $args{'dto'} && defined $args{'dto'} && $args{'dto'}) {
croak("Missing the required parameter 'dto' when calling download_shape_from_dto");
}
# parse inputs
my $_resource_path = '/slides/shape/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
# body params
if ( exists $args{'dto'} && $args{'dto'}) {
$_body_data = $args{'dto'};
}
# make the API Call
my $response = $self->{api_client}->call_api($_resource_path, $_method,
$query_params, $form_params,
$header_params, $_body_data, $files);
if (!$response) {
return;
}
my $_response_object = $self->{api_client}->deserialize('File', $response);
return $_response_object;
}
#
# download_shape_online
#
# Render shape to specified picture format.
#
# @param File $document Document data. (required)
# @param int $slide_index Slide index. (required)
# @param int $shape_index Index of shape starting from 1 (required)
# @param string $format Export picture format. (required)
# @param double $scale_x X scale ratio. (optional, default to 0.0)
# @param double $scale_y Y scale ratio. (optional, default to 0.0)
# @param string $bounds Shape thumbnail bounds type. (optional, default to 1)
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'bounds' => {
data_type => 'string',
description => 'Shape thumbnail bounds type.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Fonts folder.',
required => '0',
},
'options' => {
data_type => 'IShapeExportOptions',
description => 'Export options.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_shape_online' } = {
summary => 'Render shape to specified picture format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_shape_online {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling download_shape_online");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling download_shape_online");
}
# verify the required parameter 'shape_index' is set
unless (exists $args{'shape_index'} && defined $args{'shape_index'}) {
croak("Missing the required parameter 'shape_index' when calling download_shape_online");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_shape_online");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Svg', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# verify enum value
if (exists $args{'bounds'} && $args{'bounds'} && !grep(/^$args{'bounds'}$/i, ( 'Slide', 'Shape', 'Appearance' ))) {
croak("Invalid value for 'bounds': " . $args{'bounds'});
}
# parse inputs
my $_resource_path = '/slides/slides/{slideIndex}/shapes/{shapeIndex}/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('multipart/form-data');
# query params
if (exists $args{'scale_x'} && defined $args{'scale_x'}) {
$query_params->{'scaleX'} = $self->{api_client}->to_query_value($args{'scale_x'});
}
# query params
if (exists $args{'scale_y'} && defined $args{'scale_y'}) {
$query_params->{'scaleY'} = $self->{api_client}->to_query_value($args{'scale_y'});
}
# query params
if (exists $args{'bounds'} && defined $args{'bounds'}) {
$query_params->{'bounds'} = $self->{api_client}->to_query_value($args{'bounds'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'slide_index'}) {
my $_base_variable = "{" . "slideIndex" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'slide_index'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'width' => {
data_type => 'int',
description => 'The width of the slide representation in the output format; 0 to not adjust the size. Default is 0.',
required => '0',
},
'height' => {
data_type => 'int',
description => 'The height of the slide representation in the output format; 0 to not adjust the size. Default is 0.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Document folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Storage folder containing custom fonts to be used with the document.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_slide' } = {
summary => 'Save a slide to a specified format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_slide {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling download_slide");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling download_slide");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_slide");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Html', 'Pdf', 'Xps', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Potx', 'Pot', 'Potm', 'Svg', 'Fodp', 'Xaml', 'Html5', 'Md', 'Xml', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/{name}/slides/{slideIndex}/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'width'} && defined $args{'width'}) {
$query_params->{'width'} = $self->{api_client}->to_query_value($args{'width'});
}
# query params
if (exists $args{'height'} && defined $args{'height'}) {
$query_params->{'height'} = $self->{api_client}->to_query_value($args{'height'});
}
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'name'}) {
my $_base_variable = "{" . "name" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'name'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
# path params
if ( exists $args{'slide_index'}) {
my $_base_variable = "{" . "slideIndex" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'slide_index'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '1',
},
'width' => {
data_type => 'int',
description => 'The width of the slide representation in the output format; 0 to not adjust the size. Default is 0.',
required => '0',
},
'height' => {
data_type => 'int',
description => 'The height of the slide representation in the output format; 0 to not adjust the size. Default is 0.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Storage folder containing custom fonts to be used with the document.',
required => '0',
},
'options' => {
data_type => 'ExportOptions',
description => 'Export options.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_slide_online' } = {
summary => 'Save a slide to a specified format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_slide_online {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling download_slide_online");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling download_slide_online");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_slide_online");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Html', 'Pdf', 'Xps', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Potx', 'Pot', 'Potm', 'Svg', 'Fodp', 'Xaml', 'Html5', 'Md', 'Xml', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/slides/{slideIndex}/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('multipart/form-data');
# query params
if (exists $args{'width'} && defined $args{'width'}) {
$query_params->{'width'} = $self->{api_client}->to_query_value($args{'width'});
}
# query params
if (exists $args{'height'} && defined $args{'height'}) {
$query_params->{'height'} = $self->{api_client}->to_query_value($args{'height'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'slide_index'}) {
my $_base_variable = "{" . "slideIndex" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'slide_index'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
my $_body_data;
my $files = [];
if ( exists $args{'document'} && $args{'document'}) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Presentation storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Fonts folder.',
required => '0',
},
'sub_shape' => {
data_type => 'string',
description => 'Sub-shape path (e.g. \"3\", \"3/shapes/2).',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'download_special_slide_shape' } = {
summary => 'Render shape to specified picture format.',
params => $params,
returns => 'File',
};
}
# @return File
#
sub download_special_slide_shape {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling download_special_slide_shape");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling download_special_slide_shape");
}
# verify the required parameter 'slide_type' is set
unless (exists $args{'slide_type'} && defined $args{'slide_type'} && $args{'slide_type'}) {
croak("Missing the required parameter 'slide_type' when calling download_special_slide_shape");
}
# verify enum value
if (!grep(/^$args{'slide_type'}$/i, ( 'MasterSlide', 'LayoutSlide', 'NotesSlide' ))) {
croak("Invalid value for 'slide_type': " . $args{'slide_type'});
}
# verify the required parameter 'shape_index' is set
unless (exists $args{'shape_index'} && defined $args{'shape_index'}) {
croak("Missing the required parameter 'shape_index' when calling download_special_slide_shape");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling download_special_slide_shape");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Svg', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# verify enum value
if (exists $args{'bounds'} && $args{'bounds'} && !grep(/^$args{'bounds'}$/i, ( 'Slide', 'Shape', 'Appearance' ))) {
croak("Invalid value for 'bounds': " . $args{'bounds'});
}
# parse inputs
my $_resource_path = '/slides/{name}/slides/{slideIndex}/{slideType}/shapes/{shapeIndex}/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'scale_x'} && defined $args{'scale_x'}) {
$query_params->{'scaleX'} = $self->{api_client}->to_query_value($args{'scale_x'});
}
# query params
if (exists $args{'scale_y'} && defined $args{'scale_y'}) {
$query_params->{'scaleY'} = $self->{api_client}->to_query_value($args{'scale_y'});
}
# query params
if (exists $args{'bounds'} && defined $args{'bounds'}) {
$query_params->{'bounds'} = $self->{api_client}->to_query_value($args{'bounds'});
}
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# query params
if (exists $args{'sub_shape'} && defined $args{'sub_shape'}) {
$query_params->{'subShape'} = $self->{api_client}->to_query_value($args{'sub_shape'});
}
# header params
if ( exists $args{'password'}) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '1',
},
'out_path' => {
data_type => 'string',
description => 'Output path.',
required => '1',
},
'options' => {
data_type => 'ExportOptions',
description => 'Export options.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Document folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Custom fonts folder.',
required => '0',
},
'slides' => {
data_type => 'int[]',
description => 'The indices of the slides to be saved. If not specified, all slides are saved by default.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'save_presentation' } = {
summary => 'Save a presentation to a specified format.',
params => $params,
returns => undef,
};
}
# @return void
#
sub save_presentation {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling save_presentation");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling save_presentation");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Pdf', 'Xps', 'Tiff', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Pot', 'Potx', 'Potm', 'Html', 'Html5', 'Swf', 'Svg', 'Jpeg', 'Png', 'Gif', 'Bmp', 'Fodp', 'Xaml', 'Mpeg4', 'Md', 'Xml', 'Emf' )))...
croak("Invalid value for 'format': " . $args{'format'});
}
# verify the required parameter 'out_path' is set
unless (exists $args{'out_path'} && defined $args{'out_path'} && $args{'out_path'}) {
croak("Missing the required parameter 'out_path' when calling save_presentation");
}
# parse inputs
my $_resource_path = '/slides/{name}/{format}';
my $_method = 'PUT';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('application/json');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'out_path'} && defined $args{'out_path'}) {
$query_params->{'outPath'} = $self->{api_client}->to_query_value($args{'out_path'});
}
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# query params
if (exists $args{'slides'} && defined $args{'slides'}) {
$query_params->{'slides'} = $self->{api_client}->to_query_value($args{'slides'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'name'}) {
my $_base_variable = "{" . "name" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'name'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Presentation folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Presentation storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Fonts folder.',
required => '0',
},
'sub_shape' => {
data_type => 'string',
description => 'Sub-shape path (e.g. \"3\", \"3/shapes/2).',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'save_shape' } = {
summary => 'Render shape to specified picture format.',
params => $params,
returns => undef,
};
}
# @return void
#
sub save_shape {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling save_shape");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling save_shape");
}
# verify the required parameter 'shape_index' is set
unless (exists $args{'shape_index'} && defined $args{'shape_index'}) {
croak("Missing the required parameter 'shape_index' when calling save_shape");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling save_shape");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Svg', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# verify the required parameter 'out_path' is set
unless (exists $args{'out_path'} && defined $args{'out_path'} && $args{'out_path'}) {
croak("Missing the required parameter 'out_path' when calling save_shape");
}
# verify enum value
if (exists $args{'bounds'} && $args{'bounds'} && !grep(/^$args{'bounds'}$/i, ( 'Slide', 'Shape', 'Appearance' ))) {
croak("Invalid value for 'bounds': " . $args{'bounds'});
}
# parse inputs
my $_resource_path = '/slides/{name}/slides/{slideIndex}/shapes/{shapeIndex}/{format}';
my $_method = 'PUT';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('application/json');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'out_path'} && defined $args{'out_path'}) {
$query_params->{'outPath'} = $self->{api_client}->to_query_value($args{'out_path'});
}
# query params
if (exists $args{'scale_x'} && defined $args{'scale_x'}) {
$query_params->{'scaleX'} = $self->{api_client}->to_query_value($args{'scale_x'});
}
# query params
if (exists $args{'scale_y'} && defined $args{'scale_y'}) {
$query_params->{'scaleY'} = $self->{api_client}->to_query_value($args{'scale_y'});
}
# query params
if (exists $args{'bounds'} && defined $args{'bounds'}) {
$query_params->{'bounds'} = $self->{api_client}->to_query_value($args{'bounds'});
}
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'bounds' => {
data_type => 'string',
description => 'Shape thumbnail bounds type.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Fonts folder.',
required => '0',
},
'options' => {
data_type => 'IShapeExportOptions',
description => 'Export options.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'save_shape_online' } = {
summary => 'Render shape to specified picture format.',
params => $params,
returns => undef,
};
}
# @return void
#
sub save_shape_online {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling save_shape_online");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling save_shape_online");
}
# verify the required parameter 'shape_index' is set
unless (exists $args{'shape_index'} && defined $args{'shape_index'}) {
croak("Missing the required parameter 'shape_index' when calling save_shape_online");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling save_shape_online");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Svg', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# verify the required parameter 'out_path' is set
unless (exists $args{'out_path'} && defined $args{'out_path'} && $args{'out_path'}) {
croak("Missing the required parameter 'out_path' when calling save_shape_online");
}
# verify enum value
if (exists $args{'bounds'} && $args{'bounds'} && !grep(/^$args{'bounds'}$/i, ( 'Slide', 'Shape', 'Appearance' ))) {
croak("Invalid value for 'bounds': " . $args{'bounds'});
}
# parse inputs
my $_resource_path = '/slides/slides/{slideIndex}/shapes/{shapeIndex}/{format}';
my $_method = 'PUT';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('application/json');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('multipart/form-data');
# query params
if (exists $args{'out_path'} && defined $args{'out_path'}) {
$query_params->{'outPath'} = $self->{api_client}->to_query_value($args{'out_path'});
}
# query params
if (exists $args{'scale_x'} && defined $args{'scale_x'}) {
$query_params->{'scaleX'} = $self->{api_client}->to_query_value($args{'scale_x'});
}
# query params
if (exists $args{'scale_y'} && defined $args{'scale_y'}) {
$query_params->{'scaleY'} = $self->{api_client}->to_query_value($args{'scale_y'});
}
# query params
if (exists $args{'bounds'} && defined $args{'bounds'}) {
$query_params->{'bounds'} = $self->{api_client}->to_query_value($args{'bounds'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'width' => {
data_type => 'int',
description => 'The width of the slide representation in the output format; 0 to not adjust the size. Default is 0.',
required => '0',
},
'height' => {
data_type => 'int',
description => 'The height of the slide representation in the output format; 0 to not adjust the size. Default is 0.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Document folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Storage folder containing custom fonts to be used with the document.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'save_slide' } = {
summary => 'Save a slide to a specified format.',
params => $params,
returns => undef,
};
}
# @return void
#
sub save_slide {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling save_slide");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling save_slide");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling save_slide");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Html', 'Pdf', 'Xps', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Potx', 'Pot', 'Potm', 'Svg', 'Fodp', 'Xaml', 'Html5', 'Md', 'Xml', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# verify the required parameter 'out_path' is set
unless (exists $args{'out_path'} && defined $args{'out_path'} && $args{'out_path'}) {
croak("Missing the required parameter 'out_path' when calling save_slide");
}
# parse inputs
my $_resource_path = '/slides/{name}/slides/{slideIndex}/{format}';
my $_method = 'PUT';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('application/json');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'out_path'} && defined $args{'out_path'}) {
$query_params->{'outPath'} = $self->{api_client}->to_query_value($args{'out_path'});
}
# query params
if (exists $args{'width'} && defined $args{'width'}) {
$query_params->{'width'} = $self->{api_client}->to_query_value($args{'width'});
}
# query params
if (exists $args{'height'} && defined $args{'height'}) {
$query_params->{'height'} = $self->{api_client}->to_query_value($args{'height'});
}
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'name'}) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '1',
},
'width' => {
data_type => 'int',
description => 'The width of the slide representation in the output format; 0 to not adjust the size. Default is 0.',
required => '0',
},
'height' => {
data_type => 'int',
description => 'The height of the slide representation in the output format; 0 to not adjust the size. Default is 0.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Storage folder containing custom fonts to be used with the document.',
required => '0',
},
'options' => {
data_type => 'ExportOptions',
description => 'Export options.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'save_slide_online' } = {
summary => 'Save a slide to a specified format.',
params => $params,
returns => undef,
};
}
# @return void
#
sub save_slide_online {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling save_slide_online");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling save_slide_online");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling save_slide_online");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Html', 'Pdf', 'Xps', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Potx', 'Pot', 'Potm', 'Svg', 'Fodp', 'Xaml', 'Html5', 'Md', 'Xml', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# verify the required parameter 'out_path' is set
unless (exists $args{'out_path'} && defined $args{'out_path'} && $args{'out_path'}) {
croak("Missing the required parameter 'out_path' when calling save_slide_online");
}
# parse inputs
my $_resource_path = '/slides/slides/{slideIndex}/{format}';
my $_method = 'PUT';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('application/json');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('multipart/form-data');
# query params
if (exists $args{'out_path'} && defined $args{'out_path'}) {
$query_params->{'outPath'} = $self->{api_client}->to_query_value($args{'out_path'});
}
# query params
if (exists $args{'width'} && defined $args{'width'}) {
$query_params->{'width'} = $self->{api_client}->to_query_value($args{'width'});
}
# query params
if (exists $args{'height'} && defined $args{'height'}) {
$query_params->{'height'} = $self->{api_client}->to_query_value($args{'height'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'slide_index'}) {
my $_base_variable = "{" . "slideIndex" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'slide_index'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Presentation storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Fonts folder.',
required => '0',
},
'sub_shape' => {
data_type => 'string',
description => 'Sub-shape path (e.g. \"3\", \"3/shapes/2).',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'save_special_slide_shape' } = {
summary => 'Render shape to specified picture format.',
params => $params,
returns => undef,
};
}
# @return void
#
sub save_special_slide_shape {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling save_special_slide_shape");
}
# verify the required parameter 'slide_index' is set
unless (exists $args{'slide_index'} && defined $args{'slide_index'}) {
croak("Missing the required parameter 'slide_index' when calling save_special_slide_shape");
}
# verify the required parameter 'slide_type' is set
unless (exists $args{'slide_type'} && defined $args{'slide_type'} && $args{'slide_type'}) {
croak("Missing the required parameter 'slide_type' when calling save_special_slide_shape");
}
# verify enum value
if (!grep(/^$args{'slide_type'}$/i, ( 'MasterSlide', 'LayoutSlide', 'NotesSlide' ))) {
croak("Invalid value for 'slide_type': " . $args{'slide_type'});
}
# verify the required parameter 'shape_index' is set
unless (exists $args{'shape_index'} && defined $args{'shape_index'}) {
croak("Missing the required parameter 'shape_index' when calling save_special_slide_shape");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling save_special_slide_shape");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Svg', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# verify the required parameter 'out_path' is set
unless (exists $args{'out_path'} && defined $args{'out_path'} && $args{'out_path'}) {
croak("Missing the required parameter 'out_path' when calling save_special_slide_shape");
}
# verify enum value
if (exists $args{'bounds'} && $args{'bounds'} && !grep(/^$args{'bounds'}$/i, ( 'Slide', 'Shape', 'Appearance' ))) {
croak("Invalid value for 'bounds': " . $args{'bounds'});
}
# parse inputs
my $_resource_path = '/slides/{name}/slides/{slideIndex}/{slideType}/shapes/{shapeIndex}/{format}';
my $_method = 'PUT';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('application/json');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'out_path'} && defined $args{'out_path'}) {
$query_params->{'outPath'} = $self->{api_client}->to_query_value($args{'out_path'});
}
# query params
if (exists $args{'scale_x'} && defined $args{'scale_x'}) {
$query_params->{'scaleX'} = $self->{api_client}->to_query_value($args{'scale_x'});
}
# query params
if (exists $args{'scale_y'} && defined $args{'scale_y'}) {
$query_params->{'scaleY'} = $self->{api_client}->to_query_value($args{'scale_y'});
}
# query params
if (exists $args{'bounds'} && defined $args{'bounds'}) {
$query_params->{'bounds'} = $self->{api_client}->to_query_value($args{'bounds'});
}
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'height' => {
data_type => 'int',
description => 'The height of created images.',
required => '0',
},
'from' => {
data_type => 'int',
description => 'The start slide number for splitting, if is not specified splitting starts from the first slide of the presentation.',
required => '0',
},
'to' => {
data_type => 'int',
description => 'The last slide number for splitting, if is not specified splitting ends at the last slide of the document.',
required => '0',
},
'dest_folder' => {
data_type => 'string',
description => 'Folder on storage where images are going to be uploaded. If not specified then images are uploaded to same folder as presentation.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'folder' => {
data_type => 'string',
description => 'Document folder.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Custom fonts folder.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'split' } = {
summary => 'Splitting presentations. Create one image per slide.',
params => $params,
returns => 'SplitDocumentResult',
};
}
# @return SplitDocumentResult
#
sub split {
my ($self, %args) = @_;
# verify the required parameter 'name' is set
unless (exists $args{'name'} && defined $args{'name'} && $args{'name'}) {
croak("Missing the required parameter 'name' when calling split");
}
# verify enum value
if (exists $args{'format'} && $args{'format'} && !grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Html', 'Pdf', 'Xps', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Potx', 'Pot', 'Potm', 'Svg', 'Fodp', 'Xaml', 'H...
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/{name}/split';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('application/json');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('application/json');
# query params
if (exists $args{'format'} && defined $args{'format'}) {
$query_params->{'format'} = $self->{api_client}->to_query_value($args{'format'});
}
# query params
if (exists $args{'width'} && defined $args{'width'}) {
$query_params->{'width'} = $self->{api_client}->to_query_value($args{'width'});
}
# query params
if (exists $args{'height'} && defined $args{'height'}) {
$query_params->{'height'} = $self->{api_client}->to_query_value($args{'height'});
}
# query params
if (exists $args{'from'} && defined $args{'from'}) {
$query_params->{'from'} = $self->{api_client}->to_query_value($args{'from'});
}
# query params
if (exists $args{'to'} && defined $args{'to'}) {
$query_params->{'to'} = $self->{api_client}->to_query_value($args{'to'});
}
# query params
if (exists $args{'dest_folder'} && defined $args{'dest_folder'}) {
$query_params->{'destFolder'} = $self->{api_client}->to_query_value($args{'dest_folder'});
}
# query params
if (exists $args{'folder'} && defined $args{'folder'}) {
$query_params->{'folder'} = $self->{api_client}->to_query_value($args{'folder'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'height' => {
data_type => 'int',
description => 'Slide height.',
required => '0',
},
'from' => {
data_type => 'int',
description => 'The start slide number for splitting, if is not specified splitting starts from the first slide of the presentation.',
required => '0',
},
'to' => {
data_type => 'int',
description => 'The last slide number for splitting, if is not specified splitting ends at the last slide of the document.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Custom fonts folder.',
required => '0',
},
'options' => {
data_type => 'ExportOptions',
description => 'Export options.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'split_and_save_online' } = {
summary => 'Splits PowerPoint presentation slides from the specified range into separate files and exports them in the specified file format. If the range is not provided all slides will be processed. ',
params => $params,
returns => 'SplitDocumentResult',
};
}
# @return SplitDocumentResult
#
sub split_and_save_online {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling split_and_save_online");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling split_and_save_online");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Html', 'Pdf', 'Xps', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Potx', 'Pot', 'Potm', 'Svg', 'Fodp', 'Xaml', 'Html5', 'Md', 'Xml', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/split/{format}';
my $_method = 'PUT';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('application/json');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('multipart/form-data');
# query params
if (exists $args{'dest_folder'} && defined $args{'dest_folder'}) {
$query_params->{'destFolder'} = $self->{api_client}->to_query_value($args{'dest_folder'});
}
# query params
if (exists $args{'width'} && defined $args{'width'}) {
$query_params->{'width'} = $self->{api_client}->to_query_value($args{'width'});
}
# query params
if (exists $args{'height'} && defined $args{'height'}) {
$query_params->{'height'} = $self->{api_client}->to_query_value($args{'height'});
}
# query params
if (exists $args{'from'} && defined $args{'from'}) {
$query_params->{'from'} = $self->{api_client}->to_query_value($args{'from'});
}
# query params
if (exists $args{'to'} && defined $args{'to'}) {
$query_params->{'to'} = $self->{api_client}->to_query_value($args{'to'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'format'}) {
lib/AsposeSlidesCloud/SlidesApi.pm view on Meta::CPAN
required => '0',
},
'height' => {
data_type => 'int',
description => 'Slide height.',
required => '0',
},
'from' => {
data_type => 'int',
description => 'The start slide number for splitting, if is not specified splitting starts from the first slide of the presentation.',
required => '0',
},
'to' => {
data_type => 'int',
description => 'The last slide number for splitting, if is not specified splitting ends at the last slide of the document.',
required => '0',
},
'password' => {
data_type => 'string',
description => 'Document password.',
required => '0',
},
'storage' => {
data_type => 'string',
description => 'Document storage.',
required => '0',
},
'fonts_folder' => {
data_type => 'string',
description => 'Custom fonts folder.',
required => '0',
},
'options' => {
data_type => 'ExportOptions',
description => 'Export options.',
required => '0',
},
};
__PACKAGE__->method_documentation->{ 'split_online' } = {
summary => 'Splits PowerPoint presentation slides from the specified range into separate files and exports them in the specified file format. If the range is not provided all slides will be processed. ',
params => $params,
returns => 'File',
};
}
# @return File
#
sub split_online {
my ($self, %args) = @_;
# verify the required parameter 'document' is set
unless (exists $args{'document'} && defined $args{'document'} && $args{'document'}) {
croak("Missing the required parameter 'document' when calling split_online");
}
# verify the required parameter 'format' is set
unless (exists $args{'format'} && defined $args{'format'} && $args{'format'}) {
croak("Missing the required parameter 'format' when calling split_online");
}
# verify enum value
if (!grep(/^$args{'format'}$/i, ( 'Jpeg', 'Png', 'Gif', 'Bmp', 'Tiff', 'Html', 'Pdf', 'Xps', 'Pptx', 'Odp', 'Otp', 'Ppt', 'Pps', 'Ppsx', 'Pptm', 'Ppsm', 'Potx', 'Pot', 'Potm', 'Svg', 'Fodp', 'Xaml', 'Html5', 'Md', 'Xml', 'Emf' ))) {
croak("Invalid value for 'format': " . $args{'format'});
}
# parse inputs
my $_resource_path = '/slides/split/{format}';
my $_method = 'POST';
my $query_params = {};
my $header_params = {};
my $form_params = {};
# 'Accept' and 'Content-Type' header
my $_header_accept = $self->{api_client}->select_header_accept('multipart/form-data');
if ($_header_accept) {
$header_params->{'Accept'} = $_header_accept;
}
$header_params->{'Content-Type'} = $self->{api_client}->select_header_content_type('multipart/form-data');
# query params
if (exists $args{'width'} && defined $args{'width'}) {
$query_params->{'width'} = $self->{api_client}->to_query_value($args{'width'});
}
# query params
if (exists $args{'height'} && defined $args{'height'}) {
$query_params->{'height'} = $self->{api_client}->to_query_value($args{'height'});
}
# query params
if (exists $args{'from'} && defined $args{'from'}) {
$query_params->{'from'} = $self->{api_client}->to_query_value($args{'from'});
}
# query params
if (exists $args{'to'} && defined $args{'to'}) {
$query_params->{'to'} = $self->{api_client}->to_query_value($args{'to'});
}
# query params
if (exists $args{'storage'} && defined $args{'storage'}) {
$query_params->{'storage'} = $self->{api_client}->to_query_value($args{'storage'});
}
# query params
if (exists $args{'fonts_folder'} && defined $args{'fonts_folder'}) {
$query_params->{'fontsFolder'} = $self->{api_client}->to_query_value($args{'fonts_folder'});
}
# header params
if ( exists $args{'password'}) {
$header_params->{':password'} = $self->{api_client}->to_header_value($args{'password'});
}
# path params
if ( exists $args{'format'}) {
my $_base_variable = "{" . "format" . "}";
my $_base_value = $self->{api_client}->to_path_value($args{'format'});
$_resource_path =~ s/$_base_variable/$_base_value/g;
}