Package ffx.ui.commands
Class FFXClient
java.lang.Object
ffx.ui.commands.FFXClient
The FFXClient class encapsulates a socket connection to an FFXServer started by an executing FFX
instance. FFXSystem and FFXUpdate objects are sent by the FFXServer to the FFXClient on request.
- Author:
- Michael J. Schnieders
-
Constructor Summary
ConstructorDescriptionConstructor for FFXClient.FFXClient
(int port) Constructor for FFXClient.Constructor for FFXClient. -
Method Summary
-
Constructor Details
-
FFXClient
public FFXClient()Constructor for FFXClient. -
FFXClient
Constructor for FFXClient.- Parameters:
a
- aInetSocketAddress
object.
-
FFXClient
public FFXClient(int port) Constructor for FFXClient.- Parameters:
port
- a int.
-
-
Method Details
-
connect
public void connect()Attempts to connect to a Tinker FServer. If this FClient is already connected, the connection will be closed. -
getSystem
Getter for the fieldsystem
.- Returns:
- a
SimulationDefinition
object.
-
getUpdate
Getter for the fieldupdate
.- Returns:
- a
SimulationUpdate
object.
-
isClosed
public boolean isClosed()isClosed- Returns:
- a boolean.
-
isConnected
public boolean isConnected()isConnected- Returns:
- a boolean.
-
readSocket
public void readSocket()readSocket -
release
public void release()release
-