NotificationCategorizer
Categorizes notifications
Constructor Summary
Public Constructor | ||
public |
Creates empty categorizer. |
Member Summary
Public Members | ||
public get |
The amount of days this covers |
|
public get |
The amount of unique items |
Method Summary
Public Methods | ||
public |
|
|
public |
addNotificationWithSiblings(category: Category, notification: Notification): Object Attempts to find a notification's siblings in a category |
|
public |
async feed(notificationIterator,: Generator<Notification>) Takes in a notification iterator. |
|
public |
feedOnce(notification: Notification) Feeds a single notification in |
|
public |
findCategory(categoryHeader: string): Object Finds a category by a name or returns a new category |
|
public |
headerForDate(date: Date): String Obtains header for a date. |
|
public |
registerNotificationMetadata(notification: Notification) Registers a notification as an instance |
Public Constructors
Public Members
Public Methods
public * [Symbol.iterator]() source
public addNotificationWithSiblings(category: Category, notification: Notification): Object source
Attempts to find a notification's siblings in a category
Params:
Name | Type | Attribute | Description |
category | Category | ||
notification | Notification |
public async feed(notificationIterator,: Generator<Notification>) source
Takes in a notification iterator. Assumes aync
Params:
Name | Type | Attribute | Description |
notificationIterator, | Generator<Notification> |
public feedOnce(notification: Notification) source
Feeds a single notification in
Params:
Name | Type | Attribute | Description |
notification | Notification |
public findCategory(categoryHeader: string): Object source
Finds a category by a name or returns a new category
Params:
Name | Type | Attribute | Description |
categoryHeader | string |
public headerForDate(date: Date): String source
Obtains header for a date. Same header = same categorization
Params:
Name | Type | Attribute | Description |
date | Date |
public registerNotificationMetadata(notification: Notification) source
Registers a notification as an instance
Params:
Name | Type | Attribute | Description |
notification | Notification |