jvmCommonMain.com.arkivanov.mvikotlin.timetravel.proto.internal.io.Utils.kt Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of mvikotlin-timetravel-proto-internal Show documentation
Show all versions of mvikotlin-timetravel-proto-internal Show documentation
Kotlin Multiplatform MVI framework
package com.arkivanov.mvikotlin.timetravel.proto.internal.io
import java.io.Closeable
import java.net.ServerSocket
import java.net.Socket
fun Any.closeSafe() {
try {
when (this) {
is Closeable -> close()
is Socket -> close()
is ServerSocket -> close()
}
} catch (ignored: Exception) {
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy