=begin comment Copyright (c) 2025 Aspose.Cells Cloud Permission is hereby granted, free of charge, to any person obtaining a copy of this software and associated documentation files (the "Software"), to deal in the Software without restriction, including without limitation the rights to use, copy, modify, merge, publish, distribute, sublicense, and/or sell copies of the Software, and to permit persons to whom the Software is furnished to do so, subject to the following conditions: The above copyright notice and this permission notice shall be included in all copies or substantial portions of the Software. THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. =end comment =cut package AsposeCellsCloud::Request::DeleteMetadataRequest; require 5.6.0; use strict; use warnings; use utf8; use JSON ; use Data::Dumper; use Module::Runtime qw(use_module); use Log::Any qw($log); use Date::Parse; use DateTime; use base ("Class::Accessor", "Class::Data::Inheritable"); __PACKAGE__->mk_classdata('attribute_map' => {}); __PACKAGE__->mk_classdata('method_documentation' => {}); __PACKAGE__->mk_classdata('class_documentation' => {}); # new object sub new { my ($class, %args) = @_; my $self = bless {}, $class; foreach my $attribute (keys %{$class->attribute_map}) { my $args_key = $class->attribute_map->{$attribute}; $self->$attribute( $args{ $args_key } ); } return $self; } # Run Operation Request # DeleteMetadataRequest.File : File to upload , # DeleteMetadataRequest.type : Cells document property name. , # DeleteMetadataRequest.outFormat : The output data file format.(CSV/XLS/HTML/MHTML/ODS/PDF/XML/TXT/TIFF/XLSB/XLSM/XLSX/XLTM/XLTX/XPS/PNG/JPG/JPEG/GIF/EMF/BMP/MD[Markdown]/Numbers) , # DeleteMetadataRequest.password : The password needed to open an Excel file. , # DeleteMetadataRequest.checkExcelRestriction : Whether check restriction of excel file when user modify cells related objects. { my $params = { 'client' =>{ data_type => 'ApiClient', description => 'API Client.', required => '0', } }; __PACKAGE__->method_documentation->{ 'delete_metadata' } = { summary => 'Delete cells document properties in Excel file, and save them is various formats.', params => $params, returns => 'FilesResult', }; } sub run_http_request { my ($self, %args) = @_; my $client = $args{'client'}; # parse inputs my $_resource_path = '/cells/metadata/delete'; my $_method = 'POST'; my $query_params = {}; my $header_params = {}; my $form_params = {}; my $_header_accept = $client->select_header_accept('application/json'); if ($_header_accept) { $header_params->{'Accept'} = $_header_accept; } $header_params->{'Content-Type'} = $client->select_header_content_type('multipart/form-data'); if(defined $self->type){ $query_params->{'type'} = $client->to_query_value($self->type); } if(defined $self->out_format){ $query_params->{'outFormat'} = $client->to_query_value($self->out_format); } if(defined $self->password){ $query_params->{'password'} = $client->to_query_value($self->password); } if(defined $self->check_excel_restriction){ $query_params->{'checkExcelRestriction'} = $client->to_query_value($self->check_excel_restriction); } my $_body_data; if (defined $self->file) { my $map_file = $self->file; while ( my ($filename,$value) = each( %$map_file ) ) { $form_params->{$filename} = [$value ,$filename,'application/octet-stream']; } } # authentication setting, if any my $auth_settings = [qw()]; # make the API Call my $response = $client->call_api($_resource_path, $_method, $query_params, $form_params, $header_params, $_body_data, $auth_settings); return $response; } __PACKAGE__->method_documentation({ 'file' => { datatype => 'string', base_name => 'File', description => 'File to upload', format => '', read_only => '', }, 'type' => { datatype => 'string', base_name => 'type', description => 'Cells document property name.', format => '', read_only => '', }, 'out_format' => { datatype => 'string', base_name => 'outFormat', description => 'The output data file format.(CSV/XLS/HTML/MHTML/ODS/PDF/XML/TXT/TIFF/XLSB/XLSM/XLSX/XLTM/XLTX/XPS/PNG/JPG/JPEG/GIF/EMF/BMP/MD[Markdown]/Numbers)', format => '', read_only => '', }, 'password' => { datatype => 'string', base_name => 'password', description => 'The password needed to open an Excel file.', format => '', read_only => '', }, 'check_excel_restriction' => { datatype => 'string', base_name => 'checkExcelRestriction', description => 'Whether check restriction of excel file when user modify cells related objects.', format => '', read_only => '', }, }); __PACKAGE__->attribute_map( { 'file' => 'File', 'type' => 'type', 'out_format' => 'outFormat', 'password' => 'password', 'check_excel_restriction' => 'checkExcelRestriction' } ); __PACKAGE__->mk_accessors(keys %{__PACKAGE__->attribute_map}); 1;