/*
* Zernio API
*
* API reference for Zernio. Authenticate with a Bearer API key. Base URL: https://zernio.com/api Versioning and deprecation: all endpoints are versioned in the URL path (current version: /v1). Breaking changes only ship in a new path version; existing versions keep working. Deprecated operations are marked 'deprecated: true' in this spec and announced in the changelog (https://zernio.com/changelog) before removal. Errors: every 4xx/5xx response is application/json with a machine-readable 'code' and a human-readable 'error' message (see the ErrorResponse schema).
*
* The version of the OpenAPI document: 1.34.0
* Contact: support@zernio.com
* Generated by: https://openapi-generator.tech
*/
use crate::models;
use serde::{Deserialize, Serialize};
#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
pub struct FoodMenuItemAttributes {
#[serde(rename = "price", skip_serializing_if = "Option::is_none")]
pub price: Option<Box<models::Money>>,
/// Spiciness level (e.g. MILD, MEDIUM, HOT)
#[serde(rename = "spiciness", skip_serializing_if = "Option::is_none")]
pub spiciness: Option<Spiciness>,
/// Allergens (e.g. DAIRY, GLUTEN, SHELLFISH)
#[serde(rename = "allergen", skip_serializing_if = "Option::is_none")]
pub allergen: Option<Vec<String>>,
/// Dietary labels (e.g. VEGETARIAN, VEGAN, GLUTEN_FREE)
#[serde(rename = "dietaryRestriction", skip_serializing_if = "Option::is_none")]
pub dietary_restriction: Option<Vec<String>>,
/// Number of people the item serves
#[serde(rename = "servesNumPeople", skip_serializing_if = "Option::is_none")]
pub serves_num_people: Option<i32>,
/// Preparation methods (e.g. GRILLED, FRIED)
#[serde(rename = "preparationMethods", skip_serializing_if = "Option::is_none")]
pub preparation_methods: Option<Vec<String>>,
/// Media references for item photos
#[serde(rename = "mediaKeys", skip_serializing_if = "Option::is_none")]
pub media_keys: Option<Vec<String>>,
}
impl FoodMenuItemAttributes {
pub fn new() -> FoodMenuItemAttributes {
FoodMenuItemAttributes {
price: None,
spiciness: None,
allergen: None,
dietary_restriction: None,
serves_num_people: None,
preparation_methods: None,
media_keys: None,
}
}
}
/// Spiciness level (e.g. MILD, MEDIUM, HOT)
#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
pub enum Spiciness {
#[serde(rename = "SPICINESS_UNSPECIFIED")]
SpicinessUnspecified,
#[serde(rename = "MILD")]
Mild,
#[serde(rename = "MEDIUM")]
Medium,
#[serde(rename = "HOT")]
Hot,
}
impl Default for Spiciness {
fn default() -> Spiciness {
Self::SpicinessUnspecified
}
}