mirror of
https://github.com/gnosygnu/xowa.git
synced 2026-03-02 03:49:30 +00:00
uca category support and other changes
This commit is contained in:
@@ -62,7 +62,7 @@ public class Xow_data_mgr_tst {
|
||||
;
|
||||
}
|
||||
@Test public void Update_zip() {
|
||||
// fxt.Wiki().Fsys_mgr().Dir_regy()[Xow_ns_.Tid__main].Ext_tid_(gplx.core.ios.streams.Io_stream_.Tid_zip);
|
||||
// fxt.Wiki().Fsys_mgr().Dir_regy()[Xow_ns_.Tid__main].Ext_tid_(gplx.core.ios.streams.Io_stream_tid_.Tid__zip);
|
||||
// fxt.Wiki().Data_mgr().Zip_mgr_(new Io_zip_mgr_mok());
|
||||
// fxt .Create("A1", "A1 data")
|
||||
// .Create("B12", "B12 data")
|
||||
|
||||
@@ -52,7 +52,7 @@ public class Xowd_core_db_props {
|
||||
return cfg_tbl.Select_int_or(Cfg_grp, Cfg_key__schema_version, 1) == 1
|
||||
? new Xowd_core_db_props
|
||||
( 1, Xow_db_layout.Itm_lot, Xow_db_layout.Itm_lot, Xow_db_layout.Itm_lot, cfg_tbl.Select_byte_or(Xowe_wiki.Invk_db_mgr, Xodb_mgr_sql.Invk_data_storage_format
|
||||
, Io_stream_.Tid_gzip), Io_stream_.Tid_gzip, Bool_.Y, Bool_.N)
|
||||
, Io_stream_tid_.Tid__gzip), Io_stream_tid_.Tid__gzip, Bool_.Y, Bool_.N)
|
||||
: Cfg_load(cfg_tbl);
|
||||
}
|
||||
private static Xowd_core_db_props Cfg_load(Db_cfg_tbl tbl) {
|
||||
@@ -78,5 +78,5 @@ public class Xowd_core_db_props {
|
||||
, Cfg_key__hzip_enabled = "hzip_enabled"
|
||||
, Cfg_key__hzip_mode_is_b256 = "hzip_mode_is_b256"
|
||||
;
|
||||
public static final Xowd_core_db_props Test = new Xowd_core_db_props(2, Xow_db_layout.Itm_few, Xow_db_layout.Itm_few, Xow_db_layout.Itm_few, Io_stream_.Tid_raw, Io_stream_.Tid_raw, Bool_.Y, Bool_.Y);
|
||||
public static final Xowd_core_db_props Test = new Xowd_core_db_props(2, Xow_db_layout.Itm_few, Xow_db_layout.Itm_few, Xow_db_layout.Itm_few, Io_stream_tid_.Tid__raw, Io_stream_tid_.Tid__raw, Bool_.Y, Bool_.Y);
|
||||
}
|
||||
|
||||
@@ -18,9 +18,9 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
|
||||
package gplx.xowa.wikis.data.tbls; import gplx.*; import gplx.xowa.*; import gplx.xowa.wikis.*; import gplx.xowa.wikis.data.*;
|
||||
import gplx.dbs.*;
|
||||
public interface Select_in_cbk {
|
||||
int Hash_max();
|
||||
void Write_sql(Bry_bfr bfr, int idx);
|
||||
void Read_data(Db_rdr rdr);
|
||||
int Hash_max();
|
||||
}
|
||||
class Select_in_wkr {
|
||||
private final byte[] sql_bgn;
|
||||
|
||||
@@ -157,6 +157,20 @@ public class Xowd_page_tbl implements Rls_able {
|
||||
return rdr.Move_next() ? rdr.Read_int(fld_id) : Xowd_page_itm.Id_null;
|
||||
} finally {rdr.Rls();}
|
||||
}
|
||||
public void Select_in__id(Select_in_cbk cbk) {
|
||||
int pos = 0;
|
||||
Bry_bfr bfr = Bry_bfr_.New();
|
||||
Select_in_wkr wkr = Select_in_wkr.New(bfr, tbl_name, Flds_select_all(), fld_id);
|
||||
while (true) {
|
||||
pos = wkr.Make_sql_or_null(bfr, cbk, pos);
|
||||
if (pos == -1) break;
|
||||
Db_rdr rdr = conn.Stmt_sql(bfr.To_str_and_clear()).Exec_select__rls_auto();
|
||||
try {
|
||||
while (rdr.Move_next())
|
||||
cbk.Read_data(rdr);
|
||||
} finally {rdr.Rls();}
|
||||
}
|
||||
}
|
||||
public void Select_in__ttl(Cancelable cancelable, Ordered_hash rv, int ns_id, int bgn, int end) {
|
||||
Xowd_page_tbl__ttl wkr = new Xowd_page_tbl__ttl();
|
||||
wkr.Ctor(this, tbl_name, fld_title);
|
||||
|
||||
Reference in New Issue
Block a user