Joutsen v0.5.0+12-g5dd5f7e
Public Member Functions | Properties | Events | List of all members
Joutsen.Events.Event< TPayload > Interface Template Reference

An interface representing a general event with payload that can be used to pass information to another object without holding a reference to it. More...

Public Member Functions

void Fire (TPayload payload)
 Informs all listeners that the event was fired and passes the payload to them. More...
 

Properties

String Name [get]
 The name of the event which will also be passed to the listeners when the event is fired. More...
 

Events

Action< string, TPayload > Fired
 The .NET event that will be fired if the event is fired. More...
 

Detailed Description

An interface representing a general event with payload that can be used to pass information to another object without holding a reference to it.

Template Parameters
TPayloadthe type of the payload of the event. The payload will be transfered to the listeners when the event is fired.
Since
0.2.0

Member Function Documentation

◆ Fire()

void Joutsen.Events.Event< TPayload >.Fire ( TPayload  payload)

Informs all listeners that the event was fired and passes the payload to them.

Parameters
payloadthe type of the payload of the event

Implemented in Joutsen.Events.AggregatingEvent< TPayload >, and Joutsen.Events.PayloadEvent< TPayload >.

Property Documentation

◆ Name

String Joutsen.Events.Event< TPayload >.Name
get

The name of the event which will also be passed to the listeners when the event is fired.

Implemented in Joutsen.Events.PayloadEvent< TPayload >.

Event Documentation

◆ Fired

Action<string,TPayload> Joutsen.Events.Event< TPayload >.Fired

The .NET event that will be fired if the event is fired.