pub fn search<Q: ?Sized, NodeRef: Deref<Target=Node<K, V>>>(node: NodeRef, key: &Q)
                  -> SearchResult<NodeRef> where K: Borrow<Q>, Q: Ord {
        // FIXME(Gankro): Tune when to search linear or binary based on B (and maybe K/V).
        // For the B configured as of this writing (B = 6), binary search was *significantly*
        // worse for usizes.
        match node.as_slices_internal().search_linear(key) {
            (index, true) => Found(Handle { node: node, index: index, marker: PhantomData }),
            (index, false) => GoDown(Handle { node: node, index: index, marker: PhantomData }),
        }
    }
/// Searches for the given key in the node. If it finds an exact match,
/// `Found` will be yielded with the matching index. If it doesn't find an exact match,
/// `GoDown` will be yielded with the index of the subtree the key must lie in.
Searches for the given key in the node. If it finds an exact match,
`Found` will be yielded with the matching index. If it doesn't find an exact match,
`GoDown` will be yielded with the index of the subtree the key must lie in.
Searches for the given key in the node . If it finds an exact match ` Found ` will be yielded with the matching index . If it doesn ' t find an exact match ` GoDown ` will be yielded with the index of the subtree the key must lie in .
pub fn search<Q: ?Sized, NodeRef: Deref<Target=Node<K, V>>>(node: NodeRef, key: &Q)
                  -> SearchResult<NodeRef> where K: Borrow<Q>, Q: Ord {
        // FIXME(Gankro): Tune when to search linear or binary based on B (and maybe K/V).
        // For the B configured as of this writing (B = 6), binary search was *significantly*
        // worse for usizes.
        match node.as_slices_internal().search_linear(key) {
            (index, true) => Found(Handle { node: node, index: index, marker: PhantomData }),
            (index, false) => GoDown(Handle { node: node, index: index, marker: PhantomData }),
        }
    }
pub fn search < Q : ? Sized , NodeRef : Deref < Target = Node < K , V > > > ( node : NodeRef , key : & Q ) -> SearchResult < NodeRef > where K : Borrow < Q > , Q : Ord { // FIXME(Gankro): Tune when to search linear or binary based on B (and maybe K/V). // For the B configured as of this writing (B = 6), binary search was *significantly* // worse for usizes. match node . as_slices_internal ( ) . search_linear ( key ) { ( index , true ) => Found ( Handle { node : node , index : index , marker : PhantomData } ) , ( index , false ) => GoDown ( Handle { node : node , index : index , marker : PhantomData } ) , } }
Searches for the given key in the node.
Searches for the given key in the node .
node
NodeRef
key
&Q