mirror of
https://github.com/gnosygnu/xowa.git
synced 2025-06-13 12:54:14 +00:00
Embeddable: Add method to selectively clear pages from cache
This commit is contained in:
parent
f683e272ee
commit
27f6811e1f
@ -37,8 +37,10 @@ public class Xop_mediawiki_mgr {
|
||||
, root_dir.GenSubDir_nest("user", "anonymous", "wiki")
|
||||
, gplx.xowa.apps.boots.Xoa_cmd_arg_mgr.Bin_dir_name()
|
||||
);
|
||||
if (mode_is_prod)
|
||||
if (mode_is_prod) {
|
||||
app.Init_by_app();
|
||||
app.Stage_(gplx.xowa.apps.Xoa_stage_.Tid_launch); // must set to Launch, else wiki.init_needed will never be false; DATE:2017-01-26
|
||||
}
|
||||
}
|
||||
public Xop_mediawiki_wkr Make(String domain_str) {return Make(domain_str, null);}
|
||||
public Xop_mediawiki_wkr Make(String domain_str, Xop_mediawiki_loader loader) {
|
||||
|
@ -35,6 +35,8 @@ public class Xop_mediawiki_wkr {
|
||||
wiki.Parser_mgr().Scrib().Core_term();
|
||||
wiki.Appe().Wiki_mgr().Wdata_mgr().Clear();
|
||||
}
|
||||
public void Clear_cache() {
|
||||
}
|
||||
public String Parse(String page, String wikitext) {
|
||||
Xoa_ttl ttl = wiki.Ttl_parse(Bry_.new_u8(page));
|
||||
|
||||
|
@ -38,6 +38,9 @@ public class Xow_page_cache {
|
||||
}
|
||||
}
|
||||
}
|
||||
public void Del(byte[] ttl_full_db) {
|
||||
cache.Del(ttl_full_db);
|
||||
}
|
||||
public Xow_page_cache_itm Get_or_load_as_itm(Xoa_ttl ttl) {
|
||||
byte[] ttl_full_db = ttl.Full_db();
|
||||
Xow_page_cache_itm rv = (Xow_page_cache_itm)cache.Get_by(ttl_full_db);
|
||||
|
Loading…
Reference in New Issue
Block a user