com.factset.sdk.FactSetFunds.models.GroupHolding 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;
/**
* GroupHolding
*/
@JsonPropertyOrder({
GroupHolding.JSON_PROPERTY_FSYM_ID,
GroupHolding.JSON_PROPERTY_DATE,
GroupHolding.JSON_PROPERTY_NAME,
GroupHolding.JSON_PROPERTY_HOLDING_PERCENT,
GroupHolding.JSON_PROPERTY_REQUEST_ID
})
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")
public class GroupHolding implements Serializable {
private static final long serialVersionUID = 1L;
public static final String JSON_PROPERTY_FSYM_ID = "fsymId";
private String fsymId;
public static final String JSON_PROPERTY_DATE = "date";
private LocalDate date;
public static final String JSON_PROPERTY_NAME = "name";
private String name;
public static final String JSON_PROPERTY_HOLDING_PERCENT = "holdingPercent";
private JsonNullable holdingPercent = JsonNullable.undefined();
public static final String JSON_PROPERTY_REQUEST_ID = "requestId";
private String requestId;
public GroupHolding() {
}
public GroupHolding fsymId(String fsymId) {
this.fsymId = 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.")
@JsonProperty(JSON_PROPERTY_FSYM_ID)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getFsymId() {
return fsymId;
}
@JsonProperty(JSON_PROPERTY_FSYM_ID)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setFsymId(String fsymId) {
this.fsymId = fsymId;
}
public GroupHolding date(LocalDate date) {
this.date = date;
return this;
}
/**
* The date of the holdings percentages 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 holdings percentages in YYYY-MM-DD format.")
@JsonProperty(JSON_PROPERTY_DATE)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public LocalDate getDate() {
return date;
}
@JsonProperty(JSON_PROPERTY_DATE)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setDate(LocalDate date) {
this.date = date;
}
public GroupHolding name(String name) {
this.name = name;
return this;
}
/**
* The group name.
* @return name
**/
@jakarta.annotation.Nullable
@ApiModelProperty(example = "Cash/Repo/MM", value = "The group name.")
@JsonProperty(JSON_PROPERTY_NAME)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public String getName() {
return name;
}
@JsonProperty(JSON_PROPERTY_NAME)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public void setName(String name) {
this.name = name;
}
public GroupHolding holdingPercent(Double holdingPercent) {
this.holdingPercent = JsonNullable.of(holdingPercent);
return this;
}
/**
* Percentage held by the group.
* @return holdingPercent
**/
@jakarta.annotation.Nullable
@ApiModelProperty(example = "0.415299", value = "Percentage held by the group.")
@JsonIgnore
public Double getHoldingPercent() {
return holdingPercent.orElse(null);
}
@JsonProperty(JSON_PROPERTY_HOLDING_PERCENT)
@JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
public JsonNullable getHoldingPercent_JsonNullable() {
return holdingPercent;
}
@JsonProperty(JSON_PROPERTY_HOLDING_PERCENT)
public void setHoldingPercent_JsonNullable(JsonNullable holdingPercent) {
this.holdingPercent = holdingPercent;
}
public void setHoldingPercent(Double holdingPercent) {
this.holdingPercent = JsonNullable.of(holdingPercent);
}
public GroupHolding requestId(String requestId) {
this.requestId = requestId;
return this;
}
/**
* The requested Id sent as input.
* @return requestId
**/
@jakarta.annotation.Nullable
@ApiModelProperty(example = "SPAXX-US", 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;
}
/**
* Return true if this groupHolding object is equal to o.
*/
@Override
public boolean equals(Object o) {
if (this == o) {
return true;
}
if (o == null || getClass() != o.getClass()) {
return false;
}
GroupHolding groupHolding = (GroupHolding) o;
return Objects.equals(this.fsymId, groupHolding.fsymId) &&
Objects.equals(this.date, groupHolding.date) &&
Objects.equals(this.name, groupHolding.name) &&
equalsNullable(this.holdingPercent, groupHolding.holdingPercent) &&
Objects.equals(this.requestId, groupHolding.requestId);
}
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(fsymId, date, name, hashCodeNullable(holdingPercent), requestId);
}
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 GroupHolding {\n");
sb.append(" fsymId: ").append(toIndentedString(fsymId)).append("\n");
sb.append(" date: ").append(toIndentedString(date)).append("\n");
sb.append(" name: ").append(toIndentedString(name)).append("\n");
sb.append(" holdingPercent: ").append(toIndentedString(holdingPercent)).append("\n");
sb.append(" requestId: ").append(toIndentedString(requestId)).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 ");
}
}