/* * Copyright 2018-2023 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; /** *

* The refresh schedule of a dataset. *

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

* An identifier for the refresh schedule. *

*/ private String scheduleId; /** *

* The frequency for the refresh schedule. *

*/ private RefreshFrequency scheduleFrequency; /** *

* Time after which the refresh schedule can be started, expressed in YYYY-MM-DDTHH:MM:SS format. *

*/ private java.util.Date startAfterDateTime; /** *

* The type of refresh that a datset undergoes. Valid values are as follows: *

* *

* For more information on full and incremental refreshes, see Refreshing SPICE data * in the Amazon QuickSight User Guide. *

*/ private String refreshType; /** *

* The Amazon Resource Name (ARN) for the refresh schedule. *

*/ private String arn; /** *

* An identifier for the refresh schedule. *

* * @param scheduleId * An identifier for the refresh schedule. */ public void setScheduleId(String scheduleId) { this.scheduleId = scheduleId; } /** *

* An identifier for the refresh schedule. *

* * @return An identifier for the refresh schedule. */ public String getScheduleId() { return this.scheduleId; } /** *

* An identifier for the refresh schedule. *

* * @param scheduleId * An identifier for the refresh schedule. * @return Returns a reference to this object so that method calls can be chained together. */ public RefreshSchedule withScheduleId(String scheduleId) { setScheduleId(scheduleId); return this; } /** *

* The frequency for the refresh schedule. *

* * @param scheduleFrequency * The frequency for the refresh schedule. */ public void setScheduleFrequency(RefreshFrequency scheduleFrequency) { this.scheduleFrequency = scheduleFrequency; } /** *

* The frequency for the refresh schedule. *

* * @return The frequency for the refresh schedule. */ public RefreshFrequency getScheduleFrequency() { return this.scheduleFrequency; } /** *

* The frequency for the refresh schedule. *

* * @param scheduleFrequency * The frequency for the refresh schedule. * @return Returns a reference to this object so that method calls can be chained together. */ public RefreshSchedule withScheduleFrequency(RefreshFrequency scheduleFrequency) { setScheduleFrequency(scheduleFrequency); return this; } /** *

* Time after which the refresh schedule can be started, expressed in YYYY-MM-DDTHH:MM:SS format. *

* * @param startAfterDateTime * Time after which the refresh schedule can be started, expressed in YYYY-MM-DDTHH:MM:SS * format. */ public void setStartAfterDateTime(java.util.Date startAfterDateTime) { this.startAfterDateTime = startAfterDateTime; } /** *

* Time after which the refresh schedule can be started, expressed in YYYY-MM-DDTHH:MM:SS format. *

* * @return Time after which the refresh schedule can be started, expressed in YYYY-MM-DDTHH:MM:SS * format. */ public java.util.Date getStartAfterDateTime() { return this.startAfterDateTime; } /** *

* Time after which the refresh schedule can be started, expressed in YYYY-MM-DDTHH:MM:SS format. *

* * @param startAfterDateTime * Time after which the refresh schedule can be started, expressed in YYYY-MM-DDTHH:MM:SS * format. * @return Returns a reference to this object so that method calls can be chained together. */ public RefreshSchedule withStartAfterDateTime(java.util.Date startAfterDateTime) { setStartAfterDateTime(startAfterDateTime); return this; } /** *

* The type of refresh that a datset undergoes. Valid values are as follows: *

* *

* For more information on full and incremental refreshes, see Refreshing SPICE data * in the Amazon QuickSight User Guide. *

* * @param refreshType * The type of refresh that a datset undergoes. Valid values are as follows:

* *

* For more information on full and incremental refreshes, see Refreshing SPICE * data in the Amazon QuickSight User Guide. * @see IngestionType */ public void setRefreshType(String refreshType) { this.refreshType = refreshType; } /** *

* The type of refresh that a datset undergoes. Valid values are as follows: *

* *

* For more information on full and incremental refreshes, see Refreshing SPICE data * in the Amazon QuickSight User Guide. *

* * @return The type of refresh that a datset undergoes. Valid values are as follows:

* *

* For more information on full and incremental refreshes, see Refreshing SPICE * data in the Amazon QuickSight User Guide. * @see IngestionType */ public String getRefreshType() { return this.refreshType; } /** *

* The type of refresh that a datset undergoes. Valid values are as follows: *

* *

* For more information on full and incremental refreshes, see Refreshing SPICE data * in the Amazon QuickSight User Guide. *

* * @param refreshType * The type of refresh that a datset undergoes. Valid values are as follows:

* *

* For more information on full and incremental refreshes, see Refreshing SPICE * data in the Amazon QuickSight User Guide. * @return Returns a reference to this object so that method calls can be chained together. * @see IngestionType */ public RefreshSchedule withRefreshType(String refreshType) { setRefreshType(refreshType); return this; } /** *

* The type of refresh that a datset undergoes. Valid values are as follows: *

* *

* For more information on full and incremental refreshes, see Refreshing SPICE data * in the Amazon QuickSight User Guide. *

* * @param refreshType * The type of refresh that a datset undergoes. Valid values are as follows:

* *

* For more information on full and incremental refreshes, see Refreshing SPICE * data in the Amazon QuickSight User Guide. * @return Returns a reference to this object so that method calls can be chained together. * @see IngestionType */ public RefreshSchedule withRefreshType(IngestionType refreshType) { this.refreshType = refreshType.toString(); return this; } /** *

* The Amazon Resource Name (ARN) for the refresh schedule. *

* * @param arn * The Amazon Resource Name (ARN) for the refresh schedule. */ public void setArn(String arn) { this.arn = arn; } /** *

* The Amazon Resource Name (ARN) for the refresh schedule. *

* * @return The Amazon Resource Name (ARN) for the refresh schedule. */ public String getArn() { return this.arn; } /** *

* The Amazon Resource Name (ARN) for the refresh schedule. *

* * @param arn * The Amazon Resource Name (ARN) for the refresh schedule. * @return Returns a reference to this object so that method calls can be chained together. */ public RefreshSchedule withArn(String arn) { setArn(arn); 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 (getScheduleId() != null) sb.append("ScheduleId: ").append(getScheduleId()).append(","); if (getScheduleFrequency() != null) sb.append("ScheduleFrequency: ").append(getScheduleFrequency()).append(","); if (getStartAfterDateTime() != null) sb.append("StartAfterDateTime: ").append(getStartAfterDateTime()).append(","); if (getRefreshType() != null) sb.append("RefreshType: ").append(getRefreshType()).append(","); if (getArn() != null) sb.append("Arn: ").append(getArn()); sb.append("}"); return sb.toString(); } @Override public boolean equals(Object obj) { if (this == obj) return true; if (obj == null) return false; if (obj instanceof RefreshSchedule == false) return false; RefreshSchedule other = (RefreshSchedule) obj; if (other.getScheduleId() == null ^ this.getScheduleId() == null) return false; if (other.getScheduleId() != null && other.getScheduleId().equals(this.getScheduleId()) == false) return false; if (other.getScheduleFrequency() == null ^ this.getScheduleFrequency() == null) return false; if (other.getScheduleFrequency() != null && other.getScheduleFrequency().equals(this.getScheduleFrequency()) == false) return false; if (other.getStartAfterDateTime() == null ^ this.getStartAfterDateTime() == null) return false; if (other.getStartAfterDateTime() != null && other.getStartAfterDateTime().equals(this.getStartAfterDateTime()) == false) return false; if (other.getRefreshType() == null ^ this.getRefreshType() == null) return false; if (other.getRefreshType() != null && other.getRefreshType().equals(this.getRefreshType()) == false) return false; if (other.getArn() == null ^ this.getArn() == null) return false; if (other.getArn() != null && other.getArn().equals(this.getArn()) == false) return false; return true; } @Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getScheduleId() == null) ? 0 : getScheduleId().hashCode()); hashCode = prime * hashCode + ((getScheduleFrequency() == null) ? 0 : getScheduleFrequency().hashCode()); hashCode = prime * hashCode + ((getStartAfterDateTime() == null) ? 0 : getStartAfterDateTime().hashCode()); hashCode = prime * hashCode + ((getRefreshType() == null) ? 0 : getRefreshType().hashCode()); hashCode = prime * hashCode + ((getArn() == null) ? 0 : getArn().hashCode()); return hashCode; } @Override public RefreshSchedule clone() { try { return (RefreshSchedule) 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.RefreshScheduleMarshaller.getInstance().marshall(this, protocolMarshaller); } }