mil.dod.th.ose.shell/src/mil/dod/th/ose/shell/ObservationCommands.java
private boolean convertAndWrite(final Observation obs)
    {
        final byte[] xmlBytes;
        try
        {
            xmlBytes = m_XmlMarshalService.createXmlByteArray(obs, true);
        }
        catch (final MarshalException ex)
        {
            m_LogService.warning(ex, "Unable to convert observation with UUID [%s] to xml.", obs.getUuid());
            return false;
        }
        
        try
        {
            writeObsFile(obs.getUuid(), xmlBytes);
        }
        catch (final IOException ex)
        {
            m_LogService.warning(ex, "Unable to wrtie observation with UUID [%s] to a file.", obs.getUuid());
            return false;
        }
        return true;
    }
/**
     * Converts the specified observation to XML and then writes the XML data to a file.
     * 
     * @param obs
     *      Observation to be converted and written to a file.
     * @return
     *      True if the observation was successfully converted/written and false otherwise.
     */
Converts the specified observation to XML and then writes the XML data to a file.

@param obs
Observation to be converted and written to a file.
@return
True if the observation was successfully converted/written and false otherwise.
Converts the specified observation to XML and then writes the XML data to a file . @param obs Observation to be converted and written to a file . @return True if the observation was successfully converted / written and false otherwise .
private boolean convertAndWrite(final Observation obs)
    {
        final byte[] xmlBytes;
        try
        {
            xmlBytes = m_XmlMarshalService.createXmlByteArray(obs, true);
        }
        catch (final MarshalException ex)
        {
            m_LogService.warning(ex, "Unable to convert observation with UUID [%s] to xml.", obs.getUuid());
            return false;
        }
        try
        {
            writeObsFile(obs.getUuid(), xmlBytes);
        }
        catch (final IOException ex)
        {
            m_LogService.warning(ex, "Unable to wrtie observation with UUID [%s] to a file.", obs.getUuid());
            return false;
        }
        return true;
    }
private boolean convertAndWrite ( final Observation obs ) { final byte [ ] xmlBytes ; try { xmlBytes = m_XmlMarshalService . createXmlByteArray ( obs , true ) ; } catch ( final MarshalException ex ) { m_LogService . warning ( ex , "Unable to convert observation with UUID [%s] to xml." , obs . getUuid ( ) ) ; return false ; } try { writeObsFile ( obs . getUuid ( ) , xmlBytes ) ; } catch ( final IOException ex ) { m_LogService . warning ( ex , "Unable to wrtie observation with UUID [%s] to a file." , obs . getUuid ( ) ) ; return false ; } return true ; }
Converts the specified observation to XML and then writes the XML data to a file.
Converts the specified observation to XML and then writes the XML data to a file .