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

com.amazonaws.services.quicksight.model.ComparativeOrder Maven / Gradle / Ivy

/*
 * Copyright 2019-2024 Amazon.com, Inc. or its affiliates. All Rights Reserved.
 * 
 * Licensed under the Apache License, Version 2.0 (the "License"). You may not use this file except in compliance with
 * the License. A copy of the License is located at
 * 
 * http://aws.amazon.com/apache2.0
 * 
 * or in the "license" file accompanying this file. This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR
 * CONDITIONS OF ANY KIND, either express or implied. See the License for the specific language governing permissions
 * and limitations under the License.
 */
package com.amazonaws.services.quicksight.model;

import java.io.Serializable;
import javax.annotation.Generated;
import com.amazonaws.protocol.StructuredPojo;
import com.amazonaws.protocol.ProtocolMarshaller;

/**
 * 

* A structure that represents a comparative order. *

* * @see AWS API * Documentation */ @Generated("com.amazonaws:aws-java-sdk-code-generator") public class ComparativeOrder implements Serializable, Cloneable, StructuredPojo { /** *

* The ordering type for a column. Valid values for this structure are GREATER_IS_BETTER, * LESSER_IS_BETTER and SPECIFIED. *

*/ private String useOrdering; /** *

* The list of columns to be used in the ordering. *

*/ private java.util.List specifedOrder; /** *

* The treat of undefined specified values. Valid values for this structure are LEAST and * MOST. *

*/ private String treatUndefinedSpecifiedValues; /** *

* The ordering type for a column. Valid values for this structure are GREATER_IS_BETTER, * LESSER_IS_BETTER and SPECIFIED. *

* * @param useOrdering * The ordering type for a column. Valid values for this structure are GREATER_IS_BETTER, * LESSER_IS_BETTER and SPECIFIED. * @see ColumnOrderingType */ public void setUseOrdering(String useOrdering) { this.useOrdering = useOrdering; } /** *

* The ordering type for a column. Valid values for this structure are GREATER_IS_BETTER, * LESSER_IS_BETTER and SPECIFIED. *

* * @return The ordering type for a column. Valid values for this structure are GREATER_IS_BETTER, * LESSER_IS_BETTER and SPECIFIED. * @see ColumnOrderingType */ public String getUseOrdering() { return this.useOrdering; } /** *

* The ordering type for a column. Valid values for this structure are GREATER_IS_BETTER, * LESSER_IS_BETTER and SPECIFIED. *

* * @param useOrdering * The ordering type for a column. Valid values for this structure are GREATER_IS_BETTER, * LESSER_IS_BETTER and SPECIFIED. * @return Returns a reference to this object so that method calls can be chained together. * @see ColumnOrderingType */ public ComparativeOrder withUseOrdering(String useOrdering) { setUseOrdering(useOrdering); return this; } /** *

* The ordering type for a column. Valid values for this structure are GREATER_IS_BETTER, * LESSER_IS_BETTER and SPECIFIED. *

* * @param useOrdering * The ordering type for a column. Valid values for this structure are GREATER_IS_BETTER, * LESSER_IS_BETTER and SPECIFIED. * @return Returns a reference to this object so that method calls can be chained together. * @see ColumnOrderingType */ public ComparativeOrder withUseOrdering(ColumnOrderingType useOrdering) { this.useOrdering = useOrdering.toString(); return this; } /** *

* The list of columns to be used in the ordering. *

* * @return The list of columns to be used in the ordering. */ public java.util.List getSpecifedOrder() { return specifedOrder; } /** *

* The list of columns to be used in the ordering. *

* * @param specifedOrder * The list of columns to be used in the ordering. */ public void setSpecifedOrder(java.util.Collection specifedOrder) { if (specifedOrder == null) { this.specifedOrder = null; return; } this.specifedOrder = new java.util.ArrayList(specifedOrder); } /** *

* The list of columns to be used in the ordering. *

*

* NOTE: This method appends the values to the existing list (if any). Use * {@link #setSpecifedOrder(java.util.Collection)} or {@link #withSpecifedOrder(java.util.Collection)} if you want * to override the existing values. *

* * @param specifedOrder * The list of columns to be used in the ordering. * @return Returns a reference to this object so that method calls can be chained together. */ public ComparativeOrder withSpecifedOrder(String... specifedOrder) { if (this.specifedOrder == null) { setSpecifedOrder(new java.util.ArrayList(specifedOrder.length)); } for (String ele : specifedOrder) { this.specifedOrder.add(ele); } return this; } /** *

* The list of columns to be used in the ordering. *

* * @param specifedOrder * The list of columns to be used in the ordering. * @return Returns a reference to this object so that method calls can be chained together. */ public ComparativeOrder withSpecifedOrder(java.util.Collection specifedOrder) { setSpecifedOrder(specifedOrder); return this; } /** *

* The treat of undefined specified values. Valid values for this structure are LEAST and * MOST. *

* * @param treatUndefinedSpecifiedValues * The treat of undefined specified values. Valid values for this structure are LEAST and * MOST. * @see UndefinedSpecifiedValueType */ public void setTreatUndefinedSpecifiedValues(String treatUndefinedSpecifiedValues) { this.treatUndefinedSpecifiedValues = treatUndefinedSpecifiedValues; } /** *

* The treat of undefined specified values. Valid values for this structure are LEAST and * MOST. *

* * @return The treat of undefined specified values. Valid values for this structure are LEAST and * MOST. * @see UndefinedSpecifiedValueType */ public String getTreatUndefinedSpecifiedValues() { return this.treatUndefinedSpecifiedValues; } /** *

* The treat of undefined specified values. Valid values for this structure are LEAST and * MOST. *

* * @param treatUndefinedSpecifiedValues * The treat of undefined specified values. Valid values for this structure are LEAST and * MOST. * @return Returns a reference to this object so that method calls can be chained together. * @see UndefinedSpecifiedValueType */ public ComparativeOrder withTreatUndefinedSpecifiedValues(String treatUndefinedSpecifiedValues) { setTreatUndefinedSpecifiedValues(treatUndefinedSpecifiedValues); return this; } /** *

* The treat of undefined specified values. Valid values for this structure are LEAST and * MOST. *

* * @param treatUndefinedSpecifiedValues * The treat of undefined specified values. Valid values for this structure are LEAST and * MOST. * @return Returns a reference to this object so that method calls can be chained together. * @see UndefinedSpecifiedValueType */ public ComparativeOrder withTreatUndefinedSpecifiedValues(UndefinedSpecifiedValueType treatUndefinedSpecifiedValues) { this.treatUndefinedSpecifiedValues = treatUndefinedSpecifiedValues.toString(); return this; } /** * Returns a string representation of this object. This is useful for testing and debugging. Sensitive data will be * redacted from this string using a placeholder value. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getUseOrdering() != null) sb.append("UseOrdering: ").append(getUseOrdering()).append(","); if (getSpecifedOrder() != null) sb.append("SpecifedOrder: ").append(getSpecifedOrder()).append(","); if (getTreatUndefinedSpecifiedValues() != null) sb.append("TreatUndefinedSpecifiedValues: ").append(getTreatUndefinedSpecifiedValues()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof ComparativeOrder == false) return false; ComparativeOrder other = (ComparativeOrder) obj; if (other.getUseOrdering() == null ^ this.getUseOrdering() == null) return false; if (other.getUseOrdering() != null && other.getUseOrdering().equals(this.getUseOrdering()) == false) return false; if (other.getSpecifedOrder() == null ^ this.getSpecifedOrder() == null) return false; if (other.getSpecifedOrder() != null && other.getSpecifedOrder().equals(this.getSpecifedOrder()) == false) return false; if (other.getTreatUndefinedSpecifiedValues() == null ^ this.getTreatUndefinedSpecifiedValues() == null) return false; if (other.getTreatUndefinedSpecifiedValues() != null && other.getTreatUndefinedSpecifiedValues().equals(this.getTreatUndefinedSpecifiedValues()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getUseOrdering() == null) ? 0 : getUseOrdering().hashCode()); hashCode = prime * hashCode + ((getSpecifedOrder() == null) ? 0 : getSpecifedOrder().hashCode()); hashCode = prime * hashCode + ((getTreatUndefinedSpecifiedValues() == null) ? 0 : getTreatUndefinedSpecifiedValues().hashCode()); return hashCode; } @Override public ComparativeOrder clone() { try { return (ComparativeOrder) super.clone(); } catch (CloneNotSupportedException e) { throw new IllegalStateException("Got a CloneNotSupportedException from Object.clone() " + "even though we're Cloneable!", e); } } @com.amazonaws.annotation.SdkInternalApi @Override public void marshall(ProtocolMarshaller protocolMarshaller) { com.amazonaws.services.quicksight.model.transform.ComparativeOrderMarshaller.getInstance().marshall(this, protocolMarshaller); } }




© 2015 - 2025 Weber Informatics LLC | Privacy Policy