class Google::Gax::GaxError
Common base class for exceptions raised by GAX.
Attributes
status_details[R]
Public Class Methods
new(msg)
click to toggle source
@param msg [String] describes the error that occurred.
Calls superclass method
# File lib/google/gax/errors.rb, line 41 def initialize(msg) msg = "GaxError #{msg}" msg += ", caused by #{$ERROR_INFO}" if $ERROR_INFO super(msg) @cause = $ERROR_INFO @status_details = \ Google::Gax::Grpc.deserialize_error_status_details(@cause) end
Public Instance Methods
code()
click to toggle source
# File lib/google/gax/errors.rb, line 58 def code return nil unless cause && cause.respond_to?(:code) cause.code end
details()
click to toggle source
# File lib/google/gax/errors.rb, line 63 def details return nil unless cause && cause.respond_to?(:details) cause.details end
metadata()
click to toggle source
# File lib/google/gax/errors.rb, line 68 def metadata return nil unless cause && cause.respond_to?(:metadata) cause.metadata end