Example #1
0
        /// <summary>
        /// <para>Begins an asynchronous send to the members remove route.</para>
        /// </summary>
        /// <param name="user">Identity of user to remove/suspend.</param>
        /// <param name="wipeData">If provided, controls if the user's data will be deleted on
        /// their linked devices.</param>
        /// <param name="transferDestId">If provided, files from the deleted member account
        /// will be transferred to this user.</param>
        /// <param name="transferAdminId">If provided, errors during the transfer process will
        /// be sent via email to this user. If the transfer_dest_id argument was provided, then
        /// this argument must be provided as well.</param>
        /// <param name="callback">The method to be called when the asynchronous send is
        /// completed.</param>
        /// <param name="callbackState">A user provided object that distinguished this send
        /// from other send requests.</param>
        /// <returns>An object that represents the asynchronous send request.</returns>
        public sys.IAsyncResult BeginMembersRemove(UserSelectorArg user,
                                                   bool wipeData = true,
                                                   UserSelectorArg transferDestId = null,
                                                   UserSelectorArg transferAdminId = null,
                                                   sys.AsyncCallback callback = null,
                                                   object callbackState = null)
        {
            var membersRemoveArg = new MembersRemoveArg(user,
                                                        wipeData,
                                                        transferDestId,
                                                        transferAdminId);

            return this.BeginMembersRemove(membersRemoveArg, callback, callbackState);
        }
Example #2
0
        /// <summary>
        /// <para>Begins an asynchronous send to the members remove route.</para>
        /// </summary>
        /// <param name="membersRemoveArg">The request parameters.</param>
        /// <param name="callback">The method to be called when the asynchronous send is
        /// completed.</param>
        /// <param name="state">A user provided object that distinguished this send from other
        /// send requests.</param>
        /// <returns>An object that represents the asynchronous send request.</returns>
        public sys.IAsyncResult BeginMembersRemove(MembersRemoveArg membersRemoveArg, sys.AsyncCallback callback, object state = null)
        {
            var task = this.MembersRemoveAsync(membersRemoveArg);

            return enc.Util.ToApm(task, callback, state);
        }
Example #3
0
        /// <summary>
        /// <para>Removes a member from a team.</para>
        /// <para>Permission : Team member management</para>
        /// <para>Exactly one of team_member_id, email, or external_id must be provided to
        /// identify the user account.</para>
        /// <para>This is not a deactivation where the account can be re-activated again.
        /// Calling <see cref="Dropbox.Api.Team.Routes.TeamRoutes.MembersAddAsync" /> with the
        /// removed user's email address will create a new account with a new team_member_id
        /// that will not have access to any content that was shared with the initial
        /// account.</para>
        /// <para>This endpoint can also be used to cancel a pending invite to join the
        /// team.</para>
        /// <para>This endpoint may initiate an asynchronous job. To obtain the final result of
        /// the job, the client should periodically poll <see
        /// cref="Dropbox.Api.Team.Routes.TeamRoutes.MembersRemoveJobStatusGetAsync" />.</para>
        /// </summary>
        /// <param name="user">Identity of user to remove/suspend.</param>
        /// <param name="wipeData">If provided, controls if the user's data will be deleted on
        /// their linked devices.</param>
        /// <param name="transferDestId">If provided, files from the deleted member account
        /// will be transferred to this user.</param>
        /// <param name="transferAdminId">If provided, errors during the transfer process will
        /// be sent via email to this user. If the transfer_dest_id argument was provided, then
        /// this argument must be provided as well.</param>
        /// <returns>The task that represents the asynchronous send operation. The TResult
        /// parameter contains the response from the server.</returns>
        /// <exception cref="Dropbox.Api.ApiException{MembersRemoveError}">Thrown if there is
        /// an error processing the request; This will contain a <see
        /// cref="MembersRemoveError"/>.</exception>
        public t.Task<Dropbox.Api.Async.LaunchEmptyResult> MembersRemoveAsync(UserSelectorArg user,
                                                                              bool wipeData = true,
                                                                              UserSelectorArg transferDestId = null,
                                                                              UserSelectorArg transferAdminId = null)
        {
            var membersRemoveArg = new MembersRemoveArg(user,
                                                        wipeData,
                                                        transferDestId,
                                                        transferAdminId);

            return this.MembersRemoveAsync(membersRemoveArg);
        }
Example #4
0
 /// <summary>
 /// <para>Removes a member from a team.</para>
 /// <para>Permission : Team member management</para>
 /// <para>Exactly one of team_member_id, email, or external_id must be provided to
 /// identify the user account.</para>
 /// <para>This is not a deactivation where the account can be re-activated again.
 /// Calling <see cref="Dropbox.Api.Team.Routes.TeamRoutes.MembersAddAsync" /> with the
 /// removed user's email address will create a new account with a new team_member_id
 /// that will not have access to any content that was shared with the initial
 /// account.</para>
 /// <para>This endpoint can also be used to cancel a pending invite to join the
 /// team.</para>
 /// <para>This endpoint may initiate an asynchronous job. To obtain the final result of
 /// the job, the client should periodically poll <see
 /// cref="Dropbox.Api.Team.Routes.TeamRoutes.MembersRemoveJobStatusGetAsync" />.</para>
 /// </summary>
 /// <param name="membersRemoveArg">The request parameters</param>
 /// <returns>The task that represents the asynchronous send operation. The TResult
 /// parameter contains the response from the server.</returns>
 /// <exception cref="Dropbox.Api.ApiException{MembersRemoveError}">Thrown if there is
 /// an error processing the request; This will contain a <see
 /// cref="MembersRemoveError"/>.</exception>
 public t.Task<Dropbox.Api.Async.LaunchEmptyResult> MembersRemoveAsync(MembersRemoveArg membersRemoveArg)
 {
     return this.Transport.SendRpcRequestAsync<MembersRemoveArg, Dropbox.Api.Async.LaunchEmptyResult, MembersRemoveError>(membersRemoveArg, "api", "/team/members/remove", Dropbox.Api.Team.MembersRemoveArg.Encoder, Dropbox.Api.Async.LaunchEmptyResult.Decoder, Dropbox.Api.Team.MembersRemoveError.Decoder);
 }