コード例 #1
0
 private synchronized Object _get(int row) throws SQLException, IOException {
   if (data == null) {
     data = new Object[qry.getRecordcount()];
     for (int i = 0; i < data.length; i++) {
       data[i] = SimpleQuery.DEFAULT_VALUE;
     }
   }
   return data[row - 1] = cast.toCFType(type, res, index);
 }
コード例 #2
0
  public SimpleQueryColumn(
      SimpleQuery qry, ResultSet res, Collection.Key key, int type, int index) {
    this.qry = qry;
    this.res = res;
    this.key = key;
    this.index = index;

    try {
      switch (type) {
        case Types.TIMESTAMP:
          cast = Cast.TIMESTAMP;
          break;
        case Types.TIME:
          cast = Cast.TIME;
          break;
        case Types.DATE:
          cast = Cast.DATE;
          break;
        case Types.CLOB:
          cast = Cast.CLOB;
          break;
        case Types.BLOB:
          cast = Cast.BLOB;
          break;
        case Types.BIT:
          cast = Cast.BIT;
          break;
        case Types.ARRAY:
          cast = Cast.ARRAY;
          break;
        case CFTypes.OPAQUE:
          if (SQLUtil.isOracle(res.getStatement().getConnection())) cast = Cast.ORACLE_OPAQUE;
          else cast = Cast.OTHER;
          break;
        default:
          cast = Cast.OTHER;
          break;
      }
    } catch (Exception e) {
      throw SimpleQuery.toRuntimeExc(e);
    }
  }
コード例 #3
0
 private Object getChildElement(Key key, Object defaultValue) {
   // column and query has same name
   if (key.equals(this.key)) {
     return get(qry.getCurrentrow(), defaultValue);
   }
   // get it from undefined scope
   PageContext pc = ThreadLocalPageContext.get();
   if (pc != null) {
     UndefinedImpl undefined = ((UndefinedImpl) pc.undefinedScope());
     boolean old = undefined.setAllowImplicidQueryCall(false);
     Object sister = undefined.get(this.key, null);
     undefined.setAllowImplicidQueryCall(old);
     if (sister != null) {
       try {
         return pc.get(sister, key);
       } catch (PageException e) {
         return defaultValue;
       }
     }
   }
   return defaultValue;
 }
コード例 #4
0
 public Object removeEL(PageContext pc) {
   throw SimpleQuery.notSupported();
 }
コード例 #5
0
 public Object touch(PageContext pc) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #6
0
 public Object clone() {
   throw SimpleQuery.notSupported();
 }
コード例 #7
0
 public Object remove(Key key) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #8
0
 public Object set(String key, Object value) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #9
0
 public void addRow(int count) {
   throw SimpleQuery.notSupported();
 }
コード例 #10
0
 public int compareTo(String str) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #11
0
 public Object removeEL(int row) {
   throw SimpleQuery.notSupported();
 }
コード例 #12
0
 public DumpData toDumpData(PageContext pageContext, int maxlevel, DumpProperties properties) {
   throw SimpleQuery.notSupported();
 }
コード例 #13
0
 public Iterator valueIterator() {
   throw SimpleQuery.notSupported();
 }
コード例 #14
0
 public boolean containsKey(Key key) {
   throw SimpleQuery.notSupported();
 }
コード例 #15
0
 public Collection duplicate(boolean deepCopy) {
   throw SimpleQuery.notSupported();
 }
コード例 #16
0
 public Object setEL(Key key, Object value) {
   throw SimpleQuery.notSupported();
 }
コード例 #17
0
 public Object touchEL(PageContext pc) {
   throw SimpleQuery.notSupported();
 }
コード例 #18
0
 public Object set(int row, Object value) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #19
0
 public Object removeRow(int row) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #20
0
 public Object removeEL(Key key) {
   throw SimpleQuery.notSupported();
 }
コード例 #21
0
 public int compareTo(boolean b) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #22
0
 public void clear() {
   throw SimpleQuery.notSupported();
 }
コード例 #23
0
 public void add(Object value) {
   throw SimpleQuery.notSupported();
 }
コード例 #24
0
 public int compareTo(double d) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #25
0
 public Object setEL(int row, Object value) {
   throw SimpleQuery.notSupported();
 }
コード例 #26
0
 public int compareTo(DateTime dt) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #27
0
 public void cutRowsTo(int maxrows) {
   throw SimpleQuery.notSupported();
 }
コード例 #28
0
 public Object set(PageContext pc, Object value) throws PageException {
   throw SimpleQuery.notSupported();
 }
コード例 #29
0
 public Object setEL(PageContext pc, Object value) {
   throw SimpleQuery.notSupported();
 }
コード例 #30
0
 public String[] keysAsString() {
   throw SimpleQuery.notSupported();
 }