binary-streams / loggersoft.kotlin.streams / tryDetectBom

tryDetectBom

@ExperimentalUnsignedTypes fun Stream.tryDetectBom(): Boolean

Tries detect BOM signature in current position and if success updates Stream.defaultByteOrder and Stream.defaultStringEncoding.