All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.factset.sdk.FactSetFundamentals.models.Segment Maven / Gradle / Ivy

There is a newer version: 3.1.1
Show newest version
/*
 * FactSet Fundamentals API
 * Gain access to current, comprehensive, and comparative information on securities in worldwide developed and emerging markets. Composed of annual and interim/quarterly data, detailed historical financial statement content, per-share data, and calculated ratios, FactSet Fundamentals provides you with the information you need for a global investment perspective.

This API is rate-limited to 10 requests per second and 10 concurrent requests per user.

* * The version of the OpenAPI document: 2.2.0 * Contact: [email protected] * * NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech). * https://openapi-generator.tech * Do not edit the class manually. */ package com.factset.sdk.FactSetFundamentals.models; import java.util.Objects; import java.util.Arrays; import java.util.Map; import java.util.HashMap; import com.factset.sdk.FactSetFundamentals.models.SegmentValue; import com.fasterxml.jackson.annotation.JsonInclude; import com.fasterxml.jackson.annotation.JsonProperty; import com.fasterxml.jackson.annotation.JsonCreator; import com.fasterxml.jackson.annotation.JsonTypeName; import com.fasterxml.jackson.annotation.JsonValue; import io.swagger.annotations.ApiModel; import io.swagger.annotations.ApiModelProperty; import java.time.LocalDate; import org.openapitools.jackson.nullable.JsonNullable; import com.fasterxml.jackson.annotation.JsonIgnore; import org.openapitools.jackson.nullable.JsonNullable; import java.util.NoSuchElementException; import java.io.Serializable; import com.fasterxml.jackson.annotation.JsonPropertyOrder; import com.factset.sdk.FactSetFundamentals.JSON; /** * Segment */ @JsonPropertyOrder({ Segment.JSON_PROPERTY_REQUEST_ID, Segment.JSON_PROPERTY_FSYM_ID, Segment.JSON_PROPERTY_METRIC, Segment.JSON_PROPERTY_LABEL, Segment.JSON_PROPERTY_DATE, Segment.JSON_PROPERTY_VALUE }) @jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen") public class Segment implements Serializable { private static final long serialVersionUID = 1L; public static final String JSON_PROPERTY_REQUEST_ID = "requestId"; private String requestId; public static final String JSON_PROPERTY_FSYM_ID = "fsymId"; private JsonNullable fsymId = JsonNullable.undefined(); public static final String JSON_PROPERTY_METRIC = "metric"; private JsonNullable metric = JsonNullable.undefined(); public static final String JSON_PROPERTY_LABEL = "label"; private String label; public static final String JSON_PROPERTY_DATE = "date"; private JsonNullable date = JsonNullable.undefined(); public static final String JSON_PROPERTY_VALUE = "value"; private JsonNullable value = JsonNullable.undefined(); public Segment() { } @JsonCreator public Segment( @JsonProperty(value=JSON_PROPERTY_LABEL, required=true) String label ) { this(); this.label = label; } public Segment requestId(String requestId) { this.requestId = requestId; return this; } /** * Identifier that was used for the request. * @return requestId **/ @jakarta.annotation.Nullable @ApiModelProperty(example = "AAPL-US", value = "Identifier that was used for the request.") @JsonProperty(JSON_PROPERTY_REQUEST_ID) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public String getRequestId() { return requestId; } @JsonProperty(JSON_PROPERTY_REQUEST_ID) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public void setRequestId(String requestId) { this.requestId = requestId; } public Segment fsymId(String fsymId) { this.fsymId = JsonNullable.of(fsymId); return this; } /** * FactSet Regional Security Identifier. Six alpha-numeric characters, excluding vowels, with an -R suffix (XXXXXX-R). Identifies the security's best regional security data series per currency. For equities, all primary listings per region and currency are allocated a regional-level permanent identifier. The regional-level permanent identifier will be available once a SEDOL representing the region/currency has been allocated and the identifiers are on FactSet. * @return fsymId **/ @jakarta.annotation.Nullable @ApiModelProperty(example = "MH33D6-R", value = "FactSet Regional Security Identifier. Six alpha-numeric characters, excluding vowels, with an -R suffix (XXXXXX-R). Identifies the security's best regional security data series per currency. For equities, all primary listings per region and currency are allocated a regional-level permanent identifier. The regional-level permanent identifier will be available once a SEDOL representing the region/currency has been allocated and the identifiers are on FactSet.") @JsonIgnore public String getFsymId() { return fsymId.orElse(null); } @JsonProperty(JSON_PROPERTY_FSYM_ID) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public JsonNullable getFsymId_JsonNullable() { return fsymId; } @JsonProperty(JSON_PROPERTY_FSYM_ID) public void setFsymId_JsonNullable(JsonNullable fsymId) { this.fsymId = fsymId; } public void setFsymId(String fsymId) { this.fsymId = JsonNullable.of(fsymId); } public Segment metric(String metric) { this.metric = JsonNullable.of(metric); return this; } /** * The requested `metric` input, representing the Fundamental Data Item. For a definition of the item please use the /fundamentals/v#/metrics endpoint. * @return metric **/ @jakarta.annotation.Nullable @ApiModelProperty(example = "SALES", value = "The requested `metric` input, representing the Fundamental Data Item. For a definition of the item please use the /fundamentals/v#/metrics endpoint.") @JsonIgnore public String getMetric() { return metric.orElse(null); } @JsonProperty(JSON_PROPERTY_METRIC) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public JsonNullable getMetric_JsonNullable() { return metric; } @JsonProperty(JSON_PROPERTY_METRIC) public void setMetric_JsonNullable(JsonNullable metric) { this.metric = metric; } public void setMetric(String metric) { this.metric = JsonNullable.of(metric); } public Segment label(String label) { this.label = label; return this; } /** * Report labels of the segment type requested. * @return label **/ @jakarta.annotation.Nullable @ApiModelProperty(example = "iPhone", required = true, value = "Report labels of the segment type requested.") @JsonProperty(JSON_PROPERTY_LABEL) @JsonInclude(value = JsonInclude.Include.ALWAYS) public String getLabel() { return label; } @JsonProperty(JSON_PROPERTY_LABEL) @JsonInclude(value = JsonInclude.Include.ALWAYS) public void setLabel(String label) { this.label = label; } public Segment date(LocalDate date) { this.date = JsonNullable.of(date); return this; } /** * Date for the period requested expressed in YYYY-MM-DD format * @return date **/ @jakarta.annotation.Nullable @ApiModelProperty(example = "Fri Sep 30 00:00:00 UTC 2022", value = "Date for the period requested expressed in YYYY-MM-DD format") @JsonIgnore public LocalDate getDate() { return date.orElse(null); } @JsonProperty(JSON_PROPERTY_DATE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public JsonNullable getDate_JsonNullable() { return date; } @JsonProperty(JSON_PROPERTY_DATE) public void setDate_JsonNullable(JsonNullable date) { this.date = date; } public void setDate(LocalDate date) { this.date = JsonNullable.of(date); } public Segment value(SegmentValue value) { this.value = JsonNullable.of(value); return this; } /** * Get value * @return value **/ @jakarta.annotation.Nullable @ApiModelProperty(value = "") @JsonIgnore public SegmentValue getValue() { return value.orElse(null); } @JsonProperty(JSON_PROPERTY_VALUE) @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS) public JsonNullable getValue_JsonNullable() { return value; } @JsonProperty(JSON_PROPERTY_VALUE) public void setValue_JsonNullable(JsonNullable value) { this.value = value; } public void setValue(SegmentValue value) { this.value = JsonNullable.of(value); } /** * Return true if this Segment object is equal to o. */ @Override public boolean equals(Object o) { if (this == o) { return true; } if (o == null || getClass() != o.getClass()) { return false; } Segment segment = (Segment) o; return Objects.equals(this.requestId, segment.requestId) && equalsNullable(this.fsymId, segment.fsymId) && equalsNullable(this.metric, segment.metric) && Objects.equals(this.label, segment.label) && equalsNullable(this.date, segment.date) && equalsNullable(this.value, segment.value); } private static boolean equalsNullable(JsonNullable a, JsonNullable b) { return a == b || (a != null && b != null && a.isPresent() && b.isPresent() && Objects.deepEquals(a.get(), b.get())); } @Override public int hashCode() { return Objects.hash(requestId, hashCodeNullable(fsymId), hashCodeNullable(metric), label, hashCodeNullable(date), hashCodeNullable(value)); } private static int hashCodeNullable(JsonNullable a) { if (a == null) { return 1; } return a.isPresent() ? Arrays.deepHashCode(new Object[]{a.get()}) : 31; } @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("class Segment {\n"); sb.append(" requestId: ").append(toIndentedString(requestId)).append("\n"); sb.append(" fsymId: ").append(toIndentedString(fsymId)).append("\n"); sb.append(" metric: ").append(toIndentedString(metric)).append("\n"); sb.append(" label: ").append(toIndentedString(label)).append("\n"); sb.append(" date: ").append(toIndentedString(date)).append("\n"); sb.append(" value: ").append(toIndentedString(value)).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(Object o) { if (o == null) { return "null"; } return o.toString().replace("\n", "\n "); } }




© 2015 - 2024 Weber Informatics LLC | Privacy Policy