fr.lifl.magique.skill.system
Class DisconnectionSkill

java.lang.Object
  extended byfr.lifl.magique.skill.DefaultSkill
      extended byfr.lifl.magique.skill.system.DisconnectionSkill
All Implemented Interfaces:
Skill

public class DisconnectionSkill
extends DefaultSkill

Skills with ability for disconnection between agent

See Also:
ConnectionSkill

Constructor Summary
DisconnectionSkill(AtomicAgent myAgent)
           
 
Method Summary
 java.lang.Boolean acknowledgeDisconnection(java.lang.String theOther)
          performed by an agent when another agent (theOther) asked for a disconnection from him
 java.lang.Boolean askForDisconnectionFrom(java.lang.String theOther)
          disconnects me from another agent : disconnection is safe in the sense that no request are lost during disconnection : every request who leaved me or my boss arrived to its its destination.
 void disconnectFromAll()
          disconect from everyone
 void removeFromAgenda(java.lang.String theOther, java.lang.Boolean flag)
          remove theOther from my agenda (due to a disconnection).
 
Methods inherited from class fr.lifl.magique.skill.DefaultSkill
addAgenda, addSkill, addSkill, addSkill, addSkill, ask, ask, ask, ask, ask, ask, ask, ask, ask, ask, ask, ask, ask, ask, askNow, askNow, askNow, askNow, askNow, askNow, askNow, askNow, askNow, askNow, askNow, askNow, askNow, askNow, concurrentAsk, concurrentAsk, concurrentAsk, concurrentAsk, concurrentAsk, concurrentAsk, concurrentAsk, connectTo, createOrder, createOrder, createOrder, createOrder, createOrder, createOrder, createQuestion, createQuestion, createQuestion, createQuestion, createQuestion, createQuestion, getAgenda, getMyAgent, getName, getPlatform, isAnswerReceived, perform, perform, perform, perform, perform, perform, perform, perform, perform, perform, perform, perform, perform, perform, removeSkill, removeSkillFromClassName, returnAnswer, returnValue
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Constructor Detail

DisconnectionSkill

public DisconnectionSkill(AtomicAgent myAgent)
Method Detail

askForDisconnectionFrom

public java.lang.Boolean askForDisconnectionFrom(java.lang.String theOther)
disconnects me from another agent : disconnection is safe in the sense that no request are lost during disconnection : every request who leaved me or my boss arrived to its its destination. BUT nothing is said about what become the answers to questions I have asked or have been asked to answer...

Parameters:
theOther - name of the agent i disconnect from
See Also:
AtomicAgent.connectTo(java.lang.String)

disconnectFromAll

public void disconnectFromAll()
disconect from everyone


removeFromAgenda

public void removeFromAgenda(java.lang.String theOther,
                             java.lang.Boolean flag)
remove theOther from my agenda (due to a disconnection).

Parameters:
theOther - name of the agent to remove from my agenda
flag - not used here

acknowledgeDisconnection

public java.lang.Boolean acknowledgeDisconnection(java.lang.String theOther)
performed by an agent when another agent (theOther) asked for a disconnection from him

Parameters:
theOther - name of the agent who disconnect from me
Returns:
Boolean.TRUE to tell i agree and am ready for safe disconnection