lib/purecloudplatformclientv2/models/trust_create.rb in purecloudplatformclientv2-22.0.0 vs lib/purecloudplatformclientv2/models/trust_create.rb in purecloudplatformclientv2-23.0.0
- old
+ new
@@ -22,23 +22,28 @@
attr_accessor :pairing_id
# If disabled no trustee user will have access, even if they were previously added.
attr_accessor :enabled
- # The list of users and their roles to which access will be granted. The users are from the trustee and the roles are from the trustor.
+ # The list of users and their roles to which access will be granted. The users are from the trustee and the roles are from the trustor. If no users are specified, at least one group is required.
attr_accessor :users
+ # The list of groups and their roles to which access will be granted. The groups are from the trustee and the roles are from the trustor. If no groups are specified, at least one user is required.
+ attr_accessor :groups
+
# Attribute mapping from ruby-style variable name to JSON key.
def self.attribute_map
{
:'pairing_id' => :'pairingId',
:'enabled' => :'enabled',
- :'users' => :'users'
+ :'users' => :'users',
+ :'groups' => :'groups'
+
}
end
# Attribute type mapping.
def self.swagger_types
@@ -46,12 +51,14 @@
:'pairing_id' => :'String',
:'enabled' => :'BOOLEAN',
- :'users' => :'Array<TrustUserCreate>'
+ :'users' => :'Array<TrustMemberCreate>',
+ :'groups' => :'Array<TrustMemberCreate>'
+
}
end
# Initializes the object
# @param [Hash] attributes Model attributes in the form of hash
@@ -89,10 +96,21 @@
end
+ if attributes.has_key?(:'groups')
+
+ if (value = attributes[:'groups']).is_a?(Array)
+ self.groups = value
+ end
+
+
+
+ end
+
+
end
# Show invalid properties with the reasons. Usually used together with valid?
# @return Array for valid properies with the reasons
def list_invalid_properties
@@ -123,18 +141,17 @@
- if @users.nil?
- return false
- end
-
+
+
+
end
@@ -149,18 +166,24 @@
+
+
+
+
+
# Checks equality by comparing each attribute.
# @param [Object] Object to be compared
def ==(o)
return true if self.equal?(o)
self.class == o.class &&
pairing_id == o.pairing_id &&
enabled == o.enabled &&
- users == o.users
+ users == o.users &&
+ groups == o.groups
end
# @see the `==` method
# @param [Object] Object to be compared
def eql?(o)
@@ -168,10 +191,10 @@
end
# Calculates hash code according to all attributes.
# @return [Fixnum] Hash code
def hash
- [pairing_id, enabled, users].hash
+ [pairing_id, enabled, users, groups].hash
end
# build the object from hash
def build_from_hash(attributes)
return nil unless attributes.is_a?(Hash)