Missing Encoder/Decoder for Byte in OrientDB Contexts
daniel-shuy opened this issue · comments
Version: 2.3.2
Module: quill-orientdb
Database: OrientDB
Expected behavior
Built-in Encoder/Decoder for Byte
(according to https://orientdb.com/docs/last/Types.html, Byte
s are supported).
Actual behavior
Missing Encoder/Decoder for Byte
.
Workaround
import io.getquill._
lazy val ctx = new OrientDBSyncContext(SnakeCase, "ctx")
implicit val byteEncoder: Encoder[Byte] = ctx.encoder((index, value, row) => {
row.insert(index, value)
row
})
implicit val byteDecoder: Decoder[Byte] = ctx.decoder((index, row) => {
row.field[Byte](row.fieldNames()(index))
})
@getquill/maintainers