public abstract class BATClientBase
extends org.mule.tools.client.core.AbstractClient
| Modifier and Type | Field and Description |
|---|---|
static String |
BEARER_TOKEN |
protected String |
bearerToken |
static String |
EXECUTION_BASE_URL |
static String |
EXECUTION_ID_PATH |
static String |
EXECUTION_RESULT_BASE_URL |
static String |
EXECUTION_RESULT_PATH |
static String |
EXECUTIONS_PATH |
static String |
RESULTS_PATH |
| Constructor and Description |
|---|
BATClientBase(String baseUri) |
| Modifier and Type | Method and Description |
|---|---|
protected void |
configureRequest(javax.ws.rs.client.Invocation.Builder builder) |
CreateExecutionResponse |
createExecution(TestType testType)
Creates new Execution
|
String |
getBaseUri() |
protected abstract String |
getBearerToken() |
ExecutionResponse |
getExecution(String executionId)
Retrieves the Execution info
|
ExecutionResultResponse |
getExecutionResult(String executionId)
Retrieves the test result from an Execution
|
protected abstract String |
getOrganizationId() |
protected void |
init() |
abstract void |
renewToken() |
void |
saveExecutionResult(String executionId,
File file)
Save the test result to an Execution
|
ExecutionResponse |
setExecutionStatus(String executionId,
ExecutionStatus status)
Change the status of an Execution
|
public static final String EXECUTION_BASE_URL
public static final String EXECUTION_RESULT_BASE_URL
public static final String RESULTS_PATH
public static final String EXECUTION_RESULT_PATH
public static final String EXECUTIONS_PATH
public static final String EXECUTION_ID_PATH
public static final String BEARER_TOKEN
protected String bearerToken
public BATClientBase(String baseUri)
protected void init()
init in class org.mule.tools.client.core.AbstractClientpublic CreateExecutionResponse createExecution(TestType testType)
testType - type of test for the Executionpublic ExecutionResponse getExecution(String executionId)
executionId - Id of the Executionpublic ExecutionResultResponse getExecutionResult(String executionId)
executionId - Id of the Executionpublic void saveExecutionResult(String executionId, File file) throws IOException
executionId - Id of the Executionfile - that contains the result to be uploadedIOException - if reading file action failspublic ExecutionResponse setExecutionStatus(String executionId, ExecutionStatus status)
executionId - Id of the Executionstatus - the new status for the Executionprotected void configureRequest(javax.ws.rs.client.Invocation.Builder builder)
configureRequest in class org.mule.tools.client.core.AbstractClientprotected abstract String getBearerToken()
protected abstract String getOrganizationId()
public abstract void renewToken()
public String getBaseUri()
Copyright © 2020. All rights reserved.