Module: TryCatch::EXT::Object

Defined in:
lib/try-catch.rb

Instance Method Summary collapse

Instance Method Details

#catch(*exception_classes, &block) ⇒ Object



109
110
111
# File 'lib/try-catch.rb', line 109

def catch *exception_classes, &block
  ::TryCatch::Function.catch self, *exception_classes, &block
end

#try(*exception_classes, &block) ⇒ Object



105
106
107
# File 'lib/try-catch.rb', line 105

def try *exception_classes, &block
  ::TryCatch::Function.try self, *exception_classes, &block
end