Add new convert module and sketch its integration

This commit is contained in:
Eike Kettner
2020-02-11 00:33:52 +01:00
parent 3be90d64d5
commit ce22b727b1
9 changed files with 81 additions and 25 deletions

View File

@ -0,0 +1,24 @@
package docspell.convert
import fs2._
import cats.effect._
import docspell.common._
trait Conversion[F[_]] {
def toPDF(inType: MimeType): Pipe[F, Byte, Byte]
}
object Conversion {
def create[F[_]: Sync](cfg: ConvertConfig): Resource[F, Conversion[F]] =
Resource.pure(new Conversion[F] {
def toPDF(inType: MimeType): Pipe[F, Byte, Byte] = {
println(cfg)
???
}
})
}

View File

@ -0,0 +1,3 @@
package docspell.convert
case class ConvertConfig()