@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getDisableAutomatedBackup() == null) ? 0 : getDisableAutomatedBackup().hashCode()); hashCode = prime * hashCode + ((getBackupRetentionCount() == null) ? 0 : getBackupRetentionCount().hashCode()); hashCode = prime * hashCode + ((getServerName() == null) ? 0 : getServerName().hashCode()); hashCode = prime * hashCode + ((getPreferredMaintenanceWindow() == null) ? 0 : getPreferredMaintenanceWindow().hashCode()); hashCode = prime * hashCode + ((getPreferredBackupWindow() == null) ? 0 : getPreferredBackupWindow().hashCode()); return hashCode; }
/** * <p> * Sets the number of automated backups that you want to keep. * </p> * * @param backupRetentionCount * Sets the number of automated backups that you want to keep. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateServerRequest withBackupRetentionCount(Integer backupRetentionCount) { setBackupRetentionCount(backupRetentionCount); return this; }
/** * <p> * Setting DisableAutomatedBackup to <code>true</code> disables automated or scheduled backups. Automated backups * are enabled by default. * </p> * * @param disableAutomatedBackup * Setting DisableAutomatedBackup to <code>true</code> disables automated or scheduled backups. Automated * backups are enabled by default. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateServerRequest withDisableAutomatedBackup(Boolean disableAutomatedBackup) { setDisableAutomatedBackup(disableAutomatedBackup); return this; }
/** * @param preferredMaintenanceWindow * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateServerRequest withPreferredMaintenanceWindow(String preferredMaintenanceWindow) { setPreferredMaintenanceWindow(preferredMaintenanceWindow); return this; }
/** * @param preferredBackupWindow * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateServerRequest withPreferredBackupWindow(String preferredBackupWindow) { setPreferredBackupWindow(preferredBackupWindow); return this; }
/** * <p> * The name of the server to update. * </p> * * @param serverName * The name of the server to update. * @return Returns a reference to this object so that method calls can be chained together. */ public UpdateServerRequest withServerName(String serverName) { setServerName(serverName); return this; }
return false; UpdateServerRequest other = (UpdateServerRequest) obj; if (other.getDisableAutomatedBackup() == null ^ this.getDisableAutomatedBackup() == null) return false; if (other.getDisableAutomatedBackup() != null && other.getDisableAutomatedBackup().equals(this.getDisableAutomatedBackup()) == false) return false; if (other.getBackupRetentionCount() == null ^ this.getBackupRetentionCount() == null) return false; if (other.getBackupRetentionCount() != null && other.getBackupRetentionCount().equals(this.getBackupRetentionCount()) == false) return false; if (other.getServerName() == null ^ this.getServerName() == null) return false; if (other.getServerName() != null && other.getServerName().equals(this.getServerName()) == false) return false; if (other.getPreferredMaintenanceWindow() == null ^ this.getPreferredMaintenanceWindow() == null) return false; if (other.getPreferredMaintenanceWindow() != null && other.getPreferredMaintenanceWindow().equals(this.getPreferredMaintenanceWindow()) == false) return false; if (other.getPreferredBackupWindow() == null ^ this.getPreferredBackupWindow() == null) return false; if (other.getPreferredBackupWindow() != null && other.getPreferredBackupWindow().equals(this.getPreferredBackupWindow()) == false) return false; return true;
/** * 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 (getDisableAutomatedBackup() != null) sb.append("DisableAutomatedBackup: ").append(getDisableAutomatedBackup()).append(","); if (getBackupRetentionCount() != null) sb.append("BackupRetentionCount: ").append(getBackupRetentionCount()).append(","); if (getServerName() != null) sb.append("ServerName: ").append(getServerName()).append(","); if (getPreferredMaintenanceWindow() != null) sb.append("PreferredMaintenanceWindow: ").append(getPreferredMaintenanceWindow()).append(","); if (getPreferredBackupWindow() != null) sb.append("PreferredBackupWindow: ").append(getPreferredBackupWindow()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(UpdateServerRequest updateServerRequest, ProtocolMarshaller protocolMarshaller) { if (updateServerRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(updateServerRequest.getDisableAutomatedBackup(), DISABLEAUTOMATEDBACKUP_BINDING); protocolMarshaller.marshall(updateServerRequest.getBackupRetentionCount(), BACKUPRETENTIONCOUNT_BINDING); protocolMarshaller.marshall(updateServerRequest.getServerName(), SERVERNAME_BINDING); protocolMarshaller.marshall(updateServerRequest.getPreferredMaintenanceWindow(), PREFERREDMAINTENANCEWINDOW_BINDING); protocolMarshaller.marshall(updateServerRequest.getPreferredBackupWindow(), PREFERREDBACKUPWINDOW_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }