protected void Init(string resourceKey, HandlerProc handler, CoreDispatcher dispatcher, ResourceContext context = null)
 {
     ResourceKey = resourceKey;
     Handler     = handler ?? throw new ArgumentNullException(nameof(handler));
     Dispatcher  = dispatcher ?? throw new ArgumentNullException(nameof(dispatcher));
     Context     = context ?? ResourceContext.GetForCurrentView();
 }
 public ResourceMapListener(string resourceKey, HandlerProc handler, CoreDispatcher dispatcher, ResourceContext context = null)
 {
     Init(resourceKey, handler, dispatcher, context);
 }
 public ResourceMapListener(HandlerProc handler, CoreDispatcher dispatcher, ResourceContext context = null) :
     this(null, handler, dispatcher, context)
 {
 }