Hi
Could anyone teach me about the following?
1. in a File.open do ... end block, if I call break or return to exit
the block, will the file be closed?
2. Is there a way to write a class-level exception handler? See the
following:
class A
def method 1
begin
...
rescue
end
end
def method 2
begin
...
rescue
end
end
end
in the above code, I do a lot of TCP Socket related work in method1
method2 etc. I would like to return false for all these methods if
there's any error, can I do better than use a begin/rescue/end for every
of them?
Shannon