com.factset.sdk.FactSetFunds.models.Prices Maven / Gradle / Ivy
Go to download
Show more of this group Show more artifacts with this name
Show all versions of factsetfunds Show documentation
Show all versions of factsetfunds Show documentation
FactSet SDK for Java - factsetfunds
/*
* FactSet Funds API
* FactSet Mutual Funds data offers over 50 fund- and share class-specific data points for mutual funds listed in the United States. FactSet Mutual Funds Reference provides fund-specific reference information as well as FactSet's proprietary classification system. It includes but is not limited to the following coverage * Fund descriptions * A seven-tier classification system * Leverage information * Fees and expenses * Portfolio managers FactSet Mutual Funds Time Series provides quantitative data items on a historical basis. It includes but is not limited to the following coverage * Net asset value * Fund flows * Assets under management * Total return
This API is rate-limited to 10 requests per second and 10 concurrent requests per user.
*
* The version of the OpenAPI document: 1.1.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.FactSetFunds.models;
import java.util.Objects;
import java.util.Arrays;
import java.util.Map;
import java.util.HashMap;
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.FactSetFunds.JSON;
/**
* Prices
*/
@JsonPropertyOrder({
Prices.JSON_PROPERTY_FSYM_ID,
Prices.JSON_PROPERTY_PRICE,
Prices.JSON_PROPERTY_DATE,
Prices.JSON_PROPERTY_REQUEST_ID,
Prices.JSON_PROPERTY_CURRENCY
})
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class Prices implements Serializable {
private static final long serialVersionUID = 1L;
public static final String JSON_PROPERTY_FSYM_ID = "fsymId";
private JsonNullable fsymId = JsonNullable.undefined();
public static final String JSON_PROPERTY_PRICE = "price";
private JsonNullable price = JsonNullable.undefined();
public static final String JSON_PROPERTY_DATE = "date";
private JsonNullable date = JsonNullable.undefined();
public static final String JSON_PROPERTY_REQUEST_ID = "requestId";
private String requestId;
public static final String JSON_PROPERTY_CURRENCY = "currency";
private JsonNullable currency = JsonNullable.undefined();
public Prices() {
}
public Prices fsymId(String fsymId) {
this.fsymId = JsonNullable.of(fsymId);
return this;
}
/**
* FactSet Security Identifier. Six alpha-numeric characters, excluding vowels, with a -S suffix (XXXXXX-S), resolved from the requestId of the Fund requested.
* @return fsymId
**/
@jakarta.annotation.Nullable
@ApiModelProperty(example = "FNK7XP-S", value = "FactSet Security Identifier. Six alpha-numeric characters, excluding vowels, with a -S suffix (XXXXXX-S), resolved from the requestId of the Fund requested.")
@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 Prices price(Double price) {
this.price = JsonNullable.of(price);
return this;
}
/**
* The NAV for the requested share class. NOTE - FactSet Mutual Funds does not use seven-day yields to price money market funds.
* @return price
**/
@jakarta.annotation.Nullable
@ApiModelProperty(example = "19.94", value = "The NAV for the requested share class. NOTE - FactSet Mutual Funds does not use seven-day yields to price money market funds.")
@JsonIgnore
public Double getPrice() {
return price.orElse(null);
}
@JsonProperty(JSON_PROPERTY_PRICE)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public JsonNullable getPrice_JsonNullable() {
return price;
}
@JsonProperty(JSON_PROPERTY_PRICE)
public void setPrice_JsonNullable(JsonNullable price) {
this.price = price;
}
public void setPrice(Double price) {
this.price = JsonNullable.of(price);
}
public Prices date(LocalDate date) {
this.date = JsonNullable.of(date);
return this;
}
/**
* The date of the NAV in YYYY-MM-DD format.
* @return date
**/
@jakarta.annotation.Nullable
@ApiModelProperty(example = "Fri Feb 26 00:00:00 UTC 2021", value = "The date of the NAV 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 Prices requestId(String requestId) {
this.requestId = requestId;
return this;
}
/**
* The requested Id sent as input.
* @return requestId
**/
@jakarta.annotation.Nullable
@ApiModelProperty(example = "MABAX", value = "The requested Id sent as input.")
@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 Prices currency(String currency) {
this.currency = JsonNullable.of(currency);
return this;
}
/**
* ISO3 Currency
* @return currency
**/
@jakarta.annotation.Nullable
@ApiModelProperty(example = "USD", value = "ISO3 Currency")
@JsonIgnore
public String getCurrency() {
return currency.orElse(null);
}
@JsonProperty(JSON_PROPERTY_CURRENCY)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public JsonNullable getCurrency_JsonNullable() {
return currency;
}
@JsonProperty(JSON_PROPERTY_CURRENCY)
public void setCurrency_JsonNullable(JsonNullable currency) {
this.currency = currency;
}
public void setCurrency(String currency) {
this.currency = JsonNullable.of(currency);
}
/**
* Return true if this prices object is equal to o.
*/
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
Prices prices = (Prices) o;
return equalsNullable(this.fsymId, prices.fsymId) &&
equalsNullable(this.price, prices.price) &&
equalsNullable(this.date, prices.date) &&
Objects.equals(this.requestId, prices.requestId) &&
equalsNullable(this.currency, prices.currency);
}
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(hashCodeNullable(fsymId), hashCodeNullable(price), hashCodeNullable(date), requestId, hashCodeNullable(currency));
}
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 Prices {\n");
sb.append(" fsymId: ").append(toIndentedString(fsymId)).append("\n");
sb.append(" price: ").append(toIndentedString(price)).append("\n");
sb.append(" date: ").append(toIndentedString(date)).append("\n");
sb.append(" requestId: ").append(toIndentedString(requestId)).append("\n");
sb.append(" currency: ").append(toIndentedString(currency)).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 ");
}
}