Cumulus4j API
(1.1.1)

org.cumulus4j.keymanager.back.shared
Class GetKeyResponse

java.lang.Object
  extended by org.cumulus4j.keymanager.back.shared.Message
      extended by org.cumulus4j.keymanager.back.shared.Response
          extended by org.cumulus4j.keymanager.back.shared.GetKeyResponse
All Implemented Interfaces:
Serializable
Direct Known Subclasses:
GetActiveEncryptionKeyResponse

public class GetKeyResponse
extends Response

Response implementation to send a specific symmetric secret key to the app-server. It is the response to a GetKeyRequest.

Author:
Marco หงุ่ยตระกูล-Schulze - marco at nightlabs dot de
See Also:
GetKeyRequest, Serialized Form

Constructor Summary
GetKeyResponse()
          Create an empty instance of GetKeyResponse.
GetKeyResponse(Request request, long keyID, byte[] keyEncodedEncrypted)
          Create an instance of GetKeyResponse in order to reply the given request.
 
Method Summary
 byte[] getKeyEncodedEncrypted()
          Get the encrypted symmetric secret key.
 long getKeyID()
          Get the identifier of the symmetric secret key transported by this response.
 void setKeyEncodedEncrypted(byte[] key)
          Set the encrypted symmetric secret key.
 void setKeyID(long keyID)
          Set the identifier of the symmetric secret key transported by this response.
 
Methods inherited from class org.cumulus4j.keymanager.back.shared.Response
toString
 
Methods inherited from class org.cumulus4j.keymanager.back.shared.Message
equals, getRequestID, hashCode, setRequestID
 
Methods inherited from class java.lang.Object
clone, finalize, getClass, notify, notifyAll, wait, wait, wait
 

Constructor Detail

GetKeyResponse

public GetKeyResponse()
Create an empty instance of GetKeyResponse. Only used for serialisation/deserialisation.


GetKeyResponse

public GetKeyResponse(Request request,
                      long keyID,
                      byte[] keyEncodedEncrypted)
Create an instance of GetKeyResponse in order to reply the given request.

Parameters:
request - the request to be replied (an instance of GetActiveEncryptionKeyRequest).
keyID - the identifier of the key to be sent to the app-server.
keyEncodedEncrypted - the encrypted symmetric secret key.
Method Detail

getKeyID

public long getKeyID()
Get the identifier of the symmetric secret key transported by this response.

Returns:
the identifier of the symmetric secret key transported by this response.
See Also:
setKeyID(long)

setKeyID

public void setKeyID(long keyID)
Set the identifier of the symmetric secret key transported by this response.

Parameters:
keyID - the identifier of the symmetric secret key transported by this response.
See Also:
getKeyID()

getKeyEncodedEncrypted

public byte[] getKeyEncodedEncrypted()
Get the encrypted symmetric secret key.

Returns:
the encrypted symmetric secret key.
See Also:
setKeyEncodedEncrypted(byte[])

setKeyEncodedEncrypted

public void setKeyEncodedEncrypted(byte[] key)
Set the encrypted symmetric secret key.

Parameters:
key - the encrypted symmetric secret key.
See Also:
getKeyEncodedEncrypted()

Cumulus4j API
(1.1.1)

Copyright © 2013 NightLabs Consulting GmbH. All Rights Reserved.