Class: Google::Apis::ScriptV1::Status
- Inherits:
-
Object
- Object
- Google::Apis::ScriptV1::Status
- 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
If a run
call succeeds but the script function (or Apps Script itself)
throws an exception, the response body's error
field will contain this
Status
object.
Instance Attribute Summary collapse
-
#code ⇒ Fixnum
The status code, which should be an enum value of google.rpc.Code.
-
#details ⇒ Array<Hash<String,Object>>
An array that contains a single
ExecutionError
object that provides information about the nature of the error. -
#message ⇒ String
A developer-facing error message, which should be in English.
Instance Method Summary collapse
-
#initialize(**args) ⇒ Status
constructor
A new instance of Status.
-
#update!(**args) ⇒ Object
Update properties of this object.
Methods included from Core::JsonObjectSupport
Methods included from Core::Hashable
Constructor Details
#initialize(**args) ⇒ Status
Returns a new instance of Status.
157 158 159 |
# File 'generated/google/apis/script_v1/classes.rb', line 157 def initialize(**args) update!(**args) end |
Instance Attribute Details
#code ⇒ Fixnum
The status code, which should be an enum value of google.rpc.Code.
Corresponds to the JSON property code
142 143 144 |
# File 'generated/google/apis/script_v1/classes.rb', line 142 def code @code end |
#details ⇒ Array<Hash<String,Object>>
An array that contains a single ExecutionError
object that provides
information about the nature of the error.
Corresponds to the JSON property details
155 156 157 |
# File 'generated/google/apis/script_v1/classes.rb', line 155 def details @details end |
#message ⇒ String
A developer-facing error message, which should be in English. Any user-facing
error message should be localized and sent in the google.rpc.Status.details
field, or localized by the client.
Corresponds to the JSON property message
149 150 151 |
# File 'generated/google/apis/script_v1/classes.rb', line 149 def @message end |
Instance Method Details
#update!(**args) ⇒ Object
Update properties of this object
162 163 164 165 166 |
# File 'generated/google/apis/script_v1/classes.rb', line 162 def update!(**args) @code = args[:code] if args.key?(:code) @message = args[:message] if args.key?(:message) @details = args[:details] if args.key?(:details) end |