@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; }
/** * 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(); }
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)
/** * 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); } }