Exception: Yoga::Error Private

Inherits:
StandardError
  • Object
show all
Defined in:
lib/yoga/errors.rb

Overview

This class is part of a private API. You should avoid using this class if possible, as it may be removed or be changed in the future.

An error originating from the Yoga class. All behavior here is private to the Yoga module.

Direct Known Subclasses

LocationError

Instance Method Summary collapse

Constructor Details

#initialize(data) ⇒ Error

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Initialize the error.



14
15
16
17
# File 'lib/yoga/errors.rb', line 14

def initialize(data)
  data.each { |k, v| instance_variable_set(:"@#{k}", v) }
  super(generate_message)
end

Instance Method Details

#generate_message::String (private)

This method is part of a private API. You should avoid using this method if possible, as it may be removed or be changed in the future.

Generates a message for the exception.

Returns:

  • (::String)


24
25
26
# File 'lib/yoga/errors.rb', line 24

def generate_message
  message
end