Class Command

java.lang.Object
org.javalite.async.Command

public abstract class Command extends Object
Super class of all commands. Only the method execute() is to be provided by subclasses to do real application work.
Author:
Igor Polevoy on 4/4/15.
  • Constructor Details

    • Command

      public Command()
  • Method Details

    • execute

      public abstract void execute()
      Subclasses are to provide implementation of this method to get application-specific work done.
    • toBytes

      public byte[] toBytes() throws IOException
      Flattens(serializes, dehydrates, etc.) this instance to a binary representation.
      Returns:
      a binary representation
      Throws:
      IOException
    • fromBytes

      public static <T extends Command> T fromBytes(byte[] bytes) throws IOException
      Throws:
      IOException
    • getJMSMessageID

      public String getJMSMessageID()
    • setJMSMessageID

      public void setJMSMessageID(String jmsMessageID)