ctf.evaluation.simulator
Class CLI

java.lang.Object
  extended by java.lang.Thread
      extended by ctf.evaluation.simulator.CLI
All Implemented Interfaces:
java.lang.Runnable

public class CLI
extends java.lang.Thread

A command-line client for a CTF simulator


Nested Class Summary
 
Nested classes/interfaces inherited from class java.lang.Thread
java.lang.Thread.State, java.lang.Thread.UncaughtExceptionHandler
 
Field Summary
(package private)  Connection connection
          Connection to the simulator
(package private)  Log out
          Where output is logged
 
Fields inherited from class java.lang.Thread
MAX_PRIORITY, MIN_PRIORITY, NORM_PRIORITY
 
Constructor Summary
CLI(java.lang.String host, java.lang.String team, Side side)
          Constructor
 
Method Summary
static void main(java.lang.String[] args)
          Main entry point
protected  void placeFlag(Point flag)
           
protected  void placeTree(Point tree)
           
protected  void sendCommand(java.lang.String command)
           
 
Methods inherited from class java.lang.Thread
activeCount, checkAccess, countStackFrames, currentThread, destroy, dumpStack, enumerate, getAllStackTraces, getContextClassLoader, getDefaultUncaughtExceptionHandler, getId, getName, getPriority, getStackTrace, getState, getThreadGroup, getUncaughtExceptionHandler, holdsLock, interrupt, interrupted, isAlive, isDaemon, isInterrupted, join, join, join, resume, run, setContextClassLoader, setDaemon, setDefaultUncaughtExceptionHandler, setName, setPriority, setUncaughtExceptionHandler, sleep, sleep, start, stop, stop, suspend, toString, yield
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Field Detail

out

Log out
Where output is logged


connection

Connection connection
Connection to the simulator

Constructor Detail

CLI

public CLI(java.lang.String host,
           java.lang.String team,
           Side side)
    throws java.lang.Exception
Constructor

Throws:
java.lang.Exception
Method Detail

main

public static void main(java.lang.String[] args)
                 throws java.lang.Exception
Main entry point

Throws:
java.lang.Exception

sendCommand

protected void sendCommand(java.lang.String command)
                    throws java.io.IOException,
                           NetworkException
Throws:
java.io.IOException
NetworkException

placeTree

protected void placeTree(Point tree)
                  throws java.io.IOException,
                         NetworkException
Throws:
java.io.IOException
NetworkException

placeFlag

protected void placeFlag(Point flag)
                  throws java.io.IOException,
                         NetworkException
Throws:
java.io.IOException
NetworkException