Struct libradicl::BarcodeLookupMap[][src]

pub struct BarcodeLookupMap {
    pub barcodes: Vec<u64>,
    // some fields omitted
}

Fields

barcodes: Vec<u64>

Implementations

The find function searches for the barcode query in the BarcodeLookupMap. It returns a tuple (Option<usize>, usize) where the first element is either Some(usize) or None. If Some(usize) is returned, this is the index of a matching/neighboring barcode if None is returned, then no match was found. The second element is either 0, 1 or 2. If 0, no match was found; if 1 a unique match was found, if 2 then 2 or more equally good matches were found.

The parameter try_exact controls whether a an exact search is performed or not. If this parameter is true, an exact search is performed before a neighbor search. Otherwise, the exact search is skipped.

Trait Implementations

Formats the value using the given formatter. Read more

Deserialize this value from the given Serde deserializer. Read more

Serialize this value into the given Serde serializer. Read more

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.

The alignment of pointer.

The type for initializers.

Initializes a with the given initializer. Read more

Dereferences the given pointer. Read more

Mutably dereferences the given pointer. Read more

Drops the object pointed to by the given pointer. Read more

The inverse inclusion map: attempts to construct self from the equivalent element of its superset. Read more

Checks if self is actually part of its subset T (and can be converted to it).

Use with care! Same as self.to_subset but without any property checks. Always succeeds.

The inclusion map: converts self to the equivalent element of its superset.

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.