Class: Google::Apis::ScriptV1::ExecutionResponse

Inherits:
Object
  • Object
show all
Includes:
Core::Hashable, Core::JsonObjectSupport
Defined in:
generated/google/apis/script_v1/classes.rb,
generated/google/apis/script_v1/representations.rb,
generated/google/apis/script_v1/representations.rb

Overview

An object that provides the return value of a function executed through the Apps Script Execution API. If a run call succeeds and the script function returns successfully, the response body's response field contains this ExecutionResponse object.

Instance Attribute Summary collapse

Instance Method Summary collapse

Methods included from Core::JsonObjectSupport

#to_json

Methods included from Core::Hashable

process_value, #to_h

Constructor Details

#initialize(**args) ⇒ ExecutionResponse

Returns a new instance of ExecutionResponse



170
171
172
# File 'generated/google/apis/script_v1/classes.rb', line 170

def initialize(**args)
   update!(**args)
end

Instance Attribute Details

#resultObject

The return value of the script function. The type matches the object type returned in Apps Script. Functions called through the Execution API cannot return Apps Script-specific objects (such as a Document or a Calendar); they can only return primitive types such as a string, number, array, object, or boolean. Corresponds to the JSON property result

Returns:

  • (Object)


168
169
170
# File 'generated/google/apis/script_v1/classes.rb', line 168

def result
  @result
end

Instance Method Details

#update!(**args) ⇒ Object

Update properties of this object



175
176
177
# File 'generated/google/apis/script_v1/classes.rb', line 175

def update!(**args)
  @result = args[:result] if args.key?(:result)
end