Skip to content

Commit

Permalink
refactor: hardcode codec uuid
Browse files Browse the repository at this point in the history
  • Loading branch information
BFergerson committed Oct 16, 2023
1 parent bffdf87 commit 652d9ce
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion src/main/kotlin/spp/protocol/marshall/LocalMessageCodec.kt
Original file line number Diff line number Diff line change
Expand Up @@ -26,13 +26,16 @@ import java.util.*
* @since 0.1.0
*/
class LocalMessageCodec<T> : MessageCodec<T, T> {

private val name = UUID.randomUUID().toString()

override fun encodeToWire(buffer: Buffer, o: T): Unit =
throw UnsupportedOperationException("Not supported yet.")

override fun decodeFromWire(pos: Int, buffer: Buffer): T =
throw UnsupportedOperationException("Not supported yet.")

override fun transform(o: T): T = o
override fun name(): String = UUID.randomUUID().toString()
override fun name(): String = name
override fun systemCodecID(): Byte = -1
}

0 comments on commit 652d9ce

Please sign in to comment.