cloudmersive-dlp-api-client 2.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +7 -0
- data/Gemfile +7 -0
- data/README.md +124 -0
- data/Rakefile +8 -0
- data/cloudmersive-dlp-api-client.gemspec +45 -0
- data/docs/DetectApi.md +232 -0
- data/docs/DlpAdvancedDetectionRequest.md +43 -0
- data/docs/DlpAdvancedDetectionResponse.md +44 -0
- data/docs/DlpAdvancedDocumentDetectionRequest.md +46 -0
- data/docs/DlpAdvancedDocumentRedactionRequest.md +47 -0
- data/docs/DlpAdvancedDocumentRedactionResponse.md +46 -0
- data/docs/DlpAdvancedRedactionRequest.md +44 -0
- data/docs/DlpAdvancedRedactionResponse.md +44 -0
- data/docs/DlpDetectionRequest.md +31 -0
- data/docs/DlpDetectionResponse.md +31 -0
- data/docs/DlpDocumentDetectionRequest.md +33 -0
- data/docs/DlpDocumentRedactionRequest.md +34 -0
- data/docs/DlpDocumentRedactionResponse.md +33 -0
- data/docs/DlpRedactionRequest.md +32 -0
- data/docs/DlpRedactionResponse.md +32 -0
- data/docs/RedactApi.md +232 -0
- data/docs/RedactedPageInfo.md +8 -0
- data/git_push.sh +55 -0
- data/lib/cloudmersive-dlp-api-client/api/detect_api.rb +223 -0
- data/lib/cloudmersive-dlp-api-client/api/redact_api.rb +223 -0
- data/lib/cloudmersive-dlp-api-client/api_client.rb +391 -0
- data/lib/cloudmersive-dlp-api-client/api_error.rb +38 -0
- data/lib/cloudmersive-dlp-api-client/configuration.rb +209 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_advanced_detection_request.rb +536 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_advanced_detection_response.rb +546 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_advanced_document_detection_request.rb +581 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_advanced_document_redaction_request.rb +591 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_advanced_document_redaction_response.rb +583 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_advanced_redaction_request.rb +546 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_advanced_redaction_response.rb +546 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_detection_request.rb +416 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_detection_response.rb +416 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_document_detection_request.rb +451 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_document_redaction_request.rb +461 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_document_redaction_response.rb +453 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_redaction_request.rb +426 -0
- data/lib/cloudmersive-dlp-api-client/models/dlp_redaction_response.rb +426 -0
- data/lib/cloudmersive-dlp-api-client/models/redacted_page_info.rb +186 -0
- data/lib/cloudmersive-dlp-api-client/version.rb +15 -0
- data/lib/cloudmersive-dlp-api-client.rb +56 -0
- data/spec/api/detect_api_spec.rb +83 -0
- data/spec/api/redact_api_spec.rb +83 -0
- data/spec/api_client_spec.rb +243 -0
- data/spec/configuration_spec.rb +42 -0
- data/spec/models/dlp_advanced_detection_request_spec.rb +251 -0
- data/spec/models/dlp_advanced_detection_response_spec.rb +257 -0
- data/spec/models/dlp_advanced_document_detection_request_spec.rb +269 -0
- data/spec/models/dlp_advanced_document_redaction_request_spec.rb +275 -0
- data/spec/models/dlp_advanced_document_redaction_response_spec.rb +269 -0
- data/spec/models/dlp_advanced_redaction_request_spec.rb +257 -0
- data/spec/models/dlp_advanced_redaction_response_spec.rb +257 -0
- data/spec/models/dlp_detection_request_spec.rb +179 -0
- data/spec/models/dlp_detection_response_spec.rb +179 -0
- data/spec/models/dlp_document_detection_request_spec.rb +191 -0
- data/spec/models/dlp_document_redaction_request_spec.rb +197 -0
- data/spec/models/dlp_document_redaction_response_spec.rb +191 -0
- data/spec/models/dlp_redaction_request_spec.rb +185 -0
- data/spec/models/dlp_redaction_response_spec.rb +185 -0
- data/spec/models/redacted_page_info_spec.rb +41 -0
- data/spec/spec_helper.rb +111 -0
- metadata +290 -0
|
@@ -0,0 +1,546 @@
|
|
|
1
|
+
=begin
|
|
2
|
+
#dlpapi
|
|
3
|
+
|
|
4
|
+
#Easily and directly scan and detect sensitive data (PII) in input text.
|
|
5
|
+
|
|
6
|
+
OpenAPI spec version: v1
|
|
7
|
+
|
|
8
|
+
Generated by: https://github.com/swagger-api/swagger-codegen.git
|
|
9
|
+
Swagger Codegen version: 2.4.14
|
|
10
|
+
|
|
11
|
+
=end
|
|
12
|
+
|
|
13
|
+
require 'date'
|
|
14
|
+
|
|
15
|
+
module CloudmersiveDlpApiClient
|
|
16
|
+
# Response object for advanced DLP text redaction with 34 PII detection results, redacted text, and optional rationale.
|
|
17
|
+
class DlpAdvancedRedactionResponse
|
|
18
|
+
# The redacted text with PII removed or replaced, or the original text if no disallowed PII was found.
|
|
19
|
+
attr_accessor :redacted_text
|
|
20
|
+
|
|
21
|
+
# True if no disallowed PII or sensitive data types were detected; false if any disallowed type was found and redacted.
|
|
22
|
+
attr_accessor :clean_result
|
|
23
|
+
|
|
24
|
+
# True if the input contains email addresses.
|
|
25
|
+
attr_accessor :contains_email_address
|
|
26
|
+
|
|
27
|
+
# True if the input contains phone numbers.
|
|
28
|
+
attr_accessor :contains_phone_number
|
|
29
|
+
|
|
30
|
+
# True if the input contains street addresses.
|
|
31
|
+
attr_accessor :contains_street_address
|
|
32
|
+
|
|
33
|
+
# True if the input contains person names.
|
|
34
|
+
attr_accessor :contains_person_name
|
|
35
|
+
|
|
36
|
+
# True if the input contains birth dates.
|
|
37
|
+
attr_accessor :contains_birth_date
|
|
38
|
+
|
|
39
|
+
# True if the input contains passport numbers.
|
|
40
|
+
attr_accessor :contains_passport_number
|
|
41
|
+
|
|
42
|
+
# True if the input contains drivers license numbers.
|
|
43
|
+
attr_accessor :contains_drivers_license
|
|
44
|
+
|
|
45
|
+
# True if the input contains social security numbers.
|
|
46
|
+
attr_accessor :contains_social_security_number
|
|
47
|
+
|
|
48
|
+
# True if the input contains taxpayer IDs.
|
|
49
|
+
attr_accessor :contains_taxpayer_id
|
|
50
|
+
|
|
51
|
+
# True if the input contains credit card numbers.
|
|
52
|
+
attr_accessor :contains_credit_card_number
|
|
53
|
+
|
|
54
|
+
# True if the input contains credit card expiration dates.
|
|
55
|
+
attr_accessor :contains_credit_card_expiration_date
|
|
56
|
+
|
|
57
|
+
# True if the input contains credit card verification codes.
|
|
58
|
+
attr_accessor :contains_credit_card_verification_code
|
|
59
|
+
|
|
60
|
+
# True if the input contains bank account numbers.
|
|
61
|
+
attr_accessor :contains_bank_account_number
|
|
62
|
+
|
|
63
|
+
# True if the input contains IBANs.
|
|
64
|
+
attr_accessor :contains_iban
|
|
65
|
+
|
|
66
|
+
# True if the input contains health insurance numbers.
|
|
67
|
+
attr_accessor :contains_health_insurance_number
|
|
68
|
+
|
|
69
|
+
# True if the input contains bearer tokens.
|
|
70
|
+
attr_accessor :contains_bearer_token
|
|
71
|
+
|
|
72
|
+
# True if the input contains HTTP cookies.
|
|
73
|
+
attr_accessor :contains_http_cookie
|
|
74
|
+
|
|
75
|
+
# True if the input contains private keys.
|
|
76
|
+
attr_accessor :contains_private_keys
|
|
77
|
+
|
|
78
|
+
# True if the input contains credentials (usernames/passwords).
|
|
79
|
+
attr_accessor :contains_credentials
|
|
80
|
+
|
|
81
|
+
# True if the input contains deep web URLs (.onion).
|
|
82
|
+
attr_accessor :contains_deep_web_urls
|
|
83
|
+
|
|
84
|
+
# True if the input contains source code.
|
|
85
|
+
attr_accessor :contains_source_code
|
|
86
|
+
|
|
87
|
+
# True if the input contains IP addresses.
|
|
88
|
+
attr_accessor :contains_ip_address
|
|
89
|
+
|
|
90
|
+
# True if the input contains MAC addresses.
|
|
91
|
+
attr_accessor :contains_mac_address
|
|
92
|
+
|
|
93
|
+
# True if the input contains health insurance member IDs.
|
|
94
|
+
attr_accessor :contains_health_insurance_member_id
|
|
95
|
+
|
|
96
|
+
# True if the input contains references to injuries or diseases.
|
|
97
|
+
attr_accessor :contains_health_injury_or_disease
|
|
98
|
+
|
|
99
|
+
# True if the input contains references to types of medical treatment.
|
|
100
|
+
attr_accessor :contains_health_type_of_treatment
|
|
101
|
+
|
|
102
|
+
# True if the input contains dates and times of medical treatment.
|
|
103
|
+
attr_accessor :contains_health_date_and_time_of_treatment
|
|
104
|
+
|
|
105
|
+
# True if the input contains health plan beneficiary numbers.
|
|
106
|
+
attr_accessor :contains_health_plan_beneficiary_number
|
|
107
|
+
|
|
108
|
+
# True if the input contains payments made for medical treatment.
|
|
109
|
+
attr_accessor :contains_health_payments_made_for_treatment
|
|
110
|
+
|
|
111
|
+
# True if the input contains vehicle identifiers (e.g. license plates, VINs).
|
|
112
|
+
attr_accessor :contains_vehicle_id
|
|
113
|
+
|
|
114
|
+
# True if the input contains device identifiers (e.g. serial numbers, IMEIs, MAC-level device IDs).
|
|
115
|
+
attr_accessor :contains_device_id
|
|
116
|
+
|
|
117
|
+
# True if the input contains names of relatives.
|
|
118
|
+
attr_accessor :contains_names_of_relatives
|
|
119
|
+
|
|
120
|
+
# True if the input contains health universal record locators (URLs).
|
|
121
|
+
attr_accessor :contains_health_universal_record_locator
|
|
122
|
+
|
|
123
|
+
# True if the input contains biometric data references (e.g. fingerprints, retinal scans, voiceprints).
|
|
124
|
+
attr_accessor :contains_biometrics
|
|
125
|
+
|
|
126
|
+
# Rationale for why the conclusion was formed. Only populated when ProvideAnalysisRationale is set to true in the request.
|
|
127
|
+
attr_accessor :analysis_rationale
|
|
128
|
+
|
|
129
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
|
130
|
+
def self.attribute_map
|
|
131
|
+
{
|
|
132
|
+
:'redacted_text' => :'RedactedText',
|
|
133
|
+
:'clean_result' => :'CleanResult',
|
|
134
|
+
:'contains_email_address' => :'ContainsEmailAddress',
|
|
135
|
+
:'contains_phone_number' => :'ContainsPhoneNumber',
|
|
136
|
+
:'contains_street_address' => :'ContainsStreetAddress',
|
|
137
|
+
:'contains_person_name' => :'ContainsPersonName',
|
|
138
|
+
:'contains_birth_date' => :'ContainsBirthDate',
|
|
139
|
+
:'contains_passport_number' => :'ContainsPassportNumber',
|
|
140
|
+
:'contains_drivers_license' => :'ContainsDriversLicense',
|
|
141
|
+
:'contains_social_security_number' => :'ContainsSocialSecurityNumber',
|
|
142
|
+
:'contains_taxpayer_id' => :'ContainsTaxpayerID',
|
|
143
|
+
:'contains_credit_card_number' => :'ContainsCreditCardNumber',
|
|
144
|
+
:'contains_credit_card_expiration_date' => :'ContainsCreditCardExpirationDate',
|
|
145
|
+
:'contains_credit_card_verification_code' => :'ContainsCreditCardVerificationCode',
|
|
146
|
+
:'contains_bank_account_number' => :'ContainsBankAccountNumber',
|
|
147
|
+
:'contains_iban' => :'ContainsIBAN',
|
|
148
|
+
:'contains_health_insurance_number' => :'ContainsHealthInsuranceNumber',
|
|
149
|
+
:'contains_bearer_token' => :'ContainsBearerToken',
|
|
150
|
+
:'contains_http_cookie' => :'ContainsHttpCookie',
|
|
151
|
+
:'contains_private_keys' => :'ContainsPrivateKeys',
|
|
152
|
+
:'contains_credentials' => :'ContainsCredentials',
|
|
153
|
+
:'contains_deep_web_urls' => :'ContainsDeepWebUrls',
|
|
154
|
+
:'contains_source_code' => :'ContainsSourceCode',
|
|
155
|
+
:'contains_ip_address' => :'ContainsIpAddress',
|
|
156
|
+
:'contains_mac_address' => :'ContainsMacAddress',
|
|
157
|
+
:'contains_health_insurance_member_id' => :'ContainsHealthInsuranceMemberID',
|
|
158
|
+
:'contains_health_injury_or_disease' => :'ContainsHealthInjuryOrDisease',
|
|
159
|
+
:'contains_health_type_of_treatment' => :'ContainsHealthTypeOfTreatment',
|
|
160
|
+
:'contains_health_date_and_time_of_treatment' => :'ContainsHealthDateAndTimeOfTreatment',
|
|
161
|
+
:'contains_health_plan_beneficiary_number' => :'ContainsHealthPlanBeneficiaryNumber',
|
|
162
|
+
:'contains_health_payments_made_for_treatment' => :'ContainsHealthPaymentsMadeForTreatment',
|
|
163
|
+
:'contains_vehicle_id' => :'ContainsVehicleID',
|
|
164
|
+
:'contains_device_id' => :'ContainsDeviceID',
|
|
165
|
+
:'contains_names_of_relatives' => :'ContainsNamesOfRelatives',
|
|
166
|
+
:'contains_health_universal_record_locator' => :'ContainsHealthUniversalRecordLocator',
|
|
167
|
+
:'contains_biometrics' => :'ContainsBiometrics',
|
|
168
|
+
:'analysis_rationale' => :'AnalysisRationale'
|
|
169
|
+
}
|
|
170
|
+
end
|
|
171
|
+
|
|
172
|
+
# Attribute type mapping.
|
|
173
|
+
def self.swagger_types
|
|
174
|
+
{
|
|
175
|
+
:'redacted_text' => :'String',
|
|
176
|
+
:'clean_result' => :'BOOLEAN',
|
|
177
|
+
:'contains_email_address' => :'BOOLEAN',
|
|
178
|
+
:'contains_phone_number' => :'BOOLEAN',
|
|
179
|
+
:'contains_street_address' => :'BOOLEAN',
|
|
180
|
+
:'contains_person_name' => :'BOOLEAN',
|
|
181
|
+
:'contains_birth_date' => :'BOOLEAN',
|
|
182
|
+
:'contains_passport_number' => :'BOOLEAN',
|
|
183
|
+
:'contains_drivers_license' => :'BOOLEAN',
|
|
184
|
+
:'contains_social_security_number' => :'BOOLEAN',
|
|
185
|
+
:'contains_taxpayer_id' => :'BOOLEAN',
|
|
186
|
+
:'contains_credit_card_number' => :'BOOLEAN',
|
|
187
|
+
:'contains_credit_card_expiration_date' => :'BOOLEAN',
|
|
188
|
+
:'contains_credit_card_verification_code' => :'BOOLEAN',
|
|
189
|
+
:'contains_bank_account_number' => :'BOOLEAN',
|
|
190
|
+
:'contains_iban' => :'BOOLEAN',
|
|
191
|
+
:'contains_health_insurance_number' => :'BOOLEAN',
|
|
192
|
+
:'contains_bearer_token' => :'BOOLEAN',
|
|
193
|
+
:'contains_http_cookie' => :'BOOLEAN',
|
|
194
|
+
:'contains_private_keys' => :'BOOLEAN',
|
|
195
|
+
:'contains_credentials' => :'BOOLEAN',
|
|
196
|
+
:'contains_deep_web_urls' => :'BOOLEAN',
|
|
197
|
+
:'contains_source_code' => :'BOOLEAN',
|
|
198
|
+
:'contains_ip_address' => :'BOOLEAN',
|
|
199
|
+
:'contains_mac_address' => :'BOOLEAN',
|
|
200
|
+
:'contains_health_insurance_member_id' => :'BOOLEAN',
|
|
201
|
+
:'contains_health_injury_or_disease' => :'BOOLEAN',
|
|
202
|
+
:'contains_health_type_of_treatment' => :'BOOLEAN',
|
|
203
|
+
:'contains_health_date_and_time_of_treatment' => :'BOOLEAN',
|
|
204
|
+
:'contains_health_plan_beneficiary_number' => :'BOOLEAN',
|
|
205
|
+
:'contains_health_payments_made_for_treatment' => :'BOOLEAN',
|
|
206
|
+
:'contains_vehicle_id' => :'BOOLEAN',
|
|
207
|
+
:'contains_device_id' => :'BOOLEAN',
|
|
208
|
+
:'contains_names_of_relatives' => :'BOOLEAN',
|
|
209
|
+
:'contains_health_universal_record_locator' => :'BOOLEAN',
|
|
210
|
+
:'contains_biometrics' => :'BOOLEAN',
|
|
211
|
+
:'analysis_rationale' => :'String'
|
|
212
|
+
}
|
|
213
|
+
end
|
|
214
|
+
|
|
215
|
+
# Initializes the object
|
|
216
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
217
|
+
def initialize(attributes = {})
|
|
218
|
+
return unless attributes.is_a?(Hash)
|
|
219
|
+
|
|
220
|
+
# convert string to symbol for hash key
|
|
221
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
|
222
|
+
|
|
223
|
+
if attributes.has_key?(:'RedactedText')
|
|
224
|
+
self.redacted_text = attributes[:'RedactedText']
|
|
225
|
+
end
|
|
226
|
+
|
|
227
|
+
if attributes.has_key?(:'CleanResult')
|
|
228
|
+
self.clean_result = attributes[:'CleanResult']
|
|
229
|
+
end
|
|
230
|
+
|
|
231
|
+
if attributes.has_key?(:'ContainsEmailAddress')
|
|
232
|
+
self.contains_email_address = attributes[:'ContainsEmailAddress']
|
|
233
|
+
end
|
|
234
|
+
|
|
235
|
+
if attributes.has_key?(:'ContainsPhoneNumber')
|
|
236
|
+
self.contains_phone_number = attributes[:'ContainsPhoneNumber']
|
|
237
|
+
end
|
|
238
|
+
|
|
239
|
+
if attributes.has_key?(:'ContainsStreetAddress')
|
|
240
|
+
self.contains_street_address = attributes[:'ContainsStreetAddress']
|
|
241
|
+
end
|
|
242
|
+
|
|
243
|
+
if attributes.has_key?(:'ContainsPersonName')
|
|
244
|
+
self.contains_person_name = attributes[:'ContainsPersonName']
|
|
245
|
+
end
|
|
246
|
+
|
|
247
|
+
if attributes.has_key?(:'ContainsBirthDate')
|
|
248
|
+
self.contains_birth_date = attributes[:'ContainsBirthDate']
|
|
249
|
+
end
|
|
250
|
+
|
|
251
|
+
if attributes.has_key?(:'ContainsPassportNumber')
|
|
252
|
+
self.contains_passport_number = attributes[:'ContainsPassportNumber']
|
|
253
|
+
end
|
|
254
|
+
|
|
255
|
+
if attributes.has_key?(:'ContainsDriversLicense')
|
|
256
|
+
self.contains_drivers_license = attributes[:'ContainsDriversLicense']
|
|
257
|
+
end
|
|
258
|
+
|
|
259
|
+
if attributes.has_key?(:'ContainsSocialSecurityNumber')
|
|
260
|
+
self.contains_social_security_number = attributes[:'ContainsSocialSecurityNumber']
|
|
261
|
+
end
|
|
262
|
+
|
|
263
|
+
if attributes.has_key?(:'ContainsTaxpayerID')
|
|
264
|
+
self.contains_taxpayer_id = attributes[:'ContainsTaxpayerID']
|
|
265
|
+
end
|
|
266
|
+
|
|
267
|
+
if attributes.has_key?(:'ContainsCreditCardNumber')
|
|
268
|
+
self.contains_credit_card_number = attributes[:'ContainsCreditCardNumber']
|
|
269
|
+
end
|
|
270
|
+
|
|
271
|
+
if attributes.has_key?(:'ContainsCreditCardExpirationDate')
|
|
272
|
+
self.contains_credit_card_expiration_date = attributes[:'ContainsCreditCardExpirationDate']
|
|
273
|
+
end
|
|
274
|
+
|
|
275
|
+
if attributes.has_key?(:'ContainsCreditCardVerificationCode')
|
|
276
|
+
self.contains_credit_card_verification_code = attributes[:'ContainsCreditCardVerificationCode']
|
|
277
|
+
end
|
|
278
|
+
|
|
279
|
+
if attributes.has_key?(:'ContainsBankAccountNumber')
|
|
280
|
+
self.contains_bank_account_number = attributes[:'ContainsBankAccountNumber']
|
|
281
|
+
end
|
|
282
|
+
|
|
283
|
+
if attributes.has_key?(:'ContainsIBAN')
|
|
284
|
+
self.contains_iban = attributes[:'ContainsIBAN']
|
|
285
|
+
end
|
|
286
|
+
|
|
287
|
+
if attributes.has_key?(:'ContainsHealthInsuranceNumber')
|
|
288
|
+
self.contains_health_insurance_number = attributes[:'ContainsHealthInsuranceNumber']
|
|
289
|
+
end
|
|
290
|
+
|
|
291
|
+
if attributes.has_key?(:'ContainsBearerToken')
|
|
292
|
+
self.contains_bearer_token = attributes[:'ContainsBearerToken']
|
|
293
|
+
end
|
|
294
|
+
|
|
295
|
+
if attributes.has_key?(:'ContainsHttpCookie')
|
|
296
|
+
self.contains_http_cookie = attributes[:'ContainsHttpCookie']
|
|
297
|
+
end
|
|
298
|
+
|
|
299
|
+
if attributes.has_key?(:'ContainsPrivateKeys')
|
|
300
|
+
self.contains_private_keys = attributes[:'ContainsPrivateKeys']
|
|
301
|
+
end
|
|
302
|
+
|
|
303
|
+
if attributes.has_key?(:'ContainsCredentials')
|
|
304
|
+
self.contains_credentials = attributes[:'ContainsCredentials']
|
|
305
|
+
end
|
|
306
|
+
|
|
307
|
+
if attributes.has_key?(:'ContainsDeepWebUrls')
|
|
308
|
+
self.contains_deep_web_urls = attributes[:'ContainsDeepWebUrls']
|
|
309
|
+
end
|
|
310
|
+
|
|
311
|
+
if attributes.has_key?(:'ContainsSourceCode')
|
|
312
|
+
self.contains_source_code = attributes[:'ContainsSourceCode']
|
|
313
|
+
end
|
|
314
|
+
|
|
315
|
+
if attributes.has_key?(:'ContainsIpAddress')
|
|
316
|
+
self.contains_ip_address = attributes[:'ContainsIpAddress']
|
|
317
|
+
end
|
|
318
|
+
|
|
319
|
+
if attributes.has_key?(:'ContainsMacAddress')
|
|
320
|
+
self.contains_mac_address = attributes[:'ContainsMacAddress']
|
|
321
|
+
end
|
|
322
|
+
|
|
323
|
+
if attributes.has_key?(:'ContainsHealthInsuranceMemberID')
|
|
324
|
+
self.contains_health_insurance_member_id = attributes[:'ContainsHealthInsuranceMemberID']
|
|
325
|
+
end
|
|
326
|
+
|
|
327
|
+
if attributes.has_key?(:'ContainsHealthInjuryOrDisease')
|
|
328
|
+
self.contains_health_injury_or_disease = attributes[:'ContainsHealthInjuryOrDisease']
|
|
329
|
+
end
|
|
330
|
+
|
|
331
|
+
if attributes.has_key?(:'ContainsHealthTypeOfTreatment')
|
|
332
|
+
self.contains_health_type_of_treatment = attributes[:'ContainsHealthTypeOfTreatment']
|
|
333
|
+
end
|
|
334
|
+
|
|
335
|
+
if attributes.has_key?(:'ContainsHealthDateAndTimeOfTreatment')
|
|
336
|
+
self.contains_health_date_and_time_of_treatment = attributes[:'ContainsHealthDateAndTimeOfTreatment']
|
|
337
|
+
end
|
|
338
|
+
|
|
339
|
+
if attributes.has_key?(:'ContainsHealthPlanBeneficiaryNumber')
|
|
340
|
+
self.contains_health_plan_beneficiary_number = attributes[:'ContainsHealthPlanBeneficiaryNumber']
|
|
341
|
+
end
|
|
342
|
+
|
|
343
|
+
if attributes.has_key?(:'ContainsHealthPaymentsMadeForTreatment')
|
|
344
|
+
self.contains_health_payments_made_for_treatment = attributes[:'ContainsHealthPaymentsMadeForTreatment']
|
|
345
|
+
end
|
|
346
|
+
|
|
347
|
+
if attributes.has_key?(:'ContainsVehicleID')
|
|
348
|
+
self.contains_vehicle_id = attributes[:'ContainsVehicleID']
|
|
349
|
+
end
|
|
350
|
+
|
|
351
|
+
if attributes.has_key?(:'ContainsDeviceID')
|
|
352
|
+
self.contains_device_id = attributes[:'ContainsDeviceID']
|
|
353
|
+
end
|
|
354
|
+
|
|
355
|
+
if attributes.has_key?(:'ContainsNamesOfRelatives')
|
|
356
|
+
self.contains_names_of_relatives = attributes[:'ContainsNamesOfRelatives']
|
|
357
|
+
end
|
|
358
|
+
|
|
359
|
+
if attributes.has_key?(:'ContainsHealthUniversalRecordLocator')
|
|
360
|
+
self.contains_health_universal_record_locator = attributes[:'ContainsHealthUniversalRecordLocator']
|
|
361
|
+
end
|
|
362
|
+
|
|
363
|
+
if attributes.has_key?(:'ContainsBiometrics')
|
|
364
|
+
self.contains_biometrics = attributes[:'ContainsBiometrics']
|
|
365
|
+
end
|
|
366
|
+
|
|
367
|
+
if attributes.has_key?(:'AnalysisRationale')
|
|
368
|
+
self.analysis_rationale = attributes[:'AnalysisRationale']
|
|
369
|
+
end
|
|
370
|
+
end
|
|
371
|
+
|
|
372
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
|
373
|
+
# @return Array for valid properties with the reasons
|
|
374
|
+
def list_invalid_properties
|
|
375
|
+
invalid_properties = Array.new
|
|
376
|
+
invalid_properties
|
|
377
|
+
end
|
|
378
|
+
|
|
379
|
+
# Check to see if the all the properties in the model are valid
|
|
380
|
+
# @return true if the model is valid
|
|
381
|
+
def valid?
|
|
382
|
+
true
|
|
383
|
+
end
|
|
384
|
+
|
|
385
|
+
# Checks equality by comparing each attribute.
|
|
386
|
+
# @param [Object] Object to be compared
|
|
387
|
+
def ==(o)
|
|
388
|
+
return true if self.equal?(o)
|
|
389
|
+
self.class == o.class &&
|
|
390
|
+
redacted_text == o.redacted_text &&
|
|
391
|
+
clean_result == o.clean_result &&
|
|
392
|
+
contains_email_address == o.contains_email_address &&
|
|
393
|
+
contains_phone_number == o.contains_phone_number &&
|
|
394
|
+
contains_street_address == o.contains_street_address &&
|
|
395
|
+
contains_person_name == o.contains_person_name &&
|
|
396
|
+
contains_birth_date == o.contains_birth_date &&
|
|
397
|
+
contains_passport_number == o.contains_passport_number &&
|
|
398
|
+
contains_drivers_license == o.contains_drivers_license &&
|
|
399
|
+
contains_social_security_number == o.contains_social_security_number &&
|
|
400
|
+
contains_taxpayer_id == o.contains_taxpayer_id &&
|
|
401
|
+
contains_credit_card_number == o.contains_credit_card_number &&
|
|
402
|
+
contains_credit_card_expiration_date == o.contains_credit_card_expiration_date &&
|
|
403
|
+
contains_credit_card_verification_code == o.contains_credit_card_verification_code &&
|
|
404
|
+
contains_bank_account_number == o.contains_bank_account_number &&
|
|
405
|
+
contains_iban == o.contains_iban &&
|
|
406
|
+
contains_health_insurance_number == o.contains_health_insurance_number &&
|
|
407
|
+
contains_bearer_token == o.contains_bearer_token &&
|
|
408
|
+
contains_http_cookie == o.contains_http_cookie &&
|
|
409
|
+
contains_private_keys == o.contains_private_keys &&
|
|
410
|
+
contains_credentials == o.contains_credentials &&
|
|
411
|
+
contains_deep_web_urls == o.contains_deep_web_urls &&
|
|
412
|
+
contains_source_code == o.contains_source_code &&
|
|
413
|
+
contains_ip_address == o.contains_ip_address &&
|
|
414
|
+
contains_mac_address == o.contains_mac_address &&
|
|
415
|
+
contains_health_insurance_member_id == o.contains_health_insurance_member_id &&
|
|
416
|
+
contains_health_injury_or_disease == o.contains_health_injury_or_disease &&
|
|
417
|
+
contains_health_type_of_treatment == o.contains_health_type_of_treatment &&
|
|
418
|
+
contains_health_date_and_time_of_treatment == o.contains_health_date_and_time_of_treatment &&
|
|
419
|
+
contains_health_plan_beneficiary_number == o.contains_health_plan_beneficiary_number &&
|
|
420
|
+
contains_health_payments_made_for_treatment == o.contains_health_payments_made_for_treatment &&
|
|
421
|
+
contains_vehicle_id == o.contains_vehicle_id &&
|
|
422
|
+
contains_device_id == o.contains_device_id &&
|
|
423
|
+
contains_names_of_relatives == o.contains_names_of_relatives &&
|
|
424
|
+
contains_health_universal_record_locator == o.contains_health_universal_record_locator &&
|
|
425
|
+
contains_biometrics == o.contains_biometrics &&
|
|
426
|
+
analysis_rationale == o.analysis_rationale
|
|
427
|
+
end
|
|
428
|
+
|
|
429
|
+
# @see the `==` method
|
|
430
|
+
# @param [Object] Object to be compared
|
|
431
|
+
def eql?(o)
|
|
432
|
+
self == o
|
|
433
|
+
end
|
|
434
|
+
|
|
435
|
+
# Calculates hash code according to all attributes.
|
|
436
|
+
# @return [Fixnum] Hash code
|
|
437
|
+
def hash
|
|
438
|
+
[redacted_text, clean_result, contains_email_address, contains_phone_number, contains_street_address, contains_person_name, contains_birth_date, contains_passport_number, contains_drivers_license, contains_social_security_number, contains_taxpayer_id, contains_credit_card_number, contains_credit_card_expiration_date, contains_credit_card_verification_code, contains_bank_account_number, contains_iban, contains_health_insurance_number, contains_bearer_token, contains_http_cookie, contains_private_keys, contains_credentials, contains_deep_web_urls, contains_source_code, contains_ip_address, contains_mac_address, contains_health_insurance_member_id, contains_health_injury_or_disease, contains_health_type_of_treatment, contains_health_date_and_time_of_treatment, contains_health_plan_beneficiary_number, contains_health_payments_made_for_treatment, contains_vehicle_id, contains_device_id, contains_names_of_relatives, contains_health_universal_record_locator, contains_biometrics, analysis_rationale].hash
|
|
439
|
+
end
|
|
440
|
+
|
|
441
|
+
# Builds the object from hash
|
|
442
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
|
443
|
+
# @return [Object] Returns the model itself
|
|
444
|
+
def build_from_hash(attributes)
|
|
445
|
+
return nil unless attributes.is_a?(Hash)
|
|
446
|
+
self.class.swagger_types.each_pair do |key, type|
|
|
447
|
+
if type =~ /\AArray<(.*)>/i
|
|
448
|
+
# check to ensure the input is an array given that the attribute
|
|
449
|
+
# is documented as an array but the input is not
|
|
450
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
|
451
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
|
452
|
+
end
|
|
453
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
|
454
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
|
455
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
|
456
|
+
end
|
|
457
|
+
|
|
458
|
+
self
|
|
459
|
+
end
|
|
460
|
+
|
|
461
|
+
# Deserializes the data based on type
|
|
462
|
+
# @param string type Data type
|
|
463
|
+
# @param string value Value to be deserialized
|
|
464
|
+
# @return [Object] Deserialized data
|
|
465
|
+
def _deserialize(type, value)
|
|
466
|
+
case type.to_sym
|
|
467
|
+
when :DateTime
|
|
468
|
+
DateTime.parse(value)
|
|
469
|
+
when :Date
|
|
470
|
+
Date.parse(value)
|
|
471
|
+
when :String
|
|
472
|
+
value.to_s
|
|
473
|
+
when :Integer
|
|
474
|
+
value.to_i
|
|
475
|
+
when :Float
|
|
476
|
+
value.to_f
|
|
477
|
+
when :BOOLEAN
|
|
478
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
|
479
|
+
true
|
|
480
|
+
else
|
|
481
|
+
false
|
|
482
|
+
end
|
|
483
|
+
when :Object
|
|
484
|
+
# generic object (usually a Hash), return directly
|
|
485
|
+
value
|
|
486
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
|
487
|
+
inner_type = Regexp.last_match[:inner_type]
|
|
488
|
+
value.map { |v| _deserialize(inner_type, v) }
|
|
489
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
|
490
|
+
k_type = Regexp.last_match[:k_type]
|
|
491
|
+
v_type = Regexp.last_match[:v_type]
|
|
492
|
+
{}.tap do |hash|
|
|
493
|
+
value.each do |k, v|
|
|
494
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
|
495
|
+
end
|
|
496
|
+
end
|
|
497
|
+
else # model
|
|
498
|
+
temp_model = CloudmersiveDlpApiClient.const_get(type).new
|
|
499
|
+
temp_model.build_from_hash(value)
|
|
500
|
+
end
|
|
501
|
+
end
|
|
502
|
+
|
|
503
|
+
# Returns the string representation of the object
|
|
504
|
+
# @return [String] String presentation of the object
|
|
505
|
+
def to_s
|
|
506
|
+
to_hash.to_s
|
|
507
|
+
end
|
|
508
|
+
|
|
509
|
+
# to_body is an alias to to_hash (backward compatibility)
|
|
510
|
+
# @return [Hash] Returns the object in the form of hash
|
|
511
|
+
def to_body
|
|
512
|
+
to_hash
|
|
513
|
+
end
|
|
514
|
+
|
|
515
|
+
# Returns the object in the form of hash
|
|
516
|
+
# @return [Hash] Returns the object in the form of hash
|
|
517
|
+
def to_hash
|
|
518
|
+
hash = {}
|
|
519
|
+
self.class.attribute_map.each_pair do |attr, param|
|
|
520
|
+
value = self.send(attr)
|
|
521
|
+
next if value.nil?
|
|
522
|
+
hash[param] = _to_hash(value)
|
|
523
|
+
end
|
|
524
|
+
hash
|
|
525
|
+
end
|
|
526
|
+
|
|
527
|
+
# Outputs non-array value in the form of hash
|
|
528
|
+
# For object, use to_hash. Otherwise, just return the value
|
|
529
|
+
# @param [Object] value Any valid value
|
|
530
|
+
# @return [Hash] Returns the value in the form of hash
|
|
531
|
+
def _to_hash(value)
|
|
532
|
+
if value.is_a?(Array)
|
|
533
|
+
value.compact.map { |v| _to_hash(v) }
|
|
534
|
+
elsif value.is_a?(Hash)
|
|
535
|
+
{}.tap do |hash|
|
|
536
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
|
537
|
+
end
|
|
538
|
+
elsif value.respond_to? :to_hash
|
|
539
|
+
value.to_hash
|
|
540
|
+
else
|
|
541
|
+
value
|
|
542
|
+
end
|
|
543
|
+
end
|
|
544
|
+
|
|
545
|
+
end
|
|
546
|
+
end
|