public class ImportRunCommand extends PostCommand<ImportRunResponse>
Command.CommonParameters, Command.Response
CONTENT_TYPE_JSON
Constructor and Description |
---|
ImportRunCommand(int assayId) |
ImportRunCommand(int assayId,
java.io.File file) |
ImportRunCommand(int assayId,
java.util.List<java.util.Map<java.lang.String,java.lang.Object>> dataRows) |
Modifier and Type | Method and Description |
---|---|
ImportRunCommand |
copy()
Returns a copy of this object.
|
protected org.apache.http.client.methods.HttpUriRequest |
createRequest(java.net.URI uri)
Overrides
Command.createRequest(URI) to create an
HttpPost object. |
protected ImportRunResponse |
createResponse(java.lang.String text,
int status,
java.lang.String contentType,
org.json.simple.JSONObject json)
Creates an instance of the response class, initialized with
the response text, the HTTP status code, and parsed JSONObject.
|
void |
setBatchId(int batchId) |
void |
setBatchProperties(java.util.Map<java.lang.String,java.lang.Object> batchProperties) |
void |
setComment(java.lang.String comment) |
void |
setFile(java.io.File file) |
void |
setName(java.lang.String name) |
void |
setProperties(java.util.Map<java.lang.String,java.lang.Object> properties) |
void |
setRunFilePath(java.lang.String runFilePath)
Absolute or relative path to assay data file to be imported.
|
void |
setUseJson(boolean useJson) |
getJsonObject, setJsonObject
_execute, checkThrowError, execute, getActionName, getActionUrl, getControllerName, getHttpRequest, getParameters, getParamValueAsString, getQueryString, getRequiredVersion, getTimeout, setParameters, setRequiredVersion, setTimeout
public ImportRunCommand(int assayId)
public ImportRunCommand(int assayId, java.io.File file)
public ImportRunCommand(int assayId, java.util.List<java.util.Map<java.lang.String,java.lang.Object>> dataRows)
public void setUseJson(boolean useJson)
public void setName(java.lang.String name)
public void setComment(java.lang.String comment)
public void setFile(java.io.File file)
public void setRunFilePath(java.lang.String runFilePath)
runFilePath
- the data file pathpublic void setProperties(java.util.Map<java.lang.String,java.lang.Object> properties)
public void setBatchId(int batchId)
public void setBatchProperties(java.util.Map<java.lang.String,java.lang.Object> batchProperties)
public ImportRunCommand copy()
Command
copy
in class PostCommand<ImportRunResponse>
protected ImportRunResponse createResponse(java.lang.String text, int status, java.lang.String contentType, org.json.simple.JSONObject json)
Command
Override this method to create an instance of a different class that extends CommandResponse
createResponse
in class Command<ImportRunResponse>
text
- The response text from the server.status
- The HTTP status code.contentType
- The Content-Type header value.json
- The parsed JSONObject (or null if no JSON was returned).protected org.apache.http.client.methods.HttpUriRequest createRequest(java.net.URI uri)
PostCommand
Command.createRequest(URI)
to create an
HttpPost
object.
Override this method if your post command sends something other than JSON in the post body. In your override, create the PostMethod and set the RequestEntity appropriately.
createRequest
in class PostCommand<ImportRunResponse>
uri
- the uri to convert