All notable changes to this project will be documented in this file.
The format is based on Keep a Changelog and this project adheres to Semantic Versioning.
- Optimize hash container.
- Abstracting out the hash container.
- Fixed tree get height function return one larger than the real height.
- Tree-shaking not work in ES module.
Queue
and Deque
should return undefined
when container is empty.
[4.1.4-beta.0] - 2022.08.31
- Add function update key by iterator.
- Add iterator copy function to get a copy of itself.
- Add insert by iterator hint function in tree container.
- Changed OrderedMap's iterator pointer get from
Object.defineProperty'
to Proxy
.
- Improve iterator performance by remove some judgment.
- Change iterator type description from
normal
and reverse
to boolean.
[4.1.2-beta.0] - 2022.08.27
- Make
SequentialContainer
and TreeBaseContainer
export in the index.
- Change rbTree binary search from recursive to loop implementation (don't effect using).
- Reduce memory waste during deque initialization.
- Fixed priority queue not dereference on pop.
- Forgot to reset root node on rotation in red-black tree delete operation.
- Fix iterator invalidation after tree container removes iterator.
- Change some functions from recursive to loop implementation (don't effect using).
- Change some iterator function parameter type.
- Change commonjs target to
es6
.
- Change
Deque
from sequential queue to circular queue.
- Optimize so many places (don't affect using).
- Change
if (this.empty())
to if (!this.length)
.
- Change some unit test.
- Change class type and optimized type design
- Fix can push undefined to deque.
- Remove InternalError error as much as possible (don't affect using).
- Change
HashSet
api eraseElementByValue
's name to eraseElementByKey
.
- Change some unit tests to improve coverage (don't affect using).
[4.0.0-beta.0] - 2022-07-24
- Complete test examples (don't effect using).
- The error thrown is standardized, you can catch it according to the error type.
- Refactor all container from function to class (don't affect using).
- Abstracting tree containers and hash containers, change
Set
's and Map
's name to OrderedSet
and OrderedMap
to distinguish it from the official container.
- Change
OrderedSet
api eraseElementByValue
's name to eraseElementByKey
.
[3.0.0-beta.0] - 2022-04-29
- Bidirectional iterator is provided for all containers except Stack, Queue, HashSet and HashMap.
- Added begin, end, rBegin and rEnd functions to some containers for using iterator.
- Added
eraseElementByIterator
function.
- Changed Pair type
T, K
to K, V
(don't affect using).
- Changed
find
, lowerBound
, upperBound
, reverseLowerBound
and reverseUpperBound
function's returned value to Iterator
.
- Fixed an error when the insert value was 0.
- Fixed the problem that the lower version browser does not recognize symbol Compilation error caused by iterator.