docusign_esign 2.2.0.pre.rc1 → 2.2.0.rc2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (75) hide show
  1. checksums.yaml +4 -4
  2. data/docusign_esign-3.1.0.rc2.gem +0 -0
  3. data/lib/docusign_esign.rb +386 -450
  4. data/lib/docusign_esign/api/accounts_api.rb +2 -2
  5. data/lib/docusign_esign/api/bulk_envelopes_api.rb +3 -3
  6. data/lib/docusign_esign/version.rb +1 -1
  7. metadata +3 -70
  8. data/docusign_esign-3.1.0.pre.rc1.gem +0 -0
  9. data/lib/docusign_esign/api/.DS_Store +0 -0
  10. data/lib/docusign_esign/models/access_code_format.rb +0 -273
  11. data/lib/docusign_esign/models/account_notification.rb +0 -206
  12. data/lib/docusign_esign/models/account_ui_settings.rb +0 -330
  13. data/lib/docusign_esign/models/bcc_email_archive.rb +0 -276
  14. data/lib/docusign_esign/models/bcc_email_archive_history.rb +0 -237
  15. data/lib/docusign_esign/models/bcc_email_archive_history_list.rb +0 -250
  16. data/lib/docusign_esign/models/bcc_email_archive_list.rb +0 -250
  17. data/lib/docusign_esign/models/bulk_send_request.rb +0 -188
  18. data/lib/docusign_esign/models/bulk_send_response.rb +0 -222
  19. data/lib/docusign_esign/models/bulk_send_test_response.rb +0 -212
  20. data/lib/docusign_esign/models/bulk_sending_copy.rb +0 -222
  21. data/lib/docusign_esign/models/bulk_sending_copy_custom_field.rb +0 -198
  22. data/lib/docusign_esign/models/bulk_sending_copy_recipient.rb +0 -382
  23. data/lib/docusign_esign/models/bulk_sending_copy_tab.rb +0 -198
  24. data/lib/docusign_esign/models/bulk_sending_list.rb +0 -210
  25. data/lib/docusign_esign/models/bulk_sending_list_summaries.rb +0 -190
  26. data/lib/docusign_esign/models/bulk_sending_list_summary.rb +0 -218
  27. data/lib/docusign_esign/models/comment.rb +0 -392
  28. data/lib/docusign_esign/models/comment_history_result.rb +0 -220
  29. data/lib/docusign_esign/models/comment_publish.rb +0 -244
  30. data/lib/docusign_esign/models/comment_thread.rb +0 -961
  31. data/lib/docusign_esign/models/comments_publish.rb +0 -190
  32. data/lib/docusign_esign/models/connect_salesforce_field.rb +0 -258
  33. data/lib/docusign_esign/models/connect_salesforce_object.rb +0 -272
  34. data/lib/docusign_esign/models/connect_user_object.rb +0 -230
  35. data/lib/docusign_esign/models/direct_debit_processor_information.rb +0 -298
  36. data/lib/docusign_esign/models/display_appliance_document.rb +0 -258
  37. data/lib/docusign_esign/models/display_appliance_document_page.rb +0 -278
  38. data/lib/docusign_esign/models/display_appliance_envelope.rb +0 -328
  39. data/lib/docusign_esign/models/display_appliance_info.rb +0 -235
  40. data/lib/docusign_esign/models/display_appliance_page.rb +0 -278
  41. data/lib/docusign_esign/models/display_appliance_pdf.rb +0 -267
  42. data/lib/docusign_esign/models/display_appliance_recipient.rb +0 -388
  43. data/lib/docusign_esign/models/display_appliance_signer_attachment.rb +0 -248
  44. data/lib/docusign_esign/models/envelope_metadata.rb +0 -208
  45. data/lib/docusign_esign/models/envelope_purge_configuration.rb +0 -218
  46. data/lib/docusign_esign/models/envelope_transfer_rule.rb +0 -273
  47. data/lib/docusign_esign/models/envelope_transfer_rule_information.rb +0 -250
  48. data/lib/docusign_esign/models/envelope_transfer_rule_request.rb +0 -279
  49. data/lib/docusign_esign/models/external_claim.rb +0 -218
  50. data/lib/docusign_esign/models/external_document_sources.rb +0 -273
  51. data/lib/docusign_esign/models/favorite_templates_content_item.rb +0 -207
  52. data/lib/docusign_esign/models/favorite_templates_info.rb +0 -209
  53. data/lib/docusign_esign/models/feature_available_metadata.rb +0 -198
  54. data/lib/docusign_esign/models/folder_shared_item.rb +0 -289
  55. data/lib/docusign_esign/models/form_data_item.rb +0 -227
  56. data/lib/docusign_esign/models/graphics_context.rb +0 -208
  57. data/lib/docusign_esign/models/id_check_configuration.rb +0 -210
  58. data/lib/docusign_esign/models/id_check_security_step.rb +0 -188
  59. data/lib/docusign_esign/models/locale_policy.rb +0 -595
  60. data/lib/docusign_esign/models/locale_policy_tab.rb +0 -298
  61. data/lib/docusign_esign/models/notification_default_settings.rb +0 -196
  62. data/lib/docusign_esign/models/notification_defaults.rb +0 -196
  63. data/lib/docusign_esign/models/page_size.rb +0 -198
  64. data/lib/docusign_esign/models/path_extended_element.rb +0 -208
  65. data/lib/docusign_esign/models/pay_pal_legacy_settings.rb +0 -228
  66. data/lib/docusign_esign/models/payment_gateway_account_setting.rb +0 -218
  67. data/lib/docusign_esign/models/payment_method_with_options.rb +0 -200
  68. data/lib/docusign_esign/models/poly_line.rb +0 -218
  69. data/lib/docusign_esign/models/poly_line_overlay.rb +0 -885
  70. data/lib/docusign_esign/models/recipient_preview_request.rb +0 -278
  71. data/lib/docusign_esign/models/signature_properties.rb +0 -198
  72. data/lib/docusign_esign/models/tab_group.rb +0 -911
  73. data/lib/docusign_esign/models/workspace_settings.rb +0 -188
  74. data/tests/Gemfile.lock +0 -42
  75. data/tests/docs/private.pem +0 -27
@@ -1,218 +0,0 @@
1
- =begin
2
- #DocuSign REST API
3
-
4
- #The DocuSign REST API provides you with a powerful, convenient, and simple Web services API for interacting with DocuSign.
5
-
6
- OpenAPI spec version: v2.1
7
- Contact: devcenter@docusign.com
8
- Generated by: https://github.com/swagger-api/swagger-codegen.git
9
-
10
- =end
11
-
12
- require 'date'
13
-
14
- module DocuSign_eSign
15
-
16
- class PolyLine
17
- #
18
- attr_accessor :x1
19
-
20
- #
21
- attr_accessor :x2
22
-
23
- #
24
- attr_accessor :y1
25
-
26
- #
27
- attr_accessor :y2
28
-
29
-
30
- # Attribute mapping from ruby-style variable name to JSON key.
31
- def self.attribute_map
32
- {
33
- :'x1' => :'x1',
34
- :'x2' => :'x2',
35
- :'y1' => :'y1',
36
- :'y2' => :'y2'
37
- }
38
- end
39
-
40
- # Attribute type mapping.
41
- def self.swagger_types
42
- {
43
- :'x1' => :'String',
44
- :'x2' => :'String',
45
- :'y1' => :'String',
46
- :'y2' => :'String'
47
- }
48
- end
49
-
50
- # Initializes the object
51
- # @param [Hash] attributes Model attributes in the form of hash
52
- def initialize(attributes = {})
53
- return unless attributes.is_a?(Hash)
54
-
55
- # convert string to symbol for hash key
56
- attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
57
-
58
- if attributes.has_key?(:'x1')
59
- self.x1 = attributes[:'x1']
60
- end
61
-
62
- if attributes.has_key?(:'x2')
63
- self.x2 = attributes[:'x2']
64
- end
65
-
66
- if attributes.has_key?(:'y1')
67
- self.y1 = attributes[:'y1']
68
- end
69
-
70
- if attributes.has_key?(:'y2')
71
- self.y2 = attributes[:'y2']
72
- end
73
-
74
- end
75
-
76
- # Show invalid properties with the reasons. Usually used together with valid?
77
- # @return Array for valid properies with the reasons
78
- def list_invalid_properties
79
- invalid_properties = Array.new
80
- return invalid_properties
81
- end
82
-
83
- # Check to see if the all the properties in the model are valid
84
- # @return true if the model is valid
85
- def valid?
86
- return true
87
- end
88
-
89
- # Checks equality by comparing each attribute.
90
- # @param [Object] Object to be compared
91
- def ==(o)
92
- return true if self.equal?(o)
93
- self.class == o.class &&
94
- x1 == o.x1 &&
95
- x2 == o.x2 &&
96
- y1 == o.y1 &&
97
- y2 == o.y2
98
- end
99
-
100
- # @see the `==` method
101
- # @param [Object] Object to be compared
102
- def eql?(o)
103
- self == o
104
- end
105
-
106
- # Calculates hash code according to all attributes.
107
- # @return [Fixnum] Hash code
108
- def hash
109
- [x1, x2, y1, y2].hash
110
- end
111
-
112
- # Builds the object from hash
113
- # @param [Hash] attributes Model attributes in the form of hash
114
- # @return [Object] Returns the model itself
115
- def build_from_hash(attributes)
116
- return nil unless attributes.is_a?(Hash)
117
- self.class.swagger_types.each_pair do |key, type|
118
- if type =~ /\AArray<(.*)>/i
119
- # check to ensure the input is an array given that the the attribute
120
- # is documented as an array but the input is not
121
- if attributes[self.class.attribute_map[key]].is_a?(Array)
122
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
123
- end
124
- elsif !attributes[self.class.attribute_map[key]].nil?
125
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
126
- end # or else data not found in attributes(hash), not an issue as the data can be optional
127
- end
128
-
129
- self
130
- end
131
-
132
- # Deserializes the data based on type
133
- # @param string type Data type
134
- # @param string value Value to be deserialized
135
- # @return [Object] Deserialized data
136
- def _deserialize(type, value)
137
- case type.to_sym
138
- when :DateTime
139
- DateTime.parse(value)
140
- when :Date
141
- Date.parse(value)
142
- when :String
143
- value.to_s
144
- when :Integer
145
- value.to_i
146
- when :Float
147
- value.to_f
148
- when :BOOLEAN
149
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
150
- true
151
- else
152
- false
153
- end
154
- when :Object
155
- # generic object (usually a Hash), return directly
156
- value
157
- when /\AArray<(?<inner_type>.+)>\z/
158
- inner_type = Regexp.last_match[:inner_type]
159
- value.map { |v| _deserialize(inner_type, v) }
160
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
161
- k_type = Regexp.last_match[:k_type]
162
- v_type = Regexp.last_match[:v_type]
163
- {}.tap do |hash|
164
- value.each do |k, v|
165
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
166
- end
167
- end
168
- else # model
169
- temp_model = DocuSign_eSign.const_get(type).new
170
- temp_model.build_from_hash(value)
171
- end
172
- end
173
-
174
- # Returns the string representation of the object
175
- # @return [String] String presentation of the object
176
- def to_s
177
- to_hash.to_s
178
- end
179
-
180
- # to_body is an alias to to_hash (backward compatibility)
181
- # @return [Hash] Returns the object in the form of hash
182
- def to_body
183
- to_hash
184
- end
185
-
186
- # Returns the object in the form of hash
187
- # @return [Hash] Returns the object in the form of hash
188
- def to_hash
189
- hash = {}
190
- self.class.attribute_map.each_pair do |attr, param|
191
- value = self.send(attr)
192
- next if value.nil?
193
- hash[param] = _to_hash(value)
194
- end
195
- hash
196
- end
197
-
198
- # Outputs non-array value in the form of hash
199
- # For object, use to_hash. Otherwise, just return the value
200
- # @param [Object] value Any valid value
201
- # @return [Hash] Returns the value in the form of hash
202
- def _to_hash(value)
203
- if value.is_a?(Array)
204
- value.compact.map{ |v| _to_hash(v) }
205
- elsif value.is_a?(Hash)
206
- {}.tap do |hash|
207
- value.each { |k, v| hash[k] = _to_hash(v) }
208
- end
209
- elsif value.respond_to? :to_hash
210
- value.to_hash
211
- else
212
- value
213
- end
214
- end
215
-
216
- end
217
-
218
- end
@@ -1,885 +0,0 @@
1
- =begin
2
- #DocuSign REST API
3
-
4
- #The DocuSign REST API provides you with a powerful, convenient, and simple Web services API for interacting with DocuSign.
5
-
6
- OpenAPI spec version: v2.1
7
- Contact: devcenter@docusign.com
8
- Generated by: https://github.com/swagger-api/swagger-codegen.git
9
-
10
- =end
11
-
12
- require 'date'
13
-
14
- module DocuSign_eSign
15
-
16
- class PolyLineOverlay
17
- # When set to **true**, the anchor string does not consider case when matching strings in the document. The default value is **true**.
18
- attr_accessor :anchor_case_sensitive
19
-
20
- attr_accessor :anchor_case_sensitive_metadata
21
-
22
- # Specifies the alignment of anchor tabs with anchor strings. Possible values are **left** or **right**. The default value is **left**.
23
- attr_accessor :anchor_horizontal_alignment
24
-
25
- attr_accessor :anchor_horizontal_alignment_metadata
26
-
27
- # When set to **true**, this tab is ignored if anchorString is not found in the document.
28
- attr_accessor :anchor_ignore_if_not_present
29
-
30
- attr_accessor :anchor_ignore_if_not_present_metadata
31
-
32
- # When set to **true**, the anchor string in this tab matches whole words only (strings embedded in other strings are ignored.) The default value is **true**.
33
- attr_accessor :anchor_match_whole_word
34
-
35
- attr_accessor :anchor_match_whole_word_metadata
36
-
37
- # Anchor text information for a radio button.
38
- attr_accessor :anchor_string
39
-
40
- attr_accessor :anchor_string_metadata
41
-
42
- #
43
- attr_accessor :anchor_tab_processor_version
44
-
45
- attr_accessor :anchor_tab_processor_version_metadata
46
-
47
- # Specifies units of the X and Y offset. Units could be pixels, millimeters, centimeters, or inches.
48
- attr_accessor :anchor_units
49
-
50
- attr_accessor :anchor_units_metadata
51
-
52
- # Specifies the X axis location of the tab, in anchorUnits, relative to the anchorString.
53
- attr_accessor :anchor_x_offset
54
-
55
- attr_accessor :anchor_x_offset_metadata
56
-
57
- # Specifies the Y axis location of the tab, in anchorUnits, relative to the anchorString.
58
- attr_accessor :anchor_y_offset
59
-
60
- attr_accessor :anchor_y_offset_metadata
61
-
62
- # For conditional fields this is the TabLabel of the parent tab that controls this tab's visibility.
63
- attr_accessor :conditional_parent_label
64
-
65
- attr_accessor :conditional_parent_label_metadata
66
-
67
- # For conditional fields, this is the value of the parent tab that controls the tab's visibility. If the parent tab is a Checkbox, Radio button, Optional Signature, or Optional Initial use \"on\" as the value to show that the parent tab is active.
68
- attr_accessor :conditional_parent_value
69
-
70
- attr_accessor :conditional_parent_value_metadata
71
-
72
- # The DocuSign generated custom tab ID for the custom tab to be applied. This can only be used when adding new tabs for a recipient. When used, the new tab inherits all the custom tab properties.
73
- attr_accessor :custom_tab_id
74
-
75
- attr_accessor :custom_tab_id_metadata
76
-
77
- # Specifies the document ID number that the tab is placed on. This must refer to an existing Document's ID attribute.
78
- attr_accessor :document_id
79
-
80
- attr_accessor :document_id_metadata
81
-
82
- attr_accessor :error_details
83
-
84
- #
85
- attr_accessor :form_order
86
-
87
- attr_accessor :form_order_metadata
88
-
89
- #
90
- attr_accessor :form_page_label
91
-
92
- attr_accessor :form_page_label_metadata
93
-
94
- #
95
- attr_accessor :form_page_number
96
-
97
- attr_accessor :form_page_number_metadata
98
-
99
- attr_accessor :graphics_context
100
-
101
- # Height of the tab in pixels.
102
- attr_accessor :height
103
-
104
- attr_accessor :height_metadata
105
-
106
- # When set to **true**, the signer cannot change the data of the custom tab.
107
- attr_accessor :locked
108
-
109
- attr_accessor :locked_metadata
110
-
111
- attr_accessor :merge_field
112
-
113
- #
114
- attr_accessor :merge_field_xml
115
-
116
- #
117
- attr_accessor :overlay_type
118
-
119
- attr_accessor :overlay_type_metadata
120
-
121
- # Specifies the page number on which the tab is located.
122
- attr_accessor :page_number
123
-
124
- attr_accessor :page_number_metadata
125
-
126
- #
127
- attr_accessor :poly_lines
128
-
129
- # Unique for the recipient. It is used by the tab element to indicate which recipient is to sign the Document.
130
- attr_accessor :recipient_id
131
-
132
- #
133
- attr_accessor :recipient_id_guid
134
-
135
- attr_accessor :recipient_id_guid_metadata
136
-
137
- attr_accessor :recipient_id_metadata
138
-
139
- # When set to **true**, this custom tab is shared.
140
- attr_accessor :shared
141
-
142
- attr_accessor :shared_metadata
143
-
144
- # Indicates the envelope status. Valid values are: * sent - The envelope is sent to the recipients. * created - The envelope is saved as a draft and can be modified and sent later.
145
- attr_accessor :status
146
-
147
- attr_accessor :status_metadata
148
-
149
- #
150
- attr_accessor :tab_group_labels
151
-
152
- attr_accessor :tab_group_labels_metadata
153
-
154
- # The unique identifier for the tab. The tabid can be retrieved with the [ML:GET call].
155
- attr_accessor :tab_id
156
-
157
- attr_accessor :tab_id_metadata
158
-
159
- # The label string associated with the tab.
160
- attr_accessor :tab_label
161
-
162
- #
163
- attr_accessor :tab_order
164
-
165
- attr_accessor :tab_order_metadata
166
-
167
- #
168
- attr_accessor :tab_type
169
-
170
- attr_accessor :tab_type_metadata
171
-
172
- # When set to **true**, the sender cannot change any attributes of the recipient. Used only when working with template recipients.
173
- attr_accessor :template_locked
174
-
175
- attr_accessor :template_locked_metadata
176
-
177
- # When set to **true**, the sender may not remove the recipient. Used only when working with template recipients.
178
- attr_accessor :template_required
179
-
180
- attr_accessor :template_required_metadata
181
-
182
- #
183
- attr_accessor :tooltip
184
-
185
- attr_accessor :tool_tip_metadata
186
-
187
- # Width of the tab in pixels.
188
- attr_accessor :width
189
-
190
- attr_accessor :width_metadata
191
-
192
- # This indicates the horizontal offset of the object on the page. DocuSign uses 72 DPI when determining position.
193
- attr_accessor :x_position
194
-
195
- attr_accessor :x_position_metadata
196
-
197
- # This indicates the vertical offset of the object on the page. DocuSign uses 72 DPI when determining position.
198
- attr_accessor :y_position
199
-
200
- attr_accessor :y_position_metadata
201
-
202
-
203
- # Attribute mapping from ruby-style variable name to JSON key.
204
- def self.attribute_map
205
- {
206
- :'anchor_case_sensitive' => :'anchorCaseSensitive',
207
- :'anchor_case_sensitive_metadata' => :'anchorCaseSensitiveMetadata',
208
- :'anchor_horizontal_alignment' => :'anchorHorizontalAlignment',
209
- :'anchor_horizontal_alignment_metadata' => :'anchorHorizontalAlignmentMetadata',
210
- :'anchor_ignore_if_not_present' => :'anchorIgnoreIfNotPresent',
211
- :'anchor_ignore_if_not_present_metadata' => :'anchorIgnoreIfNotPresentMetadata',
212
- :'anchor_match_whole_word' => :'anchorMatchWholeWord',
213
- :'anchor_match_whole_word_metadata' => :'anchorMatchWholeWordMetadata',
214
- :'anchor_string' => :'anchorString',
215
- :'anchor_string_metadata' => :'anchorStringMetadata',
216
- :'anchor_tab_processor_version' => :'anchorTabProcessorVersion',
217
- :'anchor_tab_processor_version_metadata' => :'anchorTabProcessorVersionMetadata',
218
- :'anchor_units' => :'anchorUnits',
219
- :'anchor_units_metadata' => :'anchorUnitsMetadata',
220
- :'anchor_x_offset' => :'anchorXOffset',
221
- :'anchor_x_offset_metadata' => :'anchorXOffsetMetadata',
222
- :'anchor_y_offset' => :'anchorYOffset',
223
- :'anchor_y_offset_metadata' => :'anchorYOffsetMetadata',
224
- :'conditional_parent_label' => :'conditionalParentLabel',
225
- :'conditional_parent_label_metadata' => :'conditionalParentLabelMetadata',
226
- :'conditional_parent_value' => :'conditionalParentValue',
227
- :'conditional_parent_value_metadata' => :'conditionalParentValueMetadata',
228
- :'custom_tab_id' => :'customTabId',
229
- :'custom_tab_id_metadata' => :'customTabIdMetadata',
230
- :'document_id' => :'documentId',
231
- :'document_id_metadata' => :'documentIdMetadata',
232
- :'error_details' => :'errorDetails',
233
- :'form_order' => :'formOrder',
234
- :'form_order_metadata' => :'formOrderMetadata',
235
- :'form_page_label' => :'formPageLabel',
236
- :'form_page_label_metadata' => :'formPageLabelMetadata',
237
- :'form_page_number' => :'formPageNumber',
238
- :'form_page_number_metadata' => :'formPageNumberMetadata',
239
- :'graphics_context' => :'graphicsContext',
240
- :'height' => :'height',
241
- :'height_metadata' => :'heightMetadata',
242
- :'locked' => :'locked',
243
- :'locked_metadata' => :'lockedMetadata',
244
- :'merge_field' => :'mergeField',
245
- :'merge_field_xml' => :'mergeFieldXml',
246
- :'overlay_type' => :'overlayType',
247
- :'overlay_type_metadata' => :'overlayTypeMetadata',
248
- :'page_number' => :'pageNumber',
249
- :'page_number_metadata' => :'pageNumberMetadata',
250
- :'poly_lines' => :'polyLines',
251
- :'recipient_id' => :'recipientId',
252
- :'recipient_id_guid' => :'recipientIdGuid',
253
- :'recipient_id_guid_metadata' => :'recipientIdGuidMetadata',
254
- :'recipient_id_metadata' => :'recipientIdMetadata',
255
- :'shared' => :'shared',
256
- :'shared_metadata' => :'sharedMetadata',
257
- :'status' => :'status',
258
- :'status_metadata' => :'statusMetadata',
259
- :'tab_group_labels' => :'tabGroupLabels',
260
- :'tab_group_labels_metadata' => :'tabGroupLabelsMetadata',
261
- :'tab_id' => :'tabId',
262
- :'tab_id_metadata' => :'tabIdMetadata',
263
- :'tab_label' => :'tabLabel',
264
- :'tab_order' => :'tabOrder',
265
- :'tab_order_metadata' => :'tabOrderMetadata',
266
- :'tab_type' => :'tabType',
267
- :'tab_type_metadata' => :'tabTypeMetadata',
268
- :'template_locked' => :'templateLocked',
269
- :'template_locked_metadata' => :'templateLockedMetadata',
270
- :'template_required' => :'templateRequired',
271
- :'template_required_metadata' => :'templateRequiredMetadata',
272
- :'tooltip' => :'tooltip',
273
- :'tool_tip_metadata' => :'toolTipMetadata',
274
- :'width' => :'width',
275
- :'width_metadata' => :'widthMetadata',
276
- :'x_position' => :'xPosition',
277
- :'x_position_metadata' => :'xPositionMetadata',
278
- :'y_position' => :'yPosition',
279
- :'y_position_metadata' => :'yPositionMetadata'
280
- }
281
- end
282
-
283
- # Attribute type mapping.
284
- def self.swagger_types
285
- {
286
- :'anchor_case_sensitive' => :'String',
287
- :'anchor_case_sensitive_metadata' => :'PropertyMetadata',
288
- :'anchor_horizontal_alignment' => :'String',
289
- :'anchor_horizontal_alignment_metadata' => :'PropertyMetadata',
290
- :'anchor_ignore_if_not_present' => :'String',
291
- :'anchor_ignore_if_not_present_metadata' => :'PropertyMetadata',
292
- :'anchor_match_whole_word' => :'String',
293
- :'anchor_match_whole_word_metadata' => :'PropertyMetadata',
294
- :'anchor_string' => :'String',
295
- :'anchor_string_metadata' => :'PropertyMetadata',
296
- :'anchor_tab_processor_version' => :'String',
297
- :'anchor_tab_processor_version_metadata' => :'PropertyMetadata',
298
- :'anchor_units' => :'String',
299
- :'anchor_units_metadata' => :'PropertyMetadata',
300
- :'anchor_x_offset' => :'String',
301
- :'anchor_x_offset_metadata' => :'PropertyMetadata',
302
- :'anchor_y_offset' => :'String',
303
- :'anchor_y_offset_metadata' => :'PropertyMetadata',
304
- :'conditional_parent_label' => :'String',
305
- :'conditional_parent_label_metadata' => :'PropertyMetadata',
306
- :'conditional_parent_value' => :'String',
307
- :'conditional_parent_value_metadata' => :'PropertyMetadata',
308
- :'custom_tab_id' => :'String',
309
- :'custom_tab_id_metadata' => :'PropertyMetadata',
310
- :'document_id' => :'String',
311
- :'document_id_metadata' => :'PropertyMetadata',
312
- :'error_details' => :'ErrorDetails',
313
- :'form_order' => :'String',
314
- :'form_order_metadata' => :'PropertyMetadata',
315
- :'form_page_label' => :'String',
316
- :'form_page_label_metadata' => :'PropertyMetadata',
317
- :'form_page_number' => :'String',
318
- :'form_page_number_metadata' => :'PropertyMetadata',
319
- :'graphics_context' => :'GraphicsContext',
320
- :'height' => :'String',
321
- :'height_metadata' => :'PropertyMetadata',
322
- :'locked' => :'String',
323
- :'locked_metadata' => :'PropertyMetadata',
324
- :'merge_field' => :'MergeField',
325
- :'merge_field_xml' => :'String',
326
- :'overlay_type' => :'String',
327
- :'overlay_type_metadata' => :'PropertyMetadata',
328
- :'page_number' => :'String',
329
- :'page_number_metadata' => :'PropertyMetadata',
330
- :'poly_lines' => :'Array<PolyLine>',
331
- :'recipient_id' => :'String',
332
- :'recipient_id_guid' => :'String',
333
- :'recipient_id_guid_metadata' => :'PropertyMetadata',
334
- :'recipient_id_metadata' => :'PropertyMetadata',
335
- :'shared' => :'String',
336
- :'shared_metadata' => :'PropertyMetadata',
337
- :'status' => :'String',
338
- :'status_metadata' => :'PropertyMetadata',
339
- :'tab_group_labels' => :'Array<String>',
340
- :'tab_group_labels_metadata' => :'PropertyMetadata',
341
- :'tab_id' => :'String',
342
- :'tab_id_metadata' => :'PropertyMetadata',
343
- :'tab_label' => :'String',
344
- :'tab_order' => :'String',
345
- :'tab_order_metadata' => :'PropertyMetadata',
346
- :'tab_type' => :'String',
347
- :'tab_type_metadata' => :'PropertyMetadata',
348
- :'template_locked' => :'String',
349
- :'template_locked_metadata' => :'PropertyMetadata',
350
- :'template_required' => :'String',
351
- :'template_required_metadata' => :'PropertyMetadata',
352
- :'tooltip' => :'String',
353
- :'tool_tip_metadata' => :'PropertyMetadata',
354
- :'width' => :'String',
355
- :'width_metadata' => :'PropertyMetadata',
356
- :'x_position' => :'String',
357
- :'x_position_metadata' => :'PropertyMetadata',
358
- :'y_position' => :'String',
359
- :'y_position_metadata' => :'PropertyMetadata'
360
- }
361
- end
362
-
363
- # Initializes the object
364
- # @param [Hash] attributes Model attributes in the form of hash
365
- def initialize(attributes = {})
366
- return unless attributes.is_a?(Hash)
367
-
368
- # convert string to symbol for hash key
369
- attributes = attributes.each_with_object({}){|(k,v), h| h[k.to_sym] = v}
370
-
371
- if attributes.has_key?(:'anchorCaseSensitive')
372
- self.anchor_case_sensitive = attributes[:'anchorCaseSensitive']
373
- end
374
-
375
- if attributes.has_key?(:'anchorCaseSensitiveMetadata')
376
- self.anchor_case_sensitive_metadata = attributes[:'anchorCaseSensitiveMetadata']
377
- end
378
-
379
- if attributes.has_key?(:'anchorHorizontalAlignment')
380
- self.anchor_horizontal_alignment = attributes[:'anchorHorizontalAlignment']
381
- end
382
-
383
- if attributes.has_key?(:'anchorHorizontalAlignmentMetadata')
384
- self.anchor_horizontal_alignment_metadata = attributes[:'anchorHorizontalAlignmentMetadata']
385
- end
386
-
387
- if attributes.has_key?(:'anchorIgnoreIfNotPresent')
388
- self.anchor_ignore_if_not_present = attributes[:'anchorIgnoreIfNotPresent']
389
- end
390
-
391
- if attributes.has_key?(:'anchorIgnoreIfNotPresentMetadata')
392
- self.anchor_ignore_if_not_present_metadata = attributes[:'anchorIgnoreIfNotPresentMetadata']
393
- end
394
-
395
- if attributes.has_key?(:'anchorMatchWholeWord')
396
- self.anchor_match_whole_word = attributes[:'anchorMatchWholeWord']
397
- end
398
-
399
- if attributes.has_key?(:'anchorMatchWholeWordMetadata')
400
- self.anchor_match_whole_word_metadata = attributes[:'anchorMatchWholeWordMetadata']
401
- end
402
-
403
- if attributes.has_key?(:'anchorString')
404
- self.anchor_string = attributes[:'anchorString']
405
- end
406
-
407
- if attributes.has_key?(:'anchorStringMetadata')
408
- self.anchor_string_metadata = attributes[:'anchorStringMetadata']
409
- end
410
-
411
- if attributes.has_key?(:'anchorTabProcessorVersion')
412
- self.anchor_tab_processor_version = attributes[:'anchorTabProcessorVersion']
413
- end
414
-
415
- if attributes.has_key?(:'anchorTabProcessorVersionMetadata')
416
- self.anchor_tab_processor_version_metadata = attributes[:'anchorTabProcessorVersionMetadata']
417
- end
418
-
419
- if attributes.has_key?(:'anchorUnits')
420
- self.anchor_units = attributes[:'anchorUnits']
421
- end
422
-
423
- if attributes.has_key?(:'anchorUnitsMetadata')
424
- self.anchor_units_metadata = attributes[:'anchorUnitsMetadata']
425
- end
426
-
427
- if attributes.has_key?(:'anchorXOffset')
428
- self.anchor_x_offset = attributes[:'anchorXOffset']
429
- end
430
-
431
- if attributes.has_key?(:'anchorXOffsetMetadata')
432
- self.anchor_x_offset_metadata = attributes[:'anchorXOffsetMetadata']
433
- end
434
-
435
- if attributes.has_key?(:'anchorYOffset')
436
- self.anchor_y_offset = attributes[:'anchorYOffset']
437
- end
438
-
439
- if attributes.has_key?(:'anchorYOffsetMetadata')
440
- self.anchor_y_offset_metadata = attributes[:'anchorYOffsetMetadata']
441
- end
442
-
443
- if attributes.has_key?(:'conditionalParentLabel')
444
- self.conditional_parent_label = attributes[:'conditionalParentLabel']
445
- end
446
-
447
- if attributes.has_key?(:'conditionalParentLabelMetadata')
448
- self.conditional_parent_label_metadata = attributes[:'conditionalParentLabelMetadata']
449
- end
450
-
451
- if attributes.has_key?(:'conditionalParentValue')
452
- self.conditional_parent_value = attributes[:'conditionalParentValue']
453
- end
454
-
455
- if attributes.has_key?(:'conditionalParentValueMetadata')
456
- self.conditional_parent_value_metadata = attributes[:'conditionalParentValueMetadata']
457
- end
458
-
459
- if attributes.has_key?(:'customTabId')
460
- self.custom_tab_id = attributes[:'customTabId']
461
- end
462
-
463
- if attributes.has_key?(:'customTabIdMetadata')
464
- self.custom_tab_id_metadata = attributes[:'customTabIdMetadata']
465
- end
466
-
467
- if attributes.has_key?(:'documentId')
468
- self.document_id = attributes[:'documentId']
469
- end
470
-
471
- if attributes.has_key?(:'documentIdMetadata')
472
- self.document_id_metadata = attributes[:'documentIdMetadata']
473
- end
474
-
475
- if attributes.has_key?(:'errorDetails')
476
- self.error_details = attributes[:'errorDetails']
477
- end
478
-
479
- if attributes.has_key?(:'formOrder')
480
- self.form_order = attributes[:'formOrder']
481
- end
482
-
483
- if attributes.has_key?(:'formOrderMetadata')
484
- self.form_order_metadata = attributes[:'formOrderMetadata']
485
- end
486
-
487
- if attributes.has_key?(:'formPageLabel')
488
- self.form_page_label = attributes[:'formPageLabel']
489
- end
490
-
491
- if attributes.has_key?(:'formPageLabelMetadata')
492
- self.form_page_label_metadata = attributes[:'formPageLabelMetadata']
493
- end
494
-
495
- if attributes.has_key?(:'formPageNumber')
496
- self.form_page_number = attributes[:'formPageNumber']
497
- end
498
-
499
- if attributes.has_key?(:'formPageNumberMetadata')
500
- self.form_page_number_metadata = attributes[:'formPageNumberMetadata']
501
- end
502
-
503
- if attributes.has_key?(:'graphicsContext')
504
- self.graphics_context = attributes[:'graphicsContext']
505
- end
506
-
507
- if attributes.has_key?(:'height')
508
- self.height = attributes[:'height']
509
- end
510
-
511
- if attributes.has_key?(:'heightMetadata')
512
- self.height_metadata = attributes[:'heightMetadata']
513
- end
514
-
515
- if attributes.has_key?(:'locked')
516
- self.locked = attributes[:'locked']
517
- end
518
-
519
- if attributes.has_key?(:'lockedMetadata')
520
- self.locked_metadata = attributes[:'lockedMetadata']
521
- end
522
-
523
- if attributes.has_key?(:'mergeField')
524
- self.merge_field = attributes[:'mergeField']
525
- end
526
-
527
- if attributes.has_key?(:'mergeFieldXml')
528
- self.merge_field_xml = attributes[:'mergeFieldXml']
529
- end
530
-
531
- if attributes.has_key?(:'overlayType')
532
- self.overlay_type = attributes[:'overlayType']
533
- end
534
-
535
- if attributes.has_key?(:'overlayTypeMetadata')
536
- self.overlay_type_metadata = attributes[:'overlayTypeMetadata']
537
- end
538
-
539
- if attributes.has_key?(:'pageNumber')
540
- self.page_number = attributes[:'pageNumber']
541
- end
542
-
543
- if attributes.has_key?(:'pageNumberMetadata')
544
- self.page_number_metadata = attributes[:'pageNumberMetadata']
545
- end
546
-
547
- if attributes.has_key?(:'polyLines')
548
- if (value = attributes[:'polyLines']).is_a?(Array)
549
- self.poly_lines = value
550
- end
551
- end
552
-
553
- if attributes.has_key?(:'recipientId')
554
- self.recipient_id = attributes[:'recipientId']
555
- end
556
-
557
- if attributes.has_key?(:'recipientIdGuid')
558
- self.recipient_id_guid = attributes[:'recipientIdGuid']
559
- end
560
-
561
- if attributes.has_key?(:'recipientIdGuidMetadata')
562
- self.recipient_id_guid_metadata = attributes[:'recipientIdGuidMetadata']
563
- end
564
-
565
- if attributes.has_key?(:'recipientIdMetadata')
566
- self.recipient_id_metadata = attributes[:'recipientIdMetadata']
567
- end
568
-
569
- if attributes.has_key?(:'shared')
570
- self.shared = attributes[:'shared']
571
- end
572
-
573
- if attributes.has_key?(:'sharedMetadata')
574
- self.shared_metadata = attributes[:'sharedMetadata']
575
- end
576
-
577
- if attributes.has_key?(:'status')
578
- self.status = attributes[:'status']
579
- end
580
-
581
- if attributes.has_key?(:'statusMetadata')
582
- self.status_metadata = attributes[:'statusMetadata']
583
- end
584
-
585
- if attributes.has_key?(:'tabGroupLabels')
586
- if (value = attributes[:'tabGroupLabels']).is_a?(Array)
587
- self.tab_group_labels = value
588
- end
589
- end
590
-
591
- if attributes.has_key?(:'tabGroupLabelsMetadata')
592
- self.tab_group_labels_metadata = attributes[:'tabGroupLabelsMetadata']
593
- end
594
-
595
- if attributes.has_key?(:'tabId')
596
- self.tab_id = attributes[:'tabId']
597
- end
598
-
599
- if attributes.has_key?(:'tabIdMetadata')
600
- self.tab_id_metadata = attributes[:'tabIdMetadata']
601
- end
602
-
603
- if attributes.has_key?(:'tabLabel')
604
- self.tab_label = attributes[:'tabLabel']
605
- end
606
-
607
- if attributes.has_key?(:'tabOrder')
608
- self.tab_order = attributes[:'tabOrder']
609
- end
610
-
611
- if attributes.has_key?(:'tabOrderMetadata')
612
- self.tab_order_metadata = attributes[:'tabOrderMetadata']
613
- end
614
-
615
- if attributes.has_key?(:'tabType')
616
- self.tab_type = attributes[:'tabType']
617
- end
618
-
619
- if attributes.has_key?(:'tabTypeMetadata')
620
- self.tab_type_metadata = attributes[:'tabTypeMetadata']
621
- end
622
-
623
- if attributes.has_key?(:'templateLocked')
624
- self.template_locked = attributes[:'templateLocked']
625
- end
626
-
627
- if attributes.has_key?(:'templateLockedMetadata')
628
- self.template_locked_metadata = attributes[:'templateLockedMetadata']
629
- end
630
-
631
- if attributes.has_key?(:'templateRequired')
632
- self.template_required = attributes[:'templateRequired']
633
- end
634
-
635
- if attributes.has_key?(:'templateRequiredMetadata')
636
- self.template_required_metadata = attributes[:'templateRequiredMetadata']
637
- end
638
-
639
- if attributes.has_key?(:'tooltip')
640
- self.tooltip = attributes[:'tooltip']
641
- end
642
-
643
- if attributes.has_key?(:'toolTipMetadata')
644
- self.tool_tip_metadata = attributes[:'toolTipMetadata']
645
- end
646
-
647
- if attributes.has_key?(:'width')
648
- self.width = attributes[:'width']
649
- end
650
-
651
- if attributes.has_key?(:'widthMetadata')
652
- self.width_metadata = attributes[:'widthMetadata']
653
- end
654
-
655
- if attributes.has_key?(:'xPosition')
656
- self.x_position = attributes[:'xPosition']
657
- end
658
-
659
- if attributes.has_key?(:'xPositionMetadata')
660
- self.x_position_metadata = attributes[:'xPositionMetadata']
661
- end
662
-
663
- if attributes.has_key?(:'yPosition')
664
- self.y_position = attributes[:'yPosition']
665
- end
666
-
667
- if attributes.has_key?(:'yPositionMetadata')
668
- self.y_position_metadata = attributes[:'yPositionMetadata']
669
- end
670
-
671
- end
672
-
673
- # Show invalid properties with the reasons. Usually used together with valid?
674
- # @return Array for valid properies with the reasons
675
- def list_invalid_properties
676
- invalid_properties = Array.new
677
- return invalid_properties
678
- end
679
-
680
- # Check to see if the all the properties in the model are valid
681
- # @return true if the model is valid
682
- def valid?
683
- return true
684
- end
685
-
686
- # Checks equality by comparing each attribute.
687
- # @param [Object] Object to be compared
688
- def ==(o)
689
- return true if self.equal?(o)
690
- self.class == o.class &&
691
- anchor_case_sensitive == o.anchor_case_sensitive &&
692
- anchor_case_sensitive_metadata == o.anchor_case_sensitive_metadata &&
693
- anchor_horizontal_alignment == o.anchor_horizontal_alignment &&
694
- anchor_horizontal_alignment_metadata == o.anchor_horizontal_alignment_metadata &&
695
- anchor_ignore_if_not_present == o.anchor_ignore_if_not_present &&
696
- anchor_ignore_if_not_present_metadata == o.anchor_ignore_if_not_present_metadata &&
697
- anchor_match_whole_word == o.anchor_match_whole_word &&
698
- anchor_match_whole_word_metadata == o.anchor_match_whole_word_metadata &&
699
- anchor_string == o.anchor_string &&
700
- anchor_string_metadata == o.anchor_string_metadata &&
701
- anchor_tab_processor_version == o.anchor_tab_processor_version &&
702
- anchor_tab_processor_version_metadata == o.anchor_tab_processor_version_metadata &&
703
- anchor_units == o.anchor_units &&
704
- anchor_units_metadata == o.anchor_units_metadata &&
705
- anchor_x_offset == o.anchor_x_offset &&
706
- anchor_x_offset_metadata == o.anchor_x_offset_metadata &&
707
- anchor_y_offset == o.anchor_y_offset &&
708
- anchor_y_offset_metadata == o.anchor_y_offset_metadata &&
709
- conditional_parent_label == o.conditional_parent_label &&
710
- conditional_parent_label_metadata == o.conditional_parent_label_metadata &&
711
- conditional_parent_value == o.conditional_parent_value &&
712
- conditional_parent_value_metadata == o.conditional_parent_value_metadata &&
713
- custom_tab_id == o.custom_tab_id &&
714
- custom_tab_id_metadata == o.custom_tab_id_metadata &&
715
- document_id == o.document_id &&
716
- document_id_metadata == o.document_id_metadata &&
717
- error_details == o.error_details &&
718
- form_order == o.form_order &&
719
- form_order_metadata == o.form_order_metadata &&
720
- form_page_label == o.form_page_label &&
721
- form_page_label_metadata == o.form_page_label_metadata &&
722
- form_page_number == o.form_page_number &&
723
- form_page_number_metadata == o.form_page_number_metadata &&
724
- graphics_context == o.graphics_context &&
725
- height == o.height &&
726
- height_metadata == o.height_metadata &&
727
- locked == o.locked &&
728
- locked_metadata == o.locked_metadata &&
729
- merge_field == o.merge_field &&
730
- merge_field_xml == o.merge_field_xml &&
731
- overlay_type == o.overlay_type &&
732
- overlay_type_metadata == o.overlay_type_metadata &&
733
- page_number == o.page_number &&
734
- page_number_metadata == o.page_number_metadata &&
735
- poly_lines == o.poly_lines &&
736
- recipient_id == o.recipient_id &&
737
- recipient_id_guid == o.recipient_id_guid &&
738
- recipient_id_guid_metadata == o.recipient_id_guid_metadata &&
739
- recipient_id_metadata == o.recipient_id_metadata &&
740
- shared == o.shared &&
741
- shared_metadata == o.shared_metadata &&
742
- status == o.status &&
743
- status_metadata == o.status_metadata &&
744
- tab_group_labels == o.tab_group_labels &&
745
- tab_group_labels_metadata == o.tab_group_labels_metadata &&
746
- tab_id == o.tab_id &&
747
- tab_id_metadata == o.tab_id_metadata &&
748
- tab_label == o.tab_label &&
749
- tab_order == o.tab_order &&
750
- tab_order_metadata == o.tab_order_metadata &&
751
- tab_type == o.tab_type &&
752
- tab_type_metadata == o.tab_type_metadata &&
753
- template_locked == o.template_locked &&
754
- template_locked_metadata == o.template_locked_metadata &&
755
- template_required == o.template_required &&
756
- template_required_metadata == o.template_required_metadata &&
757
- tooltip == o.tooltip &&
758
- tool_tip_metadata == o.tool_tip_metadata &&
759
- width == o.width &&
760
- width_metadata == o.width_metadata &&
761
- x_position == o.x_position &&
762
- x_position_metadata == o.x_position_metadata &&
763
- y_position == o.y_position &&
764
- y_position_metadata == o.y_position_metadata
765
- end
766
-
767
- # @see the `==` method
768
- # @param [Object] Object to be compared
769
- def eql?(o)
770
- self == o
771
- end
772
-
773
- # Calculates hash code according to all attributes.
774
- # @return [Fixnum] Hash code
775
- def hash
776
- [anchor_case_sensitive, anchor_case_sensitive_metadata, anchor_horizontal_alignment, anchor_horizontal_alignment_metadata, anchor_ignore_if_not_present, anchor_ignore_if_not_present_metadata, anchor_match_whole_word, anchor_match_whole_word_metadata, anchor_string, anchor_string_metadata, anchor_tab_processor_version, anchor_tab_processor_version_metadata, anchor_units, anchor_units_metadata, anchor_x_offset, anchor_x_offset_metadata, anchor_y_offset, anchor_y_offset_metadata, conditional_parent_label, conditional_parent_label_metadata, conditional_parent_value, conditional_parent_value_metadata, custom_tab_id, custom_tab_id_metadata, document_id, document_id_metadata, error_details, form_order, form_order_metadata, form_page_label, form_page_label_metadata, form_page_number, form_page_number_metadata, graphics_context, height, height_metadata, locked, locked_metadata, merge_field, merge_field_xml, overlay_type, overlay_type_metadata, page_number, page_number_metadata, poly_lines, recipient_id, recipient_id_guid, recipient_id_guid_metadata, recipient_id_metadata, shared, shared_metadata, status, status_metadata, tab_group_labels, tab_group_labels_metadata, tab_id, tab_id_metadata, tab_label, tab_order, tab_order_metadata, tab_type, tab_type_metadata, template_locked, template_locked_metadata, template_required, template_required_metadata, tooltip, tool_tip_metadata, width, width_metadata, x_position, x_position_metadata, y_position, y_position_metadata].hash
777
- end
778
-
779
- # Builds the object from hash
780
- # @param [Hash] attributes Model attributes in the form of hash
781
- # @return [Object] Returns the model itself
782
- def build_from_hash(attributes)
783
- return nil unless attributes.is_a?(Hash)
784
- self.class.swagger_types.each_pair do |key, type|
785
- if type =~ /\AArray<(.*)>/i
786
- # check to ensure the input is an array given that the the attribute
787
- # is documented as an array but the input is not
788
- if attributes[self.class.attribute_map[key]].is_a?(Array)
789
- self.send("#{key}=", attributes[self.class.attribute_map[key]].map{ |v| _deserialize($1, v) } )
790
- end
791
- elsif !attributes[self.class.attribute_map[key]].nil?
792
- self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
793
- end # or else data not found in attributes(hash), not an issue as the data can be optional
794
- end
795
-
796
- self
797
- end
798
-
799
- # Deserializes the data based on type
800
- # @param string type Data type
801
- # @param string value Value to be deserialized
802
- # @return [Object] Deserialized data
803
- def _deserialize(type, value)
804
- case type.to_sym
805
- when :DateTime
806
- DateTime.parse(value)
807
- when :Date
808
- Date.parse(value)
809
- when :String
810
- value.to_s
811
- when :Integer
812
- value.to_i
813
- when :Float
814
- value.to_f
815
- when :BOOLEAN
816
- if value.to_s =~ /\A(true|t|yes|y|1)\z/i
817
- true
818
- else
819
- false
820
- end
821
- when :Object
822
- # generic object (usually a Hash), return directly
823
- value
824
- when /\AArray<(?<inner_type>.+)>\z/
825
- inner_type = Regexp.last_match[:inner_type]
826
- value.map { |v| _deserialize(inner_type, v) }
827
- when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
828
- k_type = Regexp.last_match[:k_type]
829
- v_type = Regexp.last_match[:v_type]
830
- {}.tap do |hash|
831
- value.each do |k, v|
832
- hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
833
- end
834
- end
835
- else # model
836
- temp_model = DocuSign_eSign.const_get(type).new
837
- temp_model.build_from_hash(value)
838
- end
839
- end
840
-
841
- # Returns the string representation of the object
842
- # @return [String] String presentation of the object
843
- def to_s
844
- to_hash.to_s
845
- end
846
-
847
- # to_body is an alias to to_hash (backward compatibility)
848
- # @return [Hash] Returns the object in the form of hash
849
- def to_body
850
- to_hash
851
- end
852
-
853
- # Returns the object in the form of hash
854
- # @return [Hash] Returns the object in the form of hash
855
- def to_hash
856
- hash = {}
857
- self.class.attribute_map.each_pair do |attr, param|
858
- value = self.send(attr)
859
- next if value.nil?
860
- hash[param] = _to_hash(value)
861
- end
862
- hash
863
- end
864
-
865
- # Outputs non-array value in the form of hash
866
- # For object, use to_hash. Otherwise, just return the value
867
- # @param [Object] value Any valid value
868
- # @return [Hash] Returns the value in the form of hash
869
- def _to_hash(value)
870
- if value.is_a?(Array)
871
- value.compact.map{ |v| _to_hash(v) }
872
- elsif value.is_a?(Hash)
873
- {}.tap do |hash|
874
- value.each { |k, v| hash[k] = _to_hash(v) }
875
- end
876
- elsif value.respond_to? :to_hash
877
- value.to_hash
878
- else
879
- value
880
- end
881
- end
882
-
883
- end
884
-
885
- end