Ignore:
Timestamp:
01/26/06 15:36:27 (19 years ago)
Author:
boris
Message:
  • added an abstraction around modelica nested lists and updated relevant methods to use it instead of the old Collection<Object> way
File:
1 edited

Legend:

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

    r277 r287  
    4747import java.io.IOException;
    4848import java.util.StringTokenizer;
    49 import java.util.Vector;
    5049
    5150import org.eclipse.core.resources.IFile;
    5251import org.eclipse.core.runtime.Platform;
    5352import org.modelica.mdt.core.IModelicaClass;
     53import org.modelica.mdt.core.List;
    5454import org.modelica.mdt.core.compiler.ConnectException;
    5555import org.modelica.mdt.core.compiler.IModelicaCompiler;
     
    518518     * @throws InitializationException
    519519     */
    520     public Vector<Object> getClassNames(String className)
     520    public List getClassNames(String className)
    521521        throws ConnectException, UnexpectedReplyException
    522522    {
     
    584584        String fullName = file.getLocation().toString();
    585585        String retval =
    586             sendExpression("loadFileInteractive(\"" + fullName + "\")");
     586            sendExpression("loadFileInteractiveQualified(\"" + fullName + "\")");
    587587       
    588588        /*
     
    649649        retval = "{" + retval + "}";
    650650
    651         Vector<Object> tokens = ModelicaParser.parseList(retval);
     651        List tokens = ModelicaParser.parseList(retval);
    652652        int line;
    653653
    654654        try
    655655        {
    656             line = Integer.parseInt((String)tokens.elementAt(1));
     656            line = Integer.parseInt(tokens.elementAt(1).toString());
    657657        }
    658658        catch (NumberFormatException e)
     
    663663        }
    664664       
    665         return new ElementLocation((String)tokens.elementAt(0), line);
     665        return new ElementLocation(tokens.elementAt(0).toString(), line);
    666666    }
    667667   
     
    687687     * @throws UnexpectedReplyException
    688688     */
    689     public Vector<Object> getElementsInfo(String className)
     689    public List getElementsInfo(String className)
    690690        throws ConnectException, InvocationError, UnexpectedReplyException
    691691    {
Note: See TracChangeset for help on using the changeset viewer.