Struct crushtool::Bucket
[−]
[src]
pub struct Bucket { pub id: i32, pub bucket_type: OpCode, pub alg: BucketAlg, pub hash: CrushHash, pub weight: u32, pub size: u32, pub items: Vec<(i32, Option<String>)>, pub perm_n: u32, pub perm: u32, }
Fields
id: i32
this'll be negative
bucket_type: OpCode
non-zero; type=0 is reserved for devices
alg: BucketAlg
Which algorithm to use
hash: CrushHash
which hash function to use
weight: u32
16-bit fixed point
size: u32
items: Vec<(i32, Option<String>)>
num items
perm_n: u32
perm: u32
num elements of *perm that are permuted/defined
Trait Implementations
impl Debug for Bucket
[src]
impl Clone for Bucket
[src]
fn clone(&self) -> Bucket
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0
Performs copy-assignment from source
. Read more
impl Eq for Bucket
[src]
impl Hash for Bucket
[src]
fn hash<__H: Hasher>(&self, __arg_0: &mut __H)
Feeds this value into the given [Hasher
]. Read more
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher,
1.3.0
H: Hasher,
Feeds a slice of this type into the given [Hasher
]. Read more
impl PartialEq for Bucket
[src]
fn eq(&self, __arg_0: &Bucket) -> bool
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Bucket) -> bool
This method tests for !=
.
impl Decodable for Bucket
[src]
fn decode<__D: Decoder>(__arg_0: &mut __D) -> Result<Bucket, __D::Error>
Deserialize a value using a Decoder
.