mil.dod.th.ose.gui.webapp/src/mil/dod/th/ose/gui/webapp/mp/MissionArgumentModel.java
private Object convertToActualType(final String value)
    {
        if (m_Type == MissionVariableTypesEnum.DOUBLE)
        {
            return Double.parseDouble(value);
        }
        else if (m_Type == MissionVariableTypesEnum.FLOAT)
        {
            return Float.parseFloat(value);
        }
        else if (m_Type == MissionVariableTypesEnum.INTEGER)
        {
            return Integer.parseInt(value);
        }
        else if (m_Type == MissionVariableTypesEnum.LONG)
        {
            return Long.parseLong(value);
        }
        else if (m_Type == MissionVariableTypesEnum.SHORT)
        {
            return Short.parseShort(value);
        }
        else if (m_Type == MissionVariableTypesEnum.BYTE)
        {
            return Byte.parseByte(value);
        }
        else if (m_Type == MissionVariableTypesEnum.BOOLEAN)
        {
            if (value.equalsIgnoreCase(Boolean.TRUE.toString()))
            {
                return true;
            }
            else if (value.equalsIgnoreCase(Boolean.FALSE.toString()))
            {
                return false;
            }
            else
            {
                throw new IllegalArgumentException(String.format("Value: %s cannot be parsed to a boolean value.", 
                        value));
            }
        }
        else
        {
            return checkStringTypes(value);
        }
    }
/**
     * Store the type of the object as the actual type expected.
     * @param value
     *     the string representation of the value to set for this argument
     * @return
     *     the object representing the correct value of this argument
     */
Store the type of the object as the actual type expected.
@param value
the string representation of the value to set for this argument
@return
the object representing the correct value of this argument
Store the type of the object as the actual type expected . @param value the string representation of the value to set for this argument @return the object representing the correct value of this argument
private Object convertToActualType(final String value)
    {
        if (m_Type == MissionVariableTypesEnum.DOUBLE)
        {
            return Double.parseDouble(value);
        }
        else if (m_Type == MissionVariableTypesEnum.FLOAT)
        {
            return Float.parseFloat(value);
        }
        else if (m_Type == MissionVariableTypesEnum.INTEGER)
        {
            return Integer.parseInt(value);
        }
        else if (m_Type == MissionVariableTypesEnum.LONG)
        {
            return Long.parseLong(value);
        }
        else if (m_Type == MissionVariableTypesEnum.SHORT)
        {
            return Short.parseShort(value);
        }
        else if (m_Type == MissionVariableTypesEnum.BYTE)
        {
            return Byte.parseByte(value);
        }
        else if (m_Type == MissionVariableTypesEnum.BOOLEAN)
        {
            if (value.equalsIgnoreCase(Boolean.TRUE.toString()))
            {
                return true;
            }
            else if (value.equalsIgnoreCase(Boolean.FALSE.toString()))
            {
                return false;
            }
            else
            {
                throw new IllegalArgumentException(String.format("Value: %s cannot be parsed to a boolean value.", 
                        value));
            }
        }
        else
        {
            return checkStringTypes(value);
        }
    }
private Object convertToActualType ( final String value ) { if ( m_Type == MissionVariableTypesEnum . DOUBLE ) { return Double . parseDouble ( value ) ; } else if ( m_Type == MissionVariableTypesEnum . FLOAT ) { return Float . parseFloat ( value ) ; } else if ( m_Type == MissionVariableTypesEnum . INTEGER ) { return Integer . parseInt ( value ) ; } else if ( m_Type == MissionVariableTypesEnum . LONG ) { return Long . parseLong ( value ) ; } else if ( m_Type == MissionVariableTypesEnum . SHORT ) { return Short . parseShort ( value ) ; } else if ( m_Type == MissionVariableTypesEnum . BYTE ) { return Byte . parseByte ( value ) ; } else if ( m_Type == MissionVariableTypesEnum . BOOLEAN ) { if ( value . equalsIgnoreCase ( Boolean . TRUE . toString ( ) ) ) { return true ; } else if ( value . equalsIgnoreCase ( Boolean . FALSE . toString ( ) ) ) { return false ; } else { throw new IllegalArgumentException ( String . format ( "Value: %s cannot be parsed to a boolean value." , value ) ) ; } } else { return checkStringTypes ( value ) ; } }
Store the type of the object as the actual type expected.
Store the type of the object as the actual type expected .