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

com.factset.sdk.OpenRisk.models.GroupsLabels Maven / Gradle / Ivy

There is a newer version: 5.0.2
Show newest version
/*
 * Open:Risk API
 * Service to calculate parametric linear risk statistics and generate risk model asset identifier mappings.
 *
 * The version of the OpenAPI document: 1.26.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.OpenRisk.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.io.Serializable;
import com.fasterxml.jackson.annotation.JsonPropertyOrder;
import com.factset.sdk.OpenRisk.JSON;


/**
 * Tree of input group name and calculated data results index for relevant group calculation-level
 */
@ApiModel(description = "Tree of input group name and calculated data results index for relevant group calculation-level")
@JsonPropertyOrder({
  GroupsLabels.JSON_PROPERTY_INDEX,
  GroupsLabels.JSON_PROPERTY_NAME,
  GroupsLabels.JSON_PROPERTY_GROUPS
})
@jakarta.annotation.Generated(value = "org.openapitools.codegen.languages.JavaClientCodegen")

public class GroupsLabels implements Serializable {
  private static final long serialVersionUID = 1L;

  public static final String JSON_PROPERTY_INDEX = "index";
  private Integer index;

  public static final String JSON_PROPERTY_NAME = "name";
  private String name;

  public static final String JSON_PROPERTY_GROUPS = "groups";
  private java.util.List groups = null;

  public GroupsLabels() { 
  }

  public GroupsLabels index(Integer index) {
    this.index = index;
    return this;
  }

   /**
   * 0-based index into the results array dimension for the corresponding calculation-levels
   * minimum: 0
   * @return index
  **/
  @jakarta.annotation.Nullable
  @ApiModelProperty(value = "0-based index into the results array dimension for the corresponding calculation-levels")
  @JsonProperty(JSON_PROPERTY_INDEX)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public Integer getIndex() {
    return index;
  }


  @JsonProperty(JSON_PROPERTY_INDEX)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setIndex(Integer index) {
    this.index = index;
  }


  public GroupsLabels name(String name) {
    this.name = name;
    return this;
  }

   /**
   * Name that was provided for this group
   * @return name
  **/
  @jakarta.annotation.Nullable
  @ApiModelProperty(value = "Name that was provided for this group")
  @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 GroupsLabels groups(java.util.List groups) {
    this.groups = groups;
    return this;
  }

  public GroupsLabels addGroupsItem(GroupsLabels groupsItem) {
    if (this.groups == null) {
      this.groups = new java.util.ArrayList<>();
    }
    this.groups.add(groupsItem);
    return this;
  }

   /**
   * Recursively defined elements; base case array (i.e., lowest group) contains objects with 'name' and 'index' only and not 'groups'
   * @return groups
  **/
  @jakarta.annotation.Nullable
  @ApiModelProperty(value = "Recursively defined elements; base case array (i.e., lowest group) contains objects with 'name' and 'index' only and not 'groups'")
  @JsonProperty(JSON_PROPERTY_GROUPS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)

  public java.util.List getGroups() {
    return groups;
  }


  @JsonProperty(JSON_PROPERTY_GROUPS)
  @JsonInclude(value = JsonInclude.Include.USE_DEFAULTS)
  public void setGroups(java.util.List groups) {
    this.groups = groups;
  }


  /**
   * Return true if this GroupsLabels object is equal to o.
   */
  @Override
  public boolean equals(Object o) {
    if (this == o) {
      return true;
    }
    if (o == null || getClass() != o.getClass()) {
      return false;
    }
    GroupsLabels groupsLabels = (GroupsLabels) o;
    return Objects.equals(this.index, groupsLabels.index) &&
        Objects.equals(this.name, groupsLabels.name) &&
        Objects.equals(this.groups, groupsLabels.groups);
  }

  @Override
  public int hashCode() {
    return Objects.hash(index, name, groups);
  }

  @Override
  public String toString() {
    StringBuilder sb = new StringBuilder();
    sb.append("class GroupsLabels {\n");
    sb.append("    index: ").append(toIndentedString(index)).append("\n");
    sb.append("    name: ").append(toIndentedString(name)).append("\n");
    sb.append("    groups: ").append(toIndentedString(groups)).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