示例#1
0
 public static void Val_by_obj(Db_stmt stmt, String key, Object val) {
   int tid = Type_adp_.To_tid_obj(val);
   switch (tid) {
     case Type_adp_.Tid__bool:
       stmt.Val_bool_as_byte(key, Bool_.cast(val));
       break;
     case Type_adp_.Tid__byte:
       stmt.Val_byte(key, Byte_.cast(val));
       break;
     case Type_adp_.Tid__int:
       stmt.Val_int(key, Int_.cast(val));
       break;
     case Type_adp_.Tid__long:
       stmt.Val_long(key, Long_.cast(val));
       break;
     case Type_adp_.Tid__float:
       stmt.Val_float(key, Float_.cast(val));
       break;
     case Type_adp_.Tid__double:
       stmt.Val_double(key, Double_.cast(val));
       break;
     case Type_adp_.Tid__str:
       stmt.Val_str(key, String_.cast(val));
       break;
     case Type_adp_.Tid__bry:
       stmt.Val_bry(key, Bry_.cast(val));
       break;
     default:
       throw Err_.new_unhandled_default(tid);
   }
 }
示例#2
0
 public byte[] Format_num_by_long(long val) {
   return Format_num(Bry_.new_a7(Long_.To_str(val)));
 }
示例#3
0
 Xob_stat_itm XtoStr_fld(String_bldr sb, long v) {
   sb.Add(Long_.To_str(v)).Add(Xob_stat_itm.Dlm);
   return this;
 }