refactor HashFunction
This commit is contained in:
@@ -2,11 +2,12 @@ package com.infendro.hash
|
||||
|
||||
abstract class HashFunction {
|
||||
abstract val bytes: Int
|
||||
|
||||
@Suppress("UNUSED")
|
||||
val bits: Int
|
||||
get() = bytes * 8
|
||||
|
||||
abstract fun hash(
|
||||
value: ByteArray,
|
||||
): ByteArray
|
||||
value: UByteArray,
|
||||
): UByteArray
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user