# SingleListener

abstract class SingleListener<T : Event>(priority: EventPriority, ignoreCancelled: Boolean) : Listener
Content copied to clipboard

This class represents a Listener with only one event to listen to.

## Constructors

SingleListener
Link copied to clipboard
fun SingleListener(priority: EventPriority, ignoreCancelled: Boolean)
Content copied to clipboard

## Functions

onEvent
Link copied to clipboard
abstract fun onEvent(event: T)
Content copied to clipboard

## Properties

ignoreCancelled
Link copied to clipboard
val ignoreCancelled: Boolean
Content copied to clipboard
priority
Link copied to clipboard
val priority: EventPriority
Content copied to clipboard

## Extensions

register
Link copied to clipboard
inline fun <T : Event> SingleListener<T>.register()
Content copied to clipboard
Registers the SingleListener with its event listener.