/// <summary> /// Deletes the specified container. Before you make a <code>DeleteContainer</code> request, /// delete any objects in the container or in any folders in the container. You can delete /// only empty containers. /// </summary> /// <param name="request">Container for the necessary parameters to execute the DeleteContainer service method.</param> /// /// <returns>The response from the DeleteContainer service method, as returned by MediaStore.</returns> /// <exception cref="Amazon.MediaStore.Model.ContainerInUseException"> /// Resource already exists or is being updated. /// </exception> /// <exception cref="Amazon.MediaStore.Model.ContainerNotFoundException"> /// Could not perform an operation on a container that does not exist. /// </exception> /// <exception cref="Amazon.MediaStore.Model.InternalServerErrorException"> /// The service is temporarily unavailable. /// </exception> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/mediastore-2017-09-01/DeleteContainer">REST API Reference for DeleteContainer Operation</seealso> public virtual DeleteContainerResponse DeleteContainer(DeleteContainerRequest request) { var marshaller = new DeleteContainerRequestMarshaller(); var unmarshaller = DeleteContainerResponseUnmarshaller.Instance; return(Invoke <DeleteContainerRequest, DeleteContainerResponse>(request, marshaller, unmarshaller)); }
public async Task <IActionResult> Delete([FromRoute] string id) { var request = new DeleteContainerRequest(id); await _mediator.Send(request); return(NoContent()); }
/// <summary> /// Initiates the asynchronous execution of the DeleteContainer operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the DeleteContainer operation on AmazonMediaStoreClient.</param> /// <param name="callback">An AsyncCallback delegate that is invoked when the operation completes.</param> /// <param name="state">A user-defined state object that is passed to the callback procedure. Retrieve this object from within the callback /// procedure using the AsyncState property.</param> /// /// <returns>An IAsyncResult that can be used to poll or wait for results, or both; this value is also needed when invoking EndDeleteContainer /// operation.</returns> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/mediastore-2017-09-01/DeleteContainer">REST API Reference for DeleteContainer Operation</seealso> public virtual IAsyncResult BeginDeleteContainer(DeleteContainerRequest request, AsyncCallback callback, object state) { var marshaller = new DeleteContainerRequestMarshaller(); var unmarshaller = DeleteContainerResponseUnmarshaller.Instance; return(BeginInvoke <DeleteContainerRequest>(request, marshaller, unmarshaller, callback, state)); }
/// <summary> /// Initiates the asynchronous execution of the DeleteContainer operation. /// </summary> /// /// <param name="request">Container for the necessary parameters to execute the DeleteContainer operation.</param> /// <param name="cancellationToken"> /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// </param> /// <returns>The task object representing the asynchronous operation.</returns> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/mediastore-2017-09-01/DeleteContainer">REST API Reference for DeleteContainer Operation</seealso> public virtual Task <DeleteContainerResponse> DeleteContainerAsync(DeleteContainerRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var marshaller = new DeleteContainerRequestMarshaller(); var unmarshaller = DeleteContainerResponseUnmarshaller.Instance; return(InvokeAsync <DeleteContainerRequest, DeleteContainerResponse>(request, marshaller, unmarshaller, cancellationToken)); }
/// <summary> /// Deletes the specified container. Before you make a <code>DeleteContainer</code> request, /// delete any objects in the container or in any folders in the container. You can delete /// only empty containers. /// </summary> /// <param name="request">Container for the necessary parameters to execute the DeleteContainer service method.</param> /// <param name="cancellationToken"> /// A cancellation token that can be used by other objects or threads to receive notice of cancellation. /// </param> /// /// <returns>The response from the DeleteContainer service method, as returned by MediaStore.</returns> /// <exception cref="Amazon.MediaStore.Model.ContainerInUseException"> /// The container that you specified in the request already exists or is being updated. /// </exception> /// <exception cref="Amazon.MediaStore.Model.ContainerNotFoundException"> /// The container that you specified in the request does not exist. /// </exception> /// <exception cref="Amazon.MediaStore.Model.InternalServerErrorException"> /// The service is temporarily unavailable. /// </exception> /// <seealso href="http://docs.aws.amazon.com/goto/WebAPI/mediastore-2017-09-01/DeleteContainer">REST API Reference for DeleteContainer Operation</seealso> public virtual Task <DeleteContainerResponse> DeleteContainerAsync(DeleteContainerRequest request, System.Threading.CancellationToken cancellationToken = default(CancellationToken)) { var options = new InvokeOptions(); options.RequestMarshaller = DeleteContainerRequestMarshaller.Instance; options.ResponseUnmarshaller = DeleteContainerResponseUnmarshaller.Instance; return(InvokeAsync <DeleteContainerResponse>(request, options, cancellationToken)); }
internal virtual DeleteContainerResponse DeleteContainer(DeleteContainerRequest request) { var options = new InvokeOptions(); options.RequestMarshaller = DeleteContainerRequestMarshaller.Instance; options.ResponseUnmarshaller = DeleteContainerResponseUnmarshaller.Instance; return(Invoke <DeleteContainerResponse>(request, options)); }
public DeleteContainerResponse DeleteContainer(DeleteContainerRequest request) { DeleteContainerResponse response = new DeleteContainerResponse(); try { response = FileManagerService.RemoteFileCommand(request).Action(); } catch (Exception ex) { response.Code = "0001"; response.Message = ex.Message; } return(response); }
public DeleteContainerResponse DeleteContainer(DeleteContainerRequest request) { lock (deleteContainerActionLock) { if (deleteContainerAction == null) { deleteContainerAction = PolicyInjection.Create <BusinessActions.DeleteContainerAction>(); } } request.DeleteContainerParameters.ContainerName = GetUserContainerName(request.DeleteContainerParameters.ContainerName); BusinessEntities.DeleteContainerParameters parameters = DeleteContainerParametersTranslator.TranslateFromServiceToBusiness(request.DeleteContainerParameters); BusinessEntities.DeleteContainerResult result = deleteContainerAction.Execute(parameters); DeleteContainerResponse response = new DeleteContainerResponse(); response.DeleteContainerResult = DeleteContainerResultTranslator.TranslateFromBusinessToService(result); return(response); }
public DeleteContainer(DeleteContainerRequest request) { ConnectNetDrive(); _targetPath = request.TargetContainer; }
/// <summary> /// 容器状态必须为 stopped、running 或 error状态。 <br> /// 按量付费的实例,如不主动删除将一直运行,不再使用的实例,可通过本接口主动停用。<br> /// 只能支持主动删除按配置计费类型的实例。包年包月过期的容器也可以删除,其它的情况还请发工单系统。计费状态异常的容器无法删除。 /// /// </summary> /// <param name="request">请求参数信息</param> /// <returns>请求结果信息</returns> public async Task <DeleteContainerResponse> DeleteContainer(DeleteContainerRequest request) { return(await new DeleteContainerExecutor().Client(this).Execute <DeleteContainerResponse, DeleteContainerResult, DeleteContainerRequest>(request).ConfigureAwait(false)); }
/// <summary> /// 容器状态必须为 stopped、running 或 error状态。 <br> /// 按量付费的实例,如不主动删除将一直运行,不再使用的实例,可通过本接口主动停用。<br> /// 只能支持主动删除按配置计费类型的实例。包年包月过期的容器也可以删除,其它的情况还请发工单系统。计费状态异常的容器无法删除。 /// /// </summary> /// <param name="request">请求参数信息</param> /// <returns>请求结果信息</returns> public DeleteContainerResponse DeleteContainer(DeleteContainerRequest request) { return(new DeleteContainerExecutor().Client(this).Execute <DeleteContainerResponse, DeleteContainerResult, DeleteContainerRequest>(request)); }
public async Task DeleteContainerAsync(string containerName, string leaseId = null) { var request = new DeleteContainerRequest(_account, containerName, leaseId); await request.ExecuteAsync(_containerNotFoundExceptionOverride); }
public void DeleteContainer(string containerName, string leaseId = null) { var request = new DeleteContainerRequest(_account, containerName, leaseId); request.Execute(_containerNotFoundExceptionOverride); }
public static DeleteContainer RemoteFileCommand(DeleteContainerRequest request) { return(new DeleteContainer(request)); }
public DeleteContainerResponse DeleteContainer(DeleteContainerRequest request) { return(adapter.DeleteContainer(request)); }