基于 RxJava 响应式框架 Datamill
- 授权协议: MIT
- 开发语言: Java
- 操作系统: 跨平台
- 软件首页: https://github.com/rchodava/datamill
- 软件文档: https://github.com/rchodava/datamill/wiki/Developer-Guide
软件介绍
基于RxJava 的函数式 Reactive 风格的 Java web 框架。
示例代码:
public static void main(String[] args) { // Note the Server class here is foundation.stack.datamill.http.Server
Server server = new Server(
rb -> rb.ifMethodAndUriMatch(Method.GET, "/status", r -> r.respond(b -> b.ok()))
.elseIfMethodAndUriMatch(Method.GET, "/hello", r -> r.respond(b -> b.ok("Hello world!")))
.orElse(r -> r.respond(b -> b.notFound())));
server.listen(8081);
}
