private static void Find_pages_in_ctg( Ordered_hash rv, Xowe_wiki wiki, Xodb_load_mgr load_mgr, Xowd_page_itm tmp_page, Int_obj_ref tmp_id, byte[] ctg_ttl) { Xoctg_catpage_ctg ctg = wiki.Ctg__catpage_mgr() .Get_or_load_or_null( Xoctg_catpage_url.New__blank(), wiki.Ttl_parse(gplx.xowa.wikis.nss.Xow_ns_.Tid__category, ctg_ttl), -1); if (ctg == null) return; // loop grps to get grp for (byte ctg_tid = 0; ctg_tid < Xoa_ctg_mgr.Tid___max; ++ctg_tid) { Xoctg_catpage_grp ctg_grp = ctg.Grp_by_tid(ctg_tid); int itms_len = ctg_grp.Itms__len(); // loop itms in grp and add to hash for (int i = 0; i < itms_len; ++i) { Xoctg_catpage_itm ctg_itm = ctg_grp.Itms__get_at(i); int itm_page_id = ctg_itm.Page_id(); if (rv.Has(tmp_id.Val_(itm_page_id))) continue; rv.Add(Int_obj_ref.New(itm_page_id), ctg_itm); // DELETE: recurse subcategories; PAGE:en.b:XML DATE:2016-09-18 // if (ctg_tid == Xoa_ctg_mgr.Tid__subc) { // load_mgr.Load_by_id(tmp_page, itm_page_id); // Find_pages_in_ctg(rv, wiki, load_mgr, tmp_page, tmp_id, tmp_page.Ttl_page_db()); // } } } }
public void Add(Wbase_claim_grp itm) { hash.Add(itm.Id_ref(), itm); }