min_max_heap 2.1.0
min_max_heap: ^2.1.0 copied to clipboard
A Min-max binary heap data structure implementation. AKA double ended priority queue. Supports generics.
Changelog #
1.1.0 #
- Initial published version.
2.0.0 #
A great update is here! New getters and changes.
- Major changes:
- Constructor now doesn't have the input parameter. To build a heap from an iterable, use the factory constructor fromIterable.
- Prefer the new alias, like enqueue and dequeue.
printTreenow islogTreeand uses thelog.infomethod insteadprint.
- Another changes
- Removed the following properties, methods and getters:
listMode.operator [].
- New getters:
isEmpty.isNotEmpty._lastFather.dequeueMin.tryMin.tryDequeueMin.dequeueMax.tryMax.tryDequeueMax.asMapOfLevels.
- New methods:
sortedView.enqueue.enqueueAll.
- Changes:
- New factory constructor to build the heap from iterable.
iterable.listModenow isasList.- Now the
Criteriaenum doesn't used anymore. A bool approach is used instead. - Improving doc comments.
- Removed the following properties, methods and getters:
2.0.1 #
- Renaming methods, like
enqueue*anddequeue*toadd*and backing toremove*. - New method
updateWhere. This fix an issue at Github's repository. - Fixed
sortedmethod - Some docs improvements.
2.0.2 #
- Better test coverage.
- New functions
isValidMinMaxHeapListViewgetSubtreeOf
- New method
clear, makes the heap empty.
2.0.3 #
- Fixing a hint to try achieve 140 pub points
2.1.0 #
These update changes the signature of updateWhere method and release a replaceWhere method.
- The
updateWheremethod now isreplaceWhere.replaceWhere, as the name says, replace every element which predicate is satisfied.
- A new funtion
updateWhere.- This function have change the signature. Now you should pass a void function.
For more details, see min_max_heap_test.dart file.