Class: Datadog::OpenFeature::ResolutionDetails

Inherits:
Struct
  • Object
show all
Defined in:
lib/datadog/open_feature/resolution_details.rb

Overview

This class is based on the ‘OpenFeature::SDK::Provider::ResolutionDetails` class

See: github.com/open-feature/ruby-sdk/blob/v0.4.1/lib/open_feature/sdk/provider/resolution_details.rb

Instance Attribute Summary collapse

Class Method Summary collapse

Instance Attribute Details

#allocation_keyObject

Returns the value of attribute allocation_key

Returns:

  • (Object)

    the current value of allocation_key



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def allocation_key
  @allocation_key
end

#error?Object

Returns the value of attribute error?

Returns:

  • (Object)

    the current value of error?



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def error?
  @error?
end

#error_codeObject

Returns the value of attribute error_code

Returns:

  • (Object)

    the current value of error_code



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def error_code
  @error_code
end

#error_messageObject

Returns the value of attribute error_message

Returns:

  • (Object)

    the current value of error_message



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def error_message
  @error_message
end

#extra_loggingObject

Returns the value of attribute extra_logging

Returns:

  • (Object)

    the current value of extra_logging



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def extra_logging
  @extra_logging
end

#flag_metadataObject

Returns the value of attribute flag_metadata

Returns:

  • (Object)

    the current value of flag_metadata



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def 
  @flag_metadata
end

#log?Object

Returns the value of attribute log?

Returns:

  • (Object)

    the current value of log?



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def log?
  @log?
end

#reasonObject

Returns the value of attribute reason

Returns:

  • (Object)

    the current value of reason



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def reason
  @reason
end

#valueObject

Returns the value of attribute value

Returns:

  • (Object)

    the current value of value



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def value
  @value
end

#variantObject

Returns the value of attribute variant

Returns:

  • (Object)

    the current value of variant



10
11
12
# File 'lib/datadog/open_feature/resolution_details.rb', line 10

def variant
  @variant
end

Class Method Details

.build_error(value:, error_code:, error_message:, reason: Ext::ERROR) ⇒ Object



23
24
25
26
27
28
29
30
31
32
# File 'lib/datadog/open_feature/resolution_details.rb', line 23

def self.build_error(value:, error_code:, error_message:, reason: Ext::ERROR)
  new(
    value: value,
    error_code: error_code,
    error_message: error_message,
    reason: reason,
    error?: true,
    log?: false
  ).freeze
end