Exception: Unleash::OpenFeature::Provider::VariantResolutionError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/unleash/open_feature/provider/unleash_flag_provider.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(message, variant_name:, reason: ::OpenFeature::SDK::Provider::Reason::ERROR, error_code: nil) ⇒ VariantResolutionError

Returns a new instance of VariantResolutionError.



193
194
195
196
197
198
# File 'lib/unleash/open_feature/provider/unleash_flag_provider.rb', line 193

def initialize(message, variant_name:, reason: ::OpenFeature::SDK::Provider::Reason::ERROR, error_code: nil)
  super(message)
  @variant_name = variant_name
  @reason = reason
  @error_code = error_code
end

Instance Attribute Details

#error_codeObject (readonly)

Returns the value of attribute error_code.



191
192
193
# File 'lib/unleash/open_feature/provider/unleash_flag_provider.rb', line 191

def error_code
  @error_code
end

#reasonObject (readonly)

Returns the value of attribute reason.



191
192
193
# File 'lib/unleash/open_feature/provider/unleash_flag_provider.rb', line 191

def reason
  @reason
end

#variant_nameObject (readonly)

Returns the value of attribute variant_name.



191
192
193
# File 'lib/unleash/open_feature/provider/unleash_flag_provider.rb', line 191

def variant_name
  @variant_name
end