Class: AsposeEmailCloud::AiBcrParseRequest
- Inherits:
-
EmailRequest
- Object
- EmailRequest
- AsposeEmailCloud::AiBcrParseRequest
- Defined in:
- lib/aspose-email-cloud/models/ai_bcr_parse_request.rb
Overview
Request model for ai_bcr_parse operation.
Instance Attribute Summary collapse
-
#countries ⇒ String
Comma-separated codes of countries.
-
#file ⇒ File
File to parse.
-
#is_single ⇒ BOOLEAN
Determines that image contains single VCard or more.
-
#languages ⇒ String
Comma-separated ISO-639 codes of languages (either 639-1 or 639-3; i.e. "it" or "ita" for Italian); it's "" by default.
Instance Method Summary collapse
-
#initialize(file:, countries: nil, languages: nil, is_single: nil) ⇒ AiBcrParseRequest
constructor
Parse images to vCard document models.
- #to_http_info(api_client) ⇒ Object
Methods inherited from EmailRequest
select_header_accept, select_header_content_type
Constructor Details
#initialize(file:, countries: nil, languages: nil, is_single: nil) ⇒ AiBcrParseRequest
Parse images to vCard document models
50 51 52 53 54 55 |
# File 'lib/aspose-email-cloud/models/ai_bcr_parse_request.rb', line 50 def initialize(file:, countries: nil, languages: nil, is_single: nil) self.file = file if file self.countries = countries if countries self.languages = languages if languages self.is_single = is_single if is_single end |
Instance Attribute Details
#countries ⇒ String
Comma-separated codes of countries.
37 38 39 |
# File 'lib/aspose-email-cloud/models/ai_bcr_parse_request.rb', line 37 def countries @countries end |
#file ⇒ File
File to parse
34 35 36 |
# File 'lib/aspose-email-cloud/models/ai_bcr_parse_request.rb', line 34 def file @file end |
#is_single ⇒ BOOLEAN
Determines that image contains single VCard or more.
43 44 45 |
# File 'lib/aspose-email-cloud/models/ai_bcr_parse_request.rb', line 43 def is_single @is_single end |
#languages ⇒ String
Comma-separated ISO-639 codes of languages (either 639-1 or 639-3; i.e. "it" or "ita" for Italian); it's "" by default.
40 41 42 |
# File 'lib/aspose-email-cloud/models/ai_bcr_parse_request.rb', line 40 def languages @languages end |
Instance Method Details
#to_http_info(api_client) ⇒ Object
57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 |
# File 'lib/aspose-email-cloud/models/ai_bcr_parse_request.rb', line 57 def to_http_info(api_client) # verify the required parameter 'file' is set if api_client.config.client_side_validation && self.file.nil? raise ArgumentError, "Missing the required parameter 'file' when calling AiBcrApi.parse" end # resource path local_var_path = '/email/AiBcr/parse' # query parameters query_params = {} query_params[:countries] = self.countries unless self.countries.nil? query_params[:languages] = self.languages unless self.languages.nil? query_params[:isSingle] = self.is_single unless self.is_single.nil? # form parameters form_params = {} form_params['File'] = self.file # http body (model) auth_names = ['JWT'] # header parameters header_params = {} # HTTP header 'Accept' (if needed) header_params['Accept'] = EmailRequest.select_header_accept(['application/json']) # HTTP header 'Content-Type' header_params['Content-Type'] = form_params.any? ? 'multipart/form-data' : EmailRequest.select_header_content_type(['multipart/form-data']) AsposeEmailCloud::HttpRequest.new(resource_path: local_var_path, header_params: header_params, query_params: query_params, form_params: form_params, auth_names: auth_names) end |