webhook_line/models/image_set.rs
1/*
2 * Webhook Type Definition
3 *
4 * Webhook event definition of the LINE Messaging API
5 *
6 * The version of the OpenAPI document: 1.0.0
7 *
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 ImageSet {
16 /// Image set ID. Only included when multiple images are sent simultaneously.
17 #[serde(rename = "id")]
18 pub id: String,
19 /// An index starting from 1, indicating the image number in a set of images sent simultaneously. Only included when multiple images are sent simultaneously. However, it won't be included if the sender is using LINE 11.15 or earlier for Android.
20 #[serde(rename = "index", skip_serializing_if = "Option::is_none")]
21 pub index: Option<i32>,
22 /// The total number of images sent simultaneously.
23 #[serde(rename = "total", skip_serializing_if = "Option::is_none")]
24 pub total: Option<i32>,
25}
26
27impl ImageSet {
28 pub fn new(id: String) -> ImageSet {
29 ImageSet {
30 id,
31 index: None,
32 total: None,
33 }
34 }
35}
36