Struct oramfs::TreeNode[][src]

pub struct TreeNode {
    pub height: usize,
    pub leaves_count: i64,
    // some fields omitted
}
Expand description

Node of a binary tree.

This binary tree implementation has limited functionality and is tailored specifically for the PathORAM use case.

Fields

height: usizeleaves_count: i64

Implementations

Create and return a binary tree of the given size

Invariants

n must be equal to (2^k)-1 for any k >= 0 In other words, n must be a power of two, minus one.

Return true if this node is a leaf

Return the values of the leaves in the tree

Return the nodes on the path from the root to the node with value x

Return the path from the root to the xth leaf (0-based). Path from leaf to root is called P(x) in Path ORAM

Get the node at level l from the path from root to xth leaf (0-based) Also called P(x, l) in Path ORAM level=0 => root level=L => leaves

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Performs the conversion.

Should always be Self

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.