Skip to main content
Deno 2 is finally here 🎉️
Learn more
class NotifierController
import { NotifierController } from "https://deno.land/x/sptaki@1.2.0/controllers/mod.ts";

Constructors

new
NotifierController(
notifierHelper: NotifierHelper,
httpServerHelper: HttpServerHelper,
notificationService: NotificationService,
)

Properties

protected
httpServerHelper: HttpServerHelper
protected
notificationService: NotificationService
protected
notifierHelper: NotifierHelper
protected
pollInterval: number
protected
timeout: number

Methods

getChannel(sessionID: string): INotifierChannel

Handle client/notifier/channel/create

getServer(sessionID: string): string
notifyAsync(sessionID: string): Promise<unknown>

Resolve an array of session notifications.

If no notifications are currently queued then intermittently check for new notifications until either one or more appear or when a timeout expires. If no notifications are available after the timeout, use a default message.