Class: VagrantPlugins::R10k::Helpers::ErrorWrapper

Inherits:
Vagrant::Errors::VagrantError
  • Object
show all
Defined in:
lib/vagrant-r10k/helpers.rb

Overview

wrapper to create VagrantErrors

Instance Attribute Summary collapse

Instance Method Summary collapse

Constructor Details

#initialize(original) ⇒ ErrorWrapper

Returns a new instance of ErrorWrapper.



156
157
158
# File 'lib/vagrant-r10k/helpers.rb', line 156

def initialize(original)
  @original = original
end

Dynamic Method Handling

This class handles dynamic methods through the method_missing method

#method_missing(fun, *args, &block) ⇒ Object (private)



166
167
168
# File 'lib/vagrant-r10k/helpers.rb', line 166

def method_missing(fun, *args, &block)
  original.send(fun, *args, &block)
end

Instance Attribute Details

#originalObject (readonly)

Returns the value of attribute original.



154
155
156
# File 'lib/vagrant-r10k/helpers.rb', line 154

def original
  @original
end

Instance Method Details

#to_sObject



160
161
162
# File 'lib/vagrant-r10k/helpers.rb', line 160

def to_s
  "#{original.class}: #{original.to_s}"
end