Examples of ESBase


Examples of com.caucho.es.ESBase

  }

  public static Object getObject(ResultSet rs, ESBase col)
    throws Throwable
  {
    ESBase key = col.toPrimitive();

    if (key.isString())
      return rs.getObject(key.toString());
    else
      return rs.getObject((int) key.toNum());
  }
View Full Code Here

Examples of com.caucho.es.ESBase

    ResultSetMetaData md;

    md = rs.getMetaData();

    Global global = Global.getGlobalProto();
    ESBase obj;
    if (length > 0)
      obj = call.getArg(0, length);
    else
      obj = global.createObject();

    int nColumns = md.getColumnCount();
    for (int i = 0; i < nColumns; i++) {
      String name = md.getColumnName(i + 1);
      Object value = get(rs, i + 1);

      obj.setProperty(name, global.wrap(value));
    }

    return obj;
  }
View Full Code Here

Examples of com.caucho.es.ESBase

    ResultSetMetaData md;

    md = rs.getMetaData();

    Global global = Global.getGlobalProto();
    ESBase obj;
    if (length > 0)
      obj = call.getArg(0, length);
    else
      obj = global.createObject();

    int nColumns = md.getColumnCount();
    for (int i = 0; i < nColumns; i++) {
      String name = md.getColumnName(i + 1);
      Object value = get(rs, i + 1);

      obj.setProperty(name, global.wrap(value));
    }

    return obj;
  }
View Full Code Here

Examples of com.caucho.es.ESBase

  private static final Logger log = Logger.getLogger(ResultSet.class.getName());

  public static String getString(ResultSet rs, ESBase col)
    throws Throwable
  {
    ESBase key = col.toPrimitive();

    if (key.isString())
      return rs.getString(key.toString());
    else
      return rs.getString((int) key.toNum());
  }
View Full Code Here

Examples of com.caucho.es.ESBase

  }

  public static boolean getBoolean(ResultSet rs, ESBase col)
    throws Throwable
  {
    ESBase key = col.toPrimitive();

    if (key.isString())
      return rs.getBoolean(key.toString());
    else
      return rs.getBoolean((int) key.toNum());
  }
View Full Code Here

Examples of com.caucho.es.ESBase

  }

  public static byte getByte(ResultSet rs, ESBase col)
    throws Throwable
  {
    ESBase key = col.toPrimitive();

    if (key.isString())
      return rs.getByte(key.toString());
    else
      return rs.getByte((int) key.toNum());
  }
View Full Code Here

Examples of com.caucho.es.ESBase

  }

  public static short getShort(ResultSet rs, ESBase col)
    throws Throwable
  {
    ESBase key = col.toPrimitive();

    if (key.isString())
      return rs.getShort(key.toString());
    else
      return rs.getShort((int) key.toNum());
  }
View Full Code Here

Examples of com.caucho.es.ESBase

  }

  public static int getInt(ResultSet rs, ESBase col)
    throws Throwable
  {
    ESBase key = col.toPrimitive();

    if (key.isString())
      return rs.getInt(key.toString());
    else
      return rs.getInt((int) key.toNum());
  }
View Full Code Here

Examples of com.caucho.es.ESBase

  }

  public static long getLong(ResultSet rs, ESBase col)
    throws Throwable
  {
    ESBase key = col.toPrimitive();

    if (key.isString())
      return rs.getLong(key.toString());
    else
      return rs.getLong((int) key.toNum());
  }
View Full Code Here

Examples of com.caucho.es.ESBase

  }

  public static float getFloat(ResultSet rs, ESBase col)
    throws Throwable
  {
    ESBase key = col.toPrimitive();

    if (key.isString())
      return rs.getFloat(key.toString());
    else
      return rs.getFloat((int) key.toNum());
  }
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.