export interface Observer { /** * Creates observer of event. * @param {Function[]} subscribers - callback of subscribers. */ new(subscribers: Array<(message: T) => void>); /** * Adds method of subscriber for notification. * @param {Function} callback - the method of notification, this method can be declared, when observer was notified. */ subscribe (callback: (message: T) => void); /** * Removes method of subscriber. * @param {Function} callback - the method of notification. */ unsubscribe (callback: (message: T) => void); }