Ignore:
Timestamp:
03/10/06 13:05:15 (19 years ago)
Author:
remar
Message:
File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/org.modelica.mdt.omc/src/org/modelica/mdt/omc/OMCProxy.java

    r405 r406  
    5656import org.modelica.mdt.core.List;
    5757import org.modelica.mdt.core.ListElement;
     58import org.modelica.mdt.core.ModelicaParserException;
    5859import org.modelica.mdt.core.compiler.ConnectException;
    5960import org.modelica.mdt.core.compiler.ElementsInfo;
     
    633634        getErrorString();
    634635       
    635         return ModelicaParser.parseList(retval);
     636        List list = null;
     637        try
     638        {
     639            list = ModelicaParser.parseList(retval);
     640        }
     641        catch(ModelicaParserException e)
     642        {
     643            throw new UnexpectedReplyException("Unable to parse list: "
     644                    + e.getMessage());
     645        }
     646       
     647        return list;
    636648    }
    637649
     
    741753        else
    742754        {
    743             res.setClassNames(ModelicaParser.parseList(retval));
     755            try
     756            {
     757                res.setClassNames(ModelicaParser.parseList(retval));
     758            }
     759            catch (ModelicaParserException e)
     760            {
     761                throw new UnexpectedReplyException("Unable to parse list: "
     762                        + e.getMessage());
     763            }
    744764
    745765            /*
     
    795815        retval = "{" + retval + "}";
    796816
    797         List tokens = ModelicaParser.parseList(retval);
     817        List tokens = null;
     818        try
     819        {
     820            tokens = ModelicaParser.parseList(retval);
     821        }
     822        catch (ModelicaParserException e1)
     823        {
     824            throw new UnexpectedReplyException("Unable to parse list: "
     825                    + e1.getMessage());
     826        }
    798827       
    799828        String filePath = tokens.elementAt(0).toString();
     
    867896                 * hope for the best
    868897                 */
    869                 List parsedList = ModelicaParser.parseList(retval);
     898                List parsedList = null;
     899                try
     900                {
     901                    parsedList = ModelicaParser.parseList(retval);
     902                }
     903                catch (ModelicaParserException e)
     904                {
     905                    throw new UnexpectedReplyException("Unable to parse list: "
     906                            + e.getMessage());
     907                }
    870908               
    871909                /* convert the parsedList to a collection of ElementsInfo:s */
Note: See TracChangeset for help on using the changeset viewer.