Exception: OpenFeature::GoFeatureFlag::FlagNotFoundError

Inherits:
StandardError
  • Object
show all
Defined in:
lib/openfeature/go-feature-flag/error/errors.rb

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(response, flag_key) ⇒ FlagNotFoundError

Returns a new instance of FlagNotFoundError.



9
10
11
12
13
14
15
# File 'lib/openfeature/go-feature-flag/error/errors.rb', line 9

def initialize(response, flag_key)
  error_message = "Flag not found: #{flag_key}"
  @response = response
  @error_code = SDK::Provider::ErrorCode::FLAG_NOT_FOUND
  @error_message = error_message
  super(error_message)
end

Instance Attribute Details

#error_codeObject (readonly)

Returns the value of attribute error_code.



7
8
9
# File 'lib/openfeature/go-feature-flag/error/errors.rb', line 7

def error_code
  @error_code
end

#error_messageObject (readonly)

Returns the value of attribute error_message.



7
8
9
# File 'lib/openfeature/go-feature-flag/error/errors.rb', line 7

def error_message
  @error_message
end

#responseObject (readonly)

Returns the value of attribute response.



7
8
9
# File 'lib/openfeature/go-feature-flag/error/errors.rb', line 7

def response
  @response
end