All Packages  Class Hierarchy  This Package  Previous  Next  Index

Class ajanta.pattern.Pattern

java.lang.Object
   |
   +----ajanta.pattern.Pattern

public abstract class Pattern
extends Object
implements Cloneable, Serializable
Pattern is a abstract class. Every pattern is associated with an action that the agent performs at the host it visits. This is overridden to specialize the action.


Variable Index

 o action
MethodSpec of the action that an agent perform on a host
 o DONE
Pattern action was successfuly completed
 o FAILED
Pattern action failed due to some reason
 o NOTDONE
Pattern action is yet to be performed
 o status
Current status of the pattern

Constructor Index

 o Pattern()

Method Index

 o getName()
 o next(AgentEnv)
The pattern traversal is determined by the abstarct method next.
 o print()
It prints inforamtion about the pattern i.e its status, destination server etc
 o reset()
It reset the current state of the pattern to initial state
 o scan()
It is used to scan the pattern
 o setName(String)
It sets the name of the pattern to the name passed as argument

Variables

 o DONE
 public static final int DONE
Pattern action was successfuly completed

 o NOTDONE
 public static final int NOTDONE
Pattern action is yet to be performed

 o FAILED
 public static final int FAILED
Pattern action failed due to some reason

 o status
 public int status
Current status of the pattern

 o action
 public MethodSpec action
MethodSpec of the action that an agent perform on a host

Constructors

 o Pattern
 public Pattern()

Methods

 o next
 protected abstract int next(AgentEnv host) throws UnknownHostException
The pattern traversal is determined by the abstarct method next. It captures the notion of next hop in the migration path of the agent. Each pattern has its own semantics to determine the next hop

 o reset
 protected abstract void reset()
It reset the current state of the pattern to initial state

 o scan
 protected abstract void scan()
It is used to scan the pattern

 o print
 public abstract void print()
It prints inforamtion about the pattern i.e its status, destination server etc

 o setName
 public void setName(String name)
It sets the name of the pattern to the name passed as argument

 o getName
 public String getName()
Returns:
If the name is not null it returns the name of pattern else Agent

All Packages  Class Hierarchy  This Package  Previous  Next  Index