![JAR search and dependency download from the Maven repository](/logo.png)
io.github.jfermat.strava.model.Body1 Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of strava-api-client-resttemplate Show documentation
Show all versions of strava-api-client-resttemplate Show documentation
Strava's API client with RestTemplate's library.
/*
* Strava API v3
* The [Swagger Playground](https://developers.strava.com/playground) is the easiest way to familiarize yourself with the Strava API by submitting HTTP requests and observing the responses before you write any client code. It will show what a response will look like with different endpoints depending on the authorization scope you receive from your athletes. To use the Playground, go to https://www.strava.com/settings/api and change your “Authorization Callback Domain” to developers.strava.com. Please note, we only support Swagger 2.0. There is a known issue where you can only select one scope at a time. For more information, please check the section “client code” at https://developers.strava.com/docs.
*
* OpenAPI spec version: 3.0.0
*
*
* NOTE: This class is auto generated by the swagger code generator program.
* https://github.com/swagger-api/swagger-codegen.git
* Do not edit the class manually.
*/
package io.github.jfermat.strava.model;
import java.util.Objects;
import java.util.Arrays;
import com.fasterxml.jackson.annotation.JsonProperty;
import com.fasterxml.jackson.annotation.JsonCreator;
import com.fasterxml.jackson.annotation.JsonValue;
import io.swagger.v3.oas.annotations.media.Schema;
import org.threeten.bp.OffsetDateTime;
/**
* Body1
*/
@javax.annotation.Generated(value = "io.swagger.codegen.v3.generators.java.JavaClientCodegen", date = "2021-01-10T09:15:14.081+01:00[Europe/Paris]")
public class Body1 {
@JsonProperty("name")
private String name = null;
@JsonProperty("type")
private String type = null;
@JsonProperty("start_date_local")
private OffsetDateTime startDateLocal = null;
@JsonProperty("elapsed_time")
private Integer elapsedTime = null;
@JsonProperty("description")
private String description = null;
@JsonProperty("distance")
private Float distance = null;
@JsonProperty("trainer")
private Integer trainer = null;
@JsonProperty("commute")
private Integer commute = null;
public Body1 name(String name) {
this.name = name;
return this;
}
/**
* The name of the activity.
* @return name
**/
@Schema(required = true, description = "The name of the activity.")
public String getName() {
return name;
}
public void setName(String name) {
this.name = name;
}
public Body1 type(String type) {
this.type = type;
return this;
}
/**
* Type of activity. For example - Run, Ride etc.
* @return type
**/
@Schema(required = true, description = "Type of activity. For example - Run, Ride etc.")
public String getType() {
return type;
}
public void setType(String type) {
this.type = type;
}
public Body1 startDateLocal(OffsetDateTime startDateLocal) {
this.startDateLocal = startDateLocal;
return this;
}
/**
* ISO 8601 formatted date time.
* @return startDateLocal
**/
@Schema(required = true, description = "ISO 8601 formatted date time.")
public OffsetDateTime getStartDateLocal() {
return startDateLocal;
}
public void setStartDateLocal(OffsetDateTime startDateLocal) {
this.startDateLocal = startDateLocal;
}
public Body1 elapsedTime(Integer elapsedTime) {
this.elapsedTime = elapsedTime;
return this;
}
/**
* In seconds.
* @return elapsedTime
**/
@Schema(required = true, description = "In seconds.")
public Integer getElapsedTime() {
return elapsedTime;
}
public void setElapsedTime(Integer elapsedTime) {
this.elapsedTime = elapsedTime;
}
public Body1 description(String description) {
this.description = description;
return this;
}
/**
* Description of the activity.
* @return description
**/
@Schema(description = "Description of the activity.")
public String getDescription() {
return description;
}
public void setDescription(String description) {
this.description = description;
}
public Body1 distance(Float distance) {
this.distance = distance;
return this;
}
/**
* In meters.
* @return distance
**/
@Schema(description = "In meters.")
public Float getDistance() {
return distance;
}
public void setDistance(Float distance) {
this.distance = distance;
}
public Body1 trainer(Integer trainer) {
this.trainer = trainer;
return this;
}
/**
* Set to 1 to mark as a trainer activity.
* @return trainer
**/
@Schema(description = "Set to 1 to mark as a trainer activity.")
public Integer getTrainer() {
return trainer;
}
public void setTrainer(Integer trainer) {
this.trainer = trainer;
}
public Body1 commute(Integer commute) {
this.commute = commute;
return this;
}
/**
* Set to 1 to mark as commute.
* @return commute
**/
@Schema(description = "Set to 1 to mark as commute.")
public Integer getCommute() {
return commute;
}
public void setCommute(Integer commute) {
this.commute = commute;
}
@Override
public boolean equals(java.lang.Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
Body1 body1 = (Body1) o;
return Objects.equals(this.name, body1.name) &&
Objects.equals(this.type, body1.type) &&
Objects.equals(this.startDateLocal, body1.startDateLocal) &&
Objects.equals(this.elapsedTime, body1.elapsedTime) &&
Objects.equals(this.description, body1.description) &&
Objects.equals(this.distance, body1.distance) &&
Objects.equals(this.trainer, body1.trainer) &&
Objects.equals(this.commute, body1.commute);
}
@Override
public int hashCode() {
return Objects.hash(name, type, startDateLocal, elapsedTime, description, distance, trainer, commute);
}
@Override
public String toString() {
StringBuilder sb = new StringBuilder();
sb.append("class Body1 {\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
sb.append(" type: ").append(toIndentedString(type)).append("\n");
sb.append(" startDateLocal: ").append(toIndentedString(startDateLocal)).append("\n");
sb.append(" elapsedTime: ").append(toIndentedString(elapsedTime)).append("\n");
sb.append(" description: ").append(toIndentedString(description)).append("\n");
sb.append(" distance: ").append(toIndentedString(distance)).append("\n");
sb.append(" trainer: ").append(toIndentedString(trainer)).append("\n");
sb.append(" commute: ").append(toIndentedString(commute)).append("\n");
sb.append("}");
return sb.toString();
}
/**
* Convert the given object to string with each line indented by 4 spaces
* (except the first line).
*/
private String toIndentedString(java.lang.Object o) {
if (o == null) {
return "null";
}
return o.toString().replace("\n", "\n ");
}
}
© 2015 - 2025 Weber Informatics LLC | Privacy Policy