|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectagent.interaction.samples.SimplePlace
public class SimplePlace
This example uses a GUI application to show how to log an agent into a place
and queue. Once you have done this, the example enables you to set the agent
status to Ready, Not Ready, and After Call Work. It also lets you log the
agent out.
This example is also the base class for the other Agent Interaction (Java)
code examples, including SimpleVoiceInteraction and MultipartyVoiceInteraction.
PLEASE NOTE: This code example will not work unless you edit
the configuration data in AgentInteractionData.java so that it matches objects
that already exist in your local configuration layer.
There are several steps needed to prepare an application to use the services
of Agent Interaction (Java). This example uses the services of other classes
to carry out these functions.
Connector
connects the code examples to the Agent Interaction Layer
Field Summary | |
---|---|
com.genesyslab.ail.Agent |
sampleAgent
Agent object used in this example. |
com.genesyslab.ail.Media |
sampleChat
Media object used for managing open media in this example. |
com.genesyslab.ail.Dn |
sampleDn
Dn object used in this example. |
com.genesyslab.ail.Media |
sampleEmail
Media object used for managing e-mail in this example. |
com.genesyslab.ail.Media |
sampleOpenMedia
Media object used for managing open media in this example. |
com.genesyslab.ail.Place |
samplePlace
Place object used in this example. |
Constructor Summary | |
---|---|
SimplePlace(java.lang.String windowTitle)
Creates an instance of SimplePlace. |
Method Summary | |
---|---|
void |
contactChanged(com.genesyslab.ail.event.InteractionEvent event)
This method is required by the PlaceListener interface, but is not used by the Agent Interaction (Java) code examples. |
void |
deleted()
This method is required by the PlaceListener interface, but is not used by the Agent Interaction (Java) code examples. |
void |
dnAdded(java.lang.String dn)
This method is required by the PlaceListener interface, but is not used by the Agent Interaction (Java) code examples. |
void |
dnRemoved(java.lang.String dn)
This method is required by the PlaceListener interface, but is not used by the Agent Interaction (Java) code examples. |
void |
handleDnEvent(com.genesyslab.ail.event.DnEvent event)
Receives DnEvents, which report changes to the status or data of a DN. |
void |
handleInteractionEvent(com.genesyslab.ail.event.InteractionEvent event)
This method is required by the PlaceListener interface, but is not used by the SimplePlace example because this example doesn't generate any interactions. |
void |
handlePlaceEvent(com.genesyslab.ail.event.PlaceEvent event)
Receives PlaceEvents, which report changes to the status or data of a DN. |
void |
idModified(java.lang.String id)
This method is required by the PlaceListener interface, but is not used by the Agent Interaction (Java) code examples. |
void |
linkWidgetsToGui()
This method does two important things: first, it links widgets (user interface components) to API functionality, and second, it registers a listener for events on the Place the agent has logged in to. |
static void |
main(java.lang.String[] args)
This method is used to run the SimplePlace example. |
void |
setInteractionWidgetState()
The setInteractionWidgetState() method is used by subclasses of the SimplePlace class. |
void |
setPlaceWidgetState()
Any time the place associated with this example changes its state, the example's widgets must be updated to reflect that state. |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
public com.genesyslab.ail.Agent sampleAgent
public com.genesyslab.ail.Place samplePlace
public com.genesyslab.ail.Dn sampleDn
public com.genesyslab.ail.Media sampleEmail
public com.genesyslab.ail.Media sampleOpenMedia
public com.genesyslab.ail.Media sampleChat
Constructor Detail |
---|
public SimplePlace(java.lang.String windowTitle)
windowTitle
- The title of the GUI window for this example.Method Detail |
---|
public void linkWidgetsToGui()
loginButton = agentInteractionGui.loginButton;
loginButton.setAction(new AbstractAction("Log In") {
public void actionPerformed(ActionEvent actionEvent) {
try {
sampleAgent.login(samplePlace, agentInteractionData
.getLoginId1(), agentInteractionData.getPassword1(),
agentInteractionData.getQueue(), null, null, null);
...
samplePlace.addPlaceListener(this);
public void setPlaceWidgetState()
public void setInteractionWidgetState()
public void handleDnEvent(com.genesyslab.ail.event.DnEvent event)
handleDnEvent
in interface com.genesyslab.ail.event.DnListener
public void handlePlaceEvent(com.genesyslab.ail.event.PlaceEvent event)
handlePlaceEvent
in interface com.genesyslab.ail.event.PlaceListener
public void handleInteractionEvent(com.genesyslab.ail.event.InteractionEvent event)
handleInteractionEvent
in interface com.genesyslab.ail.event.InteractionListener
public void contactChanged(com.genesyslab.ail.event.InteractionEvent event)
contactChanged
in interface com.genesyslab.ail.event.InteractionListener
public void deleted()
deleted
in interface com.genesyslab.ail.event.ConfigObjectListener
public void dnAdded(java.lang.String dn)
dnAdded
in interface com.genesyslab.ail.event.PlaceListener
public void dnRemoved(java.lang.String dn)
dnRemoved
in interface com.genesyslab.ail.event.PlaceListener
public void idModified(java.lang.String id)
idModified
in interface com.genesyslab.ail.event.PlaceListener
public static void main(java.lang.String[] args)
args
- There are no arguments for this class.
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |