public virtual Response <IPGroupResource> Update(TagsObject tagsObject, CancellationToken cancellationToken = default)
        {
            Argument.AssertNotNull(tagsObject, nameof(tagsObject));

            using var scope = _ipGroupIpGroupsClientDiagnostics.CreateScope("IPGroupResource.Update");
            scope.Start();
            try
            {
                var response = _ipGroupIpGroupsRestClient.UpdateGroups(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, tagsObject, cancellationToken);
                return(Response.FromValue(new IPGroupResource(Client, response.Value), response.GetRawResponse()));
            }
            catch (Exception e)
            {
                scope.Failed(e);
                throw;
            }
        }
Beispiel #2
0
        public virtual Response <IpGroup> Update(TagsObject parameters, CancellationToken cancellationToken = default)
        {
            if (parameters == null)
            {
                throw new ArgumentNullException(nameof(parameters));
            }

            using var scope = _clientDiagnostics.CreateScope("IpGroup.Update");
            scope.Start();
            try
            {
                var response = _ipGroupsRestClient.UpdateGroups(Id.SubscriptionId, Id.ResourceGroupName, Id.Name, parameters, cancellationToken);
                return(Response.FromValue(new IpGroup(this, response.Value), response.GetRawResponse()));
            }
            catch (Exception e)
            {
                scope.Failed(e);
                throw;
            }
        }