Struct sparse_bitfield::Bitfield[][src]

pub struct Bitfield {
    pub pages: Pager,
    // some fields omitted
}

Bitfield instance.

Fields

A memory-pager instance.

Methods

impl Bitfield
[src]

Create a new instance.

Panics

Panics if the page size is not a power of two (2, 4, 8, etc.)

Set a byte to true or false. Returns a boolean indicating if the value was changed.

Get the value of a bit.

Get a byte from our internal buffers.

Set a byte to the right value inside our internal buffers.

Get the memory page size in bytes.

Get the amount of bits in the bitfield.

Returns true if no bits are stored.

Important traits for Iter<'a>

Create an Iterator that iterates over all pages.

Trait Implementations

impl Debug for Bitfield
[src]

Formats the value using the given formatter. Read more

impl Default for Bitfield
[src]

Create a new instance with a page_size of 1kb.

Returns the "default value" for a type. Read more

Auto Trait Implementations

impl Send for Bitfield

impl Sync for Bitfield