pub struct PublicWorkout {
pub activity: String,
pub calories: Option<f64>,
pub day: IsoDate,
pub distance: Option<f64>,
pub end_datetime: LocalizedDateTime,
pub id: X,
pub intensity: PublicWorkoutIntensity,
pub label: Option<String>,
pub source: PublicWorkoutSource,
pub start_datetime: LocalizedDateTime,
}Expand description
Public model for Workout.
JSON schema
{
"title": "PublicWorkout",
"description": "Public model for Workout.",
"type": "object",
"required": [
"activity",
"day",
"end_datetime",
"id",
"intensity",
"source",
"start_datetime"
],
"properties": {
"activity": {
"title": "",
"description": "Type of the workout activity.",
"type": "string"
},
"calories": {
"title": "",
"description": "Energy burned in kilocalories during the workout.",
"type": [
"number",
"null"
]
},
"day": {
"$ref": "#/components/schemas/ISODate"
},
"distance": {
"title": "",
"description": "Distance traveled in meters during the workout.",
"type": [
"number",
"null"
]
},
"end_datetime": {
"$ref": "#/components/schemas/LocalizedDateTime"
},
"id": {
"title": "",
"description": "Unique identifier of the object.",
"type": "string",
"minLength": 1
},
"intensity": {
"$ref": "#/components/schemas/PublicWorkoutIntensity"
},
"label": {
"title": "",
"description": "User-defined label for the workout.",
"type": [
"string",
"null"
]
},
"source": {
"$ref": "#/components/schemas/PublicWorkoutSource"
},
"start_datetime": {
"$ref": "#/components/schemas/LocalizedDateTime"
}
},
"x-cloud-only": true,
"x-collection": "publicworkout",
"x-owner": "movement-squad"
}Fields§
§activity: StringType of the workout activity.
calories: Option<f64>Energy burned in kilocalories during the workout.
day: IsoDate§distance: Option<f64>Distance traveled in meters during the workout.
end_datetime: LocalizedDateTime§id: XUnique identifier of the object.
intensity: PublicWorkoutIntensity§label: Option<String>User-defined label for the workout.
source: PublicWorkoutSource§start_datetime: LocalizedDateTimeTrait Implementations§
Source§impl Clone for PublicWorkout
impl Clone for PublicWorkout
Source§impl Debug for PublicWorkout
impl Debug for PublicWorkout
Source§impl<'de> Deserialize<'de> for PublicWorkout
impl<'de> Deserialize<'de> for PublicWorkout
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Auto Trait Implementations§
impl Freeze for PublicWorkout
impl RefUnwindSafe for PublicWorkout
impl Send for PublicWorkout
impl Sync for PublicWorkout
impl Unpin for PublicWorkout
impl UnsafeUnpin for PublicWorkout
impl UnwindSafe for PublicWorkout
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more