Exception: AnalyticsOps::Error

Inherits:
StandardError
  • Object
show all
Defined in:
lib/analytics_ops/errors.rb,
sig/analytics_ops.rbs

Overview

Base for every expected, safely reportable Analytics Ops failure.

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message = nil, remote_reason: nil, remote_metadata: nil, remote_code: nil) ⇒ Error

Returns a new instance of Error.



12
13
14
15
16
17
# File 'lib/analytics_ops/errors.rb', line 12

def initialize(message = nil, remote_reason: nil, remote_metadata: nil, remote_code: nil)
  @remote_reason = safe_remote_value(remote_reason, 128)
  @remote_metadata = ()
  @remote_code = safe_remote_value(remote_code, 64)
  super(message)
end

Instance Attribute Details

#remote_codeString? (readonly)

Returns the value of attribute remote_code.

Returns:

  • (String, nil)


10
11
12
# File 'lib/analytics_ops/errors.rb', line 10

def remote_code
  @remote_code
end

#remote_metadatarecord (readonly)

Returns the value of attribute remote_metadata.

Returns:

  • (record)


10
11
12
# File 'lib/analytics_ops/errors.rb', line 10

def 
  @remote_metadata
end

#remote_reasonString? (readonly)

Returns the value of attribute remote_reason.

Returns:

  • (String, nil)


10
11
12
# File 'lib/analytics_ops/errors.rb', line 10

def remote_reason
  @remote_reason
end