de.fzi.kadmos.cloud.aws
Class SimpleCloudMessage

java.lang.Object
  extended by de.fzi.kadmos.cloud.aws.SimpleCloudMessage
All Implemented Interfaces:
Serializable

public class SimpleCloudMessage
extends Object
implements Serializable

Simple data object to wrap any serialisable object with a boolean indicating that this is a heartbeat.

Since:
1.1.0
Version:
1.3.0
Author:
Carsten Daenschel
See Also:
Serialized Form

Constructor Summary
SimpleCloudMessage()
          Generates a message without content and heartbeat set to true.
SimpleCloudMessage(Serializable msg)
          Generates a message with specified content and heartbeat set to false.
 
Method Summary
 Serializable getMessage()
          Returns the message content.
 boolean isHeartbeat()
          Checks whether this message is a heartbeat.
 String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

SimpleCloudMessage

public SimpleCloudMessage()
Generates a message without content and heartbeat set to true.


SimpleCloudMessage

public SimpleCloudMessage(Serializable msg)
Generates a message with specified content and heartbeat set to false.

Method Detail

getMessage

public Serializable getMessage()
Returns the message content.

Returns:
Message content.

isHeartbeat

public boolean isHeartbeat()
Checks whether this message is a heartbeat.

Returns:
true if this message is a heartbeat, false otherwise.

toString

public String toString()
Overrides:
toString in class Object


Copyright © 2012. All Rights Reserved.