|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--repserver.RepGroup
This class represents a Replicant Group A replicant group consists of a list of RepAgentIDs, the latest serialized state, a pointer to an active agent, and a message proxy (RepProxy).
Constructor Summary | |
RepGroup()
Constructs a blank RepGroup. |
|
RepGroup(java.lang.String platform,
java.lang.String n,
java.lang.String type)
Constructs a RepGroup with the given name |
Method Summary | |
void |
addAgent(RepAgentID aid)
Add an agent to this replicant group. |
int |
countReps()
return the number of replicants in this replicant group |
void |
delAgent(RepAgentID aid)
Delete an agent from this replicant group. |
RepAgentID |
getActive()
get the Active Agent |
RepAgentID[] |
getAgents()
Return an array of the agents in this group. |
java.lang.String |
getName()
Returns the name of this repgroup |
boolean |
getPing(RepAgentID raid)
Return the ping flag for the given agent. |
RepProxy |
getProxy()
Get the message proxy |
fipaos.ont.fipa.fipaman.AgentID |
getProxyAID()
Get the agentID of the mail proxy |
java.lang.String |
getReplicationType()
|
byte[] |
getState()
return the most recent value of the _state vector |
java.util.Date |
getUpdateTime(RepAgentID raid)
get the updatetime for the given agent. |
void |
removeDead()
remove any dead agents from the rep group. |
boolean |
setActive()
Set the active agent to be the first agent found alive Return true if one is found, false otherwise. |
boolean |
setActive(RepAgentID aid)
Set the active agent to be the agent named by aid. |
void |
setName(java.lang.String name)
Sets the name of this RepGroup |
void |
setPing(RepAgentID raid,
boolean val)
Set the ping flag for the given agent. |
void |
setReplicationType(java.lang.String reptype)
|
void |
setState(byte[] state)
add the state to the stack. |
void |
setUpdateTime(RepAgentID raid,
java.util.Date d)
set the updatetime for the given agent. |
java.lang.String |
toString()
convert this repgroup to a string. |
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Constructor Detail |
public RepGroup()
public RepGroup(java.lang.String platform, java.lang.String n, java.lang.String type)
n
- string name to name this repgroupMethod Detail |
public void setReplicationType(java.lang.String reptype)
public java.lang.String getReplicationType()
public void setName(java.lang.String name)
name
- The name to setpublic java.lang.String getName()
public void addAgent(RepAgentID aid)
aid
- - the agent to addpublic void delAgent(RepAgentID aid)
aid
- - the agent to deletepublic RepAgentID getActive()
public boolean setActive()
public boolean setActive(RepAgentID aid)
public RepProxy getProxy()
public fipaos.ont.fipa.fipaman.AgentID getProxyAID()
public java.lang.String toString()
toString
in class java.lang.Object
public RepAgentID[] getAgents()
public void setPing(RepAgentID raid, boolean val)
raid
- the agent in question.val
- what to set the flag to.public boolean getPing(RepAgentID raid)
raid
- the agent in question.public void setState(byte[] state)
state
- a byte stream containing the agent statepublic byte[] getState()
public int countReps()
public void setUpdateTime(RepAgentID raid, java.util.Date d)
public java.util.Date getUpdateTime(RepAgentID raid)
public void removeDead()
|
|||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | ||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |