Rename
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
package io.legato.kazusa.web
|
||||
|
||||
import fi.iki.elonen.NanoWSD
|
||||
import io.legato.kazusa.service.WebService
|
||||
import io.legato.kazusa.web.socket.*
|
||||
|
||||
class WebSocketServer(port: Int) : NanoWSD(port) {
|
||||
|
||||
override fun openWebSocket(handshake: IHTTPSession): WebSocket? {
|
||||
WebService.serve()
|
||||
return when (handshake.uri) {
|
||||
"/bookSourceDebug" -> {
|
||||
BookSourceDebugWebSocket(handshake)
|
||||
}
|
||||
"/rssSourceDebug" -> {
|
||||
RssSourceDebugWebSocket(handshake)
|
||||
}
|
||||
"/searchBook" -> {
|
||||
BookSearchWebSocket(handshake)
|
||||
}
|
||||
else -> null
|
||||
}
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user