Libraryless. Click here for Pure Java version (3004L/23K/61K).
!7 p { int port = serveHttp(); // find a free port S url = print("http://localhost:" + port); openPlatformBrowser(url); } static NanoHTTPD.Response serve(S uri, NanoHTTPD.Method method, Map<S,S> header, Map<S,S> parms, Map<S,S> files) { print("Serving HTML."); ret serveHTML("Hello world (as usual...)"); }
download show line numbers debug dex old transpilations
Travelled to 14 computer(s): aoiabmzegqzx, bhatertpkbcr, cbybwowwnfue, cfunsshuasjs, gwrvuhgaqvyk, ishqpsrjomds, lpdgvwnxivlt, mqqgnosmbjvj, pyentgdyhuwx, pzhvpgtvlbxg, tslmcundralx, tvejysmllsmz, vouqrxazstgt, wtqryiryparv
No comments. add comment
Snippet ID: | #1008414 |
Snippet name: | Test embedding web server in desktop app |
Eternal ID of this version: | #1008414/4 |
Text MD5: | 8779205616a019159720b258117a522c |
Transpilation MD5: | f107be6e5a8b685030f1db16b41f2c1e |
Author: | stefan |
Category: | javax / desktop |
Type: | JavaX source code |
Public (visible to everyone): | Yes |
Archived (hidden from active list): | No |
Created/modified: | 2017-05-15 14:10:15 |
Source code size: | 334 bytes / 13 lines |
Pitched / IR pitched: | No / No |
Views / Downloads: | 481 / 627 |
Version history: | 3 change(s) |
Referenced in: | [show references] |