figma_api/models/easing_easing_function_spring.rs
1/*
2 * Figma API
3 *
4 * This is the OpenAPI specification for the [Figma REST API](https://www.figma.com/developers/api). Note: we are releasing the OpenAPI specification as a beta given the large surface area and complexity of the REST API. If you notice any inaccuracies with the specification, please [file an issue](https://github.com/figma/rest-api-spec/issues).
5 *
6 * The version of the OpenAPI document: 0.31.0
7 * Contact: support@figma.com
8 * Generated by: https://openapi-generator.tech
9 */
10
11use crate::models;
12use serde::{Deserialize, Serialize};
13
14/// EasingEasingFunctionSpring : A spring function that defines the easing.
15#[derive(Clone, Default, Debug, PartialEq, Serialize, Deserialize)]
16pub struct EasingEasingFunctionSpring {
17 #[serde(rename = "mass")]
18 pub mass: f64,
19 #[serde(rename = "stiffness")]
20 pub stiffness: f64,
21 #[serde(rename = "damping")]
22 pub damping: f64,
23}
24
25impl EasingEasingFunctionSpring {
26 /// A spring function that defines the easing.
27 pub fn new(mass: f64, stiffness: f64, damping: f64) -> EasingEasingFunctionSpring {
28 EasingEasingFunctionSpring {
29 mass,
30 stiffness,
31 damping,
32 }
33 }
34}
35