docusign_esign 3.3.0.pre.rc → 3.5.0
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -5
- data/CHANGELOG.md +5 -0
- data/Gemfile.lock +7 -7
- data/README.md +7 -5
- data/docusign_esign-2.6.0.rc1.gem +0 -0
- data/docusign_esign-3.5.0.rc1.gem +0 -0
- data/lib/docusign_esign.rb +25 -0
- data/lib/docusign_esign/.DS_Store +0 -0
- data/lib/docusign_esign/api/accounts_api.rb +362 -0
- data/lib/docusign_esign/api/bulk_envelopes_api.rb +128 -6
- data/lib/docusign_esign/api/envelopes_api.rb +320 -0
- data/lib/docusign_esign/api/trust_service_providers_api.rb +74 -0
- data/lib/{.DS_Store → docusign_esign/client/.DS_Store} +0 -0
- data/lib/docusign_esign/models/account_settings_information.rb +11 -1
- data/lib/docusign_esign/models/bulk_send_batch_status.rb +287 -0
- data/lib/docusign_esign/models/bulk_send_batch_summaries.rb +277 -0
- data/lib/docusign_esign/models/bulk_send_batch_summary.rb +255 -0
- data/lib/docusign_esign/models/bulk_send_error_status.rb +207 -0
- data/lib/docusign_esign/models/bulk_send_response.rb +34 -4
- data/lib/docusign_esign/models/conditional_recipient_rule.rb +216 -0
- data/lib/docusign_esign/models/conditional_recipient_rule_condition.rb +207 -0
- data/lib/docusign_esign/models/conditional_recipient_rule_filter.rb +235 -0
- data/lib/docusign_esign/models/e_note_configuration.rb +11 -1
- data/lib/docusign_esign/models/envelope.rb +13 -4
- data/lib/docusign_esign/models/envelope_definition.rb +13 -4
- data/lib/docusign_esign/models/envelope_template.rb +13 -4
- data/lib/docusign_esign/models/new_user.rb +11 -1
- data/lib/docusign_esign/models/proof_service_resource_token.rb +14 -4
- data/lib/docusign_esign/models/recipient_additional_notification.rb +14 -4
- data/lib/docusign_esign/models/recipient_group.rb +207 -0
- data/lib/docusign_esign/models/recipient_option.rb +225 -0
- data/lib/docusign_esign/models/recipient_routing.rb +184 -0
- data/lib/docusign_esign/models/recipient_rules.rb +187 -0
- data/lib/docusign_esign/models/report_in_product_csv_run_request.rb +437 -0
- data/lib/docusign_esign/models/report_in_product_field.rb +215 -0
- data/lib/docusign_esign/models/report_in_product_get.rb +466 -0
- data/lib/docusign_esign/models/report_in_product_list.rb +187 -0
- data/lib/docusign_esign/models/report_in_product_list_item.rb +315 -0
- data/lib/docusign_esign/models/report_in_product_run_request.rb +397 -0
- data/lib/docusign_esign/models/report_in_product_run_response.rb +247 -0
- data/lib/docusign_esign/models/report_in_product_run_response_row.rb +194 -0
- data/lib/docusign_esign/models/report_in_product_run_response_row_fields.rb +1395 -0
- data/lib/docusign_esign/models/report_in_product_save_response.rb +185 -0
- data/lib/docusign_esign/models/report_in_product_sent_by_details.rb +199 -0
- data/lib/docusign_esign/models/sender_email_notifications.rb +11 -1
- data/lib/docusign_esign/models/tab_metadata.rb +21 -1
- data/lib/docusign_esign/models/workflow.rb +207 -0
- data/lib/docusign_esign/models/workflow_step.rb +254 -0
- data/lib/docusign_esign/version.rb +1 -1
- data/tests/Gemfile.lock +9 -9
- metadata +57 -31
@@ -25,6 +25,9 @@ module DocuSign_eSign
|
|
25
25
|
|
26
26
|
attr_accessor :error_details
|
27
27
|
|
28
|
+
#
|
29
|
+
attr_accessor :membership_id
|
30
|
+
|
28
31
|
#
|
29
32
|
attr_accessor :permission_profile_id
|
30
33
|
|
@@ -50,6 +53,7 @@ module DocuSign_eSign
|
|
50
53
|
:'created_date_time' => :'createdDateTime',
|
51
54
|
:'email' => :'email',
|
52
55
|
:'error_details' => :'errorDetails',
|
56
|
+
:'membership_id' => :'membershipId',
|
53
57
|
:'permission_profile_id' => :'permissionProfileId',
|
54
58
|
:'permission_profile_name' => :'permissionProfileName',
|
55
59
|
:'uri' => :'uri',
|
@@ -66,6 +70,7 @@ module DocuSign_eSign
|
|
66
70
|
:'created_date_time' => :'String',
|
67
71
|
:'email' => :'String',
|
68
72
|
:'error_details' => :'ErrorDetails',
|
73
|
+
:'membership_id' => :'String',
|
69
74
|
:'permission_profile_id' => :'String',
|
70
75
|
:'permission_profile_name' => :'String',
|
71
76
|
:'uri' => :'String',
|
@@ -99,6 +104,10 @@ module DocuSign_eSign
|
|
99
104
|
self.error_details = attributes[:'errorDetails']
|
100
105
|
end
|
101
106
|
|
107
|
+
if attributes.has_key?(:'membershipId')
|
108
|
+
self.membership_id = attributes[:'membershipId']
|
109
|
+
end
|
110
|
+
|
102
111
|
if attributes.has_key?(:'permissionProfileId')
|
103
112
|
self.permission_profile_id = attributes[:'permissionProfileId']
|
104
113
|
end
|
@@ -146,6 +155,7 @@ module DocuSign_eSign
|
|
146
155
|
created_date_time == o.created_date_time &&
|
147
156
|
email == o.email &&
|
148
157
|
error_details == o.error_details &&
|
158
|
+
membership_id == o.membership_id &&
|
149
159
|
permission_profile_id == o.permission_profile_id &&
|
150
160
|
permission_profile_name == o.permission_profile_name &&
|
151
161
|
uri == o.uri &&
|
@@ -163,7 +173,7 @@ module DocuSign_eSign
|
|
163
173
|
# Calculates hash code according to all attributes.
|
164
174
|
# @return [Fixnum] Hash code
|
165
175
|
def hash
|
166
|
-
[api_password, created_date_time, email, error_details, permission_profile_id, permission_profile_name, uri, user_id, user_name, user_status].hash
|
176
|
+
[api_password, created_date_time, email, error_details, membership_id, permission_profile_id, permission_profile_name, uri, user_id, user_name, user_status].hash
|
167
177
|
end
|
168
178
|
|
169
179
|
# Builds the object from hash
|
@@ -14,19 +14,24 @@ require 'date'
|
|
14
14
|
|
15
15
|
module DocuSign_eSign
|
16
16
|
class ProofServiceResourceToken
|
17
|
+
#
|
18
|
+
attr_accessor :proof_base_uri
|
19
|
+
|
17
20
|
#
|
18
21
|
attr_accessor :resource_token
|
19
22
|
|
20
23
|
# Attribute mapping from ruby-style variable name to JSON key.
|
21
24
|
def self.attribute_map
|
22
25
|
{
|
23
|
-
:'
|
26
|
+
:'proof_base_uri' => :'proofBaseURI',
|
27
|
+
:'resource_token' => :'resourceToken'
|
24
28
|
}
|
25
29
|
end
|
26
30
|
|
27
31
|
# Attribute type mapping.
|
28
32
|
def self.swagger_types
|
29
33
|
{
|
34
|
+
:'proof_base_uri' => :'String',
|
30
35
|
:'resource_token' => :'String'
|
31
36
|
}
|
32
37
|
end
|
@@ -39,8 +44,12 @@ module DocuSign_eSign
|
|
39
44
|
# convert string to symbol for hash key
|
40
45
|
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
41
46
|
|
42
|
-
if attributes.has_key?(:'
|
43
|
-
self.
|
47
|
+
if attributes.has_key?(:'proofBaseURI')
|
48
|
+
self.proof_base_uri = attributes[:'proofBaseURI']
|
49
|
+
end
|
50
|
+
|
51
|
+
if attributes.has_key?(:'resourceToken')
|
52
|
+
self.resource_token = attributes[:'resourceToken']
|
44
53
|
end
|
45
54
|
end
|
46
55
|
|
@@ -62,6 +71,7 @@ module DocuSign_eSign
|
|
62
71
|
def ==(o)
|
63
72
|
return true if self.equal?(o)
|
64
73
|
self.class == o.class &&
|
74
|
+
proof_base_uri == o.proof_base_uri &&
|
65
75
|
resource_token == o.resource_token
|
66
76
|
end
|
67
77
|
|
@@ -74,7 +84,7 @@ module DocuSign_eSign
|
|
74
84
|
# Calculates hash code according to all attributes.
|
75
85
|
# @return [Fixnum] Hash code
|
76
86
|
def hash
|
77
|
-
[resource_token].hash
|
87
|
+
[proof_base_uri, resource_token].hash
|
78
88
|
end
|
79
89
|
|
80
90
|
# Builds the object from hash
|
@@ -21,12 +21,16 @@ module DocuSign_eSign
|
|
21
21
|
|
22
22
|
attr_accessor :secondary_delivery_method_metadata
|
23
23
|
|
24
|
+
#
|
25
|
+
attr_accessor :secondary_delivery_status
|
26
|
+
|
24
27
|
# Attribute mapping from ruby-style variable name to JSON key.
|
25
28
|
def self.attribute_map
|
26
29
|
{
|
27
30
|
:'phone_number' => :'phoneNumber',
|
28
31
|
:'secondary_delivery_method' => :'secondaryDeliveryMethod',
|
29
|
-
:'secondary_delivery_method_metadata' => :'secondaryDeliveryMethodMetadata'
|
32
|
+
:'secondary_delivery_method_metadata' => :'secondaryDeliveryMethodMetadata',
|
33
|
+
:'secondary_delivery_status' => :'secondaryDeliveryStatus'
|
30
34
|
}
|
31
35
|
end
|
32
36
|
|
@@ -35,7 +39,8 @@ module DocuSign_eSign
|
|
35
39
|
{
|
36
40
|
:'phone_number' => :'RecipientPhoneNumber',
|
37
41
|
:'secondary_delivery_method' => :'String',
|
38
|
-
:'secondary_delivery_method_metadata' => :'PropertyMetadata'
|
42
|
+
:'secondary_delivery_method_metadata' => :'PropertyMetadata',
|
43
|
+
:'secondary_delivery_status' => :'String'
|
39
44
|
}
|
40
45
|
end
|
41
46
|
|
@@ -58,6 +63,10 @@ module DocuSign_eSign
|
|
58
63
|
if attributes.has_key?(:'secondaryDeliveryMethodMetadata')
|
59
64
|
self.secondary_delivery_method_metadata = attributes[:'secondaryDeliveryMethodMetadata']
|
60
65
|
end
|
66
|
+
|
67
|
+
if attributes.has_key?(:'secondaryDeliveryStatus')
|
68
|
+
self.secondary_delivery_status = attributes[:'secondaryDeliveryStatus']
|
69
|
+
end
|
61
70
|
end
|
62
71
|
|
63
72
|
# Show invalid properties with the reasons. Usually used together with valid?
|
@@ -80,7 +89,8 @@ module DocuSign_eSign
|
|
80
89
|
self.class == o.class &&
|
81
90
|
phone_number == o.phone_number &&
|
82
91
|
secondary_delivery_method == o.secondary_delivery_method &&
|
83
|
-
secondary_delivery_method_metadata == o.secondary_delivery_method_metadata
|
92
|
+
secondary_delivery_method_metadata == o.secondary_delivery_method_metadata &&
|
93
|
+
secondary_delivery_status == o.secondary_delivery_status
|
84
94
|
end
|
85
95
|
|
86
96
|
# @see the `==` method
|
@@ -92,7 +102,7 @@ module DocuSign_eSign
|
|
92
102
|
# Calculates hash code according to all attributes.
|
93
103
|
# @return [Fixnum] Hash code
|
94
104
|
def hash
|
95
|
-
[phone_number, secondary_delivery_method, secondary_delivery_method_metadata].hash
|
105
|
+
[phone_number, secondary_delivery_method, secondary_delivery_method_metadata, secondary_delivery_status].hash
|
96
106
|
end
|
97
107
|
|
98
108
|
# Builds the object from hash
|
@@ -0,0 +1,207 @@
|
|
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
|
+
Swagger Codegen version: 2.4.13-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module DocuSign_eSign
|
16
|
+
class RecipientGroup
|
17
|
+
#
|
18
|
+
attr_accessor :group_message
|
19
|
+
|
20
|
+
# The name of the group.
|
21
|
+
attr_accessor :group_name
|
22
|
+
|
23
|
+
# An array of powerform recipients.
|
24
|
+
attr_accessor :recipients
|
25
|
+
|
26
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
27
|
+
def self.attribute_map
|
28
|
+
{
|
29
|
+
:'group_message' => :'groupMessage',
|
30
|
+
:'group_name' => :'groupName',
|
31
|
+
:'recipients' => :'recipients'
|
32
|
+
}
|
33
|
+
end
|
34
|
+
|
35
|
+
# Attribute type mapping.
|
36
|
+
def self.swagger_types
|
37
|
+
{
|
38
|
+
:'group_message' => :'String',
|
39
|
+
:'group_name' => :'String',
|
40
|
+
:'recipients' => :'Array<RecipientOption>'
|
41
|
+
}
|
42
|
+
end
|
43
|
+
|
44
|
+
# Initializes the object
|
45
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
46
|
+
def initialize(attributes = {})
|
47
|
+
return unless attributes.is_a?(Hash)
|
48
|
+
|
49
|
+
# convert string to symbol for hash key
|
50
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
51
|
+
|
52
|
+
if attributes.has_key?(:'groupMessage')
|
53
|
+
self.group_message = attributes[:'groupMessage']
|
54
|
+
end
|
55
|
+
|
56
|
+
if attributes.has_key?(:'groupName')
|
57
|
+
self.group_name = attributes[:'groupName']
|
58
|
+
end
|
59
|
+
|
60
|
+
if attributes.has_key?(:'recipients')
|
61
|
+
if (value = attributes[:'recipients']).is_a?(Array)
|
62
|
+
self.recipients = value
|
63
|
+
end
|
64
|
+
end
|
65
|
+
end
|
66
|
+
|
67
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
68
|
+
# @return Array for valid properties with the reasons
|
69
|
+
def list_invalid_properties
|
70
|
+
invalid_properties = Array.new
|
71
|
+
invalid_properties
|
72
|
+
end
|
73
|
+
|
74
|
+
# Check to see if the all the properties in the model are valid
|
75
|
+
# @return true if the model is valid
|
76
|
+
def valid?
|
77
|
+
true
|
78
|
+
end
|
79
|
+
|
80
|
+
# Checks equality by comparing each attribute.
|
81
|
+
# @param [Object] Object to be compared
|
82
|
+
def ==(o)
|
83
|
+
return true if self.equal?(o)
|
84
|
+
self.class == o.class &&
|
85
|
+
group_message == o.group_message &&
|
86
|
+
group_name == o.group_name &&
|
87
|
+
recipients == o.recipients
|
88
|
+
end
|
89
|
+
|
90
|
+
# @see the `==` method
|
91
|
+
# @param [Object] Object to be compared
|
92
|
+
def eql?(o)
|
93
|
+
self == o
|
94
|
+
end
|
95
|
+
|
96
|
+
# Calculates hash code according to all attributes.
|
97
|
+
# @return [Fixnum] Hash code
|
98
|
+
def hash
|
99
|
+
[group_message, group_name, recipients].hash
|
100
|
+
end
|
101
|
+
|
102
|
+
# Builds the object from hash
|
103
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
104
|
+
# @return [Object] Returns the model itself
|
105
|
+
def build_from_hash(attributes)
|
106
|
+
return nil unless attributes.is_a?(Hash)
|
107
|
+
self.class.swagger_types.each_pair do |key, type|
|
108
|
+
if type =~ /\AArray<(.*)>/i
|
109
|
+
# check to ensure the input is an array given that the attribute
|
110
|
+
# is documented as an array but the input is not
|
111
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
112
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
113
|
+
end
|
114
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
115
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
116
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
117
|
+
end
|
118
|
+
|
119
|
+
self
|
120
|
+
end
|
121
|
+
|
122
|
+
# Deserializes the data based on type
|
123
|
+
# @param string type Data type
|
124
|
+
# @param string value Value to be deserialized
|
125
|
+
# @return [Object] Deserialized data
|
126
|
+
def _deserialize(type, value)
|
127
|
+
case type.to_sym
|
128
|
+
when :DateTime
|
129
|
+
DateTime.parse(value)
|
130
|
+
when :Date
|
131
|
+
Date.parse(value)
|
132
|
+
when :String
|
133
|
+
value.to_s
|
134
|
+
when :Integer
|
135
|
+
value.to_i
|
136
|
+
when :Float
|
137
|
+
value.to_f
|
138
|
+
when :BOOLEAN
|
139
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
140
|
+
true
|
141
|
+
else
|
142
|
+
false
|
143
|
+
end
|
144
|
+
when :Object
|
145
|
+
# generic object (usually a Hash), return directly
|
146
|
+
value
|
147
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
148
|
+
inner_type = Regexp.last_match[:inner_type]
|
149
|
+
value.map { |v| _deserialize(inner_type, v) }
|
150
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
151
|
+
k_type = Regexp.last_match[:k_type]
|
152
|
+
v_type = Regexp.last_match[:v_type]
|
153
|
+
{}.tap do |hash|
|
154
|
+
value.each do |k, v|
|
155
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
156
|
+
end
|
157
|
+
end
|
158
|
+
else # model
|
159
|
+
temp_model = DocuSign_eSign.const_get(type).new
|
160
|
+
temp_model.build_from_hash(value)
|
161
|
+
end
|
162
|
+
end
|
163
|
+
|
164
|
+
# Returns the string representation of the object
|
165
|
+
# @return [String] String presentation of the object
|
166
|
+
def to_s
|
167
|
+
to_hash.to_s
|
168
|
+
end
|
169
|
+
|
170
|
+
# to_body is an alias to to_hash (backward compatibility)
|
171
|
+
# @return [Hash] Returns the object in the form of hash
|
172
|
+
def to_body
|
173
|
+
to_hash
|
174
|
+
end
|
175
|
+
|
176
|
+
# Returns the object in the form of hash
|
177
|
+
# @return [Hash] Returns the object in the form of hash
|
178
|
+
def to_hash
|
179
|
+
hash = {}
|
180
|
+
self.class.attribute_map.each_pair do |attr, param|
|
181
|
+
value = self.send(attr)
|
182
|
+
next if value.nil?
|
183
|
+
hash[param] = _to_hash(value)
|
184
|
+
end
|
185
|
+
hash
|
186
|
+
end
|
187
|
+
|
188
|
+
# Outputs non-array value in the form of hash
|
189
|
+
# For object, use to_hash. Otherwise, just return the value
|
190
|
+
# @param [Object] value Any valid value
|
191
|
+
# @return [Hash] Returns the value in the form of hash
|
192
|
+
def _to_hash(value)
|
193
|
+
if value.is_a?(Array)
|
194
|
+
value.compact.map { |v| _to_hash(v) }
|
195
|
+
elsif value.is_a?(Hash)
|
196
|
+
{}.tap do |hash|
|
197
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
198
|
+
end
|
199
|
+
elsif value.respond_to? :to_hash
|
200
|
+
value.to_hash
|
201
|
+
else
|
202
|
+
value
|
203
|
+
end
|
204
|
+
end
|
205
|
+
|
206
|
+
end
|
207
|
+
end
|
@@ -0,0 +1,225 @@
|
|
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
|
+
Swagger Codegen version: 2.4.13-SNAPSHOT
|
10
|
+
|
11
|
+
=end
|
12
|
+
|
13
|
+
require 'date'
|
14
|
+
|
15
|
+
module DocuSign_eSign
|
16
|
+
class RecipientOption
|
17
|
+
#
|
18
|
+
attr_accessor :email
|
19
|
+
|
20
|
+
#
|
21
|
+
attr_accessor :name
|
22
|
+
|
23
|
+
#
|
24
|
+
attr_accessor :recipient_label
|
25
|
+
|
26
|
+
# Optional element. Specifies the role name associated with the recipient.<br/><br/>This is required when working with template recipients.
|
27
|
+
attr_accessor :role_name
|
28
|
+
|
29
|
+
# When set to **true** and the feature is enabled in the sender's account, the signing recipient is required to draw signatures and initials at each signature/initial tab ( instead of adopting a signature/initial style or only drawing a signature/initial once).
|
30
|
+
attr_accessor :signing_group_id
|
31
|
+
|
32
|
+
# Attribute mapping from ruby-style variable name to JSON key.
|
33
|
+
def self.attribute_map
|
34
|
+
{
|
35
|
+
:'email' => :'email',
|
36
|
+
:'name' => :'name',
|
37
|
+
:'recipient_label' => :'recipientLabel',
|
38
|
+
:'role_name' => :'roleName',
|
39
|
+
:'signing_group_id' => :'signingGroupId'
|
40
|
+
}
|
41
|
+
end
|
42
|
+
|
43
|
+
# Attribute type mapping.
|
44
|
+
def self.swagger_types
|
45
|
+
{
|
46
|
+
:'email' => :'String',
|
47
|
+
:'name' => :'String',
|
48
|
+
:'recipient_label' => :'String',
|
49
|
+
:'role_name' => :'String',
|
50
|
+
:'signing_group_id' => :'String'
|
51
|
+
}
|
52
|
+
end
|
53
|
+
|
54
|
+
# Initializes the object
|
55
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
56
|
+
def initialize(attributes = {})
|
57
|
+
return unless attributes.is_a?(Hash)
|
58
|
+
|
59
|
+
# convert string to symbol for hash key
|
60
|
+
attributes = attributes.each_with_object({}) { |(k, v), h| h[k.to_sym] = v }
|
61
|
+
|
62
|
+
if attributes.has_key?(:'email')
|
63
|
+
self.email = attributes[:'email']
|
64
|
+
end
|
65
|
+
|
66
|
+
if attributes.has_key?(:'name')
|
67
|
+
self.name = attributes[:'name']
|
68
|
+
end
|
69
|
+
|
70
|
+
if attributes.has_key?(:'recipientLabel')
|
71
|
+
self.recipient_label = attributes[:'recipientLabel']
|
72
|
+
end
|
73
|
+
|
74
|
+
if attributes.has_key?(:'roleName')
|
75
|
+
self.role_name = attributes[:'roleName']
|
76
|
+
end
|
77
|
+
|
78
|
+
if attributes.has_key?(:'signingGroupId')
|
79
|
+
self.signing_group_id = attributes[:'signingGroupId']
|
80
|
+
end
|
81
|
+
end
|
82
|
+
|
83
|
+
# Show invalid properties with the reasons. Usually used together with valid?
|
84
|
+
# @return Array for valid properties with the reasons
|
85
|
+
def list_invalid_properties
|
86
|
+
invalid_properties = Array.new
|
87
|
+
invalid_properties
|
88
|
+
end
|
89
|
+
|
90
|
+
# Check to see if the all the properties in the model are valid
|
91
|
+
# @return true if the model is valid
|
92
|
+
def valid?
|
93
|
+
true
|
94
|
+
end
|
95
|
+
|
96
|
+
# Checks equality by comparing each attribute.
|
97
|
+
# @param [Object] Object to be compared
|
98
|
+
def ==(o)
|
99
|
+
return true if self.equal?(o)
|
100
|
+
self.class == o.class &&
|
101
|
+
email == o.email &&
|
102
|
+
name == o.name &&
|
103
|
+
recipient_label == o.recipient_label &&
|
104
|
+
role_name == o.role_name &&
|
105
|
+
signing_group_id == o.signing_group_id
|
106
|
+
end
|
107
|
+
|
108
|
+
# @see the `==` method
|
109
|
+
# @param [Object] Object to be compared
|
110
|
+
def eql?(o)
|
111
|
+
self == o
|
112
|
+
end
|
113
|
+
|
114
|
+
# Calculates hash code according to all attributes.
|
115
|
+
# @return [Fixnum] Hash code
|
116
|
+
def hash
|
117
|
+
[email, name, recipient_label, role_name, signing_group_id].hash
|
118
|
+
end
|
119
|
+
|
120
|
+
# Builds the object from hash
|
121
|
+
# @param [Hash] attributes Model attributes in the form of hash
|
122
|
+
# @return [Object] Returns the model itself
|
123
|
+
def build_from_hash(attributes)
|
124
|
+
return nil unless attributes.is_a?(Hash)
|
125
|
+
self.class.swagger_types.each_pair do |key, type|
|
126
|
+
if type =~ /\AArray<(.*)>/i
|
127
|
+
# check to ensure the input is an array given that the attribute
|
128
|
+
# is documented as an array but the input is not
|
129
|
+
if attributes[self.class.attribute_map[key]].is_a?(Array)
|
130
|
+
self.send("#{key}=", attributes[self.class.attribute_map[key]].map { |v| _deserialize($1, v) })
|
131
|
+
end
|
132
|
+
elsif !attributes[self.class.attribute_map[key]].nil?
|
133
|
+
self.send("#{key}=", _deserialize(type, attributes[self.class.attribute_map[key]]))
|
134
|
+
end # or else data not found in attributes(hash), not an issue as the data can be optional
|
135
|
+
end
|
136
|
+
|
137
|
+
self
|
138
|
+
end
|
139
|
+
|
140
|
+
# Deserializes the data based on type
|
141
|
+
# @param string type Data type
|
142
|
+
# @param string value Value to be deserialized
|
143
|
+
# @return [Object] Deserialized data
|
144
|
+
def _deserialize(type, value)
|
145
|
+
case type.to_sym
|
146
|
+
when :DateTime
|
147
|
+
DateTime.parse(value)
|
148
|
+
when :Date
|
149
|
+
Date.parse(value)
|
150
|
+
when :String
|
151
|
+
value.to_s
|
152
|
+
when :Integer
|
153
|
+
value.to_i
|
154
|
+
when :Float
|
155
|
+
value.to_f
|
156
|
+
when :BOOLEAN
|
157
|
+
if value.to_s =~ /\A(true|t|yes|y|1)\z/i
|
158
|
+
true
|
159
|
+
else
|
160
|
+
false
|
161
|
+
end
|
162
|
+
when :Object
|
163
|
+
# generic object (usually a Hash), return directly
|
164
|
+
value
|
165
|
+
when /\AArray<(?<inner_type>.+)>\z/
|
166
|
+
inner_type = Regexp.last_match[:inner_type]
|
167
|
+
value.map { |v| _deserialize(inner_type, v) }
|
168
|
+
when /\AHash<(?<k_type>.+?), (?<v_type>.+)>\z/
|
169
|
+
k_type = Regexp.last_match[:k_type]
|
170
|
+
v_type = Regexp.last_match[:v_type]
|
171
|
+
{}.tap do |hash|
|
172
|
+
value.each do |k, v|
|
173
|
+
hash[_deserialize(k_type, k)] = _deserialize(v_type, v)
|
174
|
+
end
|
175
|
+
end
|
176
|
+
else # model
|
177
|
+
temp_model = DocuSign_eSign.const_get(type).new
|
178
|
+
temp_model.build_from_hash(value)
|
179
|
+
end
|
180
|
+
end
|
181
|
+
|
182
|
+
# Returns the string representation of the object
|
183
|
+
# @return [String] String presentation of the object
|
184
|
+
def to_s
|
185
|
+
to_hash.to_s
|
186
|
+
end
|
187
|
+
|
188
|
+
# to_body is an alias to to_hash (backward compatibility)
|
189
|
+
# @return [Hash] Returns the object in the form of hash
|
190
|
+
def to_body
|
191
|
+
to_hash
|
192
|
+
end
|
193
|
+
|
194
|
+
# Returns the object in the form of hash
|
195
|
+
# @return [Hash] Returns the object in the form of hash
|
196
|
+
def to_hash
|
197
|
+
hash = {}
|
198
|
+
self.class.attribute_map.each_pair do |attr, param|
|
199
|
+
value = self.send(attr)
|
200
|
+
next if value.nil?
|
201
|
+
hash[param] = _to_hash(value)
|
202
|
+
end
|
203
|
+
hash
|
204
|
+
end
|
205
|
+
|
206
|
+
# Outputs non-array value in the form of hash
|
207
|
+
# For object, use to_hash. Otherwise, just return the value
|
208
|
+
# @param [Object] value Any valid value
|
209
|
+
# @return [Hash] Returns the value in the form of hash
|
210
|
+
def _to_hash(value)
|
211
|
+
if value.is_a?(Array)
|
212
|
+
value.compact.map { |v| _to_hash(v) }
|
213
|
+
elsif value.is_a?(Hash)
|
214
|
+
{}.tap do |hash|
|
215
|
+
value.each { |k, v| hash[k] = _to_hash(v) }
|
216
|
+
end
|
217
|
+
elsif value.respond_to? :to_hash
|
218
|
+
value.to_hash
|
219
|
+
else
|
220
|
+
value
|
221
|
+
end
|
222
|
+
end
|
223
|
+
|
224
|
+
end
|
225
|
+
end
|