Package com.meidusa.amoeba.sqljep

Examples of com.meidusa.amoeba.sqljep.ParseException


    }
    if (param instanceof Number) {    // Long, Integer, Short, Byte
      long n =((Number)param).longValue();
      return new Integer(n > 0 ? 1 : (n < 0 ? -1 : 0));
    }
    throw new ParseException(WRONG_TYPE+" sign("+param.getClass()+")");
  }
View Full Code Here


      cal.setTimeInMillis(ts.getTime());
      int month = cal.get(MONTH);
      String[] months = symb.getMonths();
      return months[month];
    }
    throw new ParseException(WRONG_TYPE+" month("+param.getClass()+")");
  }
View Full Code Here

      return new Double(-((Number)param).doubleValue());
    }
    if (param instanceof Number) {    // Long, Integer, Short, Byte
      return new Long(-((Number)param).longValue());
    }
    throw new ParseException(WRONG_TYPE+" "+param.getClass());
  }
View Full Code Here

      return Math.ceil(((Number)param).doubleValue());
    }
    if (param instanceof Number) {    // Long, Integer, Short, Byte
      return param;
    }
    throw new ParseException(WRONG_TYPE+" ceil("+param.getClass()+")");
  }
View Full Code Here

      cal.set(HOUR_OF_DAY, h);
      cal.set(MINUTE, m);
      cal.set(SECOND, s);
      return new Time(cal.getTimeInMillis());
    }
    throw new ParseException(WRONG_TYPE+" maketime("+param1.getClass()+","+param2.getClass()+")");
  }
View Full Code Here

      Comparable<?>  param1 = runtime.stack.pop();
      return new Comparable<?>[]{param1,param2,param3};
    } else {
      // remove all parameters from stack and push null
      removeParams(runtime.stack, num);
      throw new ParseException(PARAMS_NUMBER+" for replace");
    }
  }
View Full Code Here

      return null;
    }
    if (param1 instanceof Boolean && param2 instanceof Boolean) {
      return (((Boolean)param1).booleanValue()) || (((Boolean)param2).booleanValue());
    }
    throw new ParseException(WRONG_TYPE+ param1.getClass()+" or "+ param2.getClass());
  }
View Full Code Here

        runtime.stack.push(variant);
      } else {
        runtime.stack.push(null);
      }
    } else {
      throw new ParseException("Few arguments for decode");
    }
    return null;
  }
View Full Code Here

      return Math.floor(((Number)param).doubleValue());
    }
    if (param instanceof Number) {    // Long, Integer, Short, Byte
      return param;
    }
    throw new ParseException(WRONG_TYPE+" floor("+param.getClass()+")");
  }
View Full Code Here

      Comparable<?>  param1 = runtime.stack.pop();
      return new Comparable<?>[]{param1,param2,param3};
    } else {
      // remove all parameters from stack and push null
      removeParams(runtime.stack, num);
      throw new ParseException(PARAMS_NUMBER+" for lpad");
    }
  }
View Full Code Here

TOP

Related Classes of com.meidusa.amoeba.sqljep.ParseException

Copyright © 2018 www.massapicom. 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.