hxcpp
hxcpp copied to clipboard
Libuv Asys Implementation
WIP Libuv based asys api implementation. Trying to hide the libuv-ness behind a generic asys header so someone could provide an alternative asys implementation for platforms which might not support libuv but have their own. Also going to add a "NotImplementedException" asys implementation for non desktop platforms.
I've tried a base object approach instead of differing implementations behind #ifdef checks so typed objects can be passed around instead of Dynamic. I'm also using some c++ 14 features (make_unique and nested namespaces), not sure if there's a c++ version that hxcpp tries to target. I'm not married to any of this so I'm happy to change any of it.
- [x] Event Loop
- [x] File
- [x] Directory
- [x] File System
- [x] Net
- [x] Dns
- [x] Ip
- [x] Socket
- [x] Server
- [ ] UdpSocket
- [ ] SecureSocket
- [ ] SecureServer
- [x] Processes
- [ ] stdio pipe to file paths.
- [x] Signals
- [x] Streams
Other TODO:
- [ ] Ensure all
uv_handle_t's are cleaned up when things fail (look into customunique_ptr's to automate this) - [ ] Move some stuff out of C++ and into haxe (I would like to move all the queuing stuff into haxe, easier than faffing around with state in a C API).
- [ ] Double check all GC and heap object cleanup
- [ ] Change all uses of Dynamic to typed callables (depends on https://github.com/HaxeFoundation/haxe/pull/11151)
- [ ] Reduce dependency to C++ 11.
- [ ] Revive branch I experimented on a while ago to mark
hx::Throwas no-return.