# upsertSubNode

suspend fun < K , V > SortedMapLikeBinaryTreeNode < K , V >. upsertSubNode (key: K , value: V ): SortedMapLikeBinaryTreeNode < K , V >(source)

Will add subnode in tree if there are no any node with key

- If key is greater than SortedMapLikeBinaryTreeNode.key of currently checking node, will be used SortedMapLikeBinaryTreeNode.rightNode

- If key is equal to SortedMapLikeBinaryTreeNode.key of currently checking node - will be returned currently checking node

- If key is less than SortedMapLikeBinaryTreeNode.key of currently checking node - will be used SortedMapLikeBinaryTreeNode.leftNode

This process will continue until function will not find place to put SortedMapLikeBinaryTreeNode with data or SortedMapLikeBinaryTreeNode with SortedMapLikeBinaryTreeNode.key same as key will be found