public class RobocupServer extends Object
Trainer is used for sending commands to RoboCup 3D simulation
soccer server with aim to set specific state on server.| Modifier and Type | Field and Description |
|---|---|
private RobocupServerAddress |
address |
private static Logger |
logger |
private static Map<String,RobocupServer> |
serverInstances |
private Socket |
socket |
| Modifier | Constructor and Description |
|---|---|
private |
RobocupServer(RobocupServerAddress address) |
| Modifier and Type | Method and Description |
|---|---|
static RobocupServer |
getServerInstance() |
static RobocupServer |
getServerInstance(RobocupServerAddress address) |
private void |
performCommand(RobocupServerCommand command) |
void |
setAgentPosition(AgentData agentData,
Point3D position) |
void |
setAgentPosition(String team,
int playerid,
Point3D position) |
void |
setBall(Point3D position,
Point3D velocity) |
void |
setBallPosition(Point3D position) |
void |
setBallVelocity(Point3D velocity) |
void |
setPlayMode(PlayMode mode) |
private static Logger logger
private RobocupServerAddress address
private Socket socket
private static Map<String,RobocupServer> serverInstances
private RobocupServer(RobocupServerAddress address) throws IOException
IOExceptionpublic static RobocupServer getServerInstance() throws IOException
IOExceptionpublic static RobocupServer getServerInstance(RobocupServerAddress address) throws IOException
IOExceptionprivate void performCommand(RobocupServerCommand command) throws IOException
IOExceptionpublic void setAgentPosition(AgentData agentData, Point3D position) throws IOException
IOExceptionpublic void setAgentPosition(String team, int playerid, Point3D position) throws IOException
IOExceptionpublic void setBallPosition(Point3D position) throws IOException
IOExceptionpublic void setBallVelocity(Point3D velocity) throws IOException
IOExceptionpublic void setBall(Point3D position, Point3D velocity) throws IOException
IOExceptionpublic void setPlayMode(PlayMode mode) throws IOException
IOException