File tree Expand file tree Collapse file tree 3 files changed +6
-4
lines changed
Expand file tree Collapse file tree 3 files changed +6
-4
lines changed Original file line number Diff line number Diff line change 11# @algo-js/priority-queue
22
3- Fast heap-based priority queue for production
3+ Fastest heap-based production-ready priority queue fully written on TypeScript
Original file line number Diff line number Diff line change 11{
22 "name" : " @algo-js/priority-queue" ,
33 "version" : " 1.0.2" ,
4- "description" : " Fast heap-based priority queue for production " ,
4+ "description" : " Fastest heap-based production-ready priority queue fully written on TypeScript " ,
55 "main" : " build/main/index.js" ,
66 "typings" : " build/main/index.d.ts" ,
77 "module" : " build/module/index.js" ,
8- "repository" : " https://github.com/IPRIT/ algo-js/priority-queue" ,
8+ "repository" : " https://github.com/algo-js/priority-queue" ,
99 "license" : " MIT" ,
1010 "keywords" : [],
1111 "scripts" : {
Original file line number Diff line number Diff line change @@ -65,7 +65,7 @@ export class PriorityQueue<T> extends MaxHeapTree<T> implements Queue<T> {
6565 /**
6666 * @returns {* }
6767 */
68- public dequeue ( ) : T {
68+ public dequeue ( ) : T | undefined {
6969 const element = super . poll ( ) ;
7070
7171 if ( element ) {
@@ -77,13 +77,15 @@ export class PriorityQueue<T> extends MaxHeapTree<T> implements Queue<T> {
7777
7878 /**
7979 * @private
80+ * @deprecated
8081 */
8182 public add ( element : T ) : this {
8283 throw new Error ( 'Use `queue` method instead' ) ;
8384 }
8485
8586 /**
8687 * @private
88+ * @deprecated
8789 */
8890 public poll ( ) : T {
8991 throw new Error ( 'Use `dequeue` method instead' ) ;
You can’t perform that action at this time.
0 commit comments