(skiplist-insert! skiplist key)
(skiplist-insert! skiplist key value)
This procedure inserts a key/value pair into the skip list. The following key types are valid and accepted:
The optional value parameter may be either an exact positive number or arbitrary data passed as a string.
If a node with the supplied key is already present in the skip list, the data is updated.
The skip list is modified.
unspecified (ok)
> (pp skiplist-insert!)
(lambda (s k . v)
(if (null? v)
(internal-skiplist-insert! s k 0)
(internal-skiplist-insert! s k (car s))))
ok
>
> (define s (skiplist-create))
s
> (skiplist-insert! s "String")
ok
> (skiplist-insert! s "String2" "**DATA**")
ok
> (skiplist-insert! s '00:00:00:00:00:00 11)
ok
> (skiplist-insert! s '00:00:00:00:00:01 "**DATA**")
ok
> (skiplist-insert! s '00:00:00:00:00:00-00:00:00:00:00:FF 12)
ok
> (skiplist-insert! s '01:00:00:00:00:00-01:00:00:00:00:FF "**DATA**")
ok
> (skiplist-insert! s '10.0.0.1 13)
ok
> (skiplist-insert! s 'fe80::66ff:c472:29c6:e9e3 "**DATA**")
ok
> (skiplist-insert! s '10.0.0.3-10.0.0.6)
ok
> (skiplist-insert! s 'fe80::66ff:c472:29c6:e9e3-fe80::66ff:c472:29c6:ffff "**DATA**")
ok
>