public final class Operation extends GenericJson
This is the Java data model class that specifies how to parse/serialize into the JSON that is transmitted over HTTP when working with the Google Apps Script Execution API. For a detailed explanation see: http://code.google.com/p/google-http-java-client/wiki/JSON
GenericData.Flags
AbstractMap.SimpleEntry<K,V>, AbstractMap.SimpleImmutableEntry<K,V>
Constructor and Description |
---|
Operation() |
Modifier and Type | Method and Description |
---|---|
Operation |
clone() |
Boolean |
getDone()
This field is only used with asynchronous executions and indicates whether or not the script
execution has completed.
|
Status |
getError()
If a `run` call succeeds but the script function (or Apps Script itself) throws an exception,
this field will contain a `Status` object.
|
Map<String,Object> |
getMetadata()
This field is not used.
|
Map<String,Object> |
getResponse()
If the script function returns successfully, this field will contain an `ExecutionResponse`
object with the function's return value as the object's `result` field.
|
Operation |
set(String fieldName,
Object value) |
Operation |
setDone(Boolean done)
This field is only used with asynchronous executions and indicates whether or not the script
execution has completed.
|
Operation |
setError(Status error)
If a `run` call succeeds but the script function (or Apps Script itself) throws an exception,
this field will contain a `Status` object.
|
Operation |
setMetadata(Map<String,Object> metadata)
This field is not used.
|
Operation |
setResponse(Map<String,Object> response)
If the script function returns successfully, this field will contain an `ExecutionResponse`
object with the function's return value as the object's `result` field.
|
getFactory, setFactory, toPrettyString, toString
entrySet, get, getClassInfo, getUnknownKeys, put, putAll, remove, setUnknownKeys
clear, containsKey, containsValue, equals, hashCode, isEmpty, keySet, size, values
public Boolean getDone()
null
for nonepublic Operation setDone(Boolean done)
done
- done or null
for nonepublic Status getError()
null
for nonepublic Operation setError(Status error)
error
- error or null
for nonepublic Map<String,Object> getMetadata()
null
for nonepublic Operation setMetadata(Map<String,Object> metadata)
metadata
- metadata or null
for nonepublic Map<String,Object> getResponse()
null
for nonepublic Operation setResponse(Map<String,Object> response)
response
- response or null
for nonepublic Operation set(String fieldName, Object value)
set
in class GenericJson
public Operation clone()
clone
in class GenericJson