Skip to content

Releases: SchizoidDevelopment/piko

v2.0.0

19 Sep 16:49
0dffc0c

Choose a tag to compare

v2.0.0

Overview

We've modernized the event handling API to make it cleaner and more concise. This update removes the need for explicit event parameters in your handlers, allowing for more readable code.

Breaking Change

This version introduces a breaking change in the event handler syntax. Existing code will need to be updated to work with this new version.

What's Changed

Simplified Event Handler Syntax

Event properties can now be accessed directly within the handler scope without explicitly referencing the event parameter.

Before (v1.x.x):

on<TestEvent>(Event.Priority.HIGH) { event ->
    if (event.a == 5) event.isCancelled = true
}

After (v2.0.0):

on<TestEvent>(Event.Priority.HIGH) {
    if (a == 5) isCancelled = true
}

Benefits

  • Cleaner code: Reduces boilerplate and improves readability
  • More intuitive: Access event properties directly without the event reference
  • Modern approach: Follows contemporary Kotlin idioms and patterns

Migration

This is a required migration. You must update all event handlers to the new syntax:

  1. Remove the explicit event parameter (event ->)
  2. Remove all references to the event object when accessing properties (change event.property to just property)
  3. If you need to reference the event object explicitly in special cases, you can use this

Compatibility

  • This version is not backward compatible with code written for v1.x.x
  • All event handlers must be updated to use the new syntax

Full Changelog: v1.1.0...v2.0.0

v1.1.0

31 Jan 19:04

Choose a tag to compare

v1.1.0

We are excited to announce a significant improvement in event processing time, resulting in enhanced system performance. The optimizations have successfully reduced the time taken per event, resulting in an overall faster and more efficient execution.

  • Previous Event Time: 2977ns per event
  • New Event Time: 571ns per event
  • Total Time Reduction: From 29,778,374ns to 5,710,270ns

This update marks a notable reduction of over 80% in processing time per event, significantly improving system throughput and responsiveness. Users can now expect faster processing and more efficient handling of tasks.

Full Changelog: 1.0.4...v1.1.0

1.0.4

06 Apr 19:33
feb9981

Choose a tag to compare

Performance improvement!

Full Changelog: 1.0.3...1.0.4

1.0.3

03 Nov 02:10
c61e738

Choose a tag to compare

Full Changelog: v1.0.2...1.0.3

v1.0.2

15 Apr 12:47
50f84fe

Choose a tag to compare

v1.0.2 Release

In this version, a small change has been made in the use of the event listener. It now uses a property instead of a function for the "should handle events" feature.

We hope this library helps you write cleaner and more modular code. As always, if you run into any issues or have suggestions for future improvements, please don't hesitate to open an issue or submit a pull request.

Happy coding!

Full Changelog: v1.0.1...v1.0.2

v1.0.1

14 Apr 18:51
d605011

Choose a tag to compare

v1.0.1 Release

We're thrilled to announce the next release of our event library! With this library, you can easily manage and listen to events in your Kotlin-based applications, improving the overall flexibility and scalability of your codebase.

We hope this library helps you write cleaner and more modular code. As always, if you run into any issues or have suggestions for future improvements, please don't hesitate to open an issue or submit a pull request.

Happy coding!

Full Changelog: v1.0.0...v1.0.1

v1.0.0

14 Apr 17:52
63c61f4

Choose a tag to compare

v1.0.0 Release

We're thrilled to announce the initial release of our event library! With this library, you can easily manage and listen to events in your Kotlin-based applications, improving the overall flexibility and scalability of your codebase.

Features

  • Support for prioritization of event listeners.
  • Cancellable events to give you greater control over event handling.

We hope this library helps you write cleaner and more modular code. As always, if you run into any issues or have suggestions for future improvements, please don't hesitate to open an issue or submit a pull request.

Happy coding!