This is called if the resource should be closed *after* an exception was thrown.
This is called if the resource should be closed *after* an exception was thrown. The default implementation is to call close itself.
Returns the possible exceptions that a resource could throw.
Returns the possible exceptions that a resource could throw. This list is used to catch only relevant exceptions in ARM blocks. This defaults to be any Exception (but not runtime exceptions, which are assumed to be fatal.
Opens a resource for manipulation.
Opens a resource for manipulation. Note: If the resource is already open by definition of existence, then this method should perform a no-op (the default implementation).
This is a type trait for types that are considered 'resources'. These types must be opened (potentially) and closed at some point.