osdm_sys/models/
coach_layout_place.rs

1/*
2 * UIC 90918-10 - OSDM
3 *
4 * Specifications for the OSDM API standard. The OSDM specification supports two modes of operation: Retailer Mode and Distributor Mode. The API works identically in both modes, except that in distributor mode the API also returns fare information.  The following resources are key to get started:    -  [Processes](https://osdm.io/spec/processes/)   -  [Models](https://osdm.io/spec/models/)   -  [Getting started](https://osdm.io/spec/getting-started/) 
5 *
6 * The version of the OpenAPI document: 3.7.0
7 * Contact: osdm@uic.org
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct CoachLayoutPlace {
16    /// Values from the [Graphics Items Code List](https://osdm.io/spec/catalog-of-code-lists/#GraphicsItems) 
17    #[serde(rename = "icon")]
18    pub icon: String,
19    /// place number as displayed physically on the place 
20    #[serde(rename = "number")]
21    pub number: String,
22    #[serde(rename = "direction", skip_serializing_if = "Option::is_none")]
23    pub direction: Option<models::DirectionType>,
24    /// Remark concerning the place (e.g. to be used in a tool tip). Code list according to UIC90918-1 Known Values: - MIGHT_HAVE_TABLE: place might have a table - MIGHT_NOT_HAVE_TABLE: table at the place might be missing - MIGHT_HAVE_DIFFERENT_DIRECTION: place might have a different direction - MIGHT_HAVE_TABLE_AND_DIFFERENT_DIRECTION: place might have a table and a different direction - MIGHT_NOT_HAVE_TABLE_AND_MIGHT_HAVE_DIFFERENT_DIRECTION: table at the place might be missing and place might have a different direction - MIGHT_BE_IN_COMPARTMENT: place might be in compartment - MIGHT_BE_IN_OPEN_SPACE: place might be in open space 
25    #[serde(rename = "remarkId", skip_serializing_if = "Option::is_none")]
26    pub remark_id: Option<String>,
27    #[serde(rename = "coords")]
28    pub coords: Box<models::LayoutCoordinates>,
29}
30
31impl CoachLayoutPlace {
32    pub fn new(icon: String, number: String, coords: models::LayoutCoordinates) -> CoachLayoutPlace {
33        CoachLayoutPlace {
34            icon,
35            number,
36            direction: None,
37            remark_id: None,
38            coords: Box::new(coords),
39        }
40    }
41}
42