[ci skip] Improve documentation for priority parameter in EventManager (#1619)
* Improve documentation for priority parameter in EventManager
PostOrder was deprecated in commit
(4f227badc2) in favor of priorities.
PostOrder itself was very descriptive on which PostOrder is processed first. A number cannot be descriptive about that - it is never clear if higher or lower numbers are processed first.
The Subscribe event attribute does contain a description on how priorities are evaluated. The EventManager did not, which literally did confused developers manually registering events.
This commit fixes this by describing the priority argument in EventManager with the same description that Subscribe uses.
* Fixed checkstyle
---------
Co-authored-by: Adrian Gonzales <adriangonzalesval@gmail.com>
This commit is contained in:
@@ -60,7 +60,8 @@ public interface EventManager {
|
||||
*
|
||||
* @param plugin the plugin to associate with the handler
|
||||
* @param eventClass the class for the event handler to register
|
||||
* @param postOrder the relative order in which events should be posted to the handler
|
||||
* @param postOrder the relative order in which events should be posted to the handler. The higher
|
||||
* the priority, the earlier the event handler will be called
|
||||
* @param handler the handler to register
|
||||
* @param <E> the event type to handle
|
||||
*/
|
||||
|
||||
Reference in New Issue
Block a user