autowire icon indicating copy to clipboard operation
autowire copied to clipboard

Support type parameters in autowire.Server

Open zlangbert opened this issue 10 years ago • 1 comments

Goal would be to having something like this work:

object Router {
 def route[T](apiImpl: T, path: String, data: Array[Byte]): Future[_] = {
   AutowireRouter.route[T](apiImpl)(
    autowire.Core.Request(path.split("/"),
    Unpickle[Map[String, ByteBuffer]].fromBytes(ByteBuffer.wrap(data)))
  )
 }
}

According to @lihaoyi this will take a major refactoring of the macros

zlangbert avatar Aug 20 '15 22:08 zlangbert

I think I might be running into this too: https://github.com/mscharley/scalajs-electron-demo/blob/791e088f3c0ed26fe9c27e8895f75df505d1dfee/src/main/scala/autowire/electronipc/ElectronIpcWireServer.scala

What needs to be done to get this sort of thing working?

mscharley avatar May 22 '16 12:05 mscharley