mil.dod.th.ose.remote.integration/src/mil/dod/th/ose/remote/integration/MissionProgramNamespaceUtils.java
public static void removeMissionProgram(final String missionName, final Socket socket) throws IOException, 
        InterruptedException
    {
        MessageListener listener = new MessageListener(socket);
        //removal message
        RemoveMissionProgramRequestData requestMessage = RemoveMissionProgramRequestData.newBuilder().
                setMissionName(missionName).build();
        
        //create execution message
        TerraHarvestMessage message = TestMissionProgrammingNamespace.
                createMissionProgramMessage(MissionProgrammingMessageType.RemoveMissionProgramRequest, requestMessage);
        
        // send out message
        message.writeDelimitedTo(socket.getOutputStream());
        
        //wait for execution and response, response is from the actual thread executing the mission program
        listener.waitForMessage(Namespace.MissionProgramming, 
                MissionProgrammingMessageType.RemoveMissionProgramResponse, 1000);
    }
/**
     * Remove a mission program. Assumes that the mission is canceled or shutdown.
     * @param missionName 
     *      the name of the mission program
     * @param socket
     *      the socket to use for communication to the controller
     */
Remove a mission program. Assumes that the mission is canceled or shutdown.
@param missionName
the name of the mission program
@param socket
the socket to use for communication to the controller
Remove a mission program . Assumes that the mission is canceled or shutdown . @param missionName the name of the mission program @param socket the socket to use for communication to the controller
public static void removeMissionProgram(final String missionName, final Socket socket) throws IOException, 
        InterruptedException
    {
        MessageListener listener = new MessageListener(socket);
        RemoveMissionProgramRequestData requestMessage = RemoveMissionProgramRequestData.newBuilder().
                setMissionName(missionName).build();
        TerraHarvestMessage message = TestMissionProgrammingNamespace.
                createMissionProgramMessage(MissionProgrammingMessageType.RemoveMissionProgramRequest, requestMessage);
        message.writeDelimitedTo(socket.getOutputStream());
        listener.waitForMessage(Namespace.MissionProgramming, 
                MissionProgrammingMessageType.RemoveMissionProgramResponse, 1000);
    }
public static void removeMissionProgram ( final String missionName , final Socket socket ) throws IOException , InterruptedException { MessageListener listener = new MessageListener ( socket ) ; RemoveMissionProgramRequestData requestMessage = RemoveMissionProgramRequestData . newBuilder ( ) . setMissionName ( missionName ) . build ( ) ; TerraHarvestMessage message = TestMissionProgrammingNamespace . createMissionProgramMessage ( MissionProgrammingMessageType . RemoveMissionProgramRequest , requestMessage ) ; message . writeDelimitedTo ( socket . getOutputStream ( ) ) ; listener . waitForMessage ( Namespace . MissionProgramming , MissionProgrammingMessageType . RemoveMissionProgramResponse , 1000 ) ; }
Remove a mission program.
Remove a mission program .
//removal message //create execution message // send out message //wait for execution and response, response is from the actual thread executing the mission program