mirror of
https://github.com/duke-git/lancet.git
synced 2025-10-21 22:49:28 +08:00
refactor: rename Insert to InsertNode
This commit is contained in:
@@ -22,7 +22,7 @@ func NewBSTree[T any](rootData T) *BSTree[T] {
|
||||
}
|
||||
|
||||
// Insert data into BSTree
|
||||
func (t *BSTree[T]) Insert(data T, comparator lancetconstraints.Comparator) {
|
||||
func (t *BSTree[T]) InsertNode(data T, comparator lancetconstraints.Comparator) {
|
||||
root := t.root
|
||||
newNode := datastructure.NewTreeNode(data)
|
||||
if root == nil {
|
||||
|
Reference in New Issue
Block a user