1
0
mirror of https://github.com/gnosygnu/xowa.git synced 2026-03-02 03:49:30 +00:00

Mw_parse: Mass checkin of various mediawiki parse files

This commit is contained in:
gnosygnu
2017-01-25 01:27:18 -05:00
parent 6a5c114998
commit cef2d7e2f6
81 changed files with 6723 additions and 485 deletions

View File

@@ -17,6 +17,7 @@ along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
package gplx.xowa.addons.bldrs.updates.files; import gplx.*; import gplx.xowa.*; import gplx.xowa.addons.*; import gplx.xowa.addons.bldrs.*; import gplx.xowa.addons.bldrs.updates.*;
import gplx.xowa.bldrs.*; import gplx.xowa.bldrs.wkrs.*;
import gplx.xowa.files.*;
public class Xodel_small_cmd extends Xob_cmd__base {
public Xodel_small_cmd(Xob_bldr bldr, Xowe_wiki wiki) {super(bldr, wiki);}
private final int[] ext_max_ary = Xobldr__fsdb_db__delete_small_files_.New_ext_max_ary();
@@ -31,3 +32,20 @@ public class Xodel_small_cmd extends Xob_cmd__base {
public static final Xob_cmd Prototype = new Xodel_small_cmd(null, null);
@Override public Xob_cmd Cmd_clone(Xob_bldr bldr, Xowe_wiki wiki) {return new Xodel_small_cmd(bldr, wiki);}
}
class Xobldr__fsdb_db__delete_small_files_ {
public static int[] New_ext_max_ary() {
int[] rv = new int[Xof_ext_.Id__max];
Ext_max_(rv, 35, Xof_ext_.Id_svg);
Ext_max_(rv, 40, Xof_ext_.Id_gif);
Ext_max_(rv, 100, Xof_ext_.Id_png, Xof_ext_.Id_jpg, Xof_ext_.Id_jpeg);
Ext_max_(rv, 500, Xof_ext_.Id_tif, Xof_ext_.Id_tiff);
Ext_max_(rv, 500, Xof_ext_.Id_xcf);
Ext_max_(rv, 1000, Xof_ext_.Id_bmp);
Ext_max_(rv, 700, Xof_ext_.Id_webm);
Ext_max_(rv, 1000, Xof_ext_.Id_ogv);
Ext_max_(rv, 400, Xof_ext_.Id_pdf);
Ext_max_(rv, 700, Xof_ext_.Id_djvu);
return rv;
}
private static void Ext_max_(int[] ary, int max, int... exts) {for (int ext : exts) ary[ext] = max;}
}

View File

@@ -19,6 +19,7 @@ package gplx.xowa.addons.bldrs.updates.files; import gplx.*; import gplx.xowa.*;
import gplx.dbs.*;
import gplx.xowa.bldrs.*;
import gplx.fsdb.*; import gplx.fsdb.meta.*; import gplx.xowa.files.*;
import gplx.xowa.bldrs.wkrs.*;
class Xodel_small_mgr {
public void Exec(Xowe_wiki wiki, int[] ext_max_ary) {
wiki.Init_assert();
@@ -53,20 +54,3 @@ class Xodel_small_mgr {
);
}
}
class Xobldr__fsdb_db__delete_small_files_ {
public static int[] New_ext_max_ary() {
int[] rv = new int[Xof_ext_.Id__max];
Ext_max_(rv, 35, Xof_ext_.Id_svg);
Ext_max_(rv, 40, Xof_ext_.Id_gif);
Ext_max_(rv, 100, Xof_ext_.Id_png, Xof_ext_.Id_jpg, Xof_ext_.Id_jpeg);
Ext_max_(rv, 500, Xof_ext_.Id_tif, Xof_ext_.Id_tiff);
Ext_max_(rv, 500, Xof_ext_.Id_xcf);
Ext_max_(rv, 1000, Xof_ext_.Id_bmp);
Ext_max_(rv, 700, Xof_ext_.Id_webm);
Ext_max_(rv, 1000, Xof_ext_.Id_ogv);
Ext_max_(rv, 400, Xof_ext_.Id_pdf);
Ext_max_(rv, 700, Xof_ext_.Id_djvu);
return rv;
}
private static void Ext_max_(int[] ary, int max, int... exts) {for (int ext : exts) ary[ext] = max;}
}