io.sarl.api.javafx
Class FxViewerController
All Superinterfaces:
EventListener, Identifiable
abstract class FxViewerController
extends java.lang.Object
implements EventListener
Abstract implementation of a JavaFX viewer controller.
Maven Group Identifier:
io.sarl.sdk
Maven Artifact Identifier:
api.javafx
Since:
0.7
Property Summary
Modifier and type Property and description
java.util.UUID iD
Get ID of the object on the space that is used for supporting the interactions between the agents and the JavaFX user interface.
OpenEventSpace uISpace
Replies the space for interaction between SARL agents and UI.
Action Summary
Modifier and type Action and description
void _receiveEvent(Event)
Invoked when an event is fired within an agent and received by the JavaFX user interface.
void emitToAgents(Event,[boolean],[Scope<T>])
Emit an event to the agents.
void exitApplication
Do a safe application exist.
void exitApplication(ActionEvent)
Catch exit event from JavaFX.
java.util.UUID getID
Get ID of the object on the space that is used for supporting the interactions between the agents and the JavaFX user interface.
OpenEventSpace getUISpace
Replies the space for interaction between SARL agents and UI.
void receiveEvent(Event)
Invoked when an event is fired within an agent and received by the JavaFX user interface.
void safeExit
Emit a kill signal when the application is exited.
void setUISpace(OpenEventSpace)
Method invoked by the SARL agent to register the object on a space.
void startAgentApplication(Class<T>,[UUID],Procedure0)
Start the agent application.
Property Details
iD
val iD : java.util.UUID
Get ID of the object on the space that is used for supporting the interactions between the agents and the JavaFX user interface.

This property is an alias for the action: getID

Returns:
the identifier of the space.
uISpace
var uISpace : OpenEventSpace
Replies the space for interaction between SARL agents and UI.

This property is an alias for the action: getUISpace

Returns:
the event space that is used for supporting the interaction between the SARL agents and the user interface.
Action Details
_receiveEvent(Event)
def _receiveEvent(Event)
Invoked when an event is fired within an agent and received by the JavaFX user interface.
Parameters:
event - the occurrence fired by an agent.
emitToAgents(Event,[boolean],[Scope<T>])
def emitToAgents(Event,[boolean],[Scope<T>])
Emit an event to the agents.
Parameters:
event - the occurrence to send to agents.
globalSpace - indicates if the global event space must be used in preference to the UI event space.
scope - optional parameter that enables to scope the event receiving.
Since:
0.11
exitApplication
def exitApplication
Do a safe application exist.
Since:
0.11
exitApplication(ActionEvent)
def exitApplication(ActionEvent)
Catch exit event from JavaFX. Stop the agents and the JavaFX user interface.
Parameters:
event - the JavaFx event that is the source of the exit.
getID
def getID : java.util.UUID
Get ID of the object on the space that is used for supporting the interactions between the agents and the JavaFX user interface.
Returns:
the identifier of the space.
getUISpace
def getUISpace : OpenEventSpace
Replies the space for interaction between SARL agents and UI.
Returns:
the event space that is used for supporting the interaction between the SARL agents and the user interface.
receiveEvent(Event)
def receiveEvent(Event)
Invoked when an event is fired within an agent and received by the JavaFX user interface.
Parameters:
event - the occurrence fired by an agent.
safeExit
def safeExit
Emit a kill signal when the application is exited.
setUISpace(OpenEventSpace)
def setUISpace(OpenEventSpace)
Method invoked by the SARL agent to register the object on a space.
Parameters:
space - the event space that is used for supporting the interaction between the SARL agents and the user interface.
startAgentApplication(Class<T>,[UUID],Procedure0)
def startAgentApplication(Class<T>,[UUID],Procedure0)
Start the agent application.
Parameters:
agentType - the type of the agent to launch.
agentID - is the identifier of the agent.
whenAgentLaunched - the lambda that is called when the agent is really launched.
Since:
0.11