geoengine_api_client/models/
layer_listing.rs1use crate::models;
12use serde::{Deserialize, Serialize};
13
14#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
15pub struct LayerListing {
16 #[serde(rename = "description")]
17 pub description: String,
18 #[serde(rename = "id")]
19 pub id: Box<models::ProviderLayerId>,
20 #[serde(rename = "name")]
21 pub name: String,
22 #[serde(rename = "properties", skip_serializing_if = "Option::is_none")]
24 pub properties: Option<Vec<Vec<String>>>,
25 #[serde(rename = "type")]
26 pub r#type: Type,
27}
28
29impl LayerListing {
30 pub fn new(description: String, id: models::ProviderLayerId, name: String, r#type: Type) -> LayerListing {
31 LayerListing {
32 description,
33 id: Box::new(id),
34 name,
35 properties: None,
36 r#type,
37 }
38 }
39}
40#[derive(Clone, Copy, Debug, Eq, PartialEq, Ord, PartialOrd, Hash, Serialize, Deserialize)]
42pub enum Type {
43 #[serde(rename = "layer")]
44 Layer,
45}
46
47impl Default for Type {
48 fn default() -> Type {
49 Self::Layer
50 }
51}
52