Class ReturnOutputVariablesAction

ReturnOutputVariablesAction

Contains output variables generated by the executed action in Google Workspace Studio.

Only available for Google Workspace add-ons that extend Google Workspace Studio.

Sample usage:

constvariableDataMap={
"result":AddOnsResponseService.newVariableData()
.addIntegerValue(100)
};
constworkflowAction=AddOnsResponseService.newReturnOutputVariablesAction()
.setVariableDataMap(variableDataMap);
consthostAppAction=AddOnsResponseService.newHostAppAction()
.setWorkflowAction(workflowAction);
constrenderAction=AddOnsResponseService.newRenderActionBuilder()
.setHostAppAction(hostAppAction)
.build();
returnrenderAction;

Methods

MethodReturn typeBrief description
addVariableData(key, value) ReturnOutputVariablesAction Adds a variable data keyed by its variable name, a value is overwritten if the key already exists.
setLog(log) ReturnOutputVariablesAction Sets the Log of the executed workflow action to the end user at Workflow's activity feed.
setVariableDataMap(variables) ReturnOutputVariablesAction Sets the map of the variable data keyed by variable name, a value is overwritten if the key already exists.

Detailed documentation

addVariableData(key, value)

Adds a variable data keyed by its variable name, a value is overwritten if the key already exists.

Parameters

NameTypeDescription
keyStringThe variable name of string type to retrieve the output variable data.
valueVariableData The data of the variable.

Return

ReturnOutputVariablesAction — This return output variables action, for chaining.


setLog(log)

Sets the Log of the executed workflow action to the end user at Workflow's activity feed.

Parameters

NameTypeDescription
logWorkflowTextFormat The WorkflowTextFormat log of the executed workflow action.

Return

ReturnOutputVariablesAction — This return output variables action, for chaining.


setVariableDataMap(variables)

Sets the map of the variable data keyed by variable name, a value is overwritten if the key already exists.

Parameters

NameTypeDescription
variablesObjectA collection of key-value pairs of string and variable data.

Return

ReturnOutputVariablesAction — This return output variables action, for chaining.

Except as otherwise noted, the content of this page is licensed under the Creative Commons Attribution 4.0 License, and code samples are licensed under the Apache 2.0 License. For details, see the Google Developers Site Policies. Java is a registered trademark of Oracle and/or its affiliates.

Last updated 2025年12月03日 UTC.