Class ProgressEvent<ResourceT,​CallbackT>


  • public class ProgressEvent<ResourceT,​CallbackT>
    extends Object
    • Constructor Detail

      • ProgressEvent

        public ProgressEvent()
    • Method Detail

      • defaultFailureHandler

        public static <ResourceT,​CallbackT> ProgressEvent<ResourceT,​CallbackT> defaultFailureHandler​(Throwable e,
                                                                                                                 HandlerErrorCode handlerErrorCode)
        Convenience method for constructing a FAILED response
        Type Parameters:
        ResourceT - The type for the resource model
        CallbackT - the type for the callback context
        Parameters:
        e - actual service exception
        handlerErrorCode - error code to return to CloudFormation
        Returns:
        ProgressEvent failed status code
      • defaultInProgressHandler

        public static <ResourceT,​CallbackT> ProgressEvent<ResourceT,​CallbackT> defaultInProgressHandler​(CallbackT callbackContext,
                                                                                                                    int callbackDelaySeconds,
                                                                                                                    ResourceT resourceModel)
        Convenience method for constructing a IN_PROGRESS response
        Type Parameters:
        ResourceT - The type for the resource model
        CallbackT - the type for the callback context
        Parameters:
        callbackContext - callback context
        callbackDelaySeconds - how much time to wait before calling back the handler
        resourceModel - the actual resource model state
        Returns:
        ProgressEvent with OperationStatus.IN_PROGRESS with delay
      • progress

        public static <ResourceT,​CallbackT> ProgressEvent<ResourceT,​CallbackT> progress​(ResourceT model,
                                                                                                    CallbackT cxt)
      • defaultSuccessHandler

        public static <ResourceT,​CallbackT> ProgressEvent<ResourceT,​CallbackT> defaultSuccessHandler​(ResourceT resourceModel)
        Convenience method for constructing a SUCCESS response
        Type Parameters:
        ResourceT - The type for the resource model
        CallbackT - the type for the callback context
        Parameters:
        resourceModel - the current resource model state
        Returns:
        ProgressEvent with OperationStatus.SUCCESS indicating successful completion for operation
      • success

        public static <ResourceT,​CallbackT> ProgressEvent<ResourceT,​CallbackT> success​(ResourceT model,
                                                                                                   CallbackT cxt)
      • isFailed

        public boolean isFailed()
      • isInProgress

        public boolean isInProgress()
      • canContinueProgress

        public boolean canContinueProgress()
      • isSuccess

        public boolean isSuccess()
      • isInProgressCallbackDelay

        public boolean isInProgressCallbackDelay()