if (getEnabled() != null) sb.append("Enabled: ").append(getEnabled()).append(","); if (getDescription() != null) sb.append("Description: ").append(getDescription()).append(","); if (getKeyUsage() != null) sb.append("KeyUsage: ").append(getKeyUsage()).append(",");
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAWSAccountId() == null) ? 0 : getAWSAccountId().hashCode()); hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getArn() == null) ? 0 : getArn().hashCode()); hashCode = prime * hashCode + ((getCreationDate() == null) ? 0 : getCreationDate().hashCode()); hashCode = prime * hashCode + ((getEnabled() == null) ? 0 : getEnabled().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getKeyUsage() == null) ? 0 : getKeyUsage().hashCode()); hashCode = prime * hashCode + ((getKeyState() == null) ? 0 : getKeyState().hashCode()); hashCode = prime * hashCode + ((getDeletionDate() == null) ? 0 : getDeletionDate().hashCode()); hashCode = prime * hashCode + ((getValidTo() == null) ? 0 : getValidTo().hashCode()); hashCode = prime * hashCode + ((getOrigin() == null) ? 0 : getOrigin().hashCode()); hashCode = prime * hashCode + ((getCustomKeyStoreId() == null) ? 0 : getCustomKeyStoreId().hashCode()); hashCode = prime * hashCode + ((getCloudHsmClusterId() == null) ? 0 : getCloudHsmClusterId().hashCode()); hashCode = prime * hashCode + ((getExpirationModel() == null) ? 0 : getExpirationModel().hashCode()); hashCode = prime * hashCode + ((getKeyManager() == null) ? 0 : getKeyManager().hashCode()); return hashCode; }
if (other.getEnabled() != null && other.getEnabled().equals(this.getEnabled()) == false) return false; if (other.getDescription() == null ^ this.getDescription() == null) return false; if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == false) return false; if (other.getKeyUsage() == null ^ this.getKeyUsage() == null)
/** * Marshall the given parameter object. */ public void marshall(KeyMetadata keyMetadata, ProtocolMarshaller protocolMarshaller) { if (keyMetadata == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(keyMetadata.getAWSAccountId(), AWSACCOUNTID_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyId(), KEYID_BINDING); protocolMarshaller.marshall(keyMetadata.getArn(), ARN_BINDING); protocolMarshaller.marshall(keyMetadata.getCreationDate(), CREATIONDATE_BINDING); protocolMarshaller.marshall(keyMetadata.getEnabled(), ENABLED_BINDING); protocolMarshaller.marshall(keyMetadata.getDescription(), DESCRIPTION_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyUsage(), KEYUSAGE_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyState(), KEYSTATE_BINDING); protocolMarshaller.marshall(keyMetadata.getDeletionDate(), DELETIONDATE_BINDING); protocolMarshaller.marshall(keyMetadata.getValidTo(), VALIDTO_BINDING); protocolMarshaller.marshall(keyMetadata.getOrigin(), ORIGIN_BINDING); protocolMarshaller.marshall(keyMetadata.getCustomKeyStoreId(), CUSTOMKEYSTOREID_BINDING); protocolMarshaller.marshall(keyMetadata.getCloudHsmClusterId(), CLOUDHSMCLUSTERID_BINDING); protocolMarshaller.marshall(keyMetadata.getExpirationModel(), EXPIRATIONMODEL_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyManager(), KEYMANAGER_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAWSAccountId() == null) ? 0 : getAWSAccountId().hashCode()); hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getArn() == null) ? 0 : getArn().hashCode()); hashCode = prime * hashCode + ((getCreationDate() == null) ? 0 : getCreationDate().hashCode()); hashCode = prime * hashCode + ((getEnabled() == null) ? 0 : getEnabled().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getKeyUsage() == null) ? 0 : getKeyUsage().hashCode()); hashCode = prime * hashCode + ((getKeyState() == null) ? 0 : getKeyState().hashCode()); hashCode = prime * hashCode + ((getDeletionDate() == null) ? 0 : getDeletionDate().hashCode()); hashCode = prime * hashCode + ((getValidTo() == null) ? 0 : getValidTo().hashCode()); hashCode = prime * hashCode + ((getOrigin() == null) ? 0 : getOrigin().hashCode()); hashCode = prime * hashCode + ((getCustomKeyStoreId() == null) ? 0 : getCustomKeyStoreId().hashCode()); hashCode = prime * hashCode + ((getCloudHsmClusterId() == null) ? 0 : getCloudHsmClusterId().hashCode()); hashCode = prime * hashCode + ((getExpirationModel() == null) ? 0 : getExpirationModel().hashCode()); hashCode = prime * hashCode + ((getKeyManager() == null) ? 0 : getKeyManager().hashCode()); return hashCode; }
if (getEnabled() != null) sb.append("Enabled: " + getEnabled() + ","); if (getDescription() != null) sb.append("Description: " + getDescription() + ","); if (getKeyUsage() != null) sb.append("KeyUsage: " + getKeyUsage() + ",");
if (other.getEnabled() != null && other.getEnabled().equals(this.getEnabled()) == false) return false; if (other.getDescription() == null ^ this.getDescription() == null) return false; if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == false) return false; if (other.getKeyUsage() == null ^ this.getKeyUsage() == null)
if (getEnabled() != null) sb.append("Enabled: ").append(getEnabled()).append(","); if (getDescription() != null) sb.append("Description: ").append(getDescription()).append(","); if (getKeyUsage() != null) sb.append("KeyUsage: ").append(getKeyUsage()).append(",");
if (getEnabled() != null) sb.append("Enabled: ").append(getEnabled()).append(","); if (getDescription() != null) sb.append("Description: ").append(getDescription()).append(","); if (getKeyUsage() != null) sb.append("KeyUsage: ").append(getKeyUsage()).append(",");
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAWSAccountId() == null) ? 0 : getAWSAccountId().hashCode()); hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getArn() == null) ? 0 : getArn().hashCode()); hashCode = prime * hashCode + ((getCreationDate() == null) ? 0 : getCreationDate().hashCode()); hashCode = prime * hashCode + ((getEnabled() == null) ? 0 : getEnabled().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getKeyUsage() == null) ? 0 : getKeyUsage().hashCode()); hashCode = prime * hashCode + ((getKeyState() == null) ? 0 : getKeyState().hashCode()); hashCode = prime * hashCode + ((getDeletionDate() == null) ? 0 : getDeletionDate().hashCode()); hashCode = prime * hashCode + ((getValidTo() == null) ? 0 : getValidTo().hashCode()); hashCode = prime * hashCode + ((getOrigin() == null) ? 0 : getOrigin().hashCode()); hashCode = prime * hashCode + ((getExpirationModel() == null) ? 0 : getExpirationModel().hashCode()); hashCode = prime * hashCode + ((getKeyManager() == null) ? 0 : getKeyManager().hashCode()); return hashCode; }
jsonWriter.value(enabled); if (keyMetadata.getDescription() != null) { String description = keyMetadata.getDescription(); jsonWriter.name("Description"); jsonWriter.value(description);
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAWSAccountId() == null) ? 0 : getAWSAccountId().hashCode()); hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getArn() == null) ? 0 : getArn().hashCode()); hashCode = prime * hashCode + ((getCreationDate() == null) ? 0 : getCreationDate().hashCode()); hashCode = prime * hashCode + ((getEnabled() == null) ? 0 : getEnabled().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getKeyUsage() == null) ? 0 : getKeyUsage().hashCode()); hashCode = prime * hashCode + ((getKeyState() == null) ? 0 : getKeyState().hashCode()); hashCode = prime * hashCode + ((getDeletionDate() == null) ? 0 : getDeletionDate().hashCode()); hashCode = prime * hashCode + ((getValidTo() == null) ? 0 : getValidTo().hashCode()); hashCode = prime * hashCode + ((getOrigin() == null) ? 0 : getOrigin().hashCode()); hashCode = prime * hashCode + ((getExpirationModel() == null) ? 0 : getExpirationModel().hashCode()); return hashCode; }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAWSAccountId() == null) ? 0 : getAWSAccountId().hashCode()); hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getArn() == null) ? 0 : getArn().hashCode()); hashCode = prime * hashCode + ((getCreationDate() == null) ? 0 : getCreationDate().hashCode()); hashCode = prime * hashCode + ((getEnabled() == null) ? 0 : getEnabled().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getKeyUsage() == null) ? 0 : getKeyUsage().hashCode()); hashCode = prime * hashCode + ((getKeyState() == null) ? 0 : getKeyState().hashCode()); hashCode = prime * hashCode + ((getDeletionDate() == null) ? 0 : getDeletionDate().hashCode()); hashCode = prime * hashCode + ((getValidTo() == null) ? 0 : getValidTo().hashCode()); hashCode = prime * hashCode + ((getOrigin() == null) ? 0 : getOrigin().hashCode()); hashCode = prime * hashCode + ((getCustomKeyStoreId() == null) ? 0 : getCustomKeyStoreId().hashCode()); hashCode = prime * hashCode + ((getCloudHsmClusterId() == null) ? 0 : getCloudHsmClusterId().hashCode()); hashCode = prime * hashCode + ((getExpirationModel() == null) ? 0 : getExpirationModel().hashCode()); hashCode = prime * hashCode + ((getKeyManager() == null) ? 0 : getKeyManager().hashCode()); return hashCode; }
if (getEnabled() != null) sb.append("Enabled: " + getEnabled() + ","); if (getDescription() != null) sb.append("Description: " + getDescription() + ","); if (getKeyUsage() != null) sb.append("KeyUsage: " + getKeyUsage() + ",");
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getAWSAccountId() == null) ? 0 : getAWSAccountId().hashCode()); hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getArn() == null) ? 0 : getArn().hashCode()); hashCode = prime * hashCode + ((getCreationDate() == null) ? 0 : getCreationDate().hashCode()); hashCode = prime * hashCode + ((getEnabled() == null) ? 0 : getEnabled().hashCode()); hashCode = prime * hashCode + ((getDescription() == null) ? 0 : getDescription().hashCode()); hashCode = prime * hashCode + ((getKeyUsage() == null) ? 0 : getKeyUsage().hashCode()); hashCode = prime * hashCode + ((getKeyState() == null) ? 0 : getKeyState().hashCode()); hashCode = prime * hashCode + ((getDeletionDate() == null) ? 0 : getDeletionDate().hashCode()); hashCode = prime * hashCode + ((getValidTo() == null) ? 0 : getValidTo().hashCode()); hashCode = prime * hashCode + ((getOrigin() == null) ? 0 : getOrigin().hashCode()); hashCode = prime * hashCode + ((getCustomKeyStoreId() == null) ? 0 : getCustomKeyStoreId().hashCode()); hashCode = prime * hashCode + ((getCloudHsmClusterId() == null) ? 0 : getCloudHsmClusterId().hashCode()); hashCode = prime * hashCode + ((getExpirationModel() == null) ? 0 : getExpirationModel().hashCode()); hashCode = prime * hashCode + ((getKeyManager() == null) ? 0 : getKeyManager().hashCode()); return hashCode; }
if (getEnabled() != null) sb.append("Enabled: " + getEnabled() + ","); if (getDescription() != null) sb.append("Description: " + getDescription() + ","); if (getKeyUsage() != null) sb.append("KeyUsage: " + getKeyUsage() + ",");
if (other.getEnabled() != null && other.getEnabled().equals(this.getEnabled()) == false) return false; if (other.getDescription() == null ^ this.getDescription() == null) return false; if (other.getDescription() != null && other.getDescription().equals(this.getDescription()) == false) return false; if (other.getKeyUsage() == null ^ this.getKeyUsage() == null)
/** * Marshall the given parameter object. */ public void marshall(KeyMetadata keyMetadata, ProtocolMarshaller protocolMarshaller) { if (keyMetadata == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(keyMetadata.getAWSAccountId(), AWSACCOUNTID_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyId(), KEYID_BINDING); protocolMarshaller.marshall(keyMetadata.getArn(), ARN_BINDING); protocolMarshaller.marshall(keyMetadata.getCreationDate(), CREATIONDATE_BINDING); protocolMarshaller.marshall(keyMetadata.getEnabled(), ENABLED_BINDING); protocolMarshaller.marshall(keyMetadata.getDescription(), DESCRIPTION_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyUsage(), KEYUSAGE_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyState(), KEYSTATE_BINDING); protocolMarshaller.marshall(keyMetadata.getDeletionDate(), DELETIONDATE_BINDING); protocolMarshaller.marshall(keyMetadata.getValidTo(), VALIDTO_BINDING); protocolMarshaller.marshall(keyMetadata.getOrigin(), ORIGIN_BINDING); protocolMarshaller.marshall(keyMetadata.getExpirationModel(), EXPIRATIONMODEL_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyManager(), KEYMANAGER_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }
/** * Marshall the given parameter object. */ public void marshall(KeyMetadata keyMetadata, ProtocolMarshaller protocolMarshaller) { if (keyMetadata == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(keyMetadata.getAWSAccountId(), AWSACCOUNTID_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyId(), KEYID_BINDING); protocolMarshaller.marshall(keyMetadata.getArn(), ARN_BINDING); protocolMarshaller.marshall(keyMetadata.getCreationDate(), CREATIONDATE_BINDING); protocolMarshaller.marshall(keyMetadata.getEnabled(), ENABLED_BINDING); protocolMarshaller.marshall(keyMetadata.getDescription(), DESCRIPTION_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyUsage(), KEYUSAGE_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyState(), KEYSTATE_BINDING); protocolMarshaller.marshall(keyMetadata.getDeletionDate(), DELETIONDATE_BINDING); protocolMarshaller.marshall(keyMetadata.getValidTo(), VALIDTO_BINDING); protocolMarshaller.marshall(keyMetadata.getOrigin(), ORIGIN_BINDING); protocolMarshaller.marshall(keyMetadata.getCustomKeyStoreId(), CUSTOMKEYSTOREID_BINDING); protocolMarshaller.marshall(keyMetadata.getCloudHsmClusterId(), CLOUDHSMCLUSTERID_BINDING); protocolMarshaller.marshall(keyMetadata.getExpirationModel(), EXPIRATIONMODEL_BINDING); protocolMarshaller.marshall(keyMetadata.getKeyManager(), KEYMANAGER_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }
jsonWriter.value(enabled); if (keyMetadata.getDescription() != null) { String description = keyMetadata.getDescription(); jsonWriter.name("Description"); jsonWriter.value(description);