Commit Graph

79 Commits

Author SHA1 Message Date
Tristan B. Velloza Kildaire 73bec426e0 Task
- Fixed missing `eventy.result` import to resolve the `Result` type
2023-03-03 17:32:39 +02:00
Tristan B. Velloza Kildaire d2cc6a8e93 Testing
- Added a playground where I test stuff
2023-03-03 17:31:46 +02:00
Tristan B. Velloza Kildaire 30178efb9c Package
- Added a package
2023-03-03 17:31:29 +02:00
Tristan B. Velloza Kildaire 79ba136e87 Result
- Added `Result` which is what a `Promise` returns when done executing
2023-03-03 17:31:14 +02:00
Tristan B. Velloza Kildaire 7d17b82c03 Engine
- Added an `Engine` which manages all promises and their tasks
2023-03-03 17:30:51 +02:00
Tristan B. Velloza Kildaire 9271fabfa9 Task
- Added a Task which represents the work done by a Promise
2023-03-03 17:30:33 +02:00
Tristan B. Velloza Kildaire 2f57083760 - Added code 2023-03-03 17:17:58 +02:00
Tristan B. Velloza Kildaire 7121f02321 Promise
- Added module `promise`
2023-03-03 17:17:53 +02:00
Tristan B. Velloza Kildaire abe198f6d2 - Update .gitignore 2023-03-03 17:17:07 +02:00
Tristan B. Velloza Kildaire 32aa98d125 Dub
- Added `libsnooze` as a dependency
2023-03-03 17:16:58 +02:00
Tristan B. Velloza Kildaire ea60097153 Added usage of the `then` call 2023-02-22 16:57:00 +02:00
Tristan B. Velloza Kildaire ac5c8dfcde Added ideas of what I want available to me 2023-02-22 16:45:10 +02:00
Tristan B. Velloza Kildaire 9d176cde2c Clean up for re-work 2023-02-22 15:58:13 +02:00
Tristan B. Velloza Kildaire 232b4c68b2 Updated author, copyright and added link to homepage 2023-01-21 18:35:20 +02:00
Tristan B. Velloza Kildaire 27db1734f1 Removed old code for a new slate 2023-01-21 18:33:46 +02:00
Tristan B. Velloza Kildaire 734ea26db2 Removed uneeded method 2022-11-29 13:40:47 +02:00
Tristan B. Velloza Kildaire 8d75e21055 Updated 2022-11-28 18:56:25 +02:00
Tristan B. Velloza Kildaire 0b56db2567 Added missing links 2022-11-28 18:53:46 +02:00
Tristan B. Velloza Kildaire c70fa62d22 Updated .gitignore 2022-11-28 13:39:29 +02:00
Tristan B. Velloza Kildaire 7621ee5343 Completely overhauled Eventy system for the v0.4.0 release
Removed the event-loop for a better system (for now) whereby we just dispatch signal handlers on the call to `push(Event)`.

In a future release I hope to bring the event loop back but in a signal-based manner, such that we can support deferred events and priorities and such
2022-11-28 13:39:06 +02:00
Tristan B. Velloza Kildaire 6392c92349 Cleaned up 2022-11-26 18:39:00 +02:00
Tristan B. Velloza Kildaire 28d64f799e Switch back to YIELD HoldOffMode for now (gives best performance)
We will have to investigate load average highness and ways to deal with it later
2022-11-26 18:19:21 +02:00
Tristan B. Velloza Kildaire cc75eefa15 Try 50ms 2022-11-26 18:16:07 +02:00
Tristan B. Velloza Kildaire e75e3f732d Added missing `eventy.config` import to the `package.d` module 2022-11-26 18:00:24 +02:00
Tristan B. Velloza Kildaire 4fed9fc780 Added missing comment to config.d 2022-11-26 17:58:15 +02:00
Tristan B. Velloza Kildaire 5bbb6d804a Added last missing doc header to a method in engine.d 2022-11-26 17:43:44 +02:00
Tristan B. Velloza Kildaire 6cfaa9824e Added missing comments 2022-11-26 17:37:38 +02:00
Tristan B. Velloza Kildaire 00b8eb82be Removed redundant imports 2022-11-26 17:36:11 +02:00
Tristan B. Velloza Kildaire a501de15d3 Removed commented out code
Moved testing imports within each unit test

Added a new unit test which tests the yield-based HoldOffMode

Neteaned up imports
2022-11-26 17:31:03 +02:00
Tristan B. Velloza Kildaire 59d0253b61 Implemented `agressiveTryLock` check so the user can choose whether or not to yield if a fail to grab the lock occurs 2022-11-26 17:26:05 +02:00
Tristan B. Velloza Kildaire 3603c567e8 Removed deprecated `setSleep(Duration)`
Added `getConfig()/setConfig(EngineSettings)` to retrieve and update the configuration of the Engine on the fly

Privated `getTypes()` method for now as it is not implemented yet
2022-11-26 17:23:40 +02:00
Tristan B. Velloza Kildaire be44514a51 Cleaned up `shutdown()` and added some TODOs 2022-11-26 17:14:20 +02:00
Tristan B. Velloza Kildaire e8b78156b7 Added support for graceful shutdown 2022-11-26 17:12:41 +02:00
Tristan B. Velloza Kildaire 490cfe85d6 Implemented `hasPendingEvents()` to check whether there are any pending events at all
Use `isPendingEvents()` is unit tests to ensure that we actually are able to see ALL events pushed dispatched before we, possibly, pre-maturely shutdown the engine with `shutdown()`

Removed unused function `runner(Event)`

Added new commented out test case

Formatted method documentation of some methods to conform to D's style
2022-11-26 17:07:17 +02:00
Tristan B. Velloza Kildaire 03dfe3ccfd Removed TODO comment
Added configuration system

Introduced two modes of "sleeping" the event loop, sleep-based and yield-based (with 200ms sleep-mode as the default)

Disabled `setSleep(Duration)` for now
2022-11-26 16:52:21 +02:00
Tristan B. Velloza Kildaire b67f61b848 Added isSignalExists(ulong id) to check whether a signal handler exists for a given event id 2022-05-26 14:04:34 +02:00
Tristan B. Velloza Kildaire 263188fa64 Remove todo that has since been completed 2022-05-19 16:50:56 +02:00
Tristan B. Velloza Kildaire d0c4d12155 Make unit testing method private within module 2022-05-19 16:49:52 +02:00
Tristan B. Velloza Kildaire 9a26ed7011 Removed swear words 2022-05-19 16:49:25 +02:00
Tristan B. Velloza Kildaire c6082f3941 Unit test: Shutdown engine after testing 2022-05-19 16:48:09 +02:00
Tristan B. Velloza Kildaire 692660772a Added rudimentary shutdown() method 2022-04-07 10:11:59 +02:00
Tristan B. Velloza Kildaire ea1e317431 Updated README 2022-01-16 15:02:01 +02:00
Tristan B. Velloza Kildaire f2f79e1cf8 Updated documentation 2022-01-16 14:56:26 +02:00
Tristan B. Velloza Kildaire f649a63a77 Re-worked event system 2022-01-16 14:32:00 +02:00
Tristan B. Velloza Kildaire f1a13623a6 Added comment 2022-01-16 14:22:18 +02:00
Tristan B. Velloza Kildaire c2bc5bc902 Added optional payload support 2022-01-16 14:21:09 +02:00
Tristan B. Kildaire 72a35976e1 Added a Javadoc 2021-12-27 13:04:30 +02:00
Tristan B. Kildaire 3e826aa1ac Added a Javadoc 2021-12-27 13:03:55 +02:00
Tristan B. Kildaire f87a7f44ca Added some Javadocs 2021-12-27 13:02:32 +02:00
Tristan B. Velloza Kildaire d2e9f5376c New logo 2021-12-27 12:29:47 +02:00