Examples of InterpreterException


Examples of Exceptions.Interpreter.InterpreterException

        nLinea = 0;
        posicion = 0;
        generarMapaLineas();
        do {
            if(nLlamadasRecursivas == 0) {
                throw new InterpreterException("Número de llamadas recursivas demasiado grande.");
            }
            nLinea++;
            try {
                leerSiguienteToken();
                mapaLineas.put(nLinea, posicion);
                PASEO();
            }
            catch (Exception e) {
                throw new InterpreterException("Línea " + nLinea + ": " + e.getMessage());
            }
            if (!tokenActual.lexemasIguales("TK_FIN_SENT") && !tokenActual.lexemasIguales("TK_SALIDA")) {
                throw new NewLineException("Encontrado '" + this.devolverErrorMatch(tokenActual.getLexema().substring(3)) + "', esperaba 'salto de línea'.");
            }
        }
View Full Code Here

Examples of abstrasy.interpreter.InterpreterException

        Object obj = getArgExternalInstance(commande, argindex, accessType);
        if (instance.isInstance(obj)) {
            return obj;
        }
        else {
            throw new InterpreterException(StdErrors.extend(StdErrors.Invalid_parameter, "Object (" + obj.getClass().getName() + ") required " + instance.getName()));
        }
    }
View Full Code Here

Examples of abstrasy.interpreter.InterpreterException

   
    public Node get(String id) throws Exception {
        for (int i = 0; i < oalist.size(); i++)
            if (oalist.get(i).equals(id))
                return oalist.get(i).getNode();
        throw new InterpreterException(StdErrors.extend(StdErrors.Key_not_found,"\'"+id));
    }
View Full Code Here

Examples of abstrasy.interpreter.InterpreterException

        for (int i = 0; i < oalist.size(); i++)
            if (oalist.get(i).equals(id)){
                oalist.get(i).setNode(value);
                return;
            }
        throw new InterpreterException(StdErrors.extend(StdErrors.Key_not_found,"\'"+id));
    }
View Full Code Here

Examples of abstrasy.interpreter.InterpreterException

            catch (Exception e) {
                if(Interpreter.isDebugMode()){
                    e.printStackTrace();
                    Interpreter.Log(e.toString());
                }
                throw new InterpreterException(StdErrors.extend(StdErrors.Object_not_clonable, e.getMessage()));
            }
            this.value=value;
        }
View Full Code Here

Examples of abstrasy.interpreter.InterpreterException

     * @return old
     * @throws InterpreterException
     */
    public static final Node swap(Node node) throws InterpreterException {
        if (node == null)
            throw new InterpreterException(StdErrors.Internal_error);
        Interpreter interpreter = Interpreter.mySelf();
        Node pred = interpreter.getSelf();
        interpreter.setSelf(node);
        return pred;
    }
View Full Code Here

Examples of abstrasy.interpreter.InterpreterException

    public static final Node get() throws InterpreterException {
        Node res = Interpreter.mySelf().getSelf();
        if (res != null)
            return res.requireReadLockAccess();
        else
            throw new InterpreterException(StdErrors.Symbol_not_defined);
    }
View Full Code Here

Examples of abstrasy.interpreter.InterpreterException

    int ms = getNumPairValueIfExists(0, hash, new Node(K_MILLIS));
    int dd = getNumPairValueIfExists(0, hash, new Node(K_DAY));
    int mm = getNumPairValueIfExists(0, hash, new Node(K_MONTH));
    int yy = getNumPairValueIfExists(0, hash, new Node(K_YEAR));
    if ((mm != 0)||(yy != 0))  {
      throw new InterpreterException(StdErrors.extend(StdErrors.Invalid_parameter,"unreliable"));
    }
    return new Node(ms + (s * mps) + (m * mpm) + (h * mph) + (dd * mpd));
  }
 
View Full Code Here

Examples of abstrasy.interpreter.InterpreterException

        Node res = null;
       
    if (pairlist.hasKey(k)) {
            res=pairlist.ref(k);
      if (!res.isNumber()) {
        throw new InterpreterException(StdErrors.Argument_type_mismatch);
      }
    }
       
    return res;
  }
View Full Code Here

Examples of abstrasy.interpreter.InterpreterException

                return nodeToDate(t);
           
    }
   
        // sinon, et bien...
        throw new InterpreterException(StdErrors.extend(StdErrors.Invalid_parameter, "This object do not implement :to-date method (" + arg.toString() + ")"));

  }
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.