Sha256: 583e324568dd1a14154cf848cdf8fc8927a8ac5d0a3cecee117a1500b10f5168

Contents?: true

Size: 459 Bytes

Versions: 43

Compression:

Stored size: 459 Bytes

Contents

# frozen_string_literal: true

class Tramway::Error < RuntimeError
  def initialize(*args, plugin: nil, method: nil, message: nil)
    @properties ||= {}
    @properties[:plugin] = plugin
    @properties[:method] = method
    @properties[:message] = message
    super(*args)
  end

  def message
    "Plugin: #{@properties[:plugin]}; Method: #{@properties[:method]}; Message: #{@properties[:message]}"
  end

  def properties
    @properties ||= {}
  end
end

Version data entries

43 entries across 43 versions & 1 rubygems

Version Path
tramway-core-1.17.2.1 lib/tramway/error.rb
tramway-core-1.17.2 lib/tramway/error.rb
tramway-core-1.17.1.1 lib/tramway/error.rb
tramway-core-1.17.1 lib/tramway/error.rb
tramway-core-1.17 lib/tramway/error.rb
tramway-core-1.16.2.1 lib/tramway/error.rb
tramway-core-1.16.2 lib/tramway/error.rb
tramway-core-1.16.1.9 lib/tramway/error.rb
tramway-core-1.16.1.8 lib/tramway/error.rb
tramway-core-1.16.1.7 lib/tramway/error.rb
tramway-core-1.16.1.6 lib/tramway/error.rb
tramway-core-1.16.1.5 lib/tramway/error.rb
tramway-core-1.16.1.4 lib/tramway/error.rb
tramway-core-1.16.1.3 lib/tramway/error.rb
tramway-core-1.16.1.2 lib/tramway/error.rb
tramway-core-1.16.1.1 lib/tramway/error.rb
tramway-core-1.16.1 lib/tramway/error.rb
tramway-core-1.16 lib/tramway/error.rb
tramway-core-1.15.1 lib/tramway/error.rb
tramway-core-1.15 lib/tramway/error.rb