use

common
inline fun <T : Closeable?, R> T.use(body: (T) -> R): R

Run body on the receiver and call Closeable.close before returning or throwing.

inline fun <T : Closeable?, R> T.use(body: (T) -> R): R
inline fun <T : Closeable?, R> T.use(body: (T) -> R): R