Class ResetConfigurationHandlerTestBuilder
- java.lang.Object
-
- com.snowflake.connectors.application.configuration.reset.ResetConfigurationHandlerBuilder
-
- com.snowflake.connectors.application.configuration.reset.ResetConfigurationHandlerTestBuilder
-
public class ResetConfigurationHandlerTestBuilder extends com.snowflake.connectors.application.configuration.reset.ResetConfigurationHandlerBuilder
Test builder for theResetConfigurationHandler
.Allows for customization of the following handler components:
ResetConfigurationValidator
ResetConfigurationSdkCallback
ResetConfigurationCallback
ConnectorErrorHelper
ConnectorStatusService
ConfigurationRepository
PrerequisitesRepository
TransactionManager
-
-
Constructor Summary
Constructors Constructor Description ResetConfigurationHandlerTestBuilder()
Creates a new, emptyResetConfigurationHandlerTestBuilder
.ResetConfigurationHandlerTestBuilder(Session session)
Creates a newResetConfigurationHandlerTestBuilder
.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description ResetConfigurationHandlerTestBuilder
withCallback(com.snowflake.connectors.application.configuration.reset.ResetConfigurationCallback callback)
Sets the callback used to build the handler instance.ResetConfigurationHandlerTestBuilder
withConnectorStatusService(com.snowflake.connectors.application.status.ConnectorStatusService connectorStatusService)
Sets the connector status service used to build the handler instance.ResetConfigurationHandlerTestBuilder
withErrorHelper(com.snowflake.connectors.common.exception.helper.ConnectorErrorHelper errorHelper)
Sets the error helper used to build the handler instance.ResetConfigurationHandlerTestBuilder
withSdkCallback(com.snowflake.connectors.application.configuration.reset.ResetConfigurationSdkCallback sdkCallback)
Sets the callback used to build the handler instance.ResetConfigurationHandlerTestBuilder
withValidator(com.snowflake.connectors.application.configuration.reset.ResetConfigurationValidator validator)
Sets the validator used to build the handler instance.
-
-
-
Constructor Detail
-
ResetConfigurationHandlerTestBuilder
public ResetConfigurationHandlerTestBuilder()
Creates a new, emptyResetConfigurationHandlerTestBuilder
.Properties of the new builder instance must be fully customized before a handler instance can be built.
-
ResetConfigurationHandlerTestBuilder
public ResetConfigurationHandlerTestBuilder(Session session)
Creates a newResetConfigurationHandlerTestBuilder
.The properties of this builder are initialised with:
- a default implementation of
ResetConfigurationValidator
- a default implementation of
ResetConfigurationSdkCallback
- a default implementation of
ResetConfigurationCallback
ConnectorErrorHelper
built usingbuildDefault
- a default implementation of
ConnectorStatusService
- Parameters:
session
- Snowpark session object- Throws:
NullPointerException
- if the provided session object is null
- a default implementation of
-
-
Method Detail
-
withValidator
public ResetConfigurationHandlerTestBuilder withValidator(com.snowflake.connectors.application.configuration.reset.ResetConfigurationValidator validator)
Sets the validator used to build the handler instance.- Overrides:
withValidator
in classcom.snowflake.connectors.application.configuration.reset.ResetConfigurationHandlerBuilder
- Parameters:
validator
- connector state validator- Returns:
- this builder
-
withSdkCallback
public ResetConfigurationHandlerTestBuilder withSdkCallback(com.snowflake.connectors.application.configuration.reset.ResetConfigurationSdkCallback sdkCallback)
Sets the callback used to build the handler instance.- Parameters:
sdkCallback
- pre reset configuration callback- Returns:
- this builder
-
withCallback
public ResetConfigurationHandlerTestBuilder withCallback(com.snowflake.connectors.application.configuration.reset.ResetConfigurationCallback callback)
Sets the callback used to build the handler instance.- Overrides:
withCallback
in classcom.snowflake.connectors.application.configuration.reset.ResetConfigurationHandlerBuilder
- Parameters:
callback
- reset configuration callback- Returns:
- this builder
-
withErrorHelper
public ResetConfigurationHandlerTestBuilder withErrorHelper(com.snowflake.connectors.common.exception.helper.ConnectorErrorHelper errorHelper)
Sets the error helper used to build the handler instance.- Overrides:
withErrorHelper
in classcom.snowflake.connectors.application.configuration.reset.ResetConfigurationHandlerBuilder
- Parameters:
errorHelper
- connector error helper- Returns:
- this builder
-
withConnectorStatusService
public ResetConfigurationHandlerTestBuilder withConnectorStatusService(com.snowflake.connectors.application.status.ConnectorStatusService connectorStatusService)
Sets the connector status service used to build the handler instance.- Parameters:
connectorStatusService
- connector status service- Returns:
- this builder
-
-