org.labkey.remoteapi.assay
Class AssayListResponse

java.lang.Object
  extended by org.labkey.remoteapi.CommandResponse
      extended by org.labkey.remoteapi.assay.AssayListResponse

public class AssayListResponse
extends CommandResponse

Response class for the AssayListCommand. This class provides helpful getter method to access particular bits of the parsed response data.


Constructor Summary
AssayListResponse(java.lang.String text, int statusCode, java.lang.String contentType, org.json.simple.JSONObject json, AssayListCommand sourceCommand)
          Constructs a new AssayListResponse
 
Method Summary
 java.util.Map<java.lang.String,java.lang.Object> getDefinition(int id)
          Returns an assay definition for the assay identified by the specified id.
 java.util.Map<java.lang.String,java.lang.Object> getDefinition(java.lang.String name)
          Returns an assay definition for the assay identified by the specified name.
 java.util.List<java.util.Map<java.lang.String,java.lang.Object>> getDefinitions()
          Returns the definitions section of the response.
 
Methods inherited from class org.labkey.remoteapi.CommandResponse
findObject, getContentType, getParsedData, getProperty, getProperty, getRequiredVersion, getSourceCommand, getStatusCode, getText
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

AssayListResponse

public AssayListResponse(java.lang.String text,
                         int statusCode,
                         java.lang.String contentType,
                         org.json.simple.JSONObject json,
                         AssayListCommand sourceCommand)
Constructs a new AssayListResponse

Parameters:
text - The response text.
statusCode - The HTTP status code.
contentType - The HTTP response content type
json - The parsed JSONObject (or null if JSON was not returned)
sourceCommand - A copy of the command that created this response
Method Detail

getDefinitions

public java.util.List<java.util.Map<java.lang.String,java.lang.Object>> getDefinitions()
Returns the definitions section of the response. This returns a list of assay definition Maps, each of which contains properties about the particular assay definition.

Returns:
The list of definitions.

getDefinition

public java.util.Map<java.lang.String,java.lang.Object> getDefinition(java.lang.String name)
Returns an assay definition for the assay identified by the specified name.

Parameters:
name - The name of the assay definition to find.
Returns:
The assay definition or null if not found.

getDefinition

public java.util.Map<java.lang.String,java.lang.Object> getDefinition(int id)
Returns an assay definition for the assay identified by the specified id.

Parameters:
id - The id of the assay definition to find.
Returns:
The assay definition or null if not found.