Quantcast
Channel: patterns & practices: Prism
Viewing all articles
Browse latest Browse all 1878

New Post: MessageBus without PubSubEvent

$
0
0
Are there any performance issues with using this approach for Pub/Sub events?

The idea is to wrap a message in a generic PubSubEvent so you can write the message like this:
// Create the Event Message
public class TickerSymbolSelectedMessage
{
    public string StockSymbol { get; set; }
}
And the you can send it like this:
// Broadcast Events
EventSystem.Publish<TickerSymbolSelectedMessage>(
    new TickerSymbolSelectedMessage{ StockSymbol = “STOCK0”});
I like this and it remind me of the messagebus in RxUI

Viewing all articles
Browse latest Browse all 1878

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>