Skip to main content

naurt_api/models/
feature_geometry.rs

1/*
2 * Naurt API
3 *
4 * OpenAPI specification for Naurt's APIs. 
5 *
6 * The version of the OpenAPI document: 0.1.2
7 * 
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Debug, PartialEq, Serialize, Deserialize)]
15#[serde(untagged)]
16pub enum FeatureGeometry {
17    Point(Box<models::Point>),
18    Multipoint(Box<models::Multipoint>),
19    Polygon(Box<models::Polygon>),
20}
21
22impl Default for FeatureGeometry {
23    fn default() -> Self {
24        Self::Point(Default::default())
25    }
26}
27/// 
28#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
29pub enum Type {
30    #[serde(rename = "Point")]
31    Point,
32    #[serde(rename = "MultiPoint")]
33    MultiPoint,
34    #[serde(rename = "Polygon")]
35    Polygon,
36}
37
38impl Default for Type {
39    fn default() -> Type {
40        Self::Point
41    }
42}
43