se.sics.tasim.viewer
Class ViewerPanel
java.lang.Object
se.sics.tasim.is.EventWriter
se.sics.tasim.viewer.ViewerConnection
se.sics.tasim.viewer.ViewerPanel
public class ViewerPanel
- extends ViewerConnection
Constructor Summary |
ViewerPanel(java.lang.String userName,
java.lang.String serverName)
|
Method Summary |
void |
addChatMessage(long time,
java.lang.String serverName,
java.lang.String userName,
java.lang.String message)
|
void |
addTickListener(TickListener listener)
|
void |
dataUpdated(int agent,
int type,
double value)
|
void |
dataUpdated(int agent,
int type,
float value)
|
void |
dataUpdated(int agent,
int type,
int value)
|
void |
dataUpdated(int agent,
int type,
long value)
|
void |
dataUpdated(int agent,
int type,
java.lang.String value)
|
void |
dataUpdated(int agent,
int type,
Transportable value)
|
void |
dataUpdated(int type,
Transportable value)
|
javax.swing.JComponent |
getComponent()
|
ConfigManager |
getConfig()
|
javax.swing.ImageIcon |
getIcon(java.lang.String name)
|
java.lang.String |
getServerName()
|
long |
getServerTime()
|
java.lang.String |
getUserName()
|
void |
intCache(int agent,
int type,
int[] cache)
|
void |
interaction(int fromAgent,
int toAgent,
int type)
|
void |
interactionWithRole(int fromAgent,
int role,
int type)
|
void |
nextSimulation(int realSimID,
long startTime)
Notifies about the next scheduled simulation if such exists. |
void |
nextTimeUnit(int timeUnit)
ViewerConnection API |
void |
participant(int index,
int role,
java.lang.String name,
int participantID)
Specifies a participant in the current simulation. |
void |
removeTickListener(TickListener listener)
|
void |
sendChatMessage(java.lang.String message)
|
void |
setChatListener(ChatListener listener)
|
void |
setServerTime(long serverTime)
|
void |
setStatusMessage(java.lang.String message)
|
void |
showDialog(javax.swing.JComponent dialog)
|
void |
simulationStarted(int realSimID,
java.lang.String type,
long startTime,
long endTime,
java.lang.String timeUnitName,
int timeUnitCount)
|
void |
simulationStopped(int realSimID)
|
Methods inherited from class java.lang.Object |
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
ViewerPanel
public ViewerPanel(java.lang.String userName,
java.lang.String serverName)
getComponent
public javax.swing.JComponent getComponent()
getConfig
public ConfigManager getConfig()
getUserName
public java.lang.String getUserName()
getServerName
public java.lang.String getServerName()
getServerTime
public long getServerTime()
setServerTime
public void setServerTime(long serverTime)
- Specified by:
setServerTime
in class ViewerConnection
getIcon
public javax.swing.ImageIcon getIcon(java.lang.String name)
setStatusMessage
public void setStatusMessage(java.lang.String message)
addChatMessage
public void addChatMessage(long time,
java.lang.String serverName,
java.lang.String userName,
java.lang.String message)
sendChatMessage
public void sendChatMessage(java.lang.String message)
setChatListener
public void setChatListener(ChatListener listener)
showDialog
public void showDialog(javax.swing.JComponent dialog)
addTickListener
public void addTickListener(TickListener listener)
removeTickListener
public void removeTickListener(TickListener listener)
nextTimeUnit
public void nextTimeUnit(int timeUnit)
- ViewerConnection API
- Specified by:
nextTimeUnit
in class EventWriter
- Parameters:
timeUnit
- the current time unit
participant
public void participant(int index,
int role,
java.lang.String name,
int participantID)
- Description copied from class:
EventWriter
- Specifies a participant in the current simulation. The agent field is a
local id for this participant in the simulation.
The participantID field is the global user id for the participant. A
negative participantID indicates that this participant is builtin
(dummy).
- Specified by:
participant
in class EventWriter
- Parameters:
index
- a simulation local id for this participantrole
- the role of the participantname
- the name of the participantparticipantID
- the global id of the participating agent or negative if this
participant is builtin (dummy)
dataUpdated
public void dataUpdated(int agent,
int type,
int value)
- Specified by:
dataUpdated
in class EventWriter
dataUpdated
public void dataUpdated(int agent,
int type,
long value)
- Specified by:
dataUpdated
in class EventWriter
dataUpdated
public void dataUpdated(int agent,
int type,
float value)
- Specified by:
dataUpdated
in class EventWriter
dataUpdated
public void dataUpdated(int agent,
int type,
double value)
- Specified by:
dataUpdated
in class EventWriter
dataUpdated
public void dataUpdated(int agent,
int type,
java.lang.String value)
- Specified by:
dataUpdated
in class EventWriter
dataUpdated
public void dataUpdated(int agent,
int type,
Transportable value)
- Specified by:
dataUpdated
in class EventWriter
dataUpdated
public void dataUpdated(int type,
Transportable value)
- Specified by:
dataUpdated
in class EventWriter
interaction
public void interaction(int fromAgent,
int toAgent,
int type)
- Specified by:
interaction
in class EventWriter
interactionWithRole
public void interactionWithRole(int fromAgent,
int role,
int type)
- Specified by:
interactionWithRole
in class EventWriter
simulationStarted
public void simulationStarted(int realSimID,
java.lang.String type,
long startTime,
long endTime,
java.lang.String timeUnitName,
int timeUnitCount)
- Specified by:
simulationStarted
in class ViewerConnection
simulationStopped
public void simulationStopped(int realSimID)
- Specified by:
simulationStopped
in class ViewerConnection
nextSimulation
public void nextSimulation(int realSimID,
long startTime)
- Description copied from class:
ViewerConnection
- Notifies about the next scheduled simulation if such exists.
- Specified by:
nextSimulation
in class ViewerConnection
- Parameters:
realSimID
- the public simulation id or -1 if no such id has been assignedstartTime
- the start time of the next simulation or 0 if no future
simulation has been scheduled
intCache
public void intCache(int agent,
int type,
int[] cache)
- Specified by:
intCache
in class ViewerConnection
Copyright © 2007-2009 Association for Trading Agent Research. All Rights Reserved.