Index: /trunk/IDE_metadata/NetBeans/TMCSim/build.xml
===================================================================
--- /trunk/IDE_metadata/NetBeans/TMCSim/build.xml	(revision 23)
+++ /trunk/IDE_metadata/NetBeans/TMCSim/build.xml	(revision 44)
@@ -13,11 +13,25 @@
     <property name="workdir" value="../../.."/>
 <!--        STORE SUBVERSION BUILD STRING      -->
-<!-- Store the Subversion version string every time you do clean/build. -->
-<target name="-pre-compile">
-  <exec executable="svnversion" osfamily="unix"
-    output="${workdir}/config/svn-version.txt"/>
-    <echo file="${workdir}/config/svn-version.txt" append="true">
-        # Do not edit. This file is autogenerated by the Ant build script #
-    </echo>
+<target name="-post-init" description="Sets the buildversion for the current build">
+    <exec outputproperty="svna.version" executable="svnversion">
+        <arg value="-c" />
+        <redirector>
+            <outputfilterchain>
+                <tokenfilter>
+                    <replaceregex pattern="^[0-9]*:?" replace="" flags="g"/>
+                    <replaceregex pattern="M" replace="" flags="g"/>
+                </tokenfilter>
+            </outputfilterchain>
+        </redirector>
+    </exec>
+    <propertyfile file="${src.dir}/tmcsim/application.properties">
+        <entry key="Application.revision" value="${svna.version}" type="int" operation="="/>
+    </propertyfile>
+    <echo>Setting SVN version: ${svna.version}</echo>
+</target>
+<target name="-post-jar" description="Sets the buildversion for the current build">
+    <propertyfile file="${src.dir}/tmcsim/application.properties">
+        <entry key="Application.buildnumber" value="1" type="int" operation="+"/>
+    </propertyfile>
 </target>
 <!--
Index: /trunk/src/tmcsim/application.properties
===================================================================
--- /trunk/src/tmcsim/application.properties	(revision 44)
+++ /trunk/src/tmcsim/application.properties	(revision 44)
@@ -0,0 +1,5 @@
+#Thu, 23 Jun 2016 19:19:14 -0700
+
+Application.revision=43
+
+Application.buildnumber=1
Index: /trunk/src/tmcsim/interfaces/CADViewer.java
===================================================================
--- /trunk/src/tmcsim/interfaces/CADViewer.java	(revision 44)
+++ /trunk/src/tmcsim/interfaces/CADViewer.java	(revision 44)
@@ -0,0 +1,15 @@
+package tmcsim.interfaces;
+
+/**
+ * CADViewer specifies the behavior for classes that want to be Observers of the
+ * CADSimulator.
+ *
+ * @author jdalbey
+ */
+public interface CADViewer extends java.util.Observer
+{
+
+    public void setVisible(boolean state);
+
+    public void update(java.util.Observable obs, Object obj);
+}
Index: /trunk/src/tmcsim/cadsimulator/stillimagecontrol/ATMSCommunicator.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/stillimagecontrol/ATMSCommunicator.java	(revision 2)
+++ /trunk/src/tmcsim/cadsimulator/stillimagecontrol/ATMSCommunicator.java	(revision 44)
@@ -7,117 +7,146 @@
 
 /**
- * ATMSCommunicator handles communication between the CAD Simulator and the 
- * ATMS Server.  The funcationality provided includes querying the current time 
- * on the ATMS server and replacing images on the ATMS to model 
- * traffic flow changes.  The ATMSCommunicator uses the plink.exe external 
- * application to establish an SSH communication with the ATMS server, which is
- * used to execute commands remotely.  
- * 
+ * ATMSCommunicator handles communication between the CAD Simulator and the ATMS
+ * Server. The funcationality provided includes querying the current time on the
+ * ATMS server and replacing images on the ATMS to model traffic flow changes.
+ * The ATMSCommunicator uses the plink.exe external application to establish an
+ * SSH communication with the ATMS server, which is used to execute commands
+ * remotely.
+ *
  * @author Matthew Cechini
  * @version
  */
-public class ATMSCommunicator {
-    
-    /** Connection user name. */
+public class ATMSCommunicator
+{
+
+    /**
+     * Connection user name.
+     */
     protected String username;
-    
-    /** Connection password. */
+    /**
+     * Connection password.
+     */
     protected String password;
-    
-    /** ATMS Server Host name. */
+    /**
+     * ATMS Server Host name.
+     */
     protected String viewerHost;
-    
-    /** Absolute directory path for images. */
+    /**
+     * Absolute directory path for images.
+     */
     protected String image_dir;
-    
-    /** Base plink command string. */
+    /**
+     * Base plink command string.
+     */
     protected String plinkBaseCMD;
-    
-    /** Constructor. */
-    public ATMSCommunicator(String host, String user, String pwd, String dir) {
+    protected String remoteShellCmd;
+
+    /**
+     * Constructor.
+     */
+    public ATMSCommunicator(String host, String user, String pwd, String dir)
+    {
         viewerHost = host;
-        username   = user;
-        password   = pwd;
-        image_dir  = dir;
-        
-        plinkBaseCMD = "plink -l " + username + " -pw " + password + " " + viewerHost + " ";        
+        username = user;
+        password = pwd;
+        image_dir = dir;
+        String osname = System.getProperty("os.name");
+        if (osname.startsWith("Windows"))
+        {
+            remoteShellCmd = "plink -l " + username + " -pw " + password + " " + viewerHost + " \"date\"";
+        }
+        else
+        {
+            remoteShellCmd = "date"; //sshpass -p " + password + " " + "ssh -t -l " + username + viewerHost + " date &";
+        }
     }
-    
+
     /**
-     * Get the current ATMS server time as the number of seconds since Jan 1, 1970.
-     * 
+     * Get the current ATMS server time as the number of seconds since Jan 1,
+     * 1970.
+     *
      * @return Current time in seconds.
      * @throws RemoteException If there is an exception in RMI communication.
-     */ 
-    public long getCurrentTime() throws Exception {
-        
+     */
+    public long getCurrentTime() throws Exception
+    {
+
         Calendar currentCal = Calendar.getInstance();
 
-        Process timeProc = Runtime.getRuntime().exec(plinkBaseCMD + " \"date\"");
+        Process timeProc = Runtime.getRuntime().exec(remoteShellCmd);
         timeProc.waitFor();
-        
-        if(timeProc.exitValue() == 0) {
+//        System.out.println("timeProc exit = " + timeProc.exitValue());
+//        byte[] procBytes = new byte[timeProc.getInputStream().available()];
+//        timeProc.getInputStream().read(procBytes);
+//        String returnString = new String(procBytes);
+//        System.out.println("timeProc returned: " + returnString);
+
+        if (timeProc.exitValue() == 0)
+        {
             String tempToken = null;
             byte[] dateBytes = new byte[timeProc.getInputStream().available()];
             timeProc.getInputStream().read(dateBytes);
-            
+
             StringTokenizer spaceTok = new StringTokenizer(new String(dateBytes), " ");
-            while(spaceTok.hasMoreTokens()) {
+            while (spaceTok.hasMoreTokens())
+            {
                 tempToken = spaceTok.nextToken();
-                
-                if(tempToken.indexOf(":") != -1) {
+
+                if (tempToken.indexOf(":") != -1)
+                {
                     StringTokenizer colonTok = new StringTokenizer(new String(tempToken), ":");
-                    
+
                     currentCal.set(Calendar.HOUR, Integer.parseInt(colonTok.nextToken()));
                     currentCal.set(Calendar.MINUTE, Integer.parseInt(colonTok.nextToken()));
                     currentCal.set(Calendar.SECOND, Integer.parseInt(colonTok.nextToken()));
-                    
-                    System.out.println("Time retreieved from ATRMS server: " + 
-                            DateFormat.getDateTimeInstance().format(currentCal.getTime()));                                 
-                    
+
+                    System.out.println("Time retreieved from ATRMS server: "
+                            + DateFormat.getDateTimeInstance().format(currentCal.getTime()));
+
                 }
             }
-        }       
-        
-        return currentCal.getTimeInMillis();        
+        }
+
+        return currentCal.getTimeInMillis();
 
     }
 
     /**
-     * Show a new image for an ATMS camera.  The ATMS camera files are named
-     * <ATMS_Camera_ID>.xpm.  If a camera file exists, delete it.  Then copy
-     * the parameter file name to <ATMS_Camera_ID>.xpm.  If the camera ID or 
-     * new file does not exist, throw an exception.     
-     * 
+     * Show a new image for an ATMS camera. The ATMS camera files are named
+     * <ATMS_Camera_ID>.xpm. If a camera file exists, delete it. Then copy the
+     * parameter file name to <ATMS_Camera_ID>.xpm. If the camera ID or new file
+     * does not exist, throw an exception.
+     *
      * @param ATMS_cameraID ATMS indexed camera ID.
      * @param fileName Filename to show.
      * @throws RemoteException If there is an exception in RMI communication.
-     */ 
-    public void showImage(Integer ATMS_cameraID, String fileName) throws RemoteException {
-        
+     */
+    public void showImage(Integer ATMS_cameraID, String fileName) throws RemoteException
+    {
+
         System.out.println("Showing CameraID " + ATMS_cameraID + ", with filename: " + fileName);
         /*
-        Process imageProc = Runtime.getRuntime().exec(plinkBaseCMD + "\"ls " + image_dir + "/cctvImage" + ATMS_cameraID + ".xpm\"");
-        imageProc.waitFor();
-        
-        if(imageProc.exitValue() != 0) {
-            throw new Exception(image_dir + "/cctvImage" + ATMS_cameraID + ".xpm does not exist");
-        }
-            
-        imageProc = Runtime.getRuntime().exec(plinkBaseCMD + "\"ls " + image_dir + "/" + fileName + ".xpm\"");
-        imageProc.waitFor();
+         Process imageProc = Runtime.getRuntime().exec(plinkBaseCMD + "\"ls " + image_dir + "/cctvImage" + ATMS_cameraID + ".xpm\"");
+         imageProc.waitFor();
 
-        if(imageProc.exitValue() != 0) {
-            throw new Exception(image_dir + "/" + fileName + ".xpm does not exist");
-        }
-    
-        imageProc = Runtime.getRuntime().exec(plinkBaseCMD + "\"rm " + image_dir + "/cctvImage" + ATMS_cameraID + ".xpm\"");
-        imageProc.waitFor();
-        
-        imageProc = Runtime.getRuntime().exec(plinkBaseCMD + "\"cp " + image_dir + "/" + fileName + ".xpm" + 
-                                  "   " + image_dir + "/" + "cctvImage" + ATMS_cameraID + ".xpm\"");        
-        imageProc.waitFor();
-        */
-        
-    }   
+         if(imageProc.exitValue() != 0) {
+         throw new Exception(image_dir + "/cctvImage" + ATMS_cameraID + ".xpm does not exist");
+         }
+
+         imageProc = Runtime.getRuntime().exec(plinkBaseCMD + "\"ls " + image_dir + "/" + fileName + ".xpm\"");
+         imageProc.waitFor();
+
+         if(imageProc.exitValue() != 0) {
+         throw new Exception(image_dir + "/" + fileName + ".xpm does not exist");
+         }
+
+         imageProc = Runtime.getRuntime().exec(plinkBaseCMD + "\"rm " + image_dir + "/cctvImage" + ATMS_cameraID + ".xpm\"");
+         imageProc.waitFor();
+
+         imageProc = Runtime.getRuntime().exec(plinkBaseCMD + "\"cp " + image_dir + "/" + fileName + ".xpm" +
+         "   " + image_dir + "/" + "cctvImage" + ATMS_cameraID + ".xpm\"");
+         imageProc.waitFor();
+         */
+
+    }
 }
Index: /trunk/src/tmcsim/cadsimulator/managers/MediaManager.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/managers/MediaManager.java	(revision 2)
+++ /trunk/src/tmcsim/cadsimulator/managers/MediaManager.java	(revision 44)
@@ -19,5 +19,5 @@
 import tmcsim.cadsimulator.videocontrol.DVDStatusUpdate;
 import tmcsim.cadsimulator.videocontrol.DVDTitleUpdate;
-import tmcsim.cadsimulator.viewer.CADSimulatorViewer;
+import tmcsim.cadsimulator.viewer.model.CADSimulatorModel;
 import tmcsim.common.CCTVDirections;
 import tmcsim.common.CCTVInfo;
@@ -73,6 +73,6 @@
     private StillImagesDB theImage_DB = null;
     
-    /** Reference to the CADSimulatorViewer. */
-    private CADSimulatorViewer theViewer;
+    /** Reference to the CADSimulatorModel. */
+    private CADSimulatorModel theModel;
 
     /** Properties object for the Media portion of the CAD. */
@@ -90,9 +90,9 @@
      */
     public MediaManager(String propertiesFile, ATMSManager theATMSManager, 
-            CADSimulatorViewer viewer) {
+            CADSimulatorModel model) {
         theDVD_DB   = new DVDPlayerDB();        
         theImage_DB = new StillImagesDB();
         
-        theViewer = viewer;
+        theModel = model;
 
         try {
@@ -166,8 +166,8 @@
                         ((DVDStatusUpdate)arg).exception);
             }
-            theViewer.updateDVDStatus((DVDStatusUpdate)arg);
+            theModel.updateDVDStatus((DVDStatusUpdate)arg);
         }
         else if(arg instanceof DVDTitleUpdate) {
-            theViewer.updateDVDTitle((DVDTitleUpdate)arg);
+            theModel.updateDVDTitle((DVDTitleUpdate)arg);
         }
     }
Index: /trunk/src/tmcsim/cadsimulator/managers/ParamicsSimulationManager.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/managers/ParamicsSimulationManager.java	(revision 20)
+++ /trunk/src/tmcsim/cadsimulator/managers/ParamicsSimulationManager.java	(revision 44)
@@ -6,5 +6,4 @@
 import java.util.logging.Level;
 import java.util.logging.Logger;
-
 import tmcsim.cadmodels.CMSInfo;
 import tmcsim.cadsimulator.Coordinator;
@@ -13,7 +12,7 @@
 import tmcsim.cadsimulator.paramicscontrol.ParamicsIncidentWriter;
 import tmcsim.cadsimulator.paramicscontrol.ParamicsStatusReader;
+import tmcsim.common.CADEnums.PARAMICS_STATUS;
 import tmcsim.common.SimulationException;
 import tmcsim.common.XMLIncident;
-import tmcsim.common.CADEnums.PARAMICS_STATUS;
 
 /**
@@ -22,169 +21,195 @@
  * Upon construction all ParamicsReaders and ParamicsWriters are initialized
  * with data parsed from the Properties file. When a connection is established
- * the ParamicsStatusReader is registered to read Paramics Status updates.  
- * These updates are received through the updateParamicsStatus() method, which 
- * notifies the Coordinator of the new status.  The loadParamicsNetwork() must 
- * be called to register the ParamicsIncidentWriter which will write the
- * information to cause Paramics to begin loading a traffic network.  When the
+ * the ParamicsStatusReader is registered to read Paramics Status updates. These
+ * updates are received through the updateParamicsStatus() method, which
+ * notifies the Coordinator of the new status. The loadParamicsNetwork() must be
+ * called to register the ParamicsIncidentWriter which will write the
+ * information to cause Paramics to begin loading a traffic network. When the
  * status becomes LOADED, the ParamicsCameraStatusReader is registered and
- * begins reading.  All camera speed updates are received through the
- * updateCameraInfo() method.  The startSimulation(), resetSimulation(), and 
- * sendIncidentUpdate() methods are used to control the flow of Incident 
- * update information to Paramics.  The updateIncident() and updateDiversion() 
- * methods are used to update the information that is sent to Paramics.
- *  
- *      
+ * begins reading. All camera speed updates are received through the
+ * updateCameraInfo() method. The startSimulation(), resetSimulation(), and
+ * sendIncidentUpdate() methods are used to control the flow of Incident update
+ * information to Paramics. The updateIncident() and updateDiversion() methods
+ * are used to update the information that is sent to Paramics.
+ *
+ *
  * @see PARAMICS_STATUS
  * @author Matthew Cechini
  * @version
  */
-public class ParamicsSimulationManager {
-
-    /**  Error logger.  */
+public class ParamicsSimulationManager
+{
+
+    /**
+     * Error logger.
+     */
     private static Logger paramLogger = Logger.getLogger("tmcsim.cadsimulator.paramicscontrol");
-    
+
     /**
      * Enumeration containing property names for Properties parsing.
+     *
      * @author Matthew Cechini
      */
-    private static enum PROPERTIES {
-        PARAMICS_HOST        ("ParamicsCommHost"),
-        PARAMICS_PORT        ("ParamicsCommPort"),
-        INCIDENT_UPDATE_INT  ("IncidentUpdateInterval"),
-        INCIDENT_UPDATE_FILE ("IncidentUpdateFile"),
-        PARAMICS_STATUS_INT  ("ParamicsStatusInterval"),
-        PARAMICS_STATUS_FILE ("ParamicsStatusFile"),
-        CAMERA_STATUS_INT    ("CameraStatusInterval"),
-        CAMERA_STATUS_FILE   ("CameraStatusFile");
-        
+    private static enum PROPERTIES
+    {
+
+        PARAMICS_HOST("ParamicsCommHost"),
+        PARAMICS_PORT("ParamicsCommPort"),
+        INCIDENT_UPDATE_INT("IncidentUpdateInterval"),
+        INCIDENT_UPDATE_FILE("IncidentUpdateFile"),
+        PARAMICS_STATUS_INT("ParamicsStatusInterval"),
+        PARAMICS_STATUS_FILE("ParamicsStatusFile"),
+        CAMERA_STATUS_INT("CameraStatusInterval"),
+        CAMERA_STATUS_FILE("CameraStatusFile");
         String name;
-        
-        private PROPERTIES(String n) {
+
+        private PROPERTIES(String n)
+        {
             name = n;
         }
     };
-    
-    /** ParamicsCommunicator Object used for communication. */
+    /**
+     * ParamicsCommunicator Object used for communication.
+     */
     private ParamicsCommunicator theCommunicator;
-
-    /** Reference to the Coordinator Object. */
+    /**
+     * Reference to the Coordinator Object.
+     */
     private Coordinator theCoordinator;
-
-    /** Reference to the MediaManager Object. */
+    /**
+     * Reference to the MediaManager Object.
+     */
     private MediaManager theMediaMgr;
-    
-    /** ParamicsIncidentWriter used to send incident updates to Paramics. */
-    private ParamicsIncidentWriter paramicsIncidentWriter;    
-    
-    /** ParamicsStatusReader used to read status information from Paramics. */
+    /**
+     * ParamicsIncidentWriter used to send incident updates to Paramics.
+     */
+    private ParamicsIncidentWriter paramicsIncidentWriter;
+    /**
+     * ParamicsStatusReader used to read status information from Paramics.
+     */
     private ParamicsStatusReader paramicsStatusReader;
-    
-    /** ParamicsCameraStatusReader used to read speed information from Paramics. */
+    /**
+     * ParamicsCameraStatusReader used to read speed information from Paramics.
+     */
     private ParamicsCameraStatusReader paramicsCameraStatusReader;
-
-    /** Properties file. */
+    /**
+     * Properties file.
+     */
     private Properties paramicsProperties;
-    
-    
-    /**
-     * Constructor.  Loads the Properties file and initializes all Paramics
+
+    /**
+     * Constructor. Loads the Properties file and initializes all Paramics
      * Writers and Readers with the parsed data.
-     * 
+     *
      * @param propertiesFile Target file path of properties file.
      * @param coor Coordinator Object.
      * @param mediaMgr MediaManager Object.
      */
-    public ParamicsSimulationManager(String propertiesFile, Coordinator coor, MediaManager mediaMgr) {
-        
-        try {
+    public ParamicsSimulationManager(String propertiesFile, Coordinator coor, MediaManager mediaMgr)
+    {
+
+        try
+        {
             paramicsProperties = new Properties();
             paramicsProperties.load(new FileInputStream(propertiesFile));
-            
+
             theCoordinator = coor;
-            theMediaMgr    = mediaMgr;
-                  
-            theCommunicator = new ParamicsCommunicator(this, 
+            theMediaMgr = mediaMgr;
+
+            theCommunicator = new ParamicsCommunicator(this,
                     paramicsProperties.getProperty(PROPERTIES.PARAMICS_HOST.name),
                     Integer.parseInt(paramicsProperties.getProperty(
-                            PROPERTIES.PARAMICS_PORT.name).trim()));
-                    
+                    PROPERTIES.PARAMICS_PORT.name).trim()));
+
             paramicsIncidentWriter = new ParamicsIncidentWriter(Integer.parseInt(
-                    paramicsProperties.getProperty(PROPERTIES.INCIDENT_UPDATE_INT.name).trim()));  
-            paramicsIncidentWriter.writerID   = theCommunicator.nextID();
+                    paramicsProperties.getProperty(PROPERTIES.INCIDENT_UPDATE_INT.name).trim()));
+            paramicsIncidentWriter.writerID = theCommunicator.nextID();
             paramicsIncidentWriter.targetFile = paramicsProperties.getProperty(
-                    PROPERTIES.INCIDENT_UPDATE_FILE.name);      
-            
+                    PROPERTIES.INCIDENT_UPDATE_FILE.name);
+
             paramicsStatusReader = new ParamicsStatusReader(this);
-            paramicsStatusReader.readerID   = theCommunicator.nextID();
-            paramicsStatusReader.interval   = paramicsProperties.getProperty(
+            paramicsStatusReader.readerID = theCommunicator.nextID();
+            paramicsStatusReader.interval = paramicsProperties.getProperty(
                     PROPERTIES.PARAMICS_STATUS_INT.name).trim();
             paramicsStatusReader.targetFile = paramicsProperties.getProperty(
                     PROPERTIES.PARAMICS_STATUS_FILE.name);
-            
+
             paramicsCameraStatusReader = new ParamicsCameraStatusReader(this);
-            paramicsCameraStatusReader.readerID   = theCommunicator.nextID();
-            paramicsCameraStatusReader.interval   = paramicsProperties.getProperty(
+            paramicsCameraStatusReader.readerID = theCommunicator.nextID();
+            paramicsCameraStatusReader.interval = paramicsProperties.getProperty(
                     PROPERTIES.CAMERA_STATUS_INT.name).trim();
             paramicsCameraStatusReader.targetFile = paramicsProperties.getProperty(
-                    PROPERTIES.CAMERA_STATUS_FILE.name);    
-        }
-        catch (Exception e) {
-            paramLogger.logp(Level.SEVERE, "ParamicsSimulationManager", 
+                    PROPERTIES.CAMERA_STATUS_FILE.name);
+        } catch (Exception e)
+        {
+            paramLogger.logp(Level.SEVERE, "ParamicsSimulationManager",
                     "Constructor", "Exception in parsing properties file.", e);
         }
-        
-    }
-   
+
+    }
+
     /**
      * Returns whether a connection exists to the remote ParamicsCommunicator.
+     *
      * @return true if a connection exists, false if not.
      */
-    public boolean isConnected() {
+    public boolean isConnected()
+    {
         return theCommunicator.isConnected();
     }
-    
+
     /**
      * Returns the integer Network ID that has been loaded into Paramics.
+     *
      * @return Network ID.
      */
-    public int getParamicsNetworkLoaded() {
+    public int getParamicsNetworkLoaded()
+    {
         return paramicsStatusReader.getNetworkID();
     }
-    
+
     /**
      * Returns the current status of the Paramics traffic modeler.
-     * @return Current PARAMICS_STATUS 
-     */
-    public PARAMICS_STATUS getParamicsStatus() {
+     *
+     * @return Current PARAMICS_STATUS
+     */
+    public PARAMICS_STATUS getParamicsStatus()
+    {
         return paramicsStatusReader.getStatus();
     }
-    
+
     /**
      * Updates the ParamicsIncidentWriter with new Incident information.
+     *
      * @param xmlInc Updated Incident information.
      */
-    public void updateIncident(XMLIncident xmlInc) {
+    public void updateIncident(XMLIncident xmlInc)
+    {
         paramicsIncidentWriter.updateIncident(xmlInc);
     }
-    
+
     /**
      * Updates the ParamicsIncidentWriter with the new Diversion information.
+     *
      * @param theDiversion Updated diversion information.
      */
-    public void updateDiversion(CMSInfo theDiversion) {
+    public void updateDiversion(CMSInfo theDiversion)
+    {
         paramicsIncidentWriter.updateDiversion(theDiversion);
     }
-    
+
     /**
      * Notifies the ParamicsIncidentWriter to start the simulation.
      */
-    public void startSimulation() {
+    public void startSimulation()
+    {
         paramicsIncidentWriter.startSimulation();
     }
-    
+
     /**
      * Notifies the ParamicsIncidentWriter to reset the simulation.
      */
-    public void resetSimulation() {
+    public void resetSimulation()
+    {
         paramicsIncidentWriter.resetSimulation();
     }
@@ -192,106 +217,114 @@
     /**
      * Notifies the ParamicsIncidentWriter to send an Incident update.
+     *
      * @param currentSimTime Current simulation time (in seconds).
      */
-    public void sendIncidentUpdate(long currentSimTime) {
+    public void sendIncidentUpdate(long currentSimTime)
+    {
         paramicsIncidentWriter.sendUpdate(currentSimTime);
     }
-    
-    /**
-     * Establish a connection to the remote ParamicsCommunicator.  Register
-     * the ParamicsStatusReader and update the current status to CONNECTED.
-     * If an exception occurs in connecting to the ParamicsCommunicator,
-     * update the current status to UNREACHABLE.
-     */
-    public void connectToParamics() {
-        try {           
-            theCommunicator.connect();          
+
+    /**
+     * Establish a connection to the remote ParamicsCommunicator. Register the
+     * ParamicsStatusReader and update the current status to CONNECTED. If an
+     * exception occurs in connecting to the ParamicsCommunicator, update the
+     * current status to UNREACHABLE.
+     */
+    public void connectToParamics()
+    {
+        try
+        {
+            theCommunicator.connect();
             theCommunicator.registerReader(paramicsStatusReader);
-            
+
             updateParamicsStatus(PARAMICS_STATUS.CONNECTED);
-        }
-        catch (IOException ioe) {
-            paramLogger.logp(Level.SEVERE, "Coordinator", "connectToParamics", 
+        } catch (IOException ioe)
+        {
+            paramLogger.logp(Level.SEVERE, "Coordinator", "connectToParamics",
                     "Communication error in connecting to Paramics.", ioe);
 
             updateParamicsStatus(PARAMICS_STATUS.UNREACHABLE);
-        }       
-    }
-
-    /**
-     * Close the connection to the remote ParamicsCommunicator.  Unregister
-     * all Readers and Wrtiers from the ParamicsCommunicator.  Reset the status
-     * information in the ParamicsStatusReader.  Update the current status to 
+        }
+    }
+
+    /**
+     * Close the connection to the remote ParamicsCommunicator. Unregister all
+     * Readers and Wrtiers from the ParamicsCommunicator. Reset the status
+     * information in the ParamicsStatusReader. Update the current status to
      * DISCONNECTED.
      */
-    public void disconnectFromParamics() { 
-        
+    public void disconnectFromParamics()
+    {
+
         theCommunicator.disconnect();
         theCommunicator.unregisterReader(paramicsStatusReader);
-        theCommunicator.unregisterWriter(paramicsIncidentWriter);   
+        theCommunicator.unregisterWriter(paramicsIncidentWriter);
         theCommunicator.unregisterReader(paramicsCameraStatusReader);
-                    
+
         paramicsStatusReader.resetStatusInfo();
 
         updateParamicsStatus(PARAMICS_STATUS.DISCONNECTED);
     }
-    
-    /**
-     * Updates the current paramics status.  If the new status is LOADED,
-     * then notify the ParamicsIncidentWriter that the network has been loaded
-     * and register the ParamicsCameraStatusReader with the ParamicsCommunicator.
+
+    /**
+     * Updates the current paramics status. If the new status is LOADED, then
+     * notify the ParamicsIncidentWriter that the network has been loaded and
+     * register the ParamicsCameraStatusReader with the ParamicsCommunicator.
      * Notify the Coordinator of all Paramics status updates.
      *
-     * @param  newStatus New Paramics status.
-     */ 
-    public void updateParamicsStatus(PARAMICS_STATUS newStatus) {
-                        
+     * @param newStatus New Paramics status.
+     */
+    public void updateParamicsStatus(PARAMICS_STATUS newStatus)
+    {
+
         //the network has finished loading
-        if(newStatus == PARAMICS_STATUS.LOADED) {
-        
+        if (newStatus == PARAMICS_STATUS.LOADED)
+        {
+
             paramicsIncidentWriter.networkLoaded();
-        
-            theCommunicator.registerReader(paramicsCameraStatusReader);                     
-        }
-        else if(newStatus == PARAMICS_STATUS.DROPPED) {
-            paramLogger.logp(Level.WARNING, "Coordinator", "updateParamicsStatus", 
+
+            theCommunicator.registerReader(paramicsCameraStatusReader);
+
+        } else if (newStatus == PARAMICS_STATUS.DROPPED)
+        {
+            paramLogger.logp(Level.WARNING, "Coordinator", "updateParamicsStatus",
                     "Connection to Paramics has been dropped.");
-        }else
-        {
-            paramLogger.logp(Level.INFO, "ParamicsSimulationManager", "updateParamicsStatus",
-                    "Received: " + newStatus);
-        }
-        
-        theCoordinator.setParamicsStatus(newStatus);        
-
-    } 
-    
-    /**
-     * If a connection has been made, register the ParamicsIncidentWriter
-     * and use it to notify Paramics of the Network ID to load.
-     * 
+        }
+
+        theCoordinator.setParamicsStatus(newStatus);
+
+    }
+
+    /**
+     * If a connection has been made, register the ParamicsIncidentWriter and
+     * use it to notify Paramics of the Network ID to load.
+     *
      * @param networkID Network ID to load.
-     * @throws SimulationException if a connection has not been made to the 
-     *         remote ParamicsCommunicator.
-     */
-    public void loadParamicsNetwork(int networkID) throws SimulationException {
-            
-        if(theCommunicator.isConnected()) {
+     * @throws SimulationException if a connection has not been made to the
+     * remote ParamicsCommunicator.
+     */
+    public void loadParamicsNetwork(int networkID) throws SimulationException
+    {
+
+        if (theCommunicator.isConnected())
+        {
             theCommunicator.registerWriter(paramicsIncidentWriter);
             paramicsIncidentWriter.loadNetwork(networkID);
-        }
-        else 
+        } else
+        {
             throw new SimulationException(SimulationException.PARAMICS_NOT_CONNECTED);
-    }
-    
-    /**
-     * Receive updated camera speed information. Notify the MediaManager with 
-     * the updated data. 
-     * 
+        }
+    }
+
+    /**
+     * Receive updated camera speed information. Notify the MediaManager with
+     * the updated data.
+     *
      * @param cameraID CCTV camera ID
      * @param avgSpeed_NE Average speed of traffic flowing N or E
      * @param avgSpeed_SW Average speed of traffic flowing S or W
      */
-    public void updateCameraInfo(Integer cameraID, float avgSpeed_NE, float avgSpeed_SW) {
+    public void updateCameraInfo(Integer cameraID, float avgSpeed_NE, float avgSpeed_SW)
+    {
         theMediaMgr.updateCameraInfo(cameraID, avgSpeed_NE, avgSpeed_SW);
     }
Index: /trunk/src/tmcsim/cadsimulator/viewer/SimulationStatusPanel.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/viewer/SimulationStatusPanel.java	(revision 36)
+++ /trunk/src/tmcsim/cadsimulator/viewer/SimulationStatusPanel.java	(revision 44)
@@ -5,8 +5,5 @@
 import java.awt.Dimension;
 import java.awt.Font;
-import java.util.logging.Handler;
-import java.util.logging.Level;
-import java.util.logging.LogRecord;
-import java.util.logging.Logger;
+import java.util.Observable;
 import javax.swing.BorderFactory;
 import javax.swing.Box;
@@ -19,4 +16,5 @@
 import javax.swing.border.EtchedBorder;
 import javax.swing.border.TitledBorder;
+import tmcsim.cadsimulator.viewer.model.CADSimulatorStatus;
 import tmcsim.common.CADEnums.PARAMICS_STATUS;
 import tmcsim.common.CADEnums.SCRIPT_STATUS;
@@ -37,5 +35,5 @@
  * </ul>
  *
- * @author Matthew Cechini
+ * @author Matthew Cechini, jdalbey
  * @version
  */
@@ -45,39 +43,33 @@
 
     /**
-     * Logging Handler to listen for Information and Error messages logged for
-     * the CAD Simulator. Received LogRecords are displayed in the info or error
-     * message Text Area.
-     *
-     * @author Matthew Cechini
-     */
-    private class SimulatorErrorHandler extends Handler
-    {
-
-        public void close() throws SecurityException
-        {
-        }
-
-        public void flush()
-        {
-        }
-
-        public void publish(LogRecord rec)
-        {
-            StringBuffer msgBuffer = new StringBuffer();
-
-            msgBuffer.append(rec.getSourceClassName() + "."
-                    + rec.getSourceMethodName() + " = "
-                    + rec.getMessage());
-
-            if (rec.getLevel() == Level.INFO)
-            {
-                infoMessagesTA.setText(infoMessagesTA.getText()
-                        + msgBuffer.toString() + "\n");
-            } else
-            {
-                errorMessagesTA.setText(errorMessagesTA.getText()
-                        + msgBuffer.toString() + "\n");
-            }
-        }
+     * Refresh this view
+     *
+     * @param obs the Observable we are watching
+     */
+    public void refresh(Observable obs)
+    {
+        CADSimulatorStatus status = (CADSimulatorStatus) obs;
+        termConnectedTF.setText(String.valueOf(status.getNumClients()));
+        String yesno = "No";
+        // Should we show yes or no?
+        if (status.isSimManagerConnected())
+        {
+            yesno = "Yes";
+        }
+        managerConnectedTF.setText(yesno);
+        simulationClockLabel.setText(status.getCurrentTime());
+        setScriptStatus(status.getScriptStatus());
+        setParamicsStatus(status.getParamicsStatus());
+
+        String netText = status.getParmicsNetworkID();
+        if (netText.length() == 0)
+        {
+            netText = "None";
+        }
+        setParamicsNetworkLoaded(netText);
+
+        String msgOut = status.getInfoMessages();
+        infoMessagesTA.setText(msgOut);
+        errorMessagesTA.setText(status.getErrorMessages());
     }
     /**
@@ -85,8 +77,4 @@
      */
     private int numClientsConnected = 0;
-    /**
-     * Logging ErrorHandler.
-     */
-    private SimulatorErrorHandler errorHandler;
 
     /**
@@ -102,96 +90,14 @@
         initMessagesPanes();
 
-        errorHandler = new SimulatorErrorHandler();
-        Logger.getLogger("tmcsim.cadsimulator").addHandler(errorHandler);
-
-        CADSimulatorViewerBox = Box.createVerticalBox();
-        CADSimulatorViewerBox.add(simulationTimeAndStatusBox);
-        CADSimulatorViewerBox.add(additionalInfoBox);
-        CADSimulatorViewerBox.add(infoMessagesPane);
-        CADSimulatorViewerBox.add(errorMessagesPane);
-
-        add(CADSimulatorViewerBox);
-    }
-
-    /**
-     * Method is called when a CAD Client disconnects from the CAD Simulator.
-     * The displayed number of connected clients is incremented by one.
-     */
-    public void connectClient()
-    {
-
-        numClientsConnected++;
-
-        termConnectedTF.setText(String.valueOf(numClientsConnected));
-    }
-
-    /**
-     * Method is called when a CAD Client disconnects from the CAD Simulator.
-     * The displayed number of connected clients is decremented by one.
-     */
-    public void disconnectClient()
-    {
-
-        if (numClientsConnected > 0)
-        {
-            numClientsConnected--;
-        }
-
-        termConnectedTF.setText(String.valueOf(numClientsConnected));
-    }
-
-    /**
-     * Method is called when Simulation Manager connects or disconnects.
-     *
-     * @param connection True if simulation manager is connected, false if not.
-     */
-    public void setSimManagerStatus(boolean connection)
-    {
-
-        if (connection)
-        {
-            managerConnectedTF.setText("Yes");
-        } else
-        {
-            managerConnectedTF.setText("No");
-        }
-
-    }
-
-    /**
-     * Method called to convert current simulation time (parameter long value)
-     * to a string of format H:MM:SS. Time is then updated on GUI.
-     *
-     * @param seconds Long value of current time
-     */
-    public void setTime(long seconds)
-    {
-        String time = new String();
-        long timeSegment;
-
-        timeSegment = seconds / 3600;
-        time += String.valueOf(timeSegment) + ":";
-
-        seconds = seconds % 3600;
-
-        timeSegment = seconds / 60;
-        if (timeSegment < 10)
-        {
-            time += "0";
-        }
-
-        time += String.valueOf(timeSegment) + ":";
-        seconds = seconds % 60;
-
-        timeSegment = seconds;
-        if (timeSegment < 10)
-        {
-            time += "0";
-        }
-
-        time += String.valueOf(timeSegment);
-
-        simulationClockLabel.setText(time);
-
+        //  errorHandler = new SimulatorErrorHandler();
+        //  Logger.getLogger("tmcsim.cadsimulator").addHandler(errorHandler);
+
+        cadSimulatorViewerBox = Box.createVerticalBox();
+        cadSimulatorViewerBox.add(simulationTimeAndStatusBox);
+        cadSimulatorViewerBox.add(additionalInfoBox);
+        cadSimulatorViewerBox.add(infoMessagesPane);
+        cadSimulatorViewerBox.add(errorMessagesPane);
+
+        add(cadSimulatorViewerBox);
     }
 
@@ -206,8 +112,10 @@
     protected void displayError(String errorMessage)
     {
+        // Do we clear or append?
         if (errorMessage == null)
         {
             errorMessagesTA.setText("");
-        } else
+        }
+        else
         {
             errorMessagesTA.append(errorMessage + "\n");
@@ -253,7 +161,7 @@
      * </table>
      */
-    public void setScriptStatus(SCRIPT_STATUS newStatus)
-    {
-
+    private void setScriptStatus(SCRIPT_STATUS newStatus)
+    {
+        // Display text based on status value
         switch (newStatus)
         {
@@ -291,7 +199,7 @@
      * or dropped.
      */
-    public void setParamicsStatus(PARAMICS_STATUS newStatus)
-    {
-
+    private void setParamicsStatus(PARAMICS_STATUS newStatus)
+    {
+        // Display text based on status value
         switch (newStatus)
         {
@@ -310,5 +218,5 @@
      * @param networkID Unique ID for Paramics network that has been loaded.
      */
-    public void setParamicsNetworkLoaded(String networkID)
+    private void setParamicsNetworkLoaded(String networkID)
     {
         networkLoadedTF.setText(networkID);
@@ -325,4 +233,5 @@
         simulationStatus = new JLabel("Simulation Status");
         simulationStatusText = new JLabel("No Script");
+        simulationStatusText.setName("simulationStatusText");
 
         simulationTime.setLayout(new BorderLayout());
@@ -470,5 +379,5 @@
     private Box paramicsConnectedBox;
     private Box networkLoadedBox;
-    private Box CADSimulatorViewerBox;
+    private Box cadSimulatorViewerBox;
     private Box simulationTimeAndStatusBox;
     private Box simulationStatusBox;
Index: /trunk/src/tmcsim/cadsimulator/viewer/CADSimulatorViewer.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/viewer/CADSimulatorViewer.java	(revision 36)
+++ /trunk/src/tmcsim/cadsimulator/viewer/CADSimulatorViewer.java	(revision 44)
@@ -6,4 +6,9 @@
 import java.awt.event.KeyEvent;
 import java.awt.event.WindowEvent;
+import java.io.IOException;
+import java.util.Observable;
+import java.util.Properties;
+import java.util.logging.Level;
+import java.util.logging.Logger;
 import javax.swing.JFrame;
 import javax.swing.JMenu;
@@ -13,10 +18,8 @@
 import javax.swing.JTabbedPane;
 import javax.swing.KeyStroke;
-import tmcsim.cadsimulator.videocontrol.DVDStatusUpdate;
-import tmcsim.cadsimulator.videocontrol.DVDTitleUpdate;
 import tmcsim.cadsimulator.viewer.actions.ExitAction;
-import tmcsim.common.CADEnums.PARAMICS_STATUS;
-import tmcsim.common.CADEnums.SCRIPT_STATUS;
-import tmcsim.common.RevisionNumber;
+import tmcsim.cadsimulator.viewer.model.CADMediaStatus;
+import tmcsim.cadsimulator.viewer.model.CADSimulatorStatus;
+import tmcsim.interfaces.CADViewer;
 
 /**
@@ -30,5 +33,5 @@
  */
 @SuppressWarnings("serial")
-public class CADSimulatorViewer extends JFrame
+public class CADSimulatorViewer extends JFrame implements CADViewer
 {
 
@@ -45,11 +48,12 @@
      */
     private ConfigStatusPanel configPanel;
+
     /**
      * Constructor.
      */
-    
     public CADSimulatorViewer()
     {
-        super("CAD Simulator");
+        super();
+        setTitle("CAD Simulator " + getAppVersion());
 
         initComponents();
@@ -57,73 +61,27 @@
 
     /**
-     * @see SimulationStatusPanel
+     * Read the version number from the application properties. The file
+     * 'application.properties' is generated by build.xml.
+     *
+     * @return a version string obtained from application.properties file, or
+     * "Version: unknown" if an IOerror prevents us from reading the file.
      */
-    public void connectClient()
+    private String getAppVersion()
     {
-        simulationPanel.connectClient();
-    }
-
-    /**
-     * @see SimulationStatusPanel
-     */
-    public void disconnectClient()
-    {
-        simulationPanel.disconnectClient();
-    }
-
-    /**
-     * @see SimulationStatusPanel
-     */
-    public void setSimManagerStatus(boolean connection)
-    {
-        simulationPanel.setSimManagerStatus(connection);
-    }
-
-    /**
-     * @see SimulationStatusPanel
-     */
-    public void setTime(long seconds)
-    {
-        simulationPanel.setTime(seconds);
-    }
-
-    /**
-     * @see SimulationStatusPanel
-     */
-    public void setScriptStatus(SCRIPT_STATUS newStatus)
-    {
-        simulationPanel.setScriptStatus(newStatus);
-    }
-
-    /**
-     * @see SimulationStatusPanel
-     */
-    public void setParamicsStatus(PARAMICS_STATUS newStatus)
-    {
-        simulationPanel.setParamicsStatus(newStatus);
-    }
-
-    /**
-     * @see SimulationStatusPanel
-     */
-    public void setParamicsNetworkLoaded(String networkID)
-    {
-        simulationPanel.setParamicsNetworkLoaded(networkID);
-    }
-
-    /**
-     * @see MediaStatusPanel
-     */
-    public void updateDVDStatus(DVDStatusUpdate update)
-    {
-        mediaPanel.updateDVDStatus(update);
-    }
-
-    /**
-     * @see MediaStatusPanel
-     */
-    public void updateDVDTitle(DVDTitleUpdate update)
-    {
-        mediaPanel.updateDVDTitle(update);
+        String propfilename = "/tmcsim/application.properties";
+        String propKey = "Application.revision";
+        String version = "unknown";
+        try
+        {
+            Properties props = new Properties();
+            props.load(this.getClass().getResourceAsStream(propfilename));
+            version = (String) props.get(propKey);
+        } catch (IOException ex)
+        {
+            Logger.getLogger("tmcsim/cadsimulator").log(Level.SEVERE,
+                    "CADSimulatorView.getAppVersion()",
+                    "IOError reading " + propfilename);
+        }
+        return "revision: " + version;
     }
 
@@ -147,14 +105,14 @@
         if (evt.getID() == WindowEvent.WINDOW_CLOSING)
         {
-            int option = JOptionPane.showConfirmDialog(null,
-                    "Closing the CAD Simulator will stop the current "
-                    + "simulation.  Do you wish to continue exiting?",
-                    "Confirm Exit",
-                    JOptionPane.YES_NO_OPTION);
-
-            if (option != JOptionPane.NO_OPTION)
-            {
-                System.exit(0);
-            }
+//            int option = JOptionPane.showConfirmDialog(null,
+//                    "Closing the CAD Simulator will stop the current "
+//                    + "simulation.  Do you wish to continue exiting?",
+//                    "Confirm Exit",
+//                    JOptionPane.YES_NO_OPTION);
+//
+//            if (option != JOptionPane.NO_OPTION)
+//            {
+            System.exit(0);
+//            }
         }
     }
@@ -196,5 +154,5 @@
             public void actionPerformed(java.awt.event.ActionEvent evt)
             {
-                String ver = RevisionNumber.getString();
+                String ver = "";//RevisionNumber.getString();
                 JOptionPane.showMessageDialog(rootPane, "Version: " + ver, "About", JOptionPane.INFORMATION_MESSAGE);
             }
@@ -208,4 +166,5 @@
         pack();
         setResizable(true);
+        setDefaultCloseOperation(JFrame.EXIT_ON_CLOSE);
     }
     private JTabbedPane cadSimTabbedPane;
@@ -213,3 +172,16 @@
     private JMenu fileMenu;
     private JMenuItem exitMenuItem;
+
+    @Override
+    public void update(Observable obs, Object obj)
+    {
+        if (obs instanceof CADSimulatorStatus)
+        {
+            simulationPanel.refresh(obs);
+        }
+        if (obs instanceof CADMediaStatus)
+        {
+            mediaPanel.refresh(obs);
+        }
+    }
 }
Index: /trunk/src/tmcsim/cadsimulator/viewer/DVDInfoPanel.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/viewer/DVDInfoPanel.java	(revision 2)
+++ /trunk/src/tmcsim/cadsimulator/viewer/DVDInfoPanel.java	(revision 44)
@@ -2,5 +2,4 @@
 
 import java.awt.Dimension;
-
 import javax.swing.BorderFactory;
 import javax.swing.Box;
@@ -10,5 +9,4 @@
 import javax.swing.JTable;
 import javax.swing.JTextField;
-
 import tmcsim.cadsimulator.videocontrol.DVDStatusUpdate;
 import tmcsim.cadsimulator.videocontrol.DVDTitleUpdate;
@@ -17,48 +15,57 @@
 
 /**
- * DVDInfoPanel is a GUI component used in the CADSimulatorViewer.  The panel
- * displays information regarding the DVD player's connection information.
- * One table on the panel shows all DVD title that have been played or 
- * repeated.  A second table shows all DVD status updates that have been
- * received from the controller. 
- * 
+ * DVDInfoPanel is a GUI component used in the CADSimulatorViewer. The panel
+ * displays information regarding the DVD player's connection information. One
+ * table on the panel shows all DVD title that have been played or repeated. A
+ * second table shows all DVD status updates that have been received from the
+ * controller.
+ *
  * @author Matthew Cechini
- * @version 
+ * @version
  */
 @SuppressWarnings("serial")
-public class DVDInfoPanel extends JPanel {
+public class DVDInfoPanel extends JPanel
+{
 
-    /** DVD player connection info. */
-    private String connInfo = null;
-    
-    /** Table model for the title table. */
+    /**
+     * DVD player connection info.
+     */
+    public final String connInfo;
+    /**
+     * Table model for the title table.
+     */
     private DVDTitleTableModel titleTableModel;
+    /**
+     * Table to display DVD title plays and repeats.
+     */
+    private JTable titleTable;
+    /**
+     * Table model for the Status table.
+     */
+    private DVDStatusTableModel statusTableModel;
+    /**
+     * Table to display DVD status updates.
+     */
+    private JTable statusTable;
 
-    /** Table to display DVD title plays and repeats. */
-    private JTable titleTable;
-    
-    /** Table model for the Status table. */
-    private DVDStatusTableModel statusTableModel;
-    
-    /** Table to display DVD status updates. */
-    private JTable statusTable;
-    
-    
     /**
-     * Constructor.  Initialize the panel GUI components.
-     * 
+     * Constructor. Initialize the panel GUI components.
+     *
      * @param connectionInfo DVD player connection info.
      */
-    public DVDInfoPanel(String connectionInfo) {
+    public DVDInfoPanel(String connectionInfo)
+    {
         connInfo = connectionInfo;
-        
+
         initComponents();
-    }   
-    
+    }
+
     /**
      * This method updates the DVD status table with the new update object.
+     *
      * @param update Update DVD Status update.
      */
-    public void updateDVDStatus(DVDStatusUpdate update) {
+    public void updateDVDStatus(DVDStatusUpdate update)
+    {
         statusTableModel.addStatusUpdate(update);
     }
@@ -66,32 +73,36 @@
     /**
      * This method updates the DVD title table with the new update object.
+     *
      * @param update Update DVD Status update.
      */
-    public void updateDVDTitle(DVDTitleUpdate update) {
+    public void updateDVDTitle(DVDTitleUpdate update)
+    {
         titleTableModel.addTitleUpdate(update);
     }
-    
+
     /**
      * Initialize the GUI components.
      */
-    private void initComponents() {
+    private void initComponents()
+    {
 
         connInfoLbl = new JLabel("Connection Info:");
         connInfoLbl.setAlignmentX(Box.LEFT_ALIGNMENT);
-        connInfoTF  = new JTextField(connInfo);
+        connInfoTF = new JTextField(connInfo);
         connInfoTF.setColumns(30);
         connInfoTF.setAlignmentX(Box.LEFT_ALIGNMENT);
         connInfoTF.setEditable(false);
-        
+
         Box connInfoBox = Box.createVerticalBox();
         connInfoBox.add(connInfoLbl);
         connInfoBox.add(connInfoTF);
         connInfoBox.setAlignmentX(Box.CENTER_ALIGNMENT);
-        
+
         titleTableModel = new DVDTitleTableModel();
-        titleTable      = new JTable(titleTableModel);
-        titleTable.getTableHeader().setReorderingAllowed(false);  
-        
-        for(int c = 0; c < titleTable.getColumnCount(); c++) {
+        titleTable = new JTable(titleTableModel);
+        titleTable.getTableHeader().setReorderingAllowed(false);
+
+        for (int c = 0; c < titleTable.getColumnCount(); c++)
+        {
             titleTable.getColumnModel().getColumn(c).setMinWidth(
                     titleTableModel.getColumnMinWidth(c));
@@ -102,18 +113,19 @@
             titleTable.getColumnModel().getColumn(c).setResizable(true);
         }
-        
-        titlePane       = new JScrollPane();
+
+        titlePane = new JScrollPane();
         titlePane.setAlignmentX(Box.CENTER_ALIGNMENT);
         //titlePane.setMinimumSize(new Dimension(,));
-        titlePane.setPreferredSize(new Dimension(425, 225));        
+        titlePane.setPreferredSize(new Dimension(425, 225));
         titlePane.setViewportView(titleTable);
         titlePane.setBorder(BorderFactory.createTitledBorder(
-                    BorderFactory.createRaisedBevelBorder(), "Title Updates"));
+                BorderFactory.createRaisedBevelBorder(), "Title Updates"));
 
         statusTableModel = new DVDStatusTableModel();
-        statusTable      = new JTable(statusTableModel);
-        statusTable.getTableHeader().setReorderingAllowed(false);  
-        
-        for(int c = 0; c < statusTable.getColumnCount(); c++) {
+        statusTable = new JTable(statusTableModel);
+        statusTable.getTableHeader().setReorderingAllowed(false);
+
+        for (int c = 0; c < statusTable.getColumnCount(); c++)
+        {
             statusTable.getColumnModel().getColumn(c).setMinWidth(
                     statusTableModel.getColumnMinWidth(c));
@@ -124,13 +136,13 @@
             statusTable.getColumnModel().getColumn(c).setResizable(true);
         }
-        
-        statusPane       = new JScrollPane();
+
+        statusPane = new JScrollPane();
         statusPane.setAlignmentX(Box.CENTER_ALIGNMENT);
         //statusPane.setMinimumSize(new Dimension(,));
-        statusPane.setPreferredSize(new Dimension(425, 150));       
+        statusPane.setPreferredSize(new Dimension(425, 150));
         statusPane.setViewportView(statusTable);
         statusPane.setBorder(BorderFactory.createTitledBorder(
                 BorderFactory.createRaisedBevelBorder(), "Status Updates"));
-        
+
         Box panelBox = Box.createVerticalBox();
         panelBox.add(connInfoBox);
@@ -139,14 +151,11 @@
         panelBox.add(Box.createVerticalStrut(10));
         panelBox.add(statusPane);
-        panelBox.setBorder(BorderFactory.createEmptyBorder(5,5,5,5));
-        
+        panelBox.setBorder(BorderFactory.createEmptyBorder(5, 5, 5, 5));
+
         add(panelBox);
     }
-    
     private JScrollPane titlePane;
     private JScrollPane statusPane;
-    
     private JLabel connInfoLbl;
-    
     private JTextField connInfoTF;
 }
Index: /trunk/src/tmcsim/cadsimulator/viewer/CADConsoleViewer.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/viewer/CADConsoleViewer.java	(revision 44)
+++ /trunk/src/tmcsim/cadsimulator/viewer/CADConsoleViewer.java	(revision 44)
@@ -0,0 +1,127 @@
+package tmcsim.cadsimulator.viewer;
+
+import java.io.PrintWriter;
+import java.io.Writer;
+import java.util.Observable;
+import tmcsim.cadsimulator.viewer.model.CADSimulatorModel;
+import tmcsim.cadsimulator.viewer.model.CADSimulatorStatus;
+import tmcsim.common.CADEnums.PARAMICS_STATUS;
+import static tmcsim.common.CADEnums.SCRIPT_STATUS.ATMS_SYNCHRONIZATION;
+import static tmcsim.common.CADEnums.SCRIPT_STATUS.NO_SCRIPT;
+import static tmcsim.common.CADEnums.SCRIPT_STATUS.SCRIPT_PAUSED_STARTED;
+import static tmcsim.common.CADEnums.SCRIPT_STATUS.SCRIPT_RUNNING;
+import static tmcsim.common.CADEnums.SCRIPT_STATUS.SCRIPT_STOPPED_NOT_STARTED;
+import tmcsim.interfaces.CADViewer;
+
+/**
+ * This class provides a console to view current status information for the CAD
+ * Simulator.
+ *
+ * @see SimulationStatusPanel
+ * @see MediaStatusPanel
+ * @author Matthew Cechini
+ * @version $Revision: 1.3 $ $Date: 2006/06/06 20:46:41 $
+ */
+@SuppressWarnings("serial")
+public class CADConsoleViewer implements CADViewer
+{
+
+    /**
+     * Simulation model
+     */
+    private CADSimulatorModel cadstatus;
+    private PrintWriter display;
+
+    /**
+     * Constructor.
+     */
+    public CADConsoleViewer()
+    {
+        display = new PrintWriter(System.out, true);
+    }
+
+    public void setWriter(Writer writer)
+    {
+        display = new PrintWriter(writer, true);
+    }
+
+    public void setVisible(boolean state)
+    {
+        display.print("--- CAD Simulator ---\n");
+        display.print("Elapsed Simulation Time     : 0:00:00\n");
+        display.print("Status                      : No Script\n");
+        display.print("Connected CAD Terminals     : 0\n");
+        display.print("Simulation Manager Connected: No\n");
+        display.print("Connected to Paramics       : No\n");
+        display.print("Network Loaded              : None\n");
+        display.print("-- Info Messages --\n\n");
+        display.println("-- Error Messages --\n");
+    }
+
+    /**
+     * Method calls the processEvent() method with a WINDOW_CLOSING WindowEvent
+     * to start the application closing process.
+     */
+    public void closeViewer()
+    {
+        System.exit(0);
+    }
+
+    @Override
+    public void update(Observable obs, Object obj)
+    {
+        if (obs instanceof CADSimulatorStatus)
+        {
+            CADSimulatorStatus cadstatus = (CADSimulatorStatus) obs;
+            display.println("--- CAD Simulator ---");
+            display.println("Elapsed Simulation Time     : " + cadstatus.getCurrentTime());
+            String statusTxt = "No Script";
+            switch (cadstatus.getScriptStatus())
+            {
+                case NO_SCRIPT:
+                    statusTxt = "No Script";
+                    break;
+                case SCRIPT_STOPPED_NOT_STARTED:
+                    statusTxt = "Ready";
+                    break;
+                case SCRIPT_PAUSED_STARTED:
+                    statusTxt = "Paused";
+                    break;
+                case SCRIPT_RUNNING:
+                    statusTxt = "Running";
+                    break;
+                case ATMS_SYNCHRONIZATION:
+                    statusTxt = "Synchronizing";
+                    break;
+            }
+            display.println("Status                      : " + statusTxt);
+            display.println("Connected CAD Terminals     : " + cadstatus.getNumClients());
+            String yesno = "No";
+            if (cadstatus.isSimManagerConnected())
+            {
+                yesno = "Yes";
+            }
+            display.println("Simulation Manager Connected: " + yesno);
+            statusTxt = "No";
+            if (cadstatus.getParamicsStatus().equals(PARAMICS_STATUS.CONNECTED))
+            {
+                statusTxt = "Yes";
+            }
+            display.println("Connected to Paramics       : " + statusTxt);
+            String idTxt = "None";
+            if (cadstatus.getParmicsNetworkID().length() > 0)
+            {
+                idTxt = cadstatus.getParmicsNetworkID();
+            }
+            display.println("Network Loaded              : " + idTxt);
+            display.println("-- Info Messages --");
+            display.println(cadstatus.getInfoMessages());
+            display.println("-- Error Messages --");
+            display.println(cadstatus.getErrorMessages());
+        }
+//        if (obs instanceof CADMediaStatus)
+//        {
+//            mediaPanel.refresh(obs);
+//        }
+    }
+}
Index: /trunk/src/tmcsim/cadsimulator/viewer/model/CADSimulatorModel.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/viewer/model/CADSimulatorModel.java	(revision 44)
+++ /trunk/src/tmcsim/cadsimulator/viewer/model/CADSimulatorModel.java	(revision 44)
@@ -0,0 +1,133 @@
+package tmcsim.cadsimulator.viewer.model;
+
+import java.util.Observer;
+import tmcsim.cadsimulator.videocontrol.DVDStatusUpdate;
+import tmcsim.cadsimulator.videocontrol.DVDTitleUpdate;
+import tmcsim.common.CADEnums.PARAMICS_STATUS;
+import tmcsim.common.CADEnums.SCRIPT_STATUS;
+
+/**
+ * CADSimulatorModel represents the state of the Simulation at any point in
+ * time. It is comprised of CADSimulatorStatus and CADMediaStatus.
+ *
+ * @author jdalbey
+ * @version $Revision: 1.3 $ $Date: 2006/06/06 20:46:41 $
+ */
+@SuppressWarnings("serial")
+public class CADSimulatorModel
+{
+
+    private CADSimulatorStatus simStatus;
+    private CADMediaStatus mediaStatus;
+
+    /**
+     * Constructor.
+     */
+    public CADSimulatorModel()
+    {
+        simStatus = new CADSimulatorStatus();
+        mediaStatus = new CADMediaStatus();
+    }
+
+    /**
+     * Make all of our delegates observers of the given view.
+     *
+     * @param view Someone that wants to observe us
+     */
+    public void addObserver(Observer view)
+    {
+//        super.addObserver(view);
+        simStatus.addObserver(view);
+        mediaStatus.addObserver(view);
+    }
+
+    /**
+     * @see SimulationStatusPanel
+     */
+    public void connectClient()
+    {
+        simStatus.connectClient();
+    }
+
+    /**
+     * @see SimulationStatusPanel
+     */
+    public void disconnectClient()
+    {
+        simStatus.disconnectClient();
+    }
+
+    /**
+     * Accessor to current number of clients.
+     *
+     * @return number of connected clients
+     */
+    public int getNumClients()
+    {
+        return simStatus.getNumClients();
+    }
+
+    /**
+     * @see SimulationStatusPanel
+     */
+    public void setSimManagerStatus(boolean connection)
+    {
+        simStatus.setSimManagerStatus(connection);
+    }
+
+    /**
+     * @see SimulationStatusPanel
+     */
+    public boolean isSimManagerConnected()
+    {
+        return simStatus.isSimManagerConnected();
+    }
+
+    /**
+     * @see SimulationStatusPanel
+     */
+    public void setTime(long seconds)
+    {
+        simStatus.setTime(seconds);
+    }
+
+    /**
+     * @see SimulationStatusPanel
+     */
+    public void setScriptStatus(SCRIPT_STATUS newStatus)
+    {
+        simStatus.setScriptStatus(newStatus);
+    }
+
+    /**
+     * @see SimulationStatusPanel
+     */
+    public void setParamicsStatus(PARAMICS_STATUS newStatus)
+    {
+        simStatus.setParamicsStatus(newStatus);
+    }
+
+    /**
+     * @see SimulationStatusPanel
+     */
+    public void setParamicsNetworkLoaded(String networkID)
+    {
+        simStatus.setParamicsNetworkLoaded(networkID);
+    }
+
+    /**
+     * @see MediaStatusPanel
+     */
+    public void updateDVDStatus(DVDStatusUpdate update)
+    {
+        mediaStatus.updateDVDStatus(update);
+    }
+
+    /**
+     * @see MediaStatusPanel
+     */
+    public void updateDVDTitle(DVDTitleUpdate update)
+    {
+        mediaStatus.updateDVDTitle(update);
+    }
+}
Index: /trunk/src/tmcsim/cadsimulator/viewer/model/CADMediaStatus.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/viewer/model/CADMediaStatus.java	(revision 44)
+++ /trunk/src/tmcsim/cadsimulator/viewer/model/CADMediaStatus.java	(revision 44)
@@ -0,0 +1,85 @@
+package tmcsim.cadsimulator.viewer.model;
+
+import java.util.Iterator;
+import java.util.Observable;
+import java.util.TreeMap;
+import tmcsim.cadsimulator.videocontrol.DVDStatusUpdate;
+import tmcsim.cadsimulator.videocontrol.DVDTitleUpdate;
+import tmcsim.cadsimulator.viewer.DVDInfoPanel;
+
+/**
+ * CADMediaStatus is the status of the DVD connections created by the CAD
+ * Simulator. All status and title updates are sent to the corresponding
+ * DVDInfoPanel. The DVDs are referenced by connection info, which is unique to
+ * each DVD player.
+ *
+ * @author jdalbey
+ */
+@SuppressWarnings("serial")
+public class CADMediaStatus extends Observable
+{
+
+    /**
+     * Map of DVDInfoPanels(values) referenced by a DVD's connection info(key).
+     */
+    private TreeMap<String, DVDInfoPanel> dvdPanels = null;
+
+    /**
+     * Constructor. Initialize data and GUI components.
+     */
+    public CADMediaStatus()
+    {
+
+        dvdPanels = new TreeMap<String, DVDInfoPanel>();
+    }
+
+    /**
+     * Updates the current DVDInfoPanel with the status update. If a panel does
+     * not current exist, create one and add a new tab.
+     *
+     * @param update DVD status update.
+     */
+    public void updateDVDStatus(DVDStatusUpdate update)
+    {
+        if (dvdPanels.get(update.connectionInfo) == null)
+        {
+            dvdPanels.put(update.connectionInfo, new DVDInfoPanel(
+                    update.connectionInfo));
+        }
+
+
+        dvdPanels.get(update.connectionInfo).updateDVDStatus(update);
+        setChanged();
+        notifyObservers();
+
+    }
+
+    public DVDInfoPanel getInfoPanel(String connectionInfo)
+    {
+        return dvdPanels.get(connectionInfo);
+    }
+
+    /**
+     * Updates the current DVDInfoPanel with the title update. If a panel does
+     * not current exist, create one and add a new tab.
+     *
+     * @param update DVD title update.
+     */
+    public void updateDVDTitle(DVDTitleUpdate update)
+    {
+        if (dvdPanels.get(update.connectionInfo) == null)
+        {
+            dvdPanels.put(update.connectionInfo, new DVDInfoPanel(update.connectionInfo));
+        }
+
+        dvdPanels.get(update.connectionInfo).updateDVDTitle(update);
+        setChanged();
+        notifyObservers();
+
+    }
+
+    public Iterator<DVDInfoPanel> getDVDlist()
+    {
+        return dvdPanels.values().iterator();
+    }
+}
Index: /trunk/src/tmcsim/cadsimulator/viewer/model/CADSimulatorStatus.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/viewer/model/CADSimulatorStatus.java	(revision 44)
+++ /trunk/src/tmcsim/cadsimulator/viewer/model/CADSimulatorStatus.java	(revision 44)
@@ -0,0 +1,320 @@
+package tmcsim.cadsimulator.viewer.model;
+
+import java.util.logging.Handler;
+import java.util.logging.Level;
+import java.util.logging.LogRecord;
+import java.util.logging.Logger;
+import tmcsim.common.CADEnums;
+import tmcsim.common.CADEnums.PARAMICS_STATUS;
+
+/**
+ * SimulatorStatus represents the status of the current simulation. This
+ * information includes:
+ *
+ * <ul>
+ * <li>Current simulation time.</li>
+ * <li>Current simulation status.</li>
+ * <li>Number of remote CAD Clients connected.</li>
+ * <li>Status of Simulation Manager connection.</li>
+ * <li>Status of Paramics connection.</li>
+ * <li>Paramics Network Loaded</li>
+ * <li>Information log messages.</li>
+ * <li>Error log messages</li>
+ * </ul>
+ *
+ * @author jdalbey
+ * @version 0.1
+ */
+@SuppressWarnings("serial")
+public class CADSimulatorStatus extends java.util.Observable
+{
+
+    /**
+     * Count of how many CAD clients have connected.
+     */
+    private int numClientsConnected;
+    /**
+     * Is the Simulation Manager connected?
+     */
+    private boolean simMgrStatus;
+    /**
+     * The current state of the script this simulation has loaded.
+     */
+    private CADEnums.SCRIPT_STATUS scriptState;
+    /**
+     * The current simulation elapsed time.
+     */
+    private long currentTime;
+    /**
+     * The current state of the connectio to paramics
+     */
+    private PARAMICS_STATUS paramicsConnectionStatus;
+    /**
+     * ID of currently loaded paramics network
+     */
+    private String networkID;
+    /**
+     * Logging ErrorHandler.
+     */
+    private SimulatorErrorHandler errorHandler;
+    private StringBuffer infoMessages;
+    private StringBuffer errorMessages;
+
+    /**
+     * Constructor. Initialize GUI Objects. Register the logging handler to
+     * listen for log records from all loggers that exist in the
+     * "tmcsim.cadsimulator" package structure.
+     */
+    public CADSimulatorStatus()
+    {
+        errorHandler = new SimulatorErrorHandler();
+        Logger.getLogger("tmcsim.cadsimulator").addHandler(errorHandler);
+        scriptState = CADEnums.SCRIPT_STATUS.NO_SCRIPT;
+        paramicsConnectionStatus = PARAMICS_STATUS.DISCONNECTED;
+        networkID = "";
+        numClientsConnected = 0;
+        infoMessages = new StringBuffer();
+        errorMessages = new StringBuffer();
+    }
+
+    public String getInfoMessages()
+    {
+        return infoMessages.toString();
+    }
+
+    public String getErrorMessages()
+    {
+        return errorMessages.toString();
+    }
+
+    /**
+     * Method is called when a CAD Client disconnects from the CAD Simulator.
+     * The displayed number of connected clients is incremented by one.
+     */
+    public void connectClient()
+    {
+        numClientsConnected += 1;
+        setChanged();
+        notifyObservers();
+
+        //termConnectedTF.setText(String.valueOf(numClientsConnected));
+    }
+
+    /**
+     * Method is called when a CAD Client disconnects from the CAD Simulator.
+     * The displayed number of connected clients is decremented by one.
+     */
+    public void disconnectClient()
+    {
+        if (numClientsConnected > 0)
+        {
+            numClientsConnected--;
+        }
+        setChanged();
+        notifyObservers();
+
+        //termConnectedTF.setText(String.valueOf(numClientsConnected));
+    }
+
+    /**
+     * Accessor to current number of clients.
+     *
+     * @return number of connected clients
+     */
+    public int getNumClients()
+    {
+        return numClientsConnected;
+    }
+
+    /**
+     * Method is called when Simulation Manager connects or disconnects.
+     *
+     * @param connection True if simulation manager is connected, false if not.
+     */
+    public void setSimManagerStatus(boolean connection)
+    {
+        simMgrStatus = connection;
+        setChanged();
+        notifyObservers();
+
+        //managerConnectedTF.setText("Yes");
+    }
+
+    /**
+     * Accessor to Sim Mgr connection status
+     *
+     * @return number of connected clients
+     */
+    public boolean isSimManagerConnected()
+    {
+        return simMgrStatus;
+    }
+
+    /**
+     * Method called to convert current simulation time (parameter long value)
+     * to a string of format H:MM:SS. Time is then updated on GUI.
+     *
+     * @param seconds Long value of current time
+     */
+    public void setTime(long seconds)
+    {
+        currentTime = seconds;
+        setChanged();
+        notifyObservers();
+    }
+
+    public String getCurrentTime()
+    {
+        String time = new String();
+        long timeSegment;
+        long seconds = currentTime;
+        timeSegment = seconds / 3600;
+        time += String.valueOf(timeSegment) + ":";
+
+        seconds = seconds % 3600;
+
+        timeSegment = seconds / 60;
+        if (timeSegment < 10)
+        {
+            time += "0";
+        }
+
+        time += String.valueOf(timeSegment) + ":";
+        seconds = seconds % 60;
+
+        timeSegment = seconds;
+        if (timeSegment < 10)
+        {
+            time += "0";
+        }
+
+        time += String.valueOf(timeSegment);
+        return time;
+        //simulationClockLabel.setText(time);
+
+    }
+
+    /**
+     * Method is called to display the current status of the simulation.
+     *
+     * @param newStatus Current status of simulation. The following table
+     * describes each possible status and what is displayed. Each status code is
+     * found as a public static int in the Coordinator Class.
+     *
+     * <table cellpadding="2" cellspacing="2" border="1" style="text-align:
+     * left; width: 250px;">
+     * <tbody>
+     * <tr>
+     * <th>Status<br></th>
+     * <th>Actions Taken<br></th>
+     * </tr>
+     * <tr>
+     * <td>NO_SCRIPT<br></td>
+     * <td>Set the simulation status text to a black "No Script". <br></td>
+     * </tr>
+     * <tr>
+     * <td>SCRIPT_STOPPED_NOT_STARTED<br></td>
+     * <td>Set the simulation status text to a red "Ready". <br></td>
+     * </tr>
+     * <tr>
+     * <td>SCRIPT_PAUSED_STARTED<br></td>
+     * <td>Set the simulation status text to a red "Paused". <br></td>
+     * </tr>
+     * <tr>
+     * <td>SCRIPT_RUNNING<br></td>
+     * <td>Set the simulation status text to a green "Running". <br></td>
+     * </tr>
+     * <tr>
+     * <td>ATMS_SYNCHRONIZATION<br></td>
+     * <td>Set the simulation status text to an orange "Synchronizing".
+     * <br></td>
+     * </tr>
+     * </tbody>
+     * </table>
+     */
+    public void setScriptStatus(CADEnums.SCRIPT_STATUS newStatus)
+    {
+        scriptState = newStatus;
+        setChanged();
+        notifyObservers();
+    }
+
+    public CADEnums.SCRIPT_STATUS getScriptStatus()
+    {
+        return scriptState;
+    }
+
+    /**
+     * Method is called when a connection to paramics is made or dropped.
+     *
+     * @param newStatus The status denoting whether a connection has been made
+     * or dropped.
+     */
+    public void setParamicsStatus(CADEnums.PARAMICS_STATUS newStatus)
+    {
+        paramicsConnectionStatus = newStatus;
+        setChanged();
+        notifyObservers();
+    }
+
+    public CADEnums.PARAMICS_STATUS getParamicsStatus()
+    {
+        return paramicsConnectionStatus;
+    }
+
+    /**
+     * Method is called when a paramics network is loaded.
+     *
+     * @param networkID Unique ID for Paramics network that has been loaded.
+     */
+    public void setParamicsNetworkLoaded(String networkID)
+    {
+        this.networkID = networkID;
+        setChanged();
+        notifyObservers();
+    }
+
+    public String getParmicsNetworkID()
+    {
+        return networkID;
+    }
+
+    /**
+     * Logging Handler to listen for Information and Error messages logged for
+     * the CAD Simulator. Received LogRecords are displayed in the info or error
+     * message Text Area.
+     *
+     * @author Matthew Cechini
+     */
+    private class SimulatorErrorHandler extends Handler
+    {
+
+        public void close() throws SecurityException
+        {
+        }
+
+        public void flush()
+        {
+        }
+
+        public void publish(LogRecord rec)
+        {
+            StringBuffer msgBuffer = new StringBuffer();
+
+            msgBuffer.append(rec.getSourceClassName() + "."
+                    + rec.getSourceMethodName() + " = "
+                    + rec.getMessage());
+            // which panel to display in
+            if (rec.getLevel() == Level.INFO)
+            {
+                infoMessages.append(msgBuffer);
+            }
+            else
+            {
+                errorMessages.append(msgBuffer);
+            }
+            setChanged();
+            notifyObservers();
+        }
+    }
+}
Index: /trunk/src/tmcsim/cadsimulator/viewer/MediaStatusPanel.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/viewer/MediaStatusPanel.java	(revision 2)
+++ /trunk/src/tmcsim/cadsimulator/viewer/MediaStatusPanel.java	(revision 44)
@@ -1,48 +1,76 @@
 package tmcsim.cadsimulator.viewer;
 
+import java.util.Iterator;
+import java.util.Observable;
 import java.util.TreeMap;
-
 import javax.swing.JPanel;
 import javax.swing.JTabbedPane;
-
 import tmcsim.cadsimulator.videocontrol.DVDStatusUpdate;
 import tmcsim.cadsimulator.videocontrol.DVDTitleUpdate;
+import tmcsim.cadsimulator.viewer.model.CADMediaStatus;
 
 /**
- * MediaStatusPanel is a GUI object used for displaying information
- * for DVD connections created by the CAD Simulator.  Tabs for each
- * DVD are created and information is displayed on a DVDInfoPanel.
- * All status and title updates are sent to the corresponding
- * DVDInfoPanel.  The DVDs are referenced by connection info, which
- * is unique to each DVD player.
- * 
- * @author Matthew Cechini
- * @version
+ * MediaStatusPanel is a GUI object used for displaying information for DVD
+ * connections created by the CAD Simulator. Tabs for each DVD are created and
+ * information is displayed on a DVDInfoPanel. All status and title updates are
+ * sent to the corresponding DVDInfoPanel. The DVDs are referenced by connection
+ * info, which is unique to each DVD player.
+ *
+ * @author jdalbey
  */
 @SuppressWarnings("serial")
-public class MediaStatusPanel extends JPanel {
-    
-    /** Map of DVDInfoPanels(values) referenced by a DVD's connection info(key). */
+public class MediaStatusPanel extends JPanel
+{
+
+    /**
+     * Map of DVDInfoPanels(values) referenced by a DVD's connection info(key).
+     */
     private TreeMap<String, DVDInfoPanel> dvdPanels = null;
 
     /**
-     * Constructor.  Initialize data and GUI components.
+     * Constructor. Initialize data and GUI components.
      */
-    public MediaStatusPanel() {
+    public MediaStatusPanel()
+    {
 
-        dvdPanels   = new TreeMap<String, DVDInfoPanel>();
-        
+        dvdPanels = new TreeMap<String, DVDInfoPanel>();
+
         initComponents();
     }
-    
+
+    public void refresh(Observable obs)
+    {
+        CADMediaStatus status = (CADMediaStatus) obs;
+        Iterator<DVDInfoPanel> iter = status.getDVDlist();
+        // Remove existing tabs before adding them all back
+        mediaTabs.removeAll();
+        // add a new tab for each dvd panel
+        while (iter.hasNext())
+        {
+            DVDInfoPanel item = iter.next();
+            mediaTabs.addTab(
+                    "DVD " + (Integer.parseInt(item.connInfo
+                    .substring(item.connInfo
+                    .indexOf(":") + 1)) % 3000),
+                    dvdPanels.get(item.connInfo));
+        }
+//            mediaTabs.addTab(
+//                    "DVD " + (Integer.parseInt(update.connectionInfo
+//                    .substring(update.connectionInfo
+//                    .indexOf(":") + 1)) % 3000),
+//                    dvdPanels.get(update.connectionInfo));
+
+    }
+
     /**
-     * Updates the current DVDInfoPanel with the status update.
-     * If a panel does not current exist, create one and add
-     * a new tab.
-     * 
+     * Updates the current DVDInfoPanel with the status update. If a panel does
+     * not current exist, create one and add a new tab.
+     *
      * @param update DVD status update.
      */
-    public void updateDVDStatus(DVDStatusUpdate update) {
-        if(dvdPanels.get(update.connectionInfo) == null) {
+    public void updateDVDStatus(DVDStatusUpdate update)
+    {
+        if (dvdPanels.get(update.connectionInfo) == null)
+        {
             dvdPanels.put(update.connectionInfo, new DVDInfoPanel(
                     update.connectionInfo));
@@ -50,41 +78,41 @@
             mediaTabs.addTab(
                     "DVD " + (Integer.parseInt(update.connectionInfo
-                                    .substring(update.connectionInfo
-                                            .indexOf(":")+1)) % 3000), 
+                    .substring(update.connectionInfo
+                    .indexOf(":") + 1)) % 3000),
                     dvdPanels.get(update.connectionInfo));
         }
-        
-        
+
+
         dvdPanels.get(update.connectionInfo).updateDVDStatus(update);
     }
-    
+
     /**
-     * Updates the current DVDInfoPanel with the title update.
-     * If a panel does not current exist, create one and add
-     * a new tab.
-     * 
+     * Updates the current DVDInfoPanel with the title update. If a panel does
+     * not current exist, create one and add a new tab.
+     *
      * @param update DVD title update.
      */
-    public void updateDVDTitle(DVDTitleUpdate update) {
-        if(dvdPanels.get(update.connectionInfo) == null) {
+    public void updateDVDTitle(DVDTitleUpdate update)
+    {
+        if (dvdPanels.get(update.connectionInfo) == null)
+        {
             dvdPanels.put(update.connectionInfo, new DVDInfoPanel(update.connectionInfo));
-            
-            mediaTabs.addTab("DVD " + dvdPanels.size(), 
+
+            mediaTabs.addTab("DVD " + dvdPanels.size(),
                     dvdPanels.get(update.connectionInfo));
         }
-        
+
         dvdPanels.get(update.connectionInfo).updateDVDTitle(update);
     }
-    
+
     /**
      * Initialize GUI components.
      */
-    private void initComponents() {
+    private void initComponents()
+    {
         mediaTabs = new JTabbedPane();
-        
+
         add(mediaTabs);
     }
-    
     private JTabbedPane mediaTabs;
-    
 }
Index: /trunk/src/tmcsim/cadsimulator/Coordinator.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/Coordinator.java	(revision 35)
+++ /trunk/src/tmcsim/cadsimulator/Coordinator.java	(revision 44)
@@ -28,4 +28,5 @@
 import tmcsim.cadsimulator.managers.ParamicsSimulationManager;
 import tmcsim.cadsimulator.managers.SimulationControlManager;
+import tmcsim.cadsimulator.viewer.model.CADSimulatorModel;
 import tmcsim.client.cadclientgui.CardfileReader;
 import tmcsim.client.cadclientgui.ScriptHandler;
@@ -106,4 +107,5 @@
     private static CADData cadData;
     private static CardfileData cardfileData;
+    private CADSimulatorModel cadModel;
 
     /**
@@ -113,7 +115,8 @@
      * @throws RemoteException
      */
-    public Coordinator() throws RemoteException
+    public Coordinator(CADSimulatorModel model) throws RemoteException
     {
         super();
+        cadModel = model;
         clientList = new LinkedList<CADClientInterface>();
         cadData = new CADData();
@@ -133,5 +136,5 @@
     {
         clientList.add(client);
-        CADSimulator.theViewer.connectClient();
+        cadModel.connectClient();
     }
 
@@ -139,5 +142,5 @@
     {
         clientList.remove(client);
-        CADSimulator.theViewer.disconnectClient();
+        cadModel.disconnectClient();
     }
 
@@ -145,5 +148,5 @@
     {
         managerInt = simManInt;
-        CADSimulator.theViewer.setSimManagerStatus(true);
+        cadModel.setSimManagerStatus(true);
     }
 
@@ -151,5 +154,5 @@
     {
         managerInt = null;
-        CADSimulator.theViewer.setSimManagerStatus(false);
+        cadModel.setSimManagerStatus(false);
     }
 
@@ -157,10 +160,9 @@
     {
 
-        coorLogger.logp(Level.INFO, "Coordinator", "startSimulation",
-                "entering startSimulation()");
         if (!CADSimulator.theIncidentMgr.areIncidentsLoaded())
         {
             throw new ScriptException(ScriptException.NO_SCRIPT_LOADED);
-        } else if (CADSimulator.theParamicsSimMgr.isConnected())
+        }
+        else if (CADSimulator.theParamicsSimMgr.isConnected())
         {
             Runnable startRun = new Runnable()
@@ -168,31 +170,37 @@
                 public void run()
                 {
-//                    try
-//                    {
-//                        setScriptStatus(SCRIPT_STATUS.ATMS_SYNCHRONIZATION);
-//
-//                        long currentATMSTime = CADSimulator.theATMSMgr.getCurrentTime();
-//                        long sleepTime = ((60 * 1000) - (currentATMSTime % (60 * 1000))) % (30 * 1000);
-//
+                    try
+                    {
+                        setScriptStatus(SCRIPT_STATUS.ATMS_SYNCHRONIZATION);
+
+                        /* I have NO idea why this is needed. Why does it get the time from the remote
+                         * ATMS server instead of just our system time? Why does it need to sleep?
+                         * Is some process happening on the ATMS side that we need to wait for?
+                         */
+                        long currentATMSTime = CADSimulator.theATMSMgr.getCurrentTime();
+                        /* Seems like it waits 0-30 seconds, depending on what the time is on
+                         * the ATMS server.  Does something happen every 30 seconds over there?
+                         * Was it trying to make the Paramics time the same?
+                         */
+                        long sleepTime = ((60 * 1000) - (currentATMSTime % (60 * 1000))) % (30 * 1000);
+
 //                        coorLogger.logp(Level.INFO, "Coordinator", "StartSimulation",
 //                                "Sleeping for " + sleepTime / 1000 + " seconds.");
-//                        Thread.sleep(sleepTime);
-//
-//                        //currentATMSTime += sleepTime;
-//                        //ParamicsCommunicator.getInstance().serverTime.setTimeInMillis(currentATMSTime);
-//                    } catch (Exception e)
-//                    {
-//                        setScriptStatus(SCRIPT_STATUS.SCRIPT_RUNNING);
-//
-//                        coorLogger.logp(Level.SEVERE, "Coordinator", "StartSimulation:run",
-//                                "Unable to connect to ATMS server.", e);
-//                    } finally
-//                    {
-                        coorLogger.logp(Level.INFO, "Coordinator", "StartSimulation",
-                                "Starting WITH paramics connected ");
+                        // not needed   Thread.sleep(sleepTime);
+
+                        //currentATMSTime += sleepTime;
+                        //ParamicsCommunicator.getInstance().serverTime.setTimeInMillis(currentATMSTime);
+                    } catch (Exception e)
+                    {
+                        setScriptStatus(SCRIPT_STATUS.SCRIPT_RUNNING);
+
+                        coorLogger.logp(Level.SEVERE, "Coordinator", "StartSimulation:run",
+                                "Unable to connect to ATMS server.", e);
+                    } finally
+                    {
                         CADSimulator.theSimulationCntrlMgr.startSimulation();
                         CADSimulator.theParamicsSimMgr.startSimulation();
                         CADSimulator.theSoundPlayer.setAudioEnabled(true);
-//                    }
+                    }
                 }
             };
@@ -200,13 +208,10 @@
             Thread startThread = new Thread(startRun);
             startThread.start();
-        } else // Paramics isn't connected so start without it
-        {
-            coorLogger.logp(Level.INFO, "Coordinator", "startSimulation",
-                "starting without paramics connection. ..");            
+        }
+        else
+        {
             CADSimulator.theSimulationCntrlMgr.startSimulation();
             CADSimulator.theSoundPlayer.setAudioEnabled(true);
         }
-        coorLogger.logp(Level.INFO, "Coordinator", "StartSimulation:run",
-                "Simulation has started.");
     }
 
@@ -226,5 +231,5 @@
         CADSimulator.theSoundPlayer.deQueueAll();
 
-        CADSimulator.theViewer.setTime(0);
+        cadModel.setTime(0);
 
         setScriptStatus(SCRIPT_STATUS.SCRIPT_STOPPED_NOT_STARTED);
@@ -262,5 +267,5 @@
             public void run()
             {
-                CADSimulator.theViewer.setTime(newSimTime);
+                cadModel.setTime(newSimTime);
 
                 if (managerInt != null)
@@ -273,5 +278,5 @@
                         //Simulation Manager has disappeared
                         managerInt = null;
-                        CADSimulator.theViewer.setSimManagerStatus(false);
+                        cadModel.setSimManagerStatus(false);
 
                         coorLogger.logp(Level.SEVERE, "Coordinator", "gotoSimulationTime:run",
@@ -299,5 +304,5 @@
             {
 
-                CADSimulator.theViewer.setScriptStatus(status);
+                cadModel.setScriptStatus(status);
 
                 if (managerInt != null)
@@ -310,5 +315,5 @@
                         //Simulation Manager has disappeared
                         managerInt = null;
-                        CADSimulator.theViewer.setSimManagerStatus(false);
+                        cadModel.setSimManagerStatus(false);
 
                         coorLogger.logp(Level.SEVERE, "Coordinator", "setScriptStatus:run",
@@ -334,5 +339,20 @@
             public void run()
             {
-                CADSimulator.theViewer.setParamicsStatus(status);
+                cadModel.setParamicsStatus(status);
+                // Is the update for network loaded event?
+                // Fixes defect where network ID is never displayed.
+                if (status == PARAMICS_STATUS.LOADED)
+                {
+                    try
+                    {
+                        // Then we need to tell the model it has a new network ID
+                        int currentNetwork = getParamicsNetworkLoaded();
+                        cadModel.setParamicsNetworkLoaded("" + currentNetwork);
+                    } catch (RemoteException ex)
+                    {
+                        coorLogger.logp(Level.SEVERE, "Coordinator", "setParamicsStatus:run",
+                                "Unable to get current network loaded", ex);
+                    }
+                }
 
                 if (managerInt != null)
@@ -345,5 +365,5 @@
                         //Simulation Manager has disappeared
                         managerInt = null;
-                        CADSimulator.theViewer.setSimManagerStatus(false);
+                        cadModel.setSimManagerStatus(false);
 
                         coorLogger.logp(Level.SEVERE, "Coordinator", "setParamicsStatus:run",
@@ -395,5 +415,6 @@
         {
             throw new ScriptException(ScriptException.SIM_NOT_STARTED);
-        } else if (!CADSimulator.theIncidentMgr.areIncidentsLoaded())
+        }
+        else if (!CADSimulator.theIncidentMgr.areIncidentsLoaded())
         {
             throw new ScriptException(ScriptException.NO_SCRIPT_LOADED);
@@ -422,5 +443,5 @@
                 //Simulation Manager has disappeared
                 managerInt = null;
-                CADSimulator.theViewer.setSimManagerStatus(false);
+                cadModel.setSimManagerStatus(false);
 
                 coorLogger.logp(Level.SEVERE, "Coordinator", "deleteIncident",
@@ -456,5 +477,5 @@
                 //Simulation Manager has disappeared
                 managerInt = null;
-                CADSimulator.theViewer.setSimManagerStatus(false);
+                cadModel.setSimManagerStatus(false);
 
                 coorLogger.logp(Level.SEVERE, "Coordinator", "addIncident",
@@ -507,5 +528,6 @@
             {
                 return SCRIPT_STATUS.SCRIPT_RUNNING;
-            } else
+            }
+            else
             {
                 for (Incident inc : CADSimulator.theIncidentMgr.getIncidentList())
@@ -620,5 +642,5 @@
                 public void run()
                 {
-                    CADSimulator.theViewer.setTime(currentSimTime);
+                    cadModel.setTime(currentSimTime);
 
                     //send an update every 30 seconds
@@ -637,5 +659,5 @@
                             //Simulation Manager has disappeared
                             managerInt = null;
-                            CADSimulator.theViewer.setSimManagerStatus(false);
+                            cadModel.setSimManagerStatus(false);
 
                             coorLogger.logp(Level.SEVERE, "Coordinator", "tick:run",
@@ -680,5 +702,5 @@
                         //Simulation Manager has disappeared
                         managerInt = null;
-                        CADSimulator.theViewer.setSimManagerStatus(false);
+                        cadModel.setSimManagerStatus(false);
 
                         coorLogger.logp(Level.SEVERE, "Coordinator", "updateIncidents",
@@ -736,5 +758,5 @@
                         //Simulation Manager has disappeared
                         managerInt = null;
-                        CADSimulator.theViewer.setSimManagerStatus(false);
+                        cadModel.setSimManagerStatus(false);
 
                         coorLogger.logp(Level.SEVERE, "Coordinator", "updateIncidents:run",
@@ -861,14 +883,18 @@
         {
             return cadData.tableForAssignedIncidents();
-        } else if (tag.equals(TABLE.UNIT_STATUS))
+        }
+        else if (tag.equals(TABLE.UNIT_STATUS))
         {
             return cadData.tableForUnitStatus();
-        } else if (tag.equals(TABLE.PENDING_INCIDENTS))
+        }
+        else if (tag.equals(TABLE.PENDING_INCIDENTS))
         {
             return cadData.tableForPendingIncidents();
-        } else if (tag.equals(TABLE.INCIDENT_EDITOR))
+        }
+        else if (tag.equals(TABLE.INCIDENT_EDITOR))
         {
             return cadData.tableForIncidentEditor();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataTable");
@@ -932,29 +958,38 @@
         {
             return cadData.getIncident(incidentId).getLogNum();
-        } else if (tag.equals(INC_VAL.MASTER_INC))
+        }
+        else if (tag.equals(INC_VAL.MASTER_INC))
         {
             return cadData.getIncident(incidentId).getMasterInc();
-        } else if (tag.equals(INC_VAL.OAU))
+        }
+        else if (tag.equals(INC_VAL.OAU))
         {
             return cadData.getIncident(incidentId).getOau();
-        } else if (tag.equals(INC_VAL.P))
+        }
+        else if (tag.equals(INC_VAL.P))
         {
             return cadData.getIncident(incidentId).getP();
-        } else if (tag.equals(INC_VAL.DESCRIPTION))
+        }
+        else if (tag.equals(INC_VAL.DESCRIPTION))
         {
             return cadData.getIncident(incidentId).getDescription();
-        } else if (tag.equals(INC_VAL.RP))
+        }
+        else if (tag.equals(INC_VAL.RP))
         {
             return cadData.getIncident(incidentId).getRp();
-        } else if (tag.equals(INC_VAL.RP_TYPE))
+        }
+        else if (tag.equals(INC_VAL.RP_TYPE))
         {
             return cadData.getIncident(incidentId).getRpType();
-        } else if (tag.equals(INC_VAL.ALI))
+        }
+        else if (tag.equals(INC_VAL.ALI))
         {
             return cadData.getIncident(incidentId).getAli();
-        } else if (tag.equals(INC_VAL.MEDIA))
+        }
+        else if (tag.equals(INC_VAL.MEDIA))
         {
             return cadData.getIncident(incidentId).getMedia();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncVal");
@@ -974,23 +1009,30 @@
         {
             cadData.getIncident(incidentId).setOau(value);
-        } else if (tag.equals(INC_VAL.P))
+        }
+        else if (tag.equals(INC_VAL.P))
         {
             cadData.getIncident(incidentId).setP(value);
-        } else if (tag.equals(INC_VAL.DESCRIPTION))
+        }
+        else if (tag.equals(INC_VAL.DESCRIPTION))
         {
             cadData.getIncident(incidentId).setDescription(value);
-        } else if (tag.equals(INC_VAL.RP))
+        }
+        else if (tag.equals(INC_VAL.RP))
         {
             cadData.getIncident(incidentId).setRp(value);
-        } else if (tag.equals(INC_VAL.RP_TYPE))
+        }
+        else if (tag.equals(INC_VAL.RP_TYPE))
         {
             cadData.getIncident(incidentId).setRpType(value);
-        } else if (tag.equals(INC_VAL.ALI))
+        }
+        else if (tag.equals(INC_VAL.ALI))
         {
             cadData.getIncident(incidentId).setAli(value);
-        } else if (tag.equals(INC_VAL.MEDIA))
+        }
+        else if (tag.equals(INC_VAL.MEDIA))
         {
             cadData.getIncident(incidentId).setMedia(value);
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.setCadDataIncVal");
@@ -1010,53 +1052,70 @@
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getAddress();
-        } else if (tag.equals(INC_LOC.LOC))
+        }
+        else if (tag.equals(INC_LOC.LOC))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getLoc();
-        } else if (tag.equals(INC_LOC.CITY))
+        }
+        else if (tag.equals(INC_LOC.CITY))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getCity();
-        } else if (tag.equals(INC_LOC.COUNTY))
+        }
+        else if (tag.equals(INC_LOC.COUNTY))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getCounty();
-        } else if (tag.equals(INC_LOC.STATE))
+        }
+        else if (tag.equals(INC_LOC.STATE))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getState();
-        } else if (tag.equals(INC_LOC.ZIP))
+        }
+        else if (tag.equals(INC_LOC.ZIP))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getZip();
-        } else if (tag.equals(INC_LOC.BEAT))
+        }
+        else if (tag.equals(INC_LOC.BEAT))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getBeat();
-        } else if (tag.equals(INC_LOC.AREA))
+        }
+        else if (tag.equals(INC_LOC.AREA))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getArea();
-        } else if (tag.equals(INC_LOC.SECTOR))
+        }
+        else if (tag.equals(INC_LOC.SECTOR))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getSector();
-        } else if (tag.equals(INC_LOC.SECTOR_CODE))
+        }
+        else if (tag.equals(INC_LOC.SECTOR_CODE))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getSectorCode();
-        } else if (tag.equals(INC_LOC.DIVISION))
+        }
+        else if (tag.equals(INC_LOC.DIVISION))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getDivision();
-        } else if (tag.equals(INC_LOC.APT))
+        }
+        else if (tag.equals(INC_LOC.APT))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getApt();
-        } else if (tag.equals(INC_LOC.BUILDING))
+        }
+        else if (tag.equals(INC_LOC.BUILDING))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getBuilding();
-        } else if (tag.equals(INC_LOC.CROSS_ST))
+        }
+        else if (tag.equals(INC_LOC.CROSS_ST))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getCrossSt();
-        } else if (tag.equals(INC_LOC.LAW))
+        }
+        else if (tag.equals(INC_LOC.LAW))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getLaw();
-        } else if (tag.equals(INC_LOC.FIRE))
+        }
+        else if (tag.equals(INC_LOC.FIRE))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getFire();
-        } else if (tag.equals(INC_LOC.EMS))
+        }
+        else if (tag.equals(INC_LOC.EMS))
         {
             return cadData.getIncident(incidentId).getIncidentLocation().getEms();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncLoc");
@@ -1076,53 +1135,70 @@
         {
             cadData.getIncident(incidentId).getIncidentLocation().setAddress(value);
-        } else if (tag.equals(INC_LOC.LOC))
+        }
+        else if (tag.equals(INC_LOC.LOC))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setLoc(value);
-        } else if (tag.equals(INC_LOC.CITY))
+        }
+        else if (tag.equals(INC_LOC.CITY))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setCity(value);
-        } else if (tag.equals(INC_LOC.COUNTY))
+        }
+        else if (tag.equals(INC_LOC.COUNTY))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setCounty(value);
-        } else if (tag.equals(INC_LOC.STATE))
+        }
+        else if (tag.equals(INC_LOC.STATE))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setState(value);
-        } else if (tag.equals(INC_LOC.ZIP))
+        }
+        else if (tag.equals(INC_LOC.ZIP))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setZip(value);
-        } else if (tag.equals(INC_LOC.BEAT))
+        }
+        else if (tag.equals(INC_LOC.BEAT))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setBeat(value);
-        } else if (tag.equals(INC_LOC.AREA))
+        }
+        else if (tag.equals(INC_LOC.AREA))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setArea(value);
-        } else if (tag.equals(INC_LOC.SECTOR))
+        }
+        else if (tag.equals(INC_LOC.SECTOR))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setSector(value);
-        } else if (tag.equals(INC_LOC.SECTOR_CODE))
+        }
+        else if (tag.equals(INC_LOC.SECTOR_CODE))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setSectorCode(value);
-        } else if (tag.equals(INC_LOC.DIVISION))
+        }
+        else if (tag.equals(INC_LOC.DIVISION))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setDivision(value);
-        } else if (tag.equals(INC_LOC.APT))
+        }
+        else if (tag.equals(INC_LOC.APT))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setApt(value);
-        } else if (tag.equals(INC_LOC.BUILDING))
+        }
+        else if (tag.equals(INC_LOC.BUILDING))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setBuilding(value);
-        } else if (tag.equals(INC_LOC.CROSS_ST))
+        }
+        else if (tag.equals(INC_LOC.CROSS_ST))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setCrossSt(value);
-        } else if (tag.equals(INC_LOC.LAW))
+        }
+        else if (tag.equals(INC_LOC.LAW))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setLaw(value);
-        } else if (tag.equals(INC_LOC.FIRE))
+        }
+        else if (tag.equals(INC_LOC.FIRE))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setFire(value);
-        } else if (tag.equals(INC_LOC.EMS))
+        }
+        else if (tag.equals(INC_LOC.EMS))
         {
             cadData.getIncident(incidentId).getIncidentLocation().setEms(value);
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.setCadDataIncLoc");
@@ -1142,14 +1218,18 @@
         {
             return cadData.getIncident(incidentId).getIncidentCaller().getCallerType();
-        } else if (tag.equals(INC_CALLER.NAME))
+        }
+        else if (tag.equals(INC_CALLER.NAME))
         {
             return cadData.getIncident(incidentId).getIncidentCaller().getCallerName();
-        } else if (tag.equals(INC_CALLER.PHONE))
+        }
+        else if (tag.equals(INC_CALLER.PHONE))
         {
             return cadData.getIncident(incidentId).getIncidentCaller().getPhone();
-        } else if (tag.equals(INC_CALLER.EXT))
+        }
+        else if (tag.equals(INC_CALLER.EXT))
         {
             return cadData.getIncident(incidentId).getIncidentCaller().getExt();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncCaller");
@@ -1169,14 +1249,18 @@
         {
             cadData.getIncident(incidentId).getIncidentCaller().setCallerType(value);
-        } else if (tag.equals(INC_CALLER.NAME))
+        }
+        else if (tag.equals(INC_CALLER.NAME))
         {
             cadData.getIncident(incidentId).getIncidentCaller().setCallerName(value);
-        } else if (tag.equals(INC_CALLER.PHONE))
+        }
+        else if (tag.equals(INC_CALLER.PHONE))
         {
             cadData.getIncident(incidentId).getIncidentCaller().setPhone(value);
-        } else if (tag.equals(INC_CALLER.EXT))
+        }
+        else if (tag.equals(INC_CALLER.EXT))
         {
             cadData.getIncident(incidentId).getIncidentCaller().setExt(value);
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.setCadDataIncCaller");
@@ -1196,11 +1280,14 @@
         {
             return cadData.getIncident(incidentId).getProblem().getProblem();
-        } else if (tag.equals(INC_PROBLEM.CODE))
+        }
+        else if (tag.equals(INC_PROBLEM.CODE))
         {
             return cadData.getIncident(incidentId).getProblem().getProblemCode();
-        } else if (tag.equals(INC_PROBLEM.PRIORITY))
+        }
+        else if (tag.equals(INC_PROBLEM.PRIORITY))
         {
             return cadData.getIncident(incidentId).getProblem().getPriority();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncProblem");
@@ -1220,11 +1307,14 @@
         {
             cadData.getIncident(incidentId).getProblem().setProblem(value);
-        } else if (tag.equals(INC_PROBLEM.CODE))
+        }
+        else if (tag.equals(INC_PROBLEM.CODE))
         {
             cadData.getIncident(incidentId).getProblem().setProblemCode(value);
-        } else if (tag.equals(INC_PROBLEM.PRIORITY))
+        }
+        else if (tag.equals(INC_PROBLEM.PRIORITY))
         {
             cadData.getIncident(incidentId).getProblem().setPriority(value);
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.setCadDataIncProblem");
@@ -1244,11 +1334,14 @@
         {
             return cadData.getIncident(incidentId).getGenInfo().getJurisdiction();
-        } else if (tag.equals(INC_GEN_INFO.ALARM))
+        }
+        else if (tag.equals(INC_GEN_INFO.ALARM))
         {
             return cadData.getIncident(incidentId).getGenInfo().getAlarm();
-        } else if (tag.equals(INC_GEN_INFO.AGY))
+        }
+        else if (tag.equals(INC_GEN_INFO.AGY))
         {
             return cadData.getIncident(incidentId).getGenInfo().getAgy();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncGenInfo");
@@ -1268,11 +1361,14 @@
         {
             cadData.getIncident(incidentId).getGenInfo().setJurisdiction(value);
-        } else if (tag.equals(INC_GEN_INFO.ALARM))
+        }
+        else if (tag.equals(INC_GEN_INFO.ALARM))
         {
             cadData.getIncident(incidentId).getGenInfo().setAlarm(value);
-        } else if (tag.equals(INC_GEN_INFO.AGY))
+        }
+        else if (tag.equals(INC_GEN_INFO.AGY))
         {
             cadData.getIncident(incidentId).getGenInfo().setAgy(value);
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.setCadDataIncGenInfo");
@@ -1292,8 +1388,10 @@
         {
             return cadData.getIncident(incidentId).getResponse().getPlan();
-        } else if (tag.equals(INC_RESP.AREA))
+        }
+        else if (tag.equals(INC_RESP.AREA))
         {
             return cadData.getIncident(incidentId).getResponse().getArea();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncResp");
@@ -1313,8 +1411,10 @@
         {
             cadData.getIncident(incidentId).getResponse().setPlan(value);
-        } else if (tag.equals(INC_RESP.AREA))
+        }
+        else if (tag.equals(INC_RESP.AREA))
         {
             cadData.getIncident(incidentId).getResponse().setArea(value);
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.setCadDataIncResp");
@@ -1334,26 +1434,34 @@
         {
             return cadData.getIncident(incidentId).getAdditionalInfo().getType();
-        } else if (tag.equals(INC_ADD_INFO.TYPE_CODE))
+        }
+        else if (tag.equals(INC_ADD_INFO.TYPE_CODE))
         {
             return cadData.getIncident(incidentId).getAdditionalInfo().getTypeCode();
-        } else if (tag.equals(INC_ADD_INFO.MACHINE))
+        }
+        else if (tag.equals(INC_ADD_INFO.MACHINE))
         {
             return cadData.getIncident(incidentId).getAdditionalInfo().getMachine();
-        } else if (tag.equals(INC_ADD_INFO.CALL_STATUS))
+        }
+        else if (tag.equals(INC_ADD_INFO.CALL_STATUS))
         {
             return cadData.getIncident(incidentId).getAdditionalInfo().getCallStatus();
-        } else if (tag.equals(INC_ADD_INFO.CALL_TAKER_EXT))
+        }
+        else if (tag.equals(INC_ADD_INFO.CALL_TAKER_EXT))
         {
             return cadData.getIncident(incidentId).getAdditionalInfo().getCallTakerExt();
-        } else if (tag.equals(INC_ADD_INFO.ALARM_LEVEL))
+        }
+        else if (tag.equals(INC_ADD_INFO.ALARM_LEVEL))
         {
             return cadData.getIncident(incidentId).getAdditionalInfo().getAlarmLevel();
-        } else if (tag.equals(INC_ADD_INFO.ROTATION_PROVIDER_AREA))
+        }
+        else if (tag.equals(INC_ADD_INFO.ROTATION_PROVIDER_AREA))
         {
             return cadData.getIncident(incidentId).getAdditionalInfo().getRotationProviderArea();
-        } else if (tag.equals(INC_ADD_INFO.COMMENT))
+        }
+        else if (tag.equals(INC_ADD_INFO.COMMENT))
         {
             return cadData.getIncident(incidentId).getAdditionalInfo().getComment();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncAddInfo");
@@ -1373,26 +1481,34 @@
         {
             cadData.getIncident(incidentId).getAdditionalInfo().setType(value);
-        } else if (tag.equals(INC_ADD_INFO.TYPE_CODE))
+        }
+        else if (tag.equals(INC_ADD_INFO.TYPE_CODE))
         {
             cadData.getIncident(incidentId).getAdditionalInfo().setTypeCode(value);
-        } else if (tag.equals(INC_ADD_INFO.MACHINE))
+        }
+        else if (tag.equals(INC_ADD_INFO.MACHINE))
         {
             cadData.getIncident(incidentId).getAdditionalInfo().setMachine(value);
-        } else if (tag.equals(INC_ADD_INFO.CALL_STATUS))
+        }
+        else if (tag.equals(INC_ADD_INFO.CALL_STATUS))
         {
             cadData.getIncident(incidentId).getAdditionalInfo().setCallStatus(value);
-        } else if (tag.equals(INC_ADD_INFO.CALL_TAKER_EXT))
+        }
+        else if (tag.equals(INC_ADD_INFO.CALL_TAKER_EXT))
         {
             cadData.getIncident(incidentId).getAdditionalInfo().setCallTakerExt(value);
-        } else if (tag.equals(INC_ADD_INFO.ALARM_LEVEL))
+        }
+        else if (tag.equals(INC_ADD_INFO.ALARM_LEVEL))
         {
             cadData.getIncident(incidentId).getAdditionalInfo().setAlarmLevel(value);
-        } else if (tag.equals(INC_ADD_INFO.ROTATION_PROVIDER_AREA))
+        }
+        else if (tag.equals(INC_ADD_INFO.ROTATION_PROVIDER_AREA))
         {
             cadData.getIncident(incidentId).getAdditionalInfo().setRotationProviderArea(value);
-        } else if (tag.equals(INC_ADD_INFO.COMMENT))
+        }
+        else if (tag.equals(INC_ADD_INFO.COMMENT))
         {
             cadData.getIncident(incidentId).getAdditionalInfo().setComment(value);
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.setCadDataIncAddInfo");
@@ -1412,17 +1528,22 @@
         {
             return cadData.getIncident(incidentId).getActivities().getVehicle();
-        } else if (tag.equals(INC_ACTIVITIES.ACTIVITY))
+        }
+        else if (tag.equals(INC_ACTIVITIES.ACTIVITY))
         {
             return cadData.getIncident(incidentId).getActivities().getActivity();
-        } else if (tag.equals(INC_ACTIVITIES.LOCATION))
+        }
+        else if (tag.equals(INC_ACTIVITIES.LOCATION))
         {
             return cadData.getIncident(incidentId).getActivities().getLocation();
-        } else if (tag.equals(INC_ACTIVITIES.COMMENT))
+        }
+        else if (tag.equals(INC_ACTIVITIES.COMMENT))
         {
             return cadData.getIncident(incidentId).getActivities().getComment();
-        } else if (tag.equals(INC_ACTIVITIES.DISP))
+        }
+        else if (tag.equals(INC_ACTIVITIES.DISP))
         {
             return cadData.getIncident(incidentId).getActivities().getDisp();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncActivities");
@@ -1442,17 +1563,22 @@
         {
             cadData.getIncident(incidentId).getActivities().setVehicle(value);
-        } else if (tag.equals(INC_ACTIVITIES.ACTIVITY))
+        }
+        else if (tag.equals(INC_ACTIVITIES.ACTIVITY))
         {
             cadData.getIncident(incidentId).getActivities().setActivity(value);
-        } else if (tag.equals(INC_ACTIVITIES.LOCATION))
+        }
+        else if (tag.equals(INC_ACTIVITIES.LOCATION))
         {
             cadData.getIncident(incidentId).getActivities().setLocation(value);
-        } else if (tag.equals(INC_ACTIVITIES.COMMENT))
+        }
+        else if (tag.equals(INC_ACTIVITIES.COMMENT))
         {
             cadData.getIncident(incidentId).getActivities().setComment(value);
-        } else if (tag.equals(INC_ACTIVITIES.DISP))
+        }
+        else if (tag.equals(INC_ACTIVITIES.DISP))
         {
             cadData.getIncident(incidentId).getActivities().setDisp(value);
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.setCadDataIncActivities");
@@ -1472,8 +1598,10 @@
         {
             return cadData.getIncident(incidentId).getCallBacks().getInitial();
-        } else if (tag.equals(INC_CALLBACK.COMMENT))
+        }
+        else if (tag.equals(INC_CALLBACK.COMMENT))
         {
             return cadData.getIncident(incidentId).getCallBacks().getComment();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncCallBack");
@@ -1493,14 +1621,18 @@
         {
             return cadData.getIncident(incidentId).getEditLog().getEdit();
-        } else if (tag.equals(INC_EDIT_LOG.REASON))
+        }
+        else if (tag.equals(INC_EDIT_LOG.REASON))
         {
             return cadData.getIncident(incidentId).getEditLog().getReason();
-        } else if (tag.equals(INC_EDIT_LOG.CHANGE_BY))
+        }
+        else if (tag.equals(INC_EDIT_LOG.CHANGE_BY))
         {
             return cadData.getIncident(incidentId).getEditLog().getChangeBy();
-        } else if (tag.equals(INC_EDIT_LOG.TERMINAL))
+        }
+        else if (tag.equals(INC_EDIT_LOG.TERMINAL))
         {
             return cadData.getIncident(incidentId).getEditLog().getTerminal();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncEditLog");
@@ -1520,14 +1652,18 @@
         {
             return cadData.getIncident(incidentId).getInfo().getCallInit();
-        } else if (tag.equals(INC_INFO.CALL_TAKEN))
+        }
+        else if (tag.equals(INC_INFO.CALL_TAKEN))
         {
             return cadData.getIncident(incidentId).getInfo().getCallTaken();
-        } else if (tag.equals(INC_INFO.TIME_IN_Q))
+        }
+        else if (tag.equals(INC_INFO.TIME_IN_Q))
         {
             return cadData.getIncident(incidentId).getInfo().getTimeInQ();
-        } else if (tag.equals(INC_INFO.LAST_UPDATED))
+        }
+        else if (tag.equals(INC_INFO.LAST_UPDATED))
         {
             return cadData.getIncident(incidentId).getInfo().getLastUpdated();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataIncInfo");
@@ -1556,110 +1692,146 @@
         {
             return cardfileData.getCoastalDivisionUnitList();
-        } else if (tag.equals(CARDFILE.POLICE_SHERIFF_CORONER))
+        }
+        else if (tag.equals(CARDFILE.POLICE_SHERIFF_CORONER))
         {
             return cardfileData.getPoliceSheriffCoronerList();
-        } else if (tag.equals(CARDFILE.COURTS))
+        }
+        else if (tag.equals(CARDFILE.COURTS))
         {
             return cardfileData.getCourtsList();
-        } else if (tag.equals(CARDFILE.PUBLIC_TRANSPORTATION))
+        }
+        else if (tag.equals(CARDFILE.PUBLIC_TRANSPORTATION))
         {
             return cardfileData.getPublicTransportationList();
-        } else if (tag.equals(CARDFILE.GG_OTHER))
+        }
+        else if (tag.equals(CARDFILE.GG_OTHER))
         {
             return cardfileData.getGgOtherList();
-        } else if (tag.equals(CARDFILE.MY_MISC))
+        }
+        else if (tag.equals(CARDFILE.MY_MISC))
         {
             return cardfileData.getMyMiscList();
-        } else if (tag.equals(CARDFILE.SL_MISC))
+        }
+        else if (tag.equals(CARDFILE.SL_MISC))
         {
             return cardfileData.getSlMiscList();
-        } else if (tag.equals(CARDFILE.VT_MISC))
+        }
+        else if (tag.equals(CARDFILE.VT_MISC))
         {
             return cardfileData.getVlMiscList();
-        } else if (tag.equals(CARDFILE.CHP_OFFICES))
+        }
+        else if (tag.equals(CARDFILE.CHP_OFFICES))
         {
             return cardfileData.getChpOfficesList();
-        } else if (tag.equals(CARDFILE.STATE_AGENCIES_FACILITIES))
+        }
+        else if (tag.equals(CARDFILE.STATE_AGENCIES_FACILITIES))
         {
             return cardfileData.getStateAgenciesFacilitiesList();
-        } else if (tag.equals(CARDFILE.GOVERNMENT_OFFICIALS))
+        }
+        else if (tag.equals(CARDFILE.GOVERNMENT_OFFICIALS))
         {
             return cardfileData.getGovernmentOfficialsList();
-        } else if (tag.equals(CARDFILE.FEDERAL_AGENCIES))
+        }
+        else if (tag.equals(CARDFILE.FEDERAL_AGENCIES))
         {
             return cardfileData.getFederalAgenciesList();
-        } else if (tag.equals(CARDFILE.RANCHES_LIVESTOCK))
+        }
+        else if (tag.equals(CARDFILE.RANCHES_LIVESTOCK))
         {
             return cardfileData.getRanchesLivestockList();
-        } else if (tag.equals(CARDFILE.FIRE_EMS))
+        }
+        else if (tag.equals(CARDFILE.FIRE_EMS))
         {
             return cardfileData.getFireEmsList();
-        } else if (tag.equals(CARDFILE.JAILS))
+        }
+        else if (tag.equals(CARDFILE.JAILS))
         {
             return cardfileData.getJailsList();
-        } else if (tag.equals(CARDFILE.HOSPITALS_MED_CENTERS))
+        }
+        else if (tag.equals(CARDFILE.HOSPITALS_MED_CENTERS))
         {
             return cardfileData.getHospitalsMedCentersList();
-        } else if (tag.equals(CARDFILE.TOW_COMPANIES))
+        }
+        else if (tag.equals(CARDFILE.TOW_COMPANIES))
         {
             return cardfileData.getTowCompaniesList();
-        } else if (tag.equals(CARDFILE.CALTRANS))
+        }
+        else if (tag.equals(CARDFILE.CALTRANS))
         {
             return cardfileData.getCalTransList();
-        } else if (tag.equals(CARDFILE.COUNTY_ROADS))
+        }
+        else if (tag.equals(CARDFILE.COUNTY_ROADS))
         {
             return cardfileData.getCountyRoadsList();
-        } else if (tag.equals(CARDFILE.UTILITIES))
+        }
+        else if (tag.equals(CARDFILE.UTILITIES))
         {
             return cardfileData.getUtilitiesList();
-        } else if (tag.equals(CARDFILE.ANIMAL_CONTROL))
+        }
+        else if (tag.equals(CARDFILE.ANIMAL_CONTROL))
         {
             return cardfileData.getAnimalControlList();
-        } else if (tag.equals(CARDFILE.AIRPORTS))
+        }
+        else if (tag.equals(CARDFILE.AIRPORTS))
         {
             return cardfileData.getAirportsList();
-        } else if (tag.equals(CARDFILE.CREDIT_CARDS))
+        }
+        else if (tag.equals(CARDFILE.CREDIT_CARDS))
         {
             return cardfileData.getCreditCardsList();
-        } else if (tag.equals(CARDFILE.GG_CRISIS_SHELTERS))
+        }
+        else if (tag.equals(CARDFILE.GG_CRISIS_SHELTERS))
         {
             return cardfileData.getGgCrisisSheltersList();
-        } else if (tag.equals(CARDFILE.RANGES))
+        }
+        else if (tag.equals(CARDFILE.RANGES))
         {
             return cardfileData.getRangesList();
-        } else if (tag.equals(CARDFILE.HOTLINES))
+        }
+        else if (tag.equals(CARDFILE.HOTLINES))
         {
             return cardfileData.getHotlinesList();
-        } else if (tag.equals(CARDFILE.HWY_PATROLS_OOS))
+        }
+        else if (tag.equals(CARDFILE.HWY_PATROLS_OOS))
         {
             return cardfileData.getHwyPatrolsOosList();
-        } else if (tag.equals(CARDFILE.PARKS_RECREATION))
+        }
+        else if (tag.equals(CARDFILE.PARKS_RECREATION))
         {
             return cardfileData.getParksRecreationList();
-        } else if (tag.equals(CARDFILE.SHELTERS))
+        }
+        else if (tag.equals(CARDFILE.SHELTERS))
         {
             return cardfileData.getSheltersList();
-        } else if (tag.equals(CARDFILE.SL_COUNTY_SERVICES))
+        }
+        else if (tag.equals(CARDFILE.SL_COUNTY_SERVICES))
         {
             return cardfileData.getSlCountyServicesList();
-        } else if (tag.equals(CARDFILE.SL_RESOURCES))
+        }
+        else if (tag.equals(CARDFILE.SL_RESOURCES))
         {
             return cardfileData.getSlResourcesList();
-        } else if (tag.equals(CARDFILE.TRUCK_TIRE_REPAIR))
+        }
+        else if (tag.equals(CARDFILE.TRUCK_TIRE_REPAIR))
         {
             return cardfileData.getTruckTireRepairList();
-        } else if (tag.equals(CARDFILE.MCC_EMPLOYEES))
+        }
+        else if (tag.equals(CARDFILE.MCC_EMPLOYEES))
         {
             return cardfileData.getMccEmployeesList();
-        } else if (tag.equals(CARDFILE.GATE_ACCESS_CODES))
+        }
+        else if (tag.equals(CARDFILE.GATE_ACCESS_CODES))
         {
             return cardfileData.getGateAccessCodesList();
-        } else if (tag.equals(CARDFILE.VT_CALL_SIGNS))
+        }
+        else if (tag.equals(CARDFILE.VT_CALL_SIGNS))
         {
             return cardfileData.getVtCallSignsList();
-        } else if (tag.equals(CARDFILE.SLCC_EMPLOYEES))
+        }
+        else if (tag.equals(CARDFILE.SLCC_EMPLOYEES))
         {
             return cardfileData.getSlccEmployeesList();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCardfileList");
@@ -1679,110 +1851,146 @@
         {
             selectedList = cardfileData.getCoastalDivisionUnitList();
-        } else if (log.listTitle.equals(CARDFILE.POLICE_SHERIFF_CORONER.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.POLICE_SHERIFF_CORONER.tag))
         {
             selectedList = cardfileData.getPoliceSheriffCoronerList();
-        } else if (log.listTitle.equals(CARDFILE.COURTS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.COURTS.tag))
         {
             selectedList = cardfileData.getCourtsList();
-        } else if (log.listTitle.equals(CARDFILE.PUBLIC_TRANSPORTATION.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.PUBLIC_TRANSPORTATION.tag))
         {
             selectedList = cardfileData.getPublicTransportationList();
-        } else if (log.listTitle.equals(CARDFILE.GG_OTHER.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.GG_OTHER.tag))
         {
             selectedList = cardfileData.getGgOtherList();
-        } else if (log.listTitle.equals(CARDFILE.MY_MISC.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.MY_MISC.tag))
         {
             selectedList = cardfileData.getMyMiscList();
-        } else if (log.listTitle.equals(CARDFILE.SL_MISC.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.SL_MISC.tag))
         {
             selectedList = cardfileData.getSlMiscList();
-        } else if (log.listTitle.equals(CARDFILE.VT_MISC.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.VT_MISC.tag))
         {
             selectedList = cardfileData.getVlMiscList();
-        } else if (log.listTitle.equals(CARDFILE.CHP_OFFICES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.CHP_OFFICES.tag))
         {
             selectedList = cardfileData.getChpOfficesList();
-        } else if (log.listTitle.equals(CARDFILE.STATE_AGENCIES_FACILITIES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.STATE_AGENCIES_FACILITIES.tag))
         {
             selectedList = cardfileData.getStateAgenciesFacilitiesList();
-        } else if (log.listTitle.equals(CARDFILE.GOVERNMENT_OFFICIALS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.GOVERNMENT_OFFICIALS.tag))
         {
             selectedList = cardfileData.getGovernmentOfficialsList();
-        } else if (log.listTitle.equals(CARDFILE.FEDERAL_AGENCIES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.FEDERAL_AGENCIES.tag))
         {
             selectedList = cardfileData.getFederalAgenciesList();
-        } else if (log.listTitle.equals(CARDFILE.RANCHES_LIVESTOCK.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.RANCHES_LIVESTOCK.tag))
         {
             selectedList = cardfileData.getRanchesLivestockList();
-        } else if (log.listTitle.equals(CARDFILE.FIRE_EMS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.FIRE_EMS.tag))
         {
             selectedList = cardfileData.getFireEmsList();
-        } else if (log.listTitle.equals(CARDFILE.JAILS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.JAILS.tag))
         {
             selectedList = cardfileData.getJailsList();
-        } else if (log.listTitle.equals(CARDFILE.HOSPITALS_MED_CENTERS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.HOSPITALS_MED_CENTERS.tag))
         {
             selectedList = cardfileData.getHospitalsMedCentersList();
-        } else if (log.listTitle.equals(CARDFILE.TOW_COMPANIES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.TOW_COMPANIES.tag))
         {
             selectedList = cardfileData.getTowCompaniesList();
-        } else if (log.listTitle.equals(CARDFILE.CALTRANS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.CALTRANS.tag))
         {
             selectedList = cardfileData.getCalTransList();
-        } else if (log.listTitle.equals(CARDFILE.COUNTY_ROADS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.COUNTY_ROADS.tag))
         {
             selectedList = cardfileData.getCountyRoadsList();
-        } else if (log.listTitle.equals(CARDFILE.UTILITIES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.UTILITIES.tag))
         {
             selectedList = cardfileData.getUtilitiesList();
-        } else if (log.listTitle.equals(CARDFILE.ANIMAL_CONTROL.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.ANIMAL_CONTROL.tag))
         {
             selectedList = cardfileData.getAnimalControlList();
-        } else if (log.listTitle.equals(CARDFILE.AIRPORTS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.AIRPORTS.tag))
         {
             selectedList = cardfileData.getAirportsList();
-        } else if (log.listTitle.equals(CARDFILE.CREDIT_CARDS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.CREDIT_CARDS.tag))
         {
             selectedList = cardfileData.getCreditCardsList();
-        } else if (log.listTitle.equals(CARDFILE.GG_CRISIS_SHELTERS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.GG_CRISIS_SHELTERS.tag))
         {
             selectedList = cardfileData.getGgCrisisSheltersList();
-        } else if (log.listTitle.equals(CARDFILE.RANGES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.RANGES.tag))
         {
             selectedList = cardfileData.getRangesList();
-        } else if (log.listTitle.equals(CARDFILE.HOTLINES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.HOTLINES.tag))
         {
             selectedList = cardfileData.getHotlinesList();
-        } else if (log.listTitle.equals(CARDFILE.HWY_PATROLS_OOS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.HWY_PATROLS_OOS.tag))
         {
             selectedList = cardfileData.getHwyPatrolsOosList();
-        } else if (log.listTitle.equals(CARDFILE.PARKS_RECREATION.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.PARKS_RECREATION.tag))
         {
             selectedList = cardfileData.getParksRecreationList();
-        } else if (log.listTitle.equals(CARDFILE.SHELTERS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.SHELTERS.tag))
         {
             selectedList = cardfileData.getSheltersList();
-        } else if (log.listTitle.equals(CARDFILE.SL_COUNTY_SERVICES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.SL_COUNTY_SERVICES.tag))
         {
             selectedList = cardfileData.getSlCountyServicesList();
-        } else if (log.listTitle.equals(CARDFILE.SL_RESOURCES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.SL_RESOURCES.tag))
         {
             selectedList = cardfileData.getSlResourcesList();
-        } else if (log.listTitle.equals(CARDFILE.TRUCK_TIRE_REPAIR.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.TRUCK_TIRE_REPAIR.tag))
         {
             selectedList = cardfileData.getTruckTireRepairList();
-        } else if (log.listTitle.equals(CARDFILE.MCC_EMPLOYEES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.MCC_EMPLOYEES.tag))
         {
             selectedList = cardfileData.getMccEmployeesList();
-        } else if (log.listTitle.equals(CARDFILE.GATE_ACCESS_CODES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.GATE_ACCESS_CODES.tag))
         {
             selectedList = cardfileData.getGateAccessCodesList();
-        } else if (log.listTitle.equals(CARDFILE.VT_CALL_SIGNS.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.VT_CALL_SIGNS.tag))
         {
             selectedList = cardfileData.getVtCallSignsList();
-        } else if (log.listTitle.equals(CARDFILE.SLCC_EMPLOYEES.tag))
+        }
+        else if (log.listTitle.equals(CARDFILE.SLCC_EMPLOYEES.tag))
         {
             selectedList = cardfileData.getSlccEmployeesList();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.editCardfileDataObject");
@@ -1794,32 +2002,42 @@
             cfdo.setName(log.newValue);
             selectedList.resort(cardfileData.getCardfileDataIndex(selectedList, log.id));
-        } else if (cfdo != null && log.command.equals(EditCommand.ADDRESS))
+        }
+        else if (cfdo != null && log.command.equals(EditCommand.ADDRESS))
         {
             cfdo.setAddress(log.newValue);
-        } else if (cfdo != null && log.command.equals(EditCommand.CITY))
+        }
+        else if (cfdo != null && log.command.equals(EditCommand.CITY))
         {
             cfdo.setCity(log.newValue);
-        } else if (cfdo != null && log.command.equals(EditCommand.STATE))
+        }
+        else if (cfdo != null && log.command.equals(EditCommand.STATE))
         {
             cfdo.setState(log.newValue);
-        } else if (cfdo != null && log.command.equals(EditCommand.ZIP))
+        }
+        else if (cfdo != null && log.command.equals(EditCommand.ZIP))
         {
             cfdo.setZip(log.newValue);
-        } else if (cfdo != null && log.command.equals(EditCommand.PHONE1))
+        }
+        else if (cfdo != null && log.command.equals(EditCommand.PHONE1))
         {
             cfdo.setPhone1(log.newValue);
-        } else if (cfdo != null && log.command.equals(EditCommand.PHONE2))
+        }
+        else if (cfdo != null && log.command.equals(EditCommand.PHONE2))
         {
             cfdo.setPhone2(log.newValue);
-        } else if (cfdo != null && log.command.equals(EditCommand.FAX))
+        }
+        else if (cfdo != null && log.command.equals(EditCommand.FAX))
         {
             cfdo.setFax(log.newValue);
-        } else if (log.command.equals(EditCommand.OBJECT_DELETE))
+        }
+        else if (log.command.equals(EditCommand.OBJECT_DELETE))
         {
             selectedList.removeDataObject(cardfileData.getCardfileDataIndex(selectedList, log.id));
-        } else if (log.command.equals(EditCommand.OBJECT_ADD))
+        }
+        else if (log.command.equals(EditCommand.OBJECT_ADD))
         {
             selectedList.addDataObject(log.newCardfileObject);
-        } else if (log.command.equals(EditCommand.TABLE_ADD))
+        }
+        else if (log.command.equals(EditCommand.TABLE_ADD))
         {
             if (cfdo != null)
@@ -1827,5 +2045,6 @@
                 cfdo.addComment(log.tableFields);
             }
-        } else if (log.command.equals(EditCommand.TABLE_DELETE))
+        }
+        else if (log.command.equals(EditCommand.TABLE_DELETE))
         {
             if (cfdo != null)
@@ -1833,5 +2052,6 @@
                 cfdo.removeComment(log.timeStamp);
             }
-        } else
+        }
+        else
         {
         }
@@ -1872,50 +2092,66 @@
         {
             return cadData.getUnit(unitNum).getMasterInc();
-        } else if (tag.equals(UNIT_TAGS.STATUS))
+        }
+        else if (tag.equals(UNIT_TAGS.STATUS))
         {
             return cadData.getUnit(unitNum).getStatus();
-        } else if (tag.equals(UNIT_TAGS.OOS))
+        }
+        else if (tag.equals(UNIT_TAGS.OOS))
         {
             return cadData.getUnit(unitNum).getOos();
-        } else if (tag.equals(UNIT_TAGS.TYPE))
+        }
+        else if (tag.equals(UNIT_TAGS.TYPE))
         {
             return cadData.getUnit(unitNum).getType();
-        } else if (tag.equals(UNIT_TAGS.CURR_LOC))
+        }
+        else if (tag.equals(UNIT_TAGS.CURR_LOC))
         {
             return cadData.getUnit(unitNum).getCurrentLocation();
-        } else if (tag.equals(UNIT_TAGS.DESTINATION))
+        }
+        else if (tag.equals(UNIT_TAGS.DESTINATION))
         {
             return cadData.getUnit(unitNum).getDestination();
-        } else if (tag.equals(UNIT_TAGS.MISC_INFO))
+        }
+        else if (tag.equals(UNIT_TAGS.MISC_INFO))
         {
             return cadData.getUnit(unitNum).getMisc();
-        } else if (tag.equals(UNIT_TAGS.STACK))
+        }
+        else if (tag.equals(UNIT_TAGS.STACK))
         {
             return cadData.getUnit(unitNum).getStack();
-        } else if (tag.equals(UNIT_TAGS.AREA))
+        }
+        else if (tag.equals(UNIT_TAGS.AREA))
         {
             return cadData.getUnit(unitNum).getArea();
-        } else if (tag.equals(UNIT_TAGS.OFFICER))
+        }
+        else if (tag.equals(UNIT_TAGS.OFFICER))
         {
             return cadData.getUnit(unitNum).getOfficer();
-        } else if (tag.equals(UNIT_TAGS.BADGE_NUM))
+        }
+        else if (tag.equals(UNIT_TAGS.BADGE_NUM))
         {
             return cadData.getUnit(unitNum).getBadge();
-        } else if (tag.equals(UNIT_TAGS.TIMER))
+        }
+        else if (tag.equals(UNIT_TAGS.TIMER))
         {
             return cadData.getUnit(unitNum).getTimerInString();
-        } else if (tag.equals(UNIT_TAGS.OFFICE))
+        }
+        else if (tag.equals(UNIT_TAGS.OFFICE))
         {
             return cadData.getUnit(unitNum).getOffice();
-        } else if (tag.equals(UNIT_TAGS.P))
+        }
+        else if (tag.equals(UNIT_TAGS.P))
         {
             return cadData.getUnit(unitNum).getP();
-        } else if (tag.equals(UNIT_TAGS.AGY))
+        }
+        else if (tag.equals(UNIT_TAGS.AGY))
         {
             return cadData.getUnit(unitNum).getAgy();
-        } else if (tag.equals(UNIT_TAGS.ALIAS))
+        }
+        else if (tag.equals(UNIT_TAGS.ALIAS))
         {
             return cadData.getUnit(unitNum).getAlias();
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.getCadDataUnitValue");
@@ -1936,50 +2172,66 @@
         {
             cadData.getUnit(unitNum).setMasterInc((String) value);
-        } else if (tag.equals(UNIT_TAGS.STATUS))
+        }
+        else if (tag.equals(UNIT_TAGS.STATUS))
         {
             cadData.getUnit(unitNum).setStatus((String) value);
-        } else if (tag.equals(UNIT_TAGS.OOS))
+        }
+        else if (tag.equals(UNIT_TAGS.OOS))
         {
             cadData.getUnit(unitNum).setOos((String) value);
-        } else if (tag.equals(UNIT_TAGS.TYPE))
+        }
+        else if (tag.equals(UNIT_TAGS.TYPE))
         {
             cadData.getUnit(unitNum).setType((String) value);
-        } else if (tag.equals(UNIT_TAGS.CURR_LOC))
+        }
+        else if (tag.equals(UNIT_TAGS.CURR_LOC))
         {
             cadData.getUnit(unitNum).setCurrentLocation((String) value);
-        } else if (tag.equals(UNIT_TAGS.DESTINATION))
+        }
+        else if (tag.equals(UNIT_TAGS.DESTINATION))
         {
             cadData.getUnit(unitNum).setDestination((String) value);
-        } else if (tag.equals(UNIT_TAGS.MISC_INFO))
+        }
+        else if (tag.equals(UNIT_TAGS.MISC_INFO))
         {
             cadData.getUnit(unitNum).setMisc((String) value);
-        } else if (tag.equals(UNIT_TAGS.STACK))
+        }
+        else if (tag.equals(UNIT_TAGS.STACK))
         {
             cadData.getUnit(unitNum).setStack((String) value);
-        } else if (tag.equals(UNIT_TAGS.AREA))
+        }
+        else if (tag.equals(UNIT_TAGS.AREA))
         {
             cadData.getUnit(unitNum).setArea((String) value);
-        } else if (tag.equals(UNIT_TAGS.OFFICER))
+        }
+        else if (tag.equals(UNIT_TAGS.OFFICER))
         {
             cadData.getUnit(unitNum).setOfficer((String) value);
-        } else if (tag.equals(UNIT_TAGS.BADGE_NUM))
+        }
+        else if (tag.equals(UNIT_TAGS.BADGE_NUM))
         {
             cadData.getUnit(unitNum).setBadge((String) value);
-        } else if (tag.equals(UNIT_TAGS.UNIT_STATUS))
+        }
+        else if (tag.equals(UNIT_TAGS.UNIT_STATUS))
         {
             cadData.getUnit(unitNum).setUnitStatus((UnitStatusEnums) value);
-        } else if (tag.equals(UNIT_TAGS.OFFICE))
+        }
+        else if (tag.equals(UNIT_TAGS.OFFICE))
         {
             cadData.getUnit(unitNum).setOffice((String) value);
-        } else if (tag.equals(UNIT_TAGS.P))
+        }
+        else if (tag.equals(UNIT_TAGS.P))
         {
             cadData.getUnit(unitNum).setP((String) value);
-        } else if (tag.equals(UNIT_TAGS.AGY))
+        }
+        else if (tag.equals(UNIT_TAGS.AGY))
         {
             cadData.getUnit(unitNum).setAgy((String) value);
-        } else if (tag.equals(UNIT_TAGS.ALIAS))
+        }
+        else if (tag.equals(UNIT_TAGS.ALIAS))
         {
             cadData.getUnit(unitNum).setAlias((String) value);
-        } else
+        }
+        else
         {
             throw new RemoteException("Wrong Enum sent into Coordinator.setCadDataUnitValue");
@@ -2095,8 +2347,10 @@
             {
                 cadData.unitAssignedToIncident(unit.beat, incidentNumber, unit.isPrimary);
-            } else if (unit.statusType.equals("1097"))
+            }
+            else if (unit.statusType.equals("1097"))
             {
                 cadData.unitArrivedAtIncidentScene(unit.beat, incidentNumber, unit.isPrimary);
-            } else if (unit.statusType.equals("1098"))
+            }
+            else if (unit.statusType.equals("1098"))
             {
                 cadData.unitAvailable(unit.beat);
Index: /trunk/src/tmcsim/cadsimulator/CADSimulator.java
===================================================================
--- /trunk/src/tmcsim/cadsimulator/CADSimulator.java	(revision 33)
+++ /trunk/src/tmcsim/cadsimulator/CADSimulator.java	(revision 44)
@@ -1,6 +1,4 @@
 package tmcsim.cadsimulator;
 
-import java.awt.event.WindowEvent;
-import java.awt.event.WindowListener;
 import java.io.File;
 import java.io.FileInputStream;
@@ -10,13 +8,10 @@
 import java.util.Calendar;
 import java.util.Properties;
-import java.util.logging.FileHandler;
 import java.util.logging.Level;
 import java.util.logging.Logger;
-
 import javax.swing.JOptionPane;
 import javax.swing.JWindow;
 import javax.swing.UIManager;
 import javax.xml.parsers.DocumentBuilderFactory;
-
 import tmcsim.cadsimulator.db.CMSDiversionDB;
 import tmcsim.cadsimulator.managers.ATMSManager;
@@ -25,243 +20,302 @@
 import tmcsim.cadsimulator.managers.ParamicsSimulationManager;
 import tmcsim.cadsimulator.managers.SimulationControlManager;
-import tmcsim.cadsimulator.viewer.CADSimulatorViewer;
-import tmcsim.client.cadclientgui.data.CADData;
+import tmcsim.cadsimulator.viewer.model.CADSimulatorModel;
 import tmcsim.common.SimulationException;
-import tmcsim.simulationmanager.SimulationManager;
-
+import tmcsim.interfaces.CADViewer;
 
 /**
- * CADSimulator is main class for the CAD Simulator application.  At 
- * construction the Coordinator, CoordinatorViewer, and all CAD Simulator 
- * Managers are initialized and data relationships are established.  
- * Simulation control is managed through the Coordinator and Managers.
- * The CADSimulator contains the instances of all Manager Objects that are used
- * to control the Simulation flow of data.<br>
+ * CADSimulator is main class for the CAD Simulator application. At construction
+ * the Coordinator, CoordinatorViewer, and all CAD Simulator Managers are
+ * initialized and data relationships are established. Simulation control is
+ * managed through the Coordinator and Managers. The CADSimulator contains the
+ * instances of all Manager Objects that are used to control the Simulation flow
+ * of data.<br>
  * <br>
- * 
- * The CADSimulator is initialized with a properties file containing the 
+ *
+ * The CADSimulator is initialized with a properties file containing the
  * following data items:<br>
  * <code>
  * -----------------------------------------------------------------------------<br>
- * CADClientPort          The port number to use for remote CAD Client connections.<br>
- * CoordinatorRMIPort     The port number to use for binding the Coordinator.<br>
- * CMSDiversionXML        The filepath for the xml file containing initialization data for the Diversion "database."
- * AudioFileLocation      The root directory path where audio files are referenced from.<br>
- * ParamicsProperties     The filepath for the properties file to initialize the ParamicsControlManager.<br>
- * ATMSProperties         The filepath for the properties file to initialize the ATMSManager.<br>
- * MediaProperties        The filepath for the properties file to initialize the MediaManager.<br>
- * ErrorFile              The filename of the error file used for logging errors.<br>
+ * CADClientPort The port number to use for remote CAD Client connections.<br>
+ * CoordinatorRMIPort The port number to use for binding the Coordinator.<br>
+ * CMSDiversionXML The filepath for the xml file containing initialization data
+ * for the Diversion "database." AudioFileLocation The root directory path where
+ * audio files are referenced from.<br>
+ * ParamicsProperties The filepath for the properties file to initialize the
+ * ParamicsControlManager.<br>
+ * ATMSProperties The filepath for the properties file to initialize the
+ * ATMSManager.<br>
+ * MediaProperties The filepath for the properties file to initialize the
+ * MediaManager.<br>
+ * ErrorFile The filename of the error file used for logging errors.<br>
  * ----------------------------------------------------------------------------<br>
  * Example File:<br>
- * CADClientPort          = 4444<br>
- * CoordinatorRMIPort     = 4445<br>
- * CMSDiversionXML        = ../data/cmsdiversions.xml<br>
- * AudioFileLocation      = ../audio/<br>
- * ParamicsProperties     = ../config/paramics.properties<br>
- * ATMSProperties         = ../config/atms.properties<br>
- * MediaProperties        = ../config/media.properties<br>
- * ErrorFile              = cad_sim_error.xml<br>
+ * CADClientPort = 4444<br>
+ * CoordinatorRMIPort = 4445<br>
+ * CMSDiversionXML = ../data/cmsdiversions.xml<br>
+ * AudioFileLocation = ../audio/<br>
+ * ParamicsProperties = ../config/paramics.properties<br>
+ * ATMSProperties = ../config/atms.properties<br>
+ * MediaProperties = ../config/media.properties<br>
+ * ErrorFile = cad_sim_error.xml<br>
  * </code>
  *
- * @author Matthew Cechini (mcechini@calpoly.edu)
+ * @author Matthew Cechini (mcechini@calpoly.edu) jdalbey
  * @version $Date: 2009/04/17 16:27:46 $ $Revision: 1.5 $
  */
-public class CADSimulator {
-    
-    /** Error logger. */
+public class CADSimulator
+{
+
+    private static final String CONFIG_FILE_NAME = "cad_simulator_config.properties";
+    /**
+     * Error logger.
+     */
     private static Logger cadSimLogger = Logger.getLogger("tmcsim.cadsimulator");
 
     /**
-     * Enumeration containing properties name values.  See CADSimulator class 
+     * Enumeration containing properties name values. See CADSimulator class
      * description for more information.
+     *
      * @author Matthew
      * @see CADSimulator
      */
-    private static enum CAD_PROPERTIES {
-        /** RMI port to accept CAD Client connections. */
-        CLIENT_PORT        ("CADClientPort"),       
-        /** RMI port to bind the Coordinator to for RMI communication. */
-        COOR_RMI_PORT      ("CoordinatorRMIPort"),  
-        
-        CAD_RMI_PORT       ("CADRmiPort"),
-        /** Filepath for xml file containing diversion data. */     
-        CMS_XML_FILE       ("CMSDiversionXML"), 
-        /** Filepath for xml file containing dvd control data. */
-        DVD_XML_FILE       ("DVDPlayerXML"),    
-        /** Filepath for xml file containing still image control data. */
-        IMAGE_XML_FILE     ("StillImagesXML"),
-        /** Root directory path where audio files are referenced from. */
-        AUDIO_LOCATION     ("AudioFileLocation"),
-        /** Filepath for the properties file to initialize the media manager. */
-        MEDIA_PROP_FILE    ("MediaProperties"),
-        /** Filepath for the properties file to initialize the paramics control manager. */
-        PARAMICS_PROP_FILE ("ParamicsProperties"),
-        /** Filepath for the properties file to initialize the atms manager. */
-        ATMS_PROP_FILE     ("ATMSProperties");
-        
+    private static enum CAD_PROPERTIES
+    {
+
+        /**
+         * RMI port to accept CAD Client connections.
+         */
+        CLIENT_PORT("CADClientPort"),
+        /**
+         * RMI port to bind the Coordinator to for RMI communication.
+         */
+        COOR_RMI_PORT("CoordinatorRMIPort"),
+        CAD_RMI_PORT("CADRmiPort"),
+        /**
+         * Filepath for xml file containing diversion data.
+         */
+        CMS_XML_FILE("CMSDiversionXML"),
+        /**
+         * Filepath for xml file containing dvd control data.
+         */
+        DVD_XML_FILE("DVDPlayerXML"),
+        /**
+         * Filepath for xml file containing still image control data.
+         */
+        IMAGE_XML_FILE("StillImagesXML"),
+        /**
+         * Root directory path where audio files are referenced from.
+         */
+        AUDIO_LOCATION("AudioFileLocation"),
+        /**
+         * Filepath for the properties file to initialize the media manager.
+         */
+        MEDIA_PROP_FILE("MediaProperties"),
+        /**
+         * Filepath for the properties file to initialize the paramics control
+         * manager.
+         */
+        PARAMICS_PROP_FILE("ParamicsProperties"),
+        /**
+         * Filepath for the properties file to initialize the atms manager.
+         */
+        ATMS_PROP_FILE("ATMSProperties"),
+        /**
+         * Class name of desired user interface.
+         */
+        USER_INTERFACE("UserInterface");
         public String name;
-        
-        private CAD_PROPERTIES(String n) {
-            name = n;
+
+        private CAD_PROPERTIES(String nam)
+        {
+            name = nam;
         }
     };
-        
-            
-    /** CADSimulatorViewer instance. */
-    protected static CADSimulatorViewer theViewer;
-
-    /** Coordinator instance. */
-    protected static  Coordinator theCoordinator;
-    
-    /** SoundPlayer instance. */
-    protected static  SoundPlayer theSoundPlayer = null;
-    
-    /** SimulationControlManager instance. */
-    protected static  SimulationControlManager theSimulationCntrlMgr = null;
-    
-    /**  ParamicsSimulationManager instance. */
-    protected static  ParamicsSimulationManager theParamicsSimMgr = null;
-    
-    /** IncidentManager instance. */
-    protected static  IncidentManager theIncidentMgr = null;
-    
-    /** MediaManager instance. */   
-    protected static  MediaManager theMediaMgr = null;
-    
-    /** ATMSManager instance. */
-    protected static  ATMSManager theATMSMgr = null; 
-
-    /** Properties file for the CADSimulator. */
-    private Properties cadSimulatorProperties;  
-    
-    private static final String CONFIG_FILE_NAME = "cad_simulator_config.properties";
-
-    /**
-     * Constructor.  Load the Properties file and initialize all CAD Simulator
-     * Managers and establish Manager data relationships.  A 
-     * CADSimulatorSocketHandler is instantiated and started to being 
-     * listening for remote CAD connections.  The CMSDiversionDB is initialized
-     * with the XML data(incomplete design).
-     * 
+    /**
+     * CADSimulatorViewer instance.
+     */
+    protected static CADViewer theViewer;
+    //protected static CADSimulatorViewer theViewer;
+    //protected static CADConsoleViewer theConsole;
+    protected static CADSimulatorModel theModel;
+    /**
+     * Coordinator instance.
+     */
+    protected static Coordinator theCoordinator;
+    /**
+     * SoundPlayer instance.
+     */
+    protected static SoundPlayer theSoundPlayer = null;
+    /**
+     * SimulationControlManager instance.
+     */
+    protected static SimulationControlManager theSimulationCntrlMgr = null;
+    /**
+     * ParamicsSimulationManager instance.
+     */
+    protected static ParamicsSimulationManager theParamicsSimMgr = null;
+    /**
+     * IncidentManager instance.
+     */
+    protected static IncidentManager theIncidentMgr = null;
+    /**
+     * MediaManager instance.
+     */
+    protected static MediaManager theMediaMgr = null;
+    /**
+     * ATMSManager instance.
+     */
+    protected static ATMSManager theATMSMgr = null;
+    /**
+     * Properties file for the CADSimulator.
+     */
+    private Properties cadSimulatorProperties;
+
+    /**
+     * Constructor. Load the Properties file and initialize all CAD Simulator
+     * Managers and establish Manager data relationships. A
+     * CADSimulatorSocketHandler is instantiated and started to being listening
+     * for remote CAD connections. The CMSDiversionDB is initialized with the
+     * XML data(incomplete design).
+     *
      * @param propertiesFile Filename of CAD Simulator properties file.
-     * @throws SimulationException if there is an error in initializing the CAD Simulator.
-     */
-    public CADSimulator(String propertiesFile) throws SimulationException {
-        
-        try {
+     * @throws SimulationException if there is an error in initializing the CAD
+     * Simulator.
+     */
+    public CADSimulator(String propertiesFile) throws SimulationException
+    {
+
+        try
+        {
             cadSimulatorProperties = new Properties();
             cadSimulatorProperties.load(new FileInputStream(propertiesFile));
-        }
-        catch (Exception e) {           
-            cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Constructor", 
+        } catch (Exception e)
+        {
+            cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Constructor",
                     "Exception in reading properties file.", e);
-            
-            throw new SimulationException(SimulationException.INITIALIZE_ERROR, e); 
-        }
-    
+
+            throw new SimulationException(SimulationException.INITIALIZE_ERROR, e);
+        }
+
         //Create the Coordinator and register it for RMI communicator.  Start the
         //CAD Simulator Socket Handler to begin to accept connections from CAD Clients.
-        try {
-            theViewer             = new CADSimulatorViewer();
-            theCoordinator        = new Coordinator();
+        try
+        {
+            String userInterfaceName =
+                    cadSimulatorProperties.getProperty(
+                    CAD_PROPERTIES.USER_INTERFACE.name);
+            if (userInterfaceName == null)
+            {
+                cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Constructor",
+                        propertiesFile + " missing property for user interface.");
+                throw new SimulationException(SimulationException.INITIALIZE_ERROR);
+            }
+            try
+            {
+                Class uiClass = Class.forName(userInterfaceName);
+                theViewer = (CADViewer) uiClass.newInstance();
+            } catch (Throwable exc)
+            {
+                cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Constructor",
+                        "Unable to instantiate user interface: " + userInterfaceName);
+                throw new SimulationException(SimulationException.INITIALIZE_ERROR);
+            }
+            theModel = new CADSimulatorModel();
+            theModel.addObserver(theViewer);
+
+            theCoordinator = new Coordinator(theModel);
+
             startRegistry(Integer.parseInt(
                     cadSimulatorProperties.getProperty(
-                            CAD_PROPERTIES.COOR_RMI_PORT.name).trim()));
+                    CAD_PROPERTIES.COOR_RMI_PORT.name).trim()));
             startRegistry(Integer.parseInt(
                     cadSimulatorProperties.getProperty(
-                            CAD_PROPERTIES.CAD_RMI_PORT.name).trim()));
-
-            theSimulationCntrlMgr = new SimulationControlManager(theCoordinator);   
-            
-            theATMSMgr            = new ATMSManager(
-                    cadSimulatorProperties.getProperty(
-                            CAD_PROPERTIES.ATMS_PROP_FILE.name));
-            
-            theMediaMgr           = new MediaManager(
-                    cadSimulatorProperties.getProperty(
-                            CAD_PROPERTIES.MEDIA_PROP_FILE.name),
-                            theATMSMgr, theViewer);
-            
-            theParamicsSimMgr     = new ParamicsSimulationManager(
-                    cadSimulatorProperties.getProperty(
-                            CAD_PROPERTIES.PARAMICS_PROP_FILE.name),
-                            theCoordinator, theMediaMgr);   
-            
-            theSoundPlayer        = new SoundPlayer(
-                    cadSimulatorProperties.getProperty(
-                            CAD_PROPERTIES.AUDIO_LOCATION.name));
+                    CAD_PROPERTIES.CAD_RMI_PORT.name).trim()));
+
+            theSimulationCntrlMgr = new SimulationControlManager(theCoordinator);
+
+            theATMSMgr = new ATMSManager(
+                    cadSimulatorProperties.getProperty(
+                    CAD_PROPERTIES.ATMS_PROP_FILE.name));
+
+            theMediaMgr = new MediaManager(
+                    cadSimulatorProperties.getProperty(
+                    CAD_PROPERTIES.MEDIA_PROP_FILE.name),
+                    theATMSMgr, theModel);
+
+            theParamicsSimMgr = new ParamicsSimulationManager(
+                    cadSimulatorProperties.getProperty(
+                    CAD_PROPERTIES.PARAMICS_PROP_FILE.name),
+                    theCoordinator, theMediaMgr);
+
+            theSoundPlayer = new SoundPlayer(
+                    cadSimulatorProperties.getProperty(
+                    CAD_PROPERTIES.AUDIO_LOCATION.name));
             theSoundPlayer.start();
-            
-            theIncidentMgr        = new IncidentManager(theCoordinator, theSoundPlayer);    
-            
+
+            theIncidentMgr = new IncidentManager(theCoordinator, theSoundPlayer);
+
 
             //Begin accepting Client connections
             CADSimulatorSocketHandler tmsh = new CADSimulatorSocketHandler(
                     Integer.parseInt(cadSimulatorProperties.getProperty(
-                            CAD_PROPERTIES.CLIENT_PORT.name).trim()));
-            tmsh.start();   
-        }       
-        catch (RemoteException e) {
-            cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Constructor", 
+                    CAD_PROPERTIES.CLIENT_PORT.name).trim()));
+            tmsh.start();
+        } catch (RemoteException e)
+        {
+            cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Constructor",
                     "Exception in starting Coordinator.", e);
-            
+
             throw new SimulationException(SimulationException.BINDING, e);
-        }       
-        
+        }
+
         //Load CMS Diversion Information from the XML file
-        try {       
-            if(cadSimulatorProperties.getProperty(
-                    CAD_PROPERTIES.CMS_XML_FILE.name) != null) {
-                    CMSDiversionDB.getInstance().loadFromXML(
+        try
+        {
+            if (cadSimulatorProperties.getProperty(
+                    CAD_PROPERTIES.CMS_XML_FILE.name) != null)
+            {
+                CMSDiversionDB.getInstance().loadFromXML(
                         DocumentBuilderFactory.newInstance().newDocumentBuilder()
-                            .parse(new File(cadSimulatorProperties.getProperty(
-                                    CAD_PROPERTIES.CMS_XML_FILE.name))));
-            }           
-        }
-        catch (Exception e) 
-        {
-            cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Constructor", 
+                        .parse(new File(cadSimulatorProperties.getProperty(
+                        CAD_PROPERTIES.CMS_XML_FILE.name))));
+            }
+        } catch (Exception e)
+        {
+            cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Constructor",
                     "Exception in parsing CMSDiversion xml file.", e);
-            
-            JOptionPane.showMessageDialog(new JWindow(), "Unable to open " + 
-                    cadSimulatorProperties.getProperty(CAD_PROPERTIES.CMS_XML_FILE.name), 
-                "Initialization Error", JOptionPane.WARNING_MESSAGE);   
-        }
-             
-        theViewer.addWindowListener(new WindowListener() {
-            public void windowClosed(WindowEvent e)  {}
-            public void windowOpened(WindowEvent e)  {}            
-            public void windowIconified(WindowEvent e)  {}         
-            public void windowDeiconified(WindowEvent e)  {}    
-            public void windowActivated(WindowEvent e)  {}                             
-            public void windowDeactivated(WindowEvent e)  {}         
-            public void windowClosing(WindowEvent e)  {   
-                System.exit(0);
-            }           
-        });
-        
+
+            JOptionPane.showMessageDialog(new JWindow(), "Unable to open "
+                    + cadSimulatorProperties.getProperty(CAD_PROPERTIES.CMS_XML_FILE.name),
+                    "Initialization Error", JOptionPane.WARNING_MESSAGE);
+        }
+
         theViewer.setVisible(true);
 
-    } 
-    
-    /**
-     * Binds the Coordinator to an RMI port so that the SimulationManager
-     * can communicate with it, and so that the Coordinator can perform RMI
-     * callback method calls.  The port numbers and RMI designators are parsed from
-     * the properties file file.
+    }
+
+    /**
+     * Binds the Coordinator to an RMI port so that the SimulationManager can
+     * communicate with it, and so that the Coordinator can perform RMI callback
+     * method calls. The port numbers and RMI designators are parsed from the
+     * properties file file.
      *
      * @param theCoor A reference to the Coordinator object.
-     * @throws SimulationException if there are errors in binding the RMI to 
-     * a port and name.
-     */
-    private void startRegistry(Integer regPort) throws SimulationException {
-        
-        try{
-            LocateRegistry.createRegistry(regPort);                             
-            
+     * @throws SimulationException if there are errors in binding the RMI to a
+     * port and name.
+     */
+    private void startRegistry(Integer regPort) throws SimulationException
+    {
+
+        try
+        {
+//            if (LocateRegistry.getRegistry(regPort) == null)
+//            {
+            LocateRegistry.createRegistry(regPort);
             String registryURL = "rmi://localhost:" + regPort + "/coordinator";
             Naming.rebind(registryURL, theCoordinator);
-        }
-        catch (Exception e) {           
+//            }
+        } catch (Exception e)
+        {
             throw new SimulationException(SimulationException.BINDING, e);
         }
@@ -269,82 +323,100 @@
 
     /**
-     * Method returns a String represetnation of the current time.  String format
-     * is HHMM 
+     * Method returns a String representation of the current time. String format
+     * is HHMM
      *
      * @return String representation of the current time.
      */
-    public static String getCADTime() {
-        String time = new String();     
+    public static String getCADTime()
+    {
+        String time = new String();
 
         Calendar rightNow = Calendar.getInstance();
-        
-        if(rightNow.get(Calendar.HOUR_OF_DAY) < 10)
+
+        if (rightNow.get(Calendar.HOUR_OF_DAY) < 10)
+        {
             time += "0";
-        
+        }
+
         time += (String.valueOf(rightNow.get(Calendar.HOUR_OF_DAY)));
-        
-        if(rightNow.get(Calendar.MINUTE) < 10)
+
+        if (rightNow.get(Calendar.MINUTE) < 10)
+        {
             time += "0";
-        
-        time += (String.valueOf(rightNow.get(Calendar.MINUTE)));        
-                            
-        return time;        
-    }           
-    
-    /**
-     * Returns a string representation of the current date.  String format is:
+        }
+
+        time += (String.valueOf(rightNow.get(Calendar.MINUTE)));
+
+        return time;
+    }
+
+    /**
+     * Returns a string representation of the current date. String format is:
      * MMDDYY
      *
      * @return String format of the date.
      */
-    public static String getCADDate() {
+    public static String getCADDate()
+    {
         String date = new String();
-        
+
         Calendar rightNow = Calendar.getInstance();
-        
+
         //Months are zero referenced
-        if(rightNow.get(Calendar.MONTH) + 1 < 10)
+        if (rightNow.get(Calendar.MONTH) + 1 < 10)
+        {
             date += "0";
-        
-        date += (String.valueOf(rightNow.get(Calendar.MONTH)+ 1));
-        
-        if(rightNow.get(Calendar.DAY_OF_MONTH) < 10)
+        }
+
+        date += (String.valueOf(rightNow.get(Calendar.MONTH) + 1));
+
+        if (rightNow.get(Calendar.DAY_OF_MONTH) < 10)
+        {
             date += "0";
-        
-        date += (String.valueOf(rightNow.get(Calendar.DAY_OF_MONTH)));      
-                            
-        if(rightNow.get(Calendar.YEAR) % 1000 < 10)
+        }
+
+        date += (String.valueOf(rightNow.get(Calendar.DAY_OF_MONTH)));
+
+        if (rightNow.get(Calendar.YEAR) % 1000 < 10)
+        {
             date += "0";
-        
-        date += (String.valueOf(rightNow.get(Calendar.YEAR) % 1000));                               
-                            
-        return date;    
-        
+        }
+
+        date += (String.valueOf(rightNow.get(Calendar.YEAR) % 1000));
+
+        return date;
+
     }
-        
-    /**
-     * Main class.  Instantiate a CAD Simulator with the properties file 
+
+    /**
+     * Main class. Instantiate a CAD Simulator with the properties file
      * specified on the command line or the default properties file
-     * 
+     *
      * @param args Command line arguments.
      */
-    public static void main(String[] args) {
-        if(System.getProperty("CONFIG_DIR") == null){
-        	System.setProperty("CONFIG_DIR", "config");
-        }
-        try {
+    public static void main(String[] args)
+    {
+        if (System.getProperty("CONFIG_DIR") == null)
+        {
+            System.setProperty("CONFIG_DIR", "config");
+        }
+        try
+        {
             UIManager.setLookAndFeel(UIManager.getSystemLookAndFeelClassName());
-           new CADSimulator(System.getProperty("CONFIG_DIR") + System.getProperty("file.separator") + CONFIG_FILE_NAME);
-        }
-        catch (Exception e) {
-            cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Main", 
+            String propFile = System.getProperty("CONFIG_DIR")
+                    + System.getProperty("file.separator")
+                    + CONFIG_FILE_NAME;
+            new CADSimulator(propFile);
+        } catch (Exception e)
+        {
+            cadSimLogger.logp(Level.SEVERE, "CADSimulator", "Main",
                     "Error initializing application.", e);
-            
-            JOptionPane.showMessageDialog(new JWindow(), e.getMessage(), 
-                    "Error - Program Exiting", JOptionPane.ERROR_MESSAGE);  
-            
+
+            JOptionPane.showMessageDialog(new JWindow(), e.getMessage(),
+                    "Error - Program Exiting", JOptionPane.ERROR_MESSAGE);
+
             System.exit(-1);
         }
-        
+
     }
-} 
+}
Index: /trunk/test/tmcsim/simulationmanager/SimulationManagerSmokeTest.java
===================================================================
--- /trunk/test/tmcsim/simulationmanager/SimulationManagerSmokeTest.java	(revision 43)
+++ /trunk/test/tmcsim/simulationmanager/SimulationManagerSmokeTest.java	(revision 44)
@@ -55,4 +55,5 @@
                     } catch (Exception e)
                     {
+                        e.printStackTrace();
                         fail("Couldn't launch CADSimulator");
                     }
