pub struct NewFood {
pub name: String,
pub brand: Option<String>,
pub barcode: Option<String>,
pub calories_per_100g: f64,
pub protein_per_100g: Option<f64>,
pub carbs_per_100g: Option<f64>,
pub fat_per_100g: Option<f64>,
pub default_serving_g: Option<f64>,
pub source: String,
}Fields§
§name: String§brand: Option<String>§barcode: Option<String>§calories_per_100g: f64§protein_per_100g: Option<f64>§carbs_per_100g: Option<f64>§fat_per_100g: Option<f64>§default_serving_g: Option<f64>§source: StringTrait Implementations§
Auto Trait Implementations§
impl Freeze for NewFood
impl RefUnwindSafe for NewFood
impl Send for NewFood
impl Sync for NewFood
impl Unpin for NewFood
impl UnsafeUnpin for NewFood
impl UnwindSafe for NewFood
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more