@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getEncryptionContext() == null) ? 0 : getEncryptionContext().hashCode()); hashCode = prime * hashCode + ((getNumberOfBytes() == null) ? 0 : getNumberOfBytes().hashCode()); hashCode = prime * hashCode + ((getKeySpec() == null) ? 0 : getKeySpec().hashCode()); hashCode = prime * hashCode + ((getGrantTokens() == null) ? 0 : getGrantTokens().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 (getKeyId() != null) sb.append("KeyId: ").append(getKeyId()).append(","); if (getEncryptionContext() != null) sb.append("EncryptionContext: ").append(getEncryptionContext()).append(","); if (getNumberOfBytes() != null) sb.append("NumberOfBytes: ").append(getNumberOfBytes()).append(","); if (getKeySpec() != null) sb.append("KeySpec: ").append(getKeySpec()).append(","); if (getGrantTokens() != null) sb.append("GrantTokens: ").append(getGrantTokens()); sb.append("}"); return sb.toString(); }
if (other.getKeySpec() != null && other.getKeySpec().equals(this.getKeySpec()) == false) return false; if (other.getGrantTokens() == null ^ this.getGrantTokens() == null) return false; if (other.getGrantTokens() != null && other.getGrantTokens().equals(this.getGrantTokens()) == false) return false; return true;
/** * Marshall the given parameter object. */ public void marshall(GenerateDataKeyRequest generateDataKeyRequest, ProtocolMarshaller protocolMarshaller) { if (generateDataKeyRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(generateDataKeyRequest.getKeyId(), KEYID_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getEncryptionContext(), ENCRYPTIONCONTEXT_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getNumberOfBytes(), NUMBEROFBYTES_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getKeySpec(), KEYSPEC_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getGrantTokens(), GRANTTOKENS_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }
if (getGrantTokens() == null) { this.grantTokens = new java.util.ArrayList<String>(grantTokens.length);
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getEncryptionContext() == null) ? 0 : getEncryptionContext().hashCode()); hashCode = prime * hashCode + ((getNumberOfBytes() == null) ? 0 : getNumberOfBytes().hashCode()); hashCode = prime * hashCode + ((getKeySpec() == null) ? 0 : getKeySpec().hashCode()); hashCode = prime * hashCode + ((getGrantTokens() == null) ? 0 : getGrantTokens().hashCode()); return hashCode; }
/** * Returns a string representation of this object; useful for testing and * debugging. * * @return A string representation of this object. * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getKeyId() != null) sb.append("KeyId: " + getKeyId() + ","); if (getEncryptionContext() != null) sb.append("EncryptionContext: " + getEncryptionContext() + ","); if (getNumberOfBytes() != null) sb.append("NumberOfBytes: " + getNumberOfBytes() + ","); if (getKeySpec() != null) sb.append("KeySpec: " + getKeySpec() + ","); if (getGrantTokens() != null) sb.append("GrantTokens: " + getGrantTokens()); sb.append("}"); return sb.toString(); }
if (other.getKeySpec() != null && other.getKeySpec().equals(this.getKeySpec()) == false) return false; if (other.getGrantTokens() == null ^ this.getGrantTokens() == null) return false; if (other.getGrantTokens() != null && other.getGrantTokens().equals(this.getGrantTokens()) == false) return false; return true;
jsonWriter.value(keySpec); if (generateDataKeyRequest.getGrantTokens() != null) { java.util.List<String> grantTokens = generateDataKeyRequest.getGrantTokens(); jsonWriter.name("GrantTokens"); jsonWriter.beginArray();
if (getGrantTokens() == null) { this.grantTokens = new java.util.ArrayList<String>(grantTokens.length);
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getEncryptionContext() == null) ? 0 : getEncryptionContext().hashCode()); hashCode = prime * hashCode + ((getNumberOfBytes() == null) ? 0 : getNumberOfBytes().hashCode()); hashCode = prime * hashCode + ((getKeySpec() == null) ? 0 : getKeySpec().hashCode()); hashCode = prime * hashCode + ((getGrantTokens() == null) ? 0 : getGrantTokens().hashCode()); return hashCode; }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getEncryptionContext() == null) ? 0 : getEncryptionContext().hashCode()); hashCode = prime * hashCode + ((getNumberOfBytes() == null) ? 0 : getNumberOfBytes().hashCode()); hashCode = prime * hashCode + ((getKeySpec() == null) ? 0 : getKeySpec().hashCode()); hashCode = prime * hashCode + ((getGrantTokens() == null) ? 0 : getGrantTokens().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 (getKeyId() != null) sb.append("KeyId: ").append(getKeyId()).append(","); if (getEncryptionContext() != null) sb.append("EncryptionContext: ").append(getEncryptionContext()).append(","); if (getNumberOfBytes() != null) sb.append("NumberOfBytes: ").append(getNumberOfBytes()).append(","); if (getKeySpec() != null) sb.append("KeySpec: ").append(getKeySpec()).append(","); if (getGrantTokens() != null) sb.append("GrantTokens: ").append(getGrantTokens()); sb.append("}"); return sb.toString(); }
/** * Returns a string representation of this object; useful for testing and debugging. * * @return A string representation of this object. * * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getKeyId() != null) sb.append("KeyId: ").append(getKeyId()).append(","); if (getEncryptionContext() != null) sb.append("EncryptionContext: ").append(getEncryptionContext()).append(","); if (getNumberOfBytes() != null) sb.append("NumberOfBytes: ").append(getNumberOfBytes()).append(","); if (getKeySpec() != null) sb.append("KeySpec: ").append(getKeySpec()).append(","); if (getGrantTokens() != null) sb.append("GrantTokens: ").append(getGrantTokens()); sb.append("}"); return sb.toString(); }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getEncryptionContext() == null) ? 0 : getEncryptionContext().hashCode()); hashCode = prime * hashCode + ((getNumberOfBytes() == null) ? 0 : getNumberOfBytes().hashCode()); hashCode = prime * hashCode + ((getKeySpec() == null) ? 0 : getKeySpec().hashCode()); hashCode = prime * hashCode + ((getGrantTokens() == null) ? 0 : getGrantTokens().hashCode()); return hashCode; }
@Override public int hashCode() { final int prime = 31; int hashCode = 1; hashCode = prime * hashCode + ((getKeyId() == null) ? 0 : getKeyId().hashCode()); hashCode = prime * hashCode + ((getEncryptionContext() == null) ? 0 : getEncryptionContext().hashCode()); hashCode = prime * hashCode + ((getNumberOfBytes() == null) ? 0 : getNumberOfBytes().hashCode()); hashCode = prime * hashCode + ((getKeySpec() == null) ? 0 : getKeySpec().hashCode()); hashCode = prime * hashCode + ((getGrantTokens() == null) ? 0 : getGrantTokens().hashCode()); return hashCode; }
/** * Returns a string representation of this object; useful for testing and * debugging. * * @return A string representation of this object. * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getKeyId() != null) sb.append("KeyId: " + getKeyId() + ","); if (getEncryptionContext() != null) sb.append("EncryptionContext: " + getEncryptionContext() + ","); if (getNumberOfBytes() != null) sb.append("NumberOfBytes: " + getNumberOfBytes() + ","); if (getKeySpec() != null) sb.append("KeySpec: " + getKeySpec() + ","); if (getGrantTokens() != null) sb.append("GrantTokens: " + getGrantTokens()); sb.append("}"); return sb.toString(); }
/** * Returns a string representation of this object; useful for testing and * debugging. * * @return A string representation of this object. * @see java.lang.Object#toString() */ @Override public String toString() { StringBuilder sb = new StringBuilder(); sb.append("{"); if (getKeyId() != null) sb.append("KeyId: " + getKeyId() + ","); if (getEncryptionContext() != null) sb.append("EncryptionContext: " + getEncryptionContext() + ","); if (getNumberOfBytes() != null) sb.append("NumberOfBytes: " + getNumberOfBytes() + ","); if (getKeySpec() != null) sb.append("KeySpec: " + getKeySpec() + ","); if (getGrantTokens() != null) sb.append("GrantTokens: " + getGrantTokens()); sb.append("}"); return sb.toString(); }
/** * Marshall the given parameter object. */ public void marshall(GenerateDataKeyRequest generateDataKeyRequest, ProtocolMarshaller protocolMarshaller) { if (generateDataKeyRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(generateDataKeyRequest.getKeyId(), KEYID_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getEncryptionContext(), ENCRYPTIONCONTEXT_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getNumberOfBytes(), NUMBEROFBYTES_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getKeySpec(), KEYSPEC_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getGrantTokens(), GRANTTOKENS_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }
/** * Marshall the given parameter object. */ public void marshall(GenerateDataKeyRequest generateDataKeyRequest, ProtocolMarshaller protocolMarshaller) { if (generateDataKeyRequest == null) { throw new SdkClientException("Invalid argument passed to marshall(...)"); } try { protocolMarshaller.marshall(generateDataKeyRequest.getKeyId(), KEYID_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getEncryptionContext(), ENCRYPTIONCONTEXT_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getNumberOfBytes(), NUMBEROFBYTES_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getKeySpec(), KEYSPEC_BINDING); protocolMarshaller.marshall(generateDataKeyRequest.getGrantTokens(), GRANTTOKENS_BINDING); } catch (Exception e) { throw new SdkClientException("Unable to marshall request to JSON: " + e.getMessage(), e); } }