From 8a5d58a97319d33780d783c5a6b8d22a7fc30e55 Mon Sep 17 00:00:00 2001 From: gnosygnu Date: Sun, 15 Nov 2015 21:08:17 -0500 Subject: [PATCH] v2.11.3.1 --- 100_core/.classpath | 6 - .../gplx/Bool_.java | 1 + .../gplx/Byte_.java | 0 .../gplx/Byte__tst.java | 2 +- .../gplx/Byte_ascii.java | 3 +- .../gplx/Char_.java | 0 .../gplx/Double_.java | 0 .../gplx/Double__tst.java | 0 100_core/{src_210_env => src}/gplx/Env_.java | 0 100_core/src/gplx/Err.java | 1 + .../gplx/Float_.java | 0 .../{src_400_gfs => src}/gplx/GfsCtx.java | 2 +- .../gplx/Int_.java | 2 +- .../gplx/Int__tst.java | 0 .../gplx/Int_ary_.java | 0 .../gplx/Int_ary__tst.java | 0 .../{src_210_env => src}/gplx/JarAdp_.java | 0 .../gplx/Long_.java | 0 .../gplx/Long__tst.java | 0 .../{src_210_env => src}/gplx/Op_sys.java | 0 .../{src_210_env => src}/gplx/Op_sys_.java | 0 .../{src_210_env => src}/gplx/ProcessAdp.java | 3 +- .../gplx/ProcessAdp_tst.java | 0 .../gplx/Short_.java | 0 100_core/src/gplx/Tfds.java | 4 +- .../{src_210_env => src}/gplx/Type_adp_.java | 0 .../gplx/Yn.java | 0 .../gplx/core/brys/Bfr_arg.java} | 10 +- 100_core/src/gplx/core/brys/Bfr_arg_.java | 37 +++++ .../gplx/core/brys/Bfr_arg_base.java} | 10 +- .../gplx/core/brys/Bry_split_wkr.java | 0 .../src/gplx/core/brys/args/Bfr_arg__bry.java | 23 +++ .../gplx/core/brys/args/Bfr_arg__bry_ary.java | 26 +++ .../core/brys/args/Bfr_arg__bry_fmtr.java | 28 ++++ .../gplx/core/brys/args/Bfr_arg__byte.java | 23 +++ .../core/brys/args/Bfr_arg__decimal_int.java} | 10 +- .../gplx/core/brys/args/Bfr_arg__int.java} | 17 +- .../gplx/core/brys/args/Bfr_arg__time.java} | 10 +- .../core/brys/args/Bfr_arg__time_tst.java} | 10 +- .../gplx/core/brys/fmtrs}/Bry_fmtr.java | 12 +- .../core/brys/fmtrs}/Bry_fmtr_eval_mgr.java | 2 +- .../core/brys/fmtrs}/Bry_fmtr_eval_mgr_.java | 2 +- .../brys/fmtrs}/Bry_fmtr_eval_mgr_gfs.java | 3 +- .../gplx/core/brys/fmtrs}/Bry_fmtr_itm.java | 2 +- .../gplx/core/brys/fmtrs}/Bry_fmtr_tst.java | 2 +- .../gplx/core/brys/fmtrs}/Bry_fmtr_vals.java | 7 +- .../gplx/core/gfo_ndes}/GfoFld.java | 2 +- .../gplx/core/gfo_ndes}/GfoFldList.java | 2 +- .../gplx/core/gfo_ndes}/GfoFldList_.java | 2 +- .../gplx/core/gfo_ndes}/GfoNde.java | 2 +- .../gplx/core/gfo_ndes}/GfoNdeFxt.java | 2 +- .../gplx/core/gfo_ndes}/GfoNdeList.java | 2 +- .../gplx/core/gfo_ndes}/GfoNdeList_.java | 2 +- .../gplx/core/gfo_ndes}/GfoNde_.java | 2 +- .../gplx/core/gfo_regys}/GfoMsgParser.java | 2 +- .../gplx/core/gfo_regys}/GfoRegy.java | 3 +- .../gplx/core/gfo_regys}/GfoRegyItm.java | 2 +- .../core/gfo_regys}/GfoRegy_RegDir_tst.java | 2 +- .../core/gfo_regys}/GfoRegy_basic_tst.java | 2 +- .../core/ios/IoEngine_xrg_downloadFil.java | 1 + 100_core/src/gplx/core/ios/IoItmFil.java | 1 + 100_core/src/gplx/core/ios/IoItm_base.java | 1 + 100_core/src/gplx/core/ios/IoUrlInfoRegy.java | 1 + 100_core/src/gplx/core/ios/IoUrlTypeRegy.java | 2 +- 100_core/src/gplx/core/ios/IoZipWkr.java | 1 + .../src/gplx/core/ios/Io_download_fmt.java | 4 +- 100_core/src/gplx/core/ios/Io_size_.java | 5 +- .../src/gplx/core/log_msgs/Gfo_msg_itm.java | 1 + .../src/gplx/core/primitives/Bry_obj_ref.java | 31 ++-- .../src/gplx/langs/dsvs/DsvDataRdrOpts.java | 1 + 100_core/src/gplx/langs/dsvs/DsvDataRdr_.java | 2 +- .../langs/dsvs/DsvDataRdr_csv_dat_tst.java | 2 +- .../langs/dsvs/DsvDataRdr_dsv_hdr_tst.java | 2 +- .../langs/dsvs/DsvDataRdr_dsv_misc_tst.java | 2 +- .../langs/dsvs/DsvDataRdr_layout_tst.java | 2 +- 100_core/src/gplx/langs/dsvs/DsvDataWtr.java | 2 +- .../gplx/langs/dsvs/DsvDataWtr_csv_tst.java | 2 +- .../gplx/langs/dsvs/DsvDataWtr_tbls_tst.java | 2 +- 100_core/src/gplx/langs/gfs/GfsCore.java | 90 +++++++++++ .../gplx/langs/gfs}/GfsCoreHelp.java | 2 +- .../gplx/langs/gfs/GfsCore_.java} | 75 +-------- .../gplx/langs/gfs}/GfsCore_tst.java | 2 +- .../gplx/langs/gfs}/GfsLibIni.java | 2 +- .../gplx/langs/gfs}/GfsLibIni_core.java | 3 +- .../gplx => src/gplx/langs/gfs}/GfsRegy.java | 2 +- .../gplx/langs/gfs}/GfsTypeNames.java | 2 +- .../gplx/langs/gfs}/Gfs_Date_tst.java | 2 +- .../src_101_types_object/gplx/String_.java | 2 +- 100_core/src_130_brys/gplx/Bry_bfr.java | 13 +- 100_core/src_130_brys/gplx/Bry_fmtr_arg_.java | 33 ---- .../gplx/brys/Bry_fmtr_arg_fmtr.java | 23 --- .../gplx/brys/Bry_fmtr_arg_int.java | 23 --- 100_core/src_140_list/gplx/Ordered_hash_.java | 4 +- .../src_311_gfoObj/gplx/GfoInvkXtoStr.java | 1 + 100_core/src_311_gfoObj/gplx/GfoMsg_tst.java | 2 +- 100_core/src_330_store/gplx/DataWtr.java | 1 + 100_core/src_330_store/gplx/DataWtr_.java | 2 +- .../gplx/stores/DataRdr_mem.java | 1 + .../src_330_store/gplx/stores/GfoNdeRdr.java | 1 + .../src_330_store/gplx/stores/GfoNdeRdr_.java | 1 + .../gplx/stores/xmls/XmlDataWtr_.java | 2 +- .../gplx/Gfo_usr_dlg__log_base.java | 2 +- .../src_420_usrMsg/gplx/Gfo_usr_dlg_base.java | 1 + .../tst/gplx/stores/GfoNdeRdr_read_tst.java | 2 +- 100_core/tst/gplx/stores/GfoNdeRdr_tst.java | 2 +- .../src_600_rdrWtr/gplx/gfml/GfmlDataNde.java | 2 +- .../src_600_rdrWtr/gplx/gfml/GfmlDataWtr.java | 2 +- .../gplx/gfml/GfoMsgParser_gfml.java | 1 + 140_dbs/src/gplx/dbs/Db_crt_tst.java | 3 +- .../dbs/engines/tdbs/TdbDbLoadMgr_tst.java | 2 +- .../src/gplx/dbs/engines/tdbs/TdbDelete.java | 2 +- .../gplx/dbs/engines/tdbs/TdbFileList.java | 1 + .../src/gplx/dbs/engines/tdbs/TdbInsert.java | 1 + .../src/gplx/dbs/engines/tdbs/TdbSelect.java | 2 +- .../src/gplx/dbs/engines/tdbs/TdbTable.java | 2 +- .../gplx/dbs/engines/tdbs/TdbTableList.java | 2 +- .../src/gplx/dbs/engines/tdbs/TdbUpdate.java | 2 +- 140_dbs/src/gplx/dbs/metas/Meta_tbl_mgr.java | 4 +- .../src/gplx/dbs/qrys/Db_qry__select_cmd.java | 2 +- 140_dbs/src/gplx/dbs/qrys/Db_stmt_sql.java | 1 + .../src/gplx/dbs/sqls/Db_sqlbldr__sqlite.java | 5 +- .../gplx/dbs/sqls/Sql_order_by_sorter.java | 1 + .../src/gplx/dbs/sqls/Sql_select_fld_.java | 1 + .../gplx/dbs/sqls/Sql_select_fld_base.java | 1 + .../gplx/dbs/sqls/Sql_select_fld_list.java | 2 +- 140_dbs/src/gplx/stores/DbMaprRdr.java | 2 +- 140_dbs/src/gplx/stores/DbMaprWtr.java | 2 +- 140_dbs/tst/gplx/dbs/Db_conn_fxt.java | 2 +- 140_dbs/tst/gplx/dbs/Db_qry_fxt.java | 2 +- 140_dbs/tst/gplx/dbs/GfoNdeTstr.java | 1 + .../gplx/dbs/groupBys/GroupBys_base_tst.java | 2 +- .../dbs/insertIntos/InsertIntos_base_tst.java | 2 +- .../tst/gplx/dbs/joins/Joins_base_tst.java | 2 +- .../src_400_win/gplx/gfui/GfoConsoleWin.java | 2 +- .../src_400_win/gplx/gfui/GfuiMenuBar.java | 1 + .../src_420_box_basic/gplx/gfui/GfuiBtn.java | 1 + 150_gfui/src_600_adp/gplx/gfui/IconAdp.java | 1 + .../src_700_env/gplx/gfui/GfsLibIni_gfui.java | 1 + 150_gfui/src_700_env/gplx/gfui/GfuiEnv_.java | 2 +- 150_gfui/src_700_env/gplx/gfui/Swing_kit.java | 1 + 150_gfui/src_700_env/gplx/gfui/Swt_kit.java | 1 + 400_xowa/src/gplx/core/brys/Bry_rdr.java | 9 +- .../src/gplx/core/brys/Clear_able.java | 6 +- .../src/gplx/core/brys/Int_flag_bldr.java | 10 +- .../src/gplx/core/brys/Mid_able.java | 10 +- .../src/gplx/core/intls/Gfo_i18n_itm.java | 1 + .../src/gplx/core/primitives/Bry_cache.java | 5 +- .../core/threads/Gfo_thread_cmd_base.java | 1 + .../core/threads/Gfo_thread_cmd_download.java | 1 + .../core/threads/Gfo_thread_cmd_replace.java | 1 + .../core/threads/Gfo_thread_cmd_unzip.java | 1 + .../threads/poolables/Gfo_poolable_itm.java | 3 +- .../threads/poolables/Gfo_poolable_mgr.java | 4 +- .../threads/poolables/Gfo_poolable_mgr_.java | 21 +++ .../poolables/Gfo_poolable_mgr_tst.java | 8 +- 400_xowa/src/gplx/dbs/Db_diff_bldr.java | 54 +++++++ 400_xowa/src/gplx/langs/gfs/Gfs_msg_bldr.java | 1 + 400_xowa/src/gplx/langs/htmls/Html_bldr_.java | 3 + 400_xowa/src/gplx/langs/htmls/Html_tag_.java | 21 +++ 400_xowa/src/gplx/langs/htmls/Html_utl.java | 1 + .../src/gplx/langs/htmls/Html_utl_tst.java | 4 +- .../gplx/langs/htmls/parsers/Html_atr.java | 9 +- .../langs/htmls/parsers/Html_doc_parser.java | 41 ++--- .../langs/htmls/parsers/Html_doc_wkr.java | 3 +- .../gplx/langs/htmls/parsers/Html_tag.java | 28 ++-- .../langs/htmls/parsers/Html_tag_rdr.java | 59 +++---- .../langs/htmls/parsers/Html_tag_rdr_tst.java | 10 +- .../langs/htmls/parsers/Html_txt_wkr.java | 1 - .../Html_atr_class_.java} | 4 +- .../Html_atr_class__tst.java} | 12 +- .../parsers/clses/Html_atr_class_parser_.java | 48 ++++++ .../clses/Html_atr_class_parser__tst.java | 44 +++++ .../parsers/clses/Html_atr_class_wkr.java | 21 +++ ...arser.java => Html_atr_style_parser_.java} | 7 +- ...t.java => Html_atr_style_parser__tst.java} | 18 ++- .../parsers/styles/Html_atr_style_wkr.java | 12 -- .../Html_atr_style_wkr__get_val_as_int.java | 2 +- 400_xowa/src/gplx/xowa/Xoa_app_.java | 2 +- 400_xowa/src/gplx/xowa/Xoa_app_fxt.java | 1 + 400_xowa/src/gplx/xowa/Xoae_app.java | 2 +- 400_xowa/src/gplx/xowa/Xop_fxt.java | 2 +- 400_xowa/src/gplx/xowa/Xowe_wiki.java | 2 +- 400_xowa/src/gplx/xowa/apps/Xoa_app_eval.java | 2 + .../src/gplx/xowa/apps/Xoa_app_eval_tst.java | 1 + .../apps/apis/xowa/html/Xoapi_toggle_itm.java | 1 + .../gplx/xowa/apps/cfgs/Xoa_cfg_db_txt.java | 1 + .../gplx/xowa/apps/cfgs/gui/Xocfg_win.java | 1 + .../gplx/xowa/apps/fmtrs/Xoa_fmtr_itm.java | 1 + .../xowa/apps/fmtrs/Xoa_fmtr_itm_tst.java | 2 +- .../gplx/xowa/apps/fsys/Xoa_fsys_eval.java | 1 + .../gplx/xowa/apps/gfs/Xoa_gfs_php_mgr.java | 1 + 400_xowa/src/gplx/xowa/bldrs/Xob_cmd_mgr.java | 4 +- .../xowa/bldrs/cmds/ctgs/Xob_ctg_v1_sql.java | 1 + .../cmds/files/Xob_xfer_temp_itm_tst.java | 1 + .../bldrs/cmds/texts/Xob_search_base.java | 2 +- .../bldrs/cmds/utils/Xob_core_batch_utl.java | 1 + .../xowa/bldrs/css/Xoa_css_extractor.java | 2 +- .../gplx/xowa/bldrs/installs/Xoi_cmd_mgr.java | 2 +- .../xowa/bldrs/installs/Xoi_cmd_wiki_tst.java | 8 +- 400_xowa/src/gplx/xowa/drds/Xod_app_tst.java | 6 +- .../src/gplx/xowa/drds/Xowd_data_tstr.java | 4 +- .../files/fsdb/fs_roots/Fs_root_fsdb_mgr.java | 2 +- 400_xowa/src/gplx/xowa/guis/Xoa_gui_mgr.java | 1 + .../urls/url_macros/Xog_url_macro_grp.java | 2 +- 400_xowa/src/gplx/xowa/htmls/Xoh_page.java | 8 +- .../src/gplx/xowa/htmls/Xoh_page_mgr.java | 1 + .../src/gplx/xowa/htmls/Xoh_page_wtr_mgr.java | 1 + .../src/gplx/xowa/htmls/Xoh_page_wtr_wkr.java | 9 +- .../src/gplx/xowa/htmls/Xohp_ctg_grp_mgr.java | 5 +- .../bridges/dbuis/fmtrs/Dbui_cells_fmtr.java | 13 +- .../bridges/dbuis/fmtrs/Dbui_tbl_fmtr.java | 9 +- .../bridges/dbuis/fmtrs/Dbui_val_fmtr.java | 9 +- .../gplx/xowa/htmls/core/Xow_hdump_mgr.java | 20 +-- .../xowa/htmls/core/Xow_hdump_mgr__load.java | 50 +++--- .../htmls/core/Xow_hdump_mgr__load_tst.java | 4 +- .../xowa/htmls/core/Xow_hdump_mgr__save.java | 51 +++--- .../xowa/htmls/core/bldrs/Xob_hdump_mgr.java | 10 +- .../core/bldrs/Xob_ns_to_db_wkr__html.java | 2 +- .../htmls/core/bldrs/Xob_redlink_mkr_cmd.java | 5 +- .../xowa/htmls/core/dbs/Xoh_page_tbl.java | 21 ++- .../core/hzips/{stats => }/Hzip_stat_itm.java | 2 +- .../core/hzips/{stats => }/Hzip_stat_tbl.java | 2 +- .../xowa/htmls/core/hzips/Xoh_decode_ctx.java | 38 ----- .../xowa/htmls/core/hzips/Xoh_hzip_dict_.java | 23 +-- .../xowa/htmls/core/hzips/Xoh_hzip_fxt.java | 84 ++++++++++ .../xowa/htmls/core/hzips/Xoh_hzip_mgr.java | 44 ++--- .../xowa/htmls/core/hzips/Xoh_hzip_wkr.java | 5 +- .../xowa/htmls/core/hzips/Xow_hzip_mgr.java | 74 --------- .../htmls/core/hzips/tests/Xoh_hzip_fxt.java | 61 ------- .../xowa/htmls/core/makes/Xoh_make_mgr.java | 11 +- .../xowa/htmls/core/wkrs/Xoh_hdoc_ctx.java | 35 +++- ...oc_wkr__base.java => Xoh_hdoc_parser.java} | 23 +-- .../xowa/htmls/core/wkrs/Xoh_hdoc_wkr.java | 9 +- .../htmls/core/wkrs/Xoh_hdoc_wkr__hzip.java | 34 ++-- .../htmls/core/wkrs/Xoh_hdoc_wkr__make.java | 29 ++-- .../core/wkrs/Xoh_itm_parser_fxt_base.java | 2 +- .../core/wkrs/bfr_args/Bfr_arg__href.java | 51 ++++++ .../core/wkrs/bfr_args/Bfr_arg__html_atr.java | 53 ++++++ .../htmls/core/wkrs/bfr_args/Bfr_arg__id.java | 31 ++++ .../core/wkrs/bfr_args/Bfr_arg__indent.java | 16 +- .../core/wkrs/escapes/Xoh_escape_hzip.java | 15 +- .../wkrs/escapes/Xoh_escape_hzip_tst.java | 2 +- .../core/wkrs/escapes/Xoh_escape_parser.java | 3 +- .../core/wkrs/glys/Xoh_gly_grp_cls_.java | 12 +- .../core/wkrs/glys/Xoh_gly_grp_parser.java | 48 ++++++ .../core/wkrs/glys/Xoh_gly_itm_parser.java | 56 +++++++ .../htmls/core/wkrs/hdrs/Xoh_hdr_hzip.java | 26 +-- .../core/wkrs/hdrs/Xoh_hdr_hzip_tst.java | 2 +- .../htmls/core/wkrs/hdrs/Xoh_hdr_make.java | 8 +- .../htmls/core/wkrs/hdrs/Xoh_hdr_parser.java | 27 ++-- .../htmls/core/wkrs/imgs/Xoh_img_bldr.java | 47 ++++++ .../htmls/core/wkrs/imgs/Xoh_img_hzip.java | 98 ++++++------ .../wkrs/imgs/Xoh_img_hzip__dump__tst.java | 3 +- .../wkrs/imgs/Xoh_img_hzip__view__tst.java | 7 +- .../htmls/core/wkrs/imgs/Xoh_img_make.java | 52 ------ .../wkrs/imgs/Xoh_img_make__dump__tst.java | 4 +- .../htmls/core/wkrs/imgs/Xoh_img_parser.java | 11 +- .../htmls/core/wkrs/imgs/Xoh_img_wtr.java | 65 ++++++++ .../core/wkrs/imgs/atrs/Xoh_anch_cls_.java | 7 + .../wkrs/imgs/atrs/Xoh_anch_cls_parser.java | 7 +- .../core/wkrs/imgs/atrs/Xoh_img_cls_.java | 15 ++ .../wkrs/imgs/atrs/Xoh_img_cls_parser.java | 5 +- .../wkrs/imgs/atrs/Xoh_img_src_parser.java | 20 ++- .../imgs/atrs/Xoh_img_src_parser_tst.java | 3 + .../wkrs/imgs/atrs/Xoh_img_xoimg_parser.java | 8 +- .../htmls/core/wkrs/lnkes/Xoh_href_hzip.java | 2 +- .../htmls/core/wkrs/lnkes/Xoh_lnke_hzip.java | 26 +-- .../core/wkrs/lnkes/Xoh_lnke_hzip_tst.java | 2 +- .../core/wkrs/lnkes/Xoh_lnke_parser.java | 34 ++-- .../htmls/core/wkrs/lnkis/Xoh_lnki_dict_.java | 13 +- .../htmls/core/wkrs/lnkis/Xoh_lnki_hzip.java | 151 +++++++++++++----- .../core/wkrs/lnkis/Xoh_lnki_hzip_tst.java | 25 ++- .../core/wkrs/lnkis/Xoh_lnki_parser.java | 21 ++- .../core/wkrs/lnkis/Xoh_ttl_matcher.java | 29 ++-- .../core/wkrs/lnkis/Xoh_ttl_matcher_tst.java | 5 +- .../lnkis/anchs/Xoh_anch_href_parser.java | 64 ++++++-- .../lnkis/anchs/Xoh_anch_href_parser_tst.java | 9 ++ .../wkrs/lnkis/htmls/Xoh_arg_img_core.java | 2 +- .../lnkis/htmls/Xoh_arg_img_core__basic.java | 5 +- .../lnkis/htmls/Xoh_arg_img_core__hdump.java | 4 +- .../lnkis/htmls/Xoh_file_html_fmtr__base.java | 5 +- .../htmls/Xoh_file_html_fmtr__hdump.java | 3 +- .../wkrs/lnkis/htmls/Xoh_file_wtr__basic.java | 29 ++-- .../wkrs/lnkis/htmls/Xoh_lnki_text_fmtr.java | 5 +- .../wkrs/lnkis/htmls/Xoh_lnki_title_fmtr.java | 4 +- .../htmls/core/wkrs/mkrs/Xoh_hdoc_mkr.java | 53 ++++++ .../core/wkrs/spaces/Xoh_space_hzip.java | 17 +- .../core/wkrs/spaces/Xoh_space_hzip_tst.java | 2 +- .../core/wkrs/spaces/Xoh_space_parser.java | 5 +- ..._doc_wkr__tag.java => Xoh_tag_parser.java} | 62 +++---- .../htmls/core/wkrs/thms/Xoh_thm_bldr.java | 36 +++++ .../htmls/core/wkrs/thms/Xoh_thm_hzip.java | 109 ++++--------- .../core/wkrs/thms/Xoh_thm_hzip_tst.java | 84 +++------- .../htmls/core/wkrs/thms/Xoh_thm_parse.java | 74 --------- .../htmls/core/wkrs/thms/Xoh_thm_parser.java | 53 ++++++ .../htmls/core/wkrs/thms/Xoh_thm_wtr.java | 61 +++++++ .../thms/divs/Xoh_thm_caption_parser.java | 36 +++++ .../thms/divs/Xoh_thm_magnify_parser.java | 38 +++++ .../to_delete/Xohd_page_html_mgr__load.java | 2 +- .../to_delete/Xohd_page_html_mgr__save.java | 0 .../htmls/core/wkrs/txts/Xoh_txt_parser.java | 5 +- .../gplx/xowa/htmls/heads/Xoh_head_mgr.java | 4 +- .../xowa/htmls/heads/Xow_fragment_mgr.java | 1 + .../xowa/htmls/hrefs/Xoh_href_parser.java | 7 +- .../xowa/htmls/hrefs/Xoh_href_parser_tst.java | 10 +- .../gplx/xowa/htmls/hrefs/Xoh_href_wtr.java | 1 + .../modules/popups/Xow_popup_html_mkr.java | 1 + .../Xoh_file_page__other_resolutions.java | 4 +- .../htmls/ns_files/Xoh_file_page_wtr.java | 2 +- .../htmls/ns_files/Xoh_ns_file_page_mgr.java | 4 +- .../htmls/portal/Xoa_available_wikis_mgr.java | 1 + .../xowa/htmls/portal/Xoh_subpages_bldr.java | 5 +- .../xowa/htmls/portal/Xow_portal_mgr.java | 3 +- .../htmls/portal/vnts/Vnt_mnu_grp_fmtr.java | 9 +- .../portal/vnts/Vnt_mnu_grp_fmtr_tst.java | 2 +- .../xowa/htmls/sidebar/Xowh_sidebar_itm.java | 5 +- .../xowa/htmls/sidebar/Xowh_sidebar_mgr.java | 2 +- .../gplx/xowa/htmls/skins/Xoh_skin_itm.java | 1 + .../src/gplx/xowa/htmls/tocs/Xow_hdr_mgr.java | 4 +- .../src/gplx/xowa/htmls/tocs/Xow_toc_mgr.java | 7 +- .../src/gplx/xowa/langs/Xol_lang_itm.java | 4 +- .../src/gplx/xowa/langs/msgs/Xol_msg_itm.java | 1 + .../gplx/xowa/langs/msgs/Xol_msg_itm_.java | 2 +- .../gplx/xowa/langs/msgs/Xol_msg_mgr_.java | 1 + .../xowa/parsers/htmls/Mwh_atr_parser.java | 8 +- ...ki_align_h.java => Xop_lnki_align_h_.java} | 5 +- .../gplx/xowa/parsers/lnkis/Xop_lnki_tkn.java | 2 +- .../gplx/xowa/parsers/lnkis/Xop_lnki_wkr.java | 24 +-- .../lnkis/Xop_lnki_wkr__basic_tst.java | 4 +- .../xowa/parsers/tmpls/Xot_defn_tmpl_.java | 3 +- .../gplx/xowa/parsers/tmpls/Xot_invk_tkn.java | 5 +- .../xowa/parsers/utils/Xop_redirect_mgr.java | 5 +- .../parsers/utils/Xop_redirect_mgr_tst.java | 3 + .../specials/allPages/Xows_page_allpages.java | 10 +- .../xowa/specials/movePage/Move_page.java | 6 +- .../gplx/xowa/specials/nearby/Nearby_mgr.java | 1 + .../xowa/specials/search/Xows_html_wkr.java | 5 +- .../specials/search/Xows_html_wkr_tst.java | 2 +- .../statistics/Xop_statistics_page.java | 17 +- .../file_browsers/Xosp_fbrow_cmd__base.java | 5 +- .../popup_history/Popup_history_page.java | 1 + .../xowa/system_data/System_data_page.java | 2 +- 400_xowa/src/gplx/xowa/users/Xoue_user.java | 2 +- .../xowa/users/bmks/Dbui_tbl_itm__bmk.java | 3 +- .../users/history/Dbui_tbl_itm__history.java | 1 + .../xowa/users/history/Xou_history_html.java | 5 +- .../src/gplx/xowa/users/prefs/Prefs_mgr.java | 2 +- .../gplx/xowa/users/prefs/Prefs_mgr_tst.java | 2 +- .../gplx/xowa/wikis/ctgs/Xoctg_fmtr_all.java | 3 +- .../gplx/xowa/wikis/ctgs/Xoctg_fmtr_grp.java | 5 +- .../gplx/xowa/wikis/ctgs/Xoctg_fmtr_itm.java | 7 +- .../xowa/wikis/ctgs/Xoctg_html_mgr_tst.java | 4 +- .../xowa/wikis/ctgs/Xoctg_pagelist_grp.java | 5 +- .../xowa/wikis/ctgs/Xoctg_pagelist_itms.java | 5 +- .../xowa/wikis/ctgs/Xoctg_pagelist_mgr.java | 5 +- .../xowa/wikis/ctgs/Xoctg_pagelist_wtr.java | 3 +- .../gplx/xowa/wikis/data/Xowd_db_file.java | 6 +- .../xowa/wikis/metas/Bfmtr_eval_wiki.java | 2 + .../gplx/xowa/wikis/metas/Xow_script_mgr.java | 1 + 400_xowa/src/gplx/xowa/wikis/nss/Xow_ns_.java | 20 ++- .../xowa/wikis/nss/Xow_ns_canonical_.java | 26 ++- .../pages/skins/Xopg_xtn_skin_fmtr_arg.java | 4 +- .../gplx/xowa/wikis/xwikis/Xow_xwiki_itm.java | 2 +- .../sitelinks/htmls/Xoa_sitelink_div_wtr.java | 1 + .../sitelinks/htmls/Xoa_sitelink_grp_wtr.java | 5 +- .../sitelinks/htmls/Xoa_sitelink_itm_wtr.java | 5 +- .../src/gplx/xowa/xtns/cite/Ref_html_wtr.java | 31 ++-- .../gplx/xowa/xtns/cite/Ref_html_wtr_cfg.java | 1 + .../xtns/gallery/Gallery_box_w_fmtr_arg.java | 20 +-- .../xowa/xtns/gallery/Gallery_html_wtr.java | 3 +- .../xowa/xtns/gallery/Gallery_mgr_base.java | 1 + .../gplx/xowa/xtns/hieros/Hiero_html_wtr.java | 1 + .../gplx/xowa/xtns/imaps/Imap_html_fmtrs.java | 1 + .../xowa/xtns/imaps/Imap_img_fmtr_arg.java | 6 +- .../gplx/xowa/xtns/imaps/Imap_map_fmtr.java | 9 +- .../xowa/xtns/imaps/Imap_pts_fmtr_arg.java | 4 +- .../xtns/indicators/Indicator_html_bldr.java | 9 +- .../indicators/Indicator_html_bldr_tst.java | 2 +- .../xowa/xtns/insiders/Insider_html_bldr.java | 5 +- .../xowa/xtns/math/Xof_math_html_wtr.java | 1 + .../src/gplx/xowa/xtns/math/Xof_math_mgr.java | 1 + .../xtns/pfuncs/exprs/Pfunc_expr_shunter.java | 2 +- .../xowa/xtns/pfuncs/times/Pxd_eval_seg.java | 19 +-- .../xowa/xtns/pfuncs/times/Pxd_itm_int.java | 3 +- .../xowa/xtns/pfuncs/times/Pxd_itm_misc.java | 7 +- .../xtns/pfuncs/times/Pxd_itm_month_name.java | 9 +- .../xowa/xtns/pfuncs/times/Pxd_parser.java | 6 +- .../xtns/pfuncs/ttls/Pfunc_anchorencode.java | 6 +- .../xowa/xtns/proofreadPage/Pp_pages_nde.java | 2 +- .../xtns/relatedArticles/Articles_func.java | 5 +- .../relatedArticles/Articles_func_tst.java | 2 +- .../xtns/relatedSites/Sites_html_bldr.java | 5 +- .../gplx/xowa/xtns/scores/Score_xtn_mgr.java | 1 + .../xtns/scribunto/Scrib_invoke_func.java | 1 + .../xtns/scribunto/libs/Scrib_lib_mw.java | 4 +- .../xtns/scribunto/libs/Scrib_lib_title.java | 2 +- .../scribunto/libs/Scrib_regx_converter.java | 1 + .../xtns/translates/Xop_languages_xnde.java | 6 +- .../xtns/wdatas/Wdata_prop_val_visitor.java | 1 + .../xowa/xtns/wdatas/Wdata_wiki_mgr_fxt.java | 2 +- .../xtns/wdatas/Wdata_xwiki_link_wtr.java | 4 +- .../wdatas/core/Wdata_claim_itm_time.java | 1 + .../xowa/xtns/wdatas/core/Wdata_date.java | 1 + .../xowa/xtns/wdatas/core/Wdata_date_tst.java | 2 +- .../xtns/wdatas/hwtrs/Wdata_fmtr__claim.java | 29 ++-- .../xtns/wdatas/hwtrs/Wdata_fmtr__json.java | 5 +- .../wdatas/hwtrs/Wdata_fmtr__langtext.java | 15 +- .../xtns/wdatas/hwtrs/Wdata_fmtr__oview.java | 9 +- .../xtns/wdatas/hwtrs/Wdata_fmtr__slink.java | 17 +- .../xtns/wdatas/hwtrs/Wdata_fmtr__toc.java | 9 +- .../xtns/wdatas/hwtrs/Wdata_hwtr_mgr.java | 1 + .../xtns/wdatas/hwtrs/Wdata_hwtr_mgr_tst.java | 2 +- .../xtns/wdatas/hwtrs/Wdata_hwtr_msgs.java | 1 + .../wdatas/hwtrs/Wdata_visitor__html_wtr.java | 1 + .../specials/Wdata_itemByTitle_page.java | 2 +- .../xowa/xtns/xowa_cmds/Xop_xowa_cmd_tst.java | 1 + .../xtns/xowa_cmds/Xop_xowa_func_tst.java | 2 +- .../en.wikipedia.org-text.xowa | Bin 36864 -> 36864 bytes 418 files changed, 2694 insertions(+), 1621 deletions(-) rename 100_core/{src_100_types_primitive => src}/gplx/Bool_.java (97%) rename 100_core/{src_100_types_primitive => src}/gplx/Byte_.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Byte__tst.java (98%) rename 100_core/{src_100_types_primitive => src}/gplx/Byte_ascii.java (97%) rename 100_core/{src_100_types_primitive => src}/gplx/Char_.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Double_.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Double__tst.java (100%) rename 100_core/{src_210_env => src}/gplx/Env_.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Float_.java (100%) rename 100_core/{src_400_gfs => src}/gplx/GfsCtx.java (94%) rename 100_core/{src_100_types_primitive => src}/gplx/Int_.java (97%) rename 100_core/{src_100_types_primitive => src}/gplx/Int__tst.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Int_ary_.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Int_ary__tst.java (100%) rename 100_core/{src_210_env => src}/gplx/JarAdp_.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Long_.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Long__tst.java (100%) rename 100_core/{src_210_env => src}/gplx/Op_sys.java (100%) rename 100_core/{src_210_env => src}/gplx/Op_sys_.java (100%) rename 100_core/{src_210_env => src}/gplx/ProcessAdp.java (97%) rename 100_core/{src_210_env => src}/gplx/ProcessAdp_tst.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Short_.java (100%) rename 100_core/{src_210_env => src}/gplx/Type_adp_.java (100%) rename 100_core/{src_100_types_primitive => src}/gplx/Yn.java (100%) rename 100_core/{src_130_brys/gplx/brys/Bry_fmtr_arg_bry.java => src/gplx/core/brys/Bfr_arg.java} (72%) create mode 100644 100_core/src/gplx/core/brys/Bfr_arg_.java rename 100_core/{src_130_brys/gplx/brys/Bry_fmtr_arg_byt.java => src/gplx/core/brys/Bfr_arg_base.java} (71%) rename 100_core/{src_130_brys => src}/gplx/core/brys/Bry_split_wkr.java (100%) create mode 100644 100_core/src/gplx/core/brys/args/Bfr_arg__bry.java create mode 100644 100_core/src/gplx/core/brys/args/Bfr_arg__bry_ary.java create mode 100644 100_core/src/gplx/core/brys/args/Bfr_arg__bry_fmtr.java create mode 100644 100_core/src/gplx/core/brys/args/Bfr_arg__byte.java rename 100_core/{src_130_brys/gplx/brys/Bry_fmtr_arg_decimal_int.java => src/gplx/core/brys/args/Bfr_arg__decimal_int.java} (64%) rename 100_core/{src_130_brys/gplx/brys/Bry_fmtr_arg_ary_dim2.java => src/gplx/core/brys/args/Bfr_arg__int.java} (62%) rename 100_core/{src_130_brys/gplx/brys/Bry_fmtr_arg_time.java => src/gplx/core/brys/args/Bfr_arg__time.java} (80%) rename 100_core/{src_130_brys/gplx/brys/Bry_fmtr_arg_time_tst.java => src/gplx/core/brys/args/Bfr_arg__time_tst.java} (85%) rename 100_core/{src_130_brys/gplx => src/gplx/core/brys/fmtrs}/Bry_fmtr.java (94%) rename 100_core/{src_130_brys/gplx => src/gplx/core/brys/fmtrs}/Bry_fmtr_eval_mgr.java (89%) rename 100_core/{src_130_brys/gplx => src/gplx/core/brys/fmtrs}/Bry_fmtr_eval_mgr_.java (91%) rename 100_core/{src_130_brys/gplx => src/gplx/core/brys/fmtrs}/Bry_fmtr_eval_mgr_gfs.java (90%) rename 100_core/{src_130_brys/gplx => src/gplx/core/brys/fmtrs}/Bry_fmtr_itm.java (92%) rename 100_core/{src_130_brys/gplx => src/gplx/core/brys/fmtrs}/Bry_fmtr_tst.java (95%) rename 100_core/{src_130_brys/gplx => src/gplx/core/brys/fmtrs}/Bry_fmtr_vals.java (82%) rename 100_core/{src_310_gfoNde/gplx => src/gplx/core/gfo_ndes}/GfoFld.java (93%) rename 100_core/{src_310_gfoNde/gplx => src/gplx/core/gfo_ndes}/GfoFldList.java (92%) rename 100_core/{src_310_gfoNde/gplx => src/gplx/core/gfo_ndes}/GfoFldList_.java (95%) rename 100_core/{src_310_gfoNde/gplx => src/gplx/core/gfo_ndes}/GfoNde.java (96%) rename 100_core/{src_310_gfoNde/gplx => src/gplx/core/gfo_ndes}/GfoNdeFxt.java (95%) rename 100_core/{src_310_gfoNde/gplx => src/gplx/core/gfo_ndes}/GfoNdeList.java (92%) rename 100_core/{src_310_gfoNde/gplx => src/gplx/core/gfo_ndes}/GfoNdeList_.java (95%) rename 100_core/{src_310_gfoNde/gplx => src/gplx/core/gfo_ndes}/GfoNde_.java (96%) rename 100_core/{src_410_gfoCfg/gplx => src/gplx/core/gfo_regys}/GfoMsgParser.java (92%) rename 100_core/{src_410_gfoCfg/gplx => src/gplx/core/gfo_regys}/GfoRegy.java (96%) rename 100_core/{src_410_gfoCfg/gplx => src/gplx/core/gfo_regys}/GfoRegyItm.java (93%) rename 100_core/{src_410_gfoCfg/gplx => src/gplx/core/gfo_regys}/GfoRegy_RegDir_tst.java (95%) rename 100_core/{src_410_gfoCfg/gplx => src/gplx/core/gfo_regys}/GfoRegy_basic_tst.java (93%) create mode 100644 100_core/src/gplx/langs/gfs/GfsCore.java rename 100_core/{src_400_gfs/gplx => src/gplx/langs/gfs}/GfsCoreHelp.java (96%) rename 100_core/{src_400_gfs/gplx/GfsCore.java => src/gplx/langs/gfs/GfsCore_.java} (54%) rename 100_core/{src_400_gfs/gplx => src/gplx/langs/gfs}/GfsCore_tst.java (96%) rename 100_core/{src_400_gfs/gplx => src/gplx/langs/gfs}/GfsLibIni.java (92%) rename 100_core/{src_400_gfs/gplx => src/gplx/langs/gfs}/GfsLibIni_core.java (93%) rename 100_core/{src_400_gfs/gplx => src/gplx/langs/gfs}/GfsRegy.java (96%) rename 100_core/{src_400_gfs/gplx => src/gplx/langs/gfs}/GfsTypeNames.java (92%) rename 100_core/{src_400_gfs/gplx => src/gplx/langs/gfs}/Gfs_Date_tst.java (95%) delete mode 100644 100_core/src_130_brys/gplx/Bry_fmtr_arg_.java delete mode 100644 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_fmtr.java delete mode 100644 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_int.java rename 100_core/src_130_brys/gplx/Bry_fmtr_arg.java => 400_xowa/src/gplx/core/brys/Clear_able.java (86%) rename 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_bfr.java => 400_xowa/src/gplx/core/brys/Mid_able.java (70%) create mode 100644 400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_.java create mode 100644 400_xowa/src/gplx/dbs/Db_diff_bldr.java rename 400_xowa/src/gplx/langs/htmls/parsers/{Html_atr_cls_.java => clses/Html_atr_class_.java} (89%) rename 400_xowa/src/gplx/langs/htmls/parsers/{Html_atr_cls__tst.java => clses/Html_atr_class__tst.java} (79%) create mode 100644 400_xowa/src/gplx/langs/htmls/parsers/clses/Html_atr_class_parser_.java create mode 100644 400_xowa/src/gplx/langs/htmls/parsers/clses/Html_atr_class_parser__tst.java create mode 100644 400_xowa/src/gplx/langs/htmls/parsers/clses/Html_atr_class_wkr.java rename 400_xowa/src/gplx/langs/htmls/parsers/styles/{Html_atr_style_parser.java => Html_atr_style_parser_.java} (86%) rename 400_xowa/src/gplx/langs/htmls/parsers/styles/{Html_atr_style_parser_tst.java => Html_atr_style_parser__tst.java} (69%) rename 400_xowa/src/gplx/xowa/htmls/core/hzips/{stats => }/Hzip_stat_itm.java (92%) rename 400_xowa/src/gplx/xowa/htmls/core/hzips/{stats => }/Hzip_stat_tbl.java (94%) delete mode 100644 400_xowa/src/gplx/xowa/htmls/core/hzips/Xoh_decode_ctx.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/hzips/Xoh_hzip_fxt.java delete mode 100644 400_xowa/src/gplx/xowa/htmls/core/hzips/Xow_hzip_mgr.java delete mode 100644 400_xowa/src/gplx/xowa/htmls/core/hzips/tests/Xoh_hzip_fxt.java rename 400_xowa/src/gplx/xowa/htmls/core/wkrs/{Xoh_hdoc_wkr__base.java => Xoh_hdoc_parser.java} (58%) create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/bfr_args/Bfr_arg__href.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/bfr_args/Bfr_arg__html_atr.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/bfr_args/Bfr_arg__id.java rename 100_core/src_130_brys/gplx/Bry_fmtr_arg_fmtr_objs.java => 400_xowa/src/gplx/xowa/htmls/core/wkrs/bfr_args/Bfr_arg__indent.java (57%) rename 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_bfr_preserve.java => 400_xowa/src/gplx/xowa/htmls/core/wkrs/glys/Xoh_gly_grp_cls_.java (67%) create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/glys/Xoh_gly_grp_parser.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/glys/Xoh_gly_itm_parser.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/imgs/Xoh_img_bldr.java delete mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/imgs/Xoh_img_make.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/imgs/Xoh_img_wtr.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/mkrs/Xoh_hdoc_mkr.java rename 400_xowa/src/gplx/xowa/htmls/core/wkrs/tags/{Xoh_doc_wkr__tag.java => Xoh_tag_parser.java} (52%) create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/thms/Xoh_thm_bldr.java delete mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/thms/Xoh_thm_parse.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/thms/Xoh_thm_parser.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/thms/Xoh_thm_wtr.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/thms/divs/Xoh_thm_caption_parser.java create mode 100644 400_xowa/src/gplx/xowa/htmls/core/wkrs/thms/divs/Xoh_thm_magnify_parser.java rename 400_xowa/src/gplx/xowa/htmls/core/{ => wkrs}/to_delete/Xohd_page_html_mgr__load.java (95%) rename 400_xowa/src/gplx/xowa/htmls/core/{ => wkrs}/to_delete/Xohd_page_html_mgr__save.java (100%) rename 400_xowa/src/gplx/xowa/parsers/lnkis/{Xop_lnki_align_h.java => Xop_lnki_align_h_.java} (91%) diff --git a/100_core/.classpath b/100_core/.classpath index d384c9769..63319e41f 100644 --- a/100_core/.classpath +++ b/100_core/.classpath @@ -1,20 +1,14 @@ - - - - - - diff --git a/100_core/src_100_types_primitive/gplx/Bool_.java b/100_core/src/gplx/Bool_.java similarity index 97% rename from 100_core/src_100_types_primitive/gplx/Bool_.java rename to 100_core/src/gplx/Bool_.java index 51d698b24..845d1954f 100644 --- a/100_core/src_100_types_primitive/gplx/Bool_.java +++ b/100_core/src/gplx/Bool_.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx; +import gplx.langs.gfs.*; public class Bool_ implements GfoInvkAble { public static final String Cls_val_name = "boolean"; public static final Class Cls_ref_type = Boolean.class; diff --git a/100_core/src_100_types_primitive/gplx/Byte_.java b/100_core/src/gplx/Byte_.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Byte_.java rename to 100_core/src/gplx/Byte_.java diff --git a/100_core/src_100_types_primitive/gplx/Byte__tst.java b/100_core/src/gplx/Byte__tst.java similarity index 98% rename from 100_core/src_100_types_primitive/gplx/Byte__tst.java rename to 100_core/src/gplx/Byte__tst.java index d96b2864f..3e78dbb9b 100644 --- a/100_core/src_100_types_primitive/gplx/Byte__tst.java +++ b/100_core/src/gplx/Byte__tst.java @@ -17,7 +17,7 @@ along with this program. If not, see . */ package gplx; import org.junit.*; -public class Byte__tst { +public class Byte__tst { @Test public void int_() { tst_int_( 0, 0); tst_int_( 127, 127); diff --git a/100_core/src_100_types_primitive/gplx/Byte_ascii.java b/100_core/src/gplx/Byte_ascii.java similarity index 97% rename from 100_core/src_100_types_primitive/gplx/Byte_ascii.java rename to 100_core/src/gplx/Byte_ascii.java index f70b5176c..2b2538a83 100644 --- a/100_core/src_100_types_primitive/gplx/Byte_ascii.java +++ b/100_core/src/gplx/Byte_ascii.java @@ -99,6 +99,7 @@ public class Byte_ascii { public static final byte[] Tab_bry = new byte[] {Byte_ascii.Tab} , Nl_bry = new byte[] {Byte_ascii.Nl} + , Space_bry = new byte[] {Byte_ascii.Space} , Bang_bry = new byte[] {Byte_ascii.Bang} , Quote_bry = new byte[] {Byte_ascii.Quote} , Hash_bry = new byte[] {Byte_ascii.Hash} @@ -107,6 +108,7 @@ public class Byte_ascii { , Angle_end_bry = new byte[] {Byte_ascii.Angle_end} , Comma_bry = new byte[] {Byte_ascii.Comma} , Colon_bry = new byte[] {Byte_ascii.Colon} + , Eq_bry = new byte[] {Byte_ascii.Eq} , Amp_bry = new byte[] {Byte_ascii.Amp} , Lt_bry = new byte[] {Byte_ascii.Lt} , Gt_bry = new byte[] {Byte_ascii.Gt} @@ -118,6 +120,5 @@ public class Byte_ascii { , Slash_bry = new byte[] {Byte_ascii.Slash} , Asterisk_bry = new byte[] {Byte_ascii.Star} , Dash_bry = new byte[] {Byte_ascii.Dash} - , Space_bry = new byte[] {Byte_ascii.Space} ; } diff --git a/100_core/src_100_types_primitive/gplx/Char_.java b/100_core/src/gplx/Char_.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Char_.java rename to 100_core/src/gplx/Char_.java diff --git a/100_core/src_100_types_primitive/gplx/Double_.java b/100_core/src/gplx/Double_.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Double_.java rename to 100_core/src/gplx/Double_.java diff --git a/100_core/src_100_types_primitive/gplx/Double__tst.java b/100_core/src/gplx/Double__tst.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Double__tst.java rename to 100_core/src/gplx/Double__tst.java diff --git a/100_core/src_210_env/gplx/Env_.java b/100_core/src/gplx/Env_.java similarity index 100% rename from 100_core/src_210_env/gplx/Env_.java rename to 100_core/src/gplx/Env_.java diff --git a/100_core/src/gplx/Err.java b/100_core/src/gplx/Err.java index c7027f768..183ba6d2c 100644 --- a/100_core/src/gplx/Err.java +++ b/100_core/src/gplx/Err.java @@ -25,6 +25,7 @@ public class Err extends RuntimeException { this.trace = is_gplx ? Err_.Trace_lang(this) : trace; // NOTE: Err_ factory methods pass in null stack trace for gplx excs; call Stack_trace here, note that trace will not show constructor Msgs_add(type, msg, args); } + public boolean Logged() {return logged;} public Err Logged_y_() {logged = true; return this;} private boolean logged; public int Trace_ignore() {return trace_ignore;} public Err Trace_ignore_add_1_() {++trace_ignore; return this;} private int trace_ignore = 0; public Err Args_add(Object... args) {msgs_ary[msgs_idx - 1].Args_add(args); return this;} // i - 1 to get current @gplx.Internal protected boolean Type_match(String type) { diff --git a/100_core/src_100_types_primitive/gplx/Float_.java b/100_core/src/gplx/Float_.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Float_.java rename to 100_core/src/gplx/Float_.java diff --git a/100_core/src_400_gfs/gplx/GfsCtx.java b/100_core/src/gplx/GfsCtx.java similarity index 94% rename from 100_core/src_400_gfs/gplx/GfsCtx.java rename to 100_core/src/gplx/GfsCtx.java index 67b9fb668..88cf9f269 100644 --- a/100_core/src_400_gfs/gplx/GfsCtx.java +++ b/100_core/src/gplx/GfsCtx.java @@ -21,7 +21,7 @@ public class GfsCtx { public boolean Fail_if_unhandled() {return fail_if_unhandled;} public GfsCtx Fail_if_unhandled_(boolean v) {fail_if_unhandled = v; return this;} private boolean fail_if_unhandled; public Gfo_usr_dlg Usr_dlg() {return usr_dlg;} public GfsCtx Usr_dlg_(Gfo_usr_dlg v) {usr_dlg = v; return this;} Gfo_usr_dlg usr_dlg; public boolean Help_browseMode() {return help_browseMode;} public GfsCtx Help_browseMode_(boolean v) {help_browseMode = v; return this;} private boolean help_browseMode; - @gplx.Internal protected List_adp Help_browseList() {return help_browseList;} List_adp help_browseList = List_adp_.new_(); + public List_adp Help_browseList() {return help_browseList;} List_adp help_browseList = List_adp_.new_(); public Object MsgSrc() {return msgSrc;} public GfsCtx MsgSrc_(Object v) {msgSrc = v; return this;} Object msgSrc; public boolean Match(String k, String match) { if (help_browseMode) { diff --git a/100_core/src_100_types_primitive/gplx/Int_.java b/100_core/src/gplx/Int_.java similarity index 97% rename from 100_core/src_100_types_primitive/gplx/Int_.java rename to 100_core/src/gplx/Int_.java index 805a12892..240fbac5a 100644 --- a/100_core/src_100_types_primitive/gplx/Int_.java +++ b/100_core/src/gplx/Int_.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx; -import gplx.core.strings.*; +import gplx.core.strings.*; import gplx.langs.gfs.*; public class Int_ implements GfoInvkAble { public static final String Cls_val_name = "int"; public static final Class Cls_ref_type = Integer.class; diff --git a/100_core/src_100_types_primitive/gplx/Int__tst.java b/100_core/src/gplx/Int__tst.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Int__tst.java rename to 100_core/src/gplx/Int__tst.java diff --git a/100_core/src_100_types_primitive/gplx/Int_ary_.java b/100_core/src/gplx/Int_ary_.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Int_ary_.java rename to 100_core/src/gplx/Int_ary_.java diff --git a/100_core/src_100_types_primitive/gplx/Int_ary__tst.java b/100_core/src/gplx/Int_ary__tst.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Int_ary__tst.java rename to 100_core/src/gplx/Int_ary__tst.java diff --git a/100_core/src_210_env/gplx/JarAdp_.java b/100_core/src/gplx/JarAdp_.java similarity index 100% rename from 100_core/src_210_env/gplx/JarAdp_.java rename to 100_core/src/gplx/JarAdp_.java diff --git a/100_core/src_100_types_primitive/gplx/Long_.java b/100_core/src/gplx/Long_.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Long_.java rename to 100_core/src/gplx/Long_.java diff --git a/100_core/src_100_types_primitive/gplx/Long__tst.java b/100_core/src/gplx/Long__tst.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Long__tst.java rename to 100_core/src/gplx/Long__tst.java diff --git a/100_core/src_210_env/gplx/Op_sys.java b/100_core/src/gplx/Op_sys.java similarity index 100% rename from 100_core/src_210_env/gplx/Op_sys.java rename to 100_core/src/gplx/Op_sys.java diff --git a/100_core/src_210_env/gplx/Op_sys_.java b/100_core/src/gplx/Op_sys_.java similarity index 100% rename from 100_core/src_210_env/gplx/Op_sys_.java rename to 100_core/src/gplx/Op_sys_.java diff --git a/100_core/src_210_env/gplx/ProcessAdp.java b/100_core/src/gplx/ProcessAdp.java similarity index 97% rename from 100_core/src_210_env/gplx/ProcessAdp.java rename to 100_core/src/gplx/ProcessAdp.java index eb33e810b..3cbacd837 100644 --- a/100_core/src_210_env/gplx/ProcessAdp.java +++ b/100_core/src/gplx/ProcessAdp.java @@ -24,7 +24,8 @@ import java.io.InputStream; import java.io.InputStreamReader; import javax.management.RuntimeErrorException; -import gplx.core.strings.*; +import gplx.core.brys.fmtrs.*; +import gplx.core.strings.*; import gplx.langs.gfs.*; public class ProcessAdp implements GfoInvkAble, RlsAble { public boolean Enabled() {return enabled;} public ProcessAdp Enabled_(boolean v) {enabled = v; return this;} private boolean enabled = true; public byte Exe_exists() {return exe_exists;} public ProcessAdp Exe_exists_(byte v) {exe_exists = v; return this;} private byte exe_exists = Bool_.__byte; diff --git a/100_core/src_210_env/gplx/ProcessAdp_tst.java b/100_core/src/gplx/ProcessAdp_tst.java similarity index 100% rename from 100_core/src_210_env/gplx/ProcessAdp_tst.java rename to 100_core/src/gplx/ProcessAdp_tst.java diff --git a/100_core/src_100_types_primitive/gplx/Short_.java b/100_core/src/gplx/Short_.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Short_.java rename to 100_core/src/gplx/Short_.java diff --git a/100_core/src/gplx/Tfds.java b/100_core/src/gplx/Tfds.java index 4eea039a4..04c60020f 100644 --- a/100_core/src/gplx/Tfds.java +++ b/100_core/src/gplx/Tfds.java @@ -221,9 +221,9 @@ class TfdsMsgBldr { } sb.Add_fmt_line("{0}: {1} {2} {3}" , Int_.To_str_pad_bgn_zero(itm.Idx(), 4) - , String_.PadBgn(itm.Lhs(), lhsLenMax, " ") + , itm.Lhs() // String_.PadBgn(itm.Lhs(), lhsLenMax, " ") , eq_str - , String_.PadBgn(itm.Rhs(), rhsLenMax, " ") + , itm.Rhs() // String_.PadBgn(itm.Rhs(), rhsLenMax, " ") ); } // String compSym = isEq ? " " : "!="; diff --git a/100_core/src_210_env/gplx/Type_adp_.java b/100_core/src/gplx/Type_adp_.java similarity index 100% rename from 100_core/src_210_env/gplx/Type_adp_.java rename to 100_core/src/gplx/Type_adp_.java diff --git a/100_core/src_100_types_primitive/gplx/Yn.java b/100_core/src/gplx/Yn.java similarity index 100% rename from 100_core/src_100_types_primitive/gplx/Yn.java rename to 100_core/src/gplx/Yn.java diff --git a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_bry.java b/100_core/src/gplx/core/brys/Bfr_arg.java similarity index 72% rename from 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_bry.java rename to 100_core/src/gplx/core/brys/Bfr_arg.java index ac3d68996..9e341e121 100644 --- a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_bry.java +++ b/100_core/src/gplx/core/brys/Bfr_arg.java @@ -15,9 +15,9 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx.brys; import gplx.*; -public class Bry_fmtr_arg_bry implements Bry_fmtr_arg { - public Bry_fmtr_arg_bry Data_(byte[] v) {ary = v; return this;} - public void Fmt__do(Bry_bfr bfr) {bfr.Add(ary);} - public Bry_fmtr_arg_bry(byte[] v) {this.ary = v;} byte[] ary; +package gplx.core.brys; import gplx.*; import gplx.core.*; +public interface Bfr_arg { + void Bfr_arg__clear(); + boolean Bfr_arg__exists(); + void Bfr_arg__add(Bry_bfr bfr); } diff --git a/100_core/src/gplx/core/brys/Bfr_arg_.java b/100_core/src/gplx/core/brys/Bfr_arg_.java new file mode 100644 index 000000000..8c2b4ae91 --- /dev/null +++ b/100_core/src/gplx/core/brys/Bfr_arg_.java @@ -0,0 +1,37 @@ +/* +XOWA: the XOWA Offline Wiki Application +Copyright (C) 2012 gnosygnu@gmail.com + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as +published by the Free Software Foundation, either version 3 of the +License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see . +*/ +package gplx.core.brys; import gplx.*; import gplx.core.*; +import gplx.core.brys.args.*; import gplx.core.brys.fmtrs.*; +public class Bfr_arg_ { + public static Bfr_arg__int New_int(int v) {return new Bfr_arg__int(v);} + public static Bfr_arg__byte New_byte(byte v) {return new Bfr_arg__byte(v);} + public static Bfr_arg__bry New_bry(String v) {return new Bfr_arg__bry(Bry_.new_u8(v));} + public static Bfr_arg__bry New_bry(byte[] v) {return new Bfr_arg__bry(v);} + public static Bfr_arg__bry_fmtr New_bry_fmtr__null() {return new Bfr_arg__bry_fmtr(null, null);} + public static Bfr_arg__bry_fmtr New_bry_fmtr(Bry_fmtr v, Bfr_arg... arg_ary) {return new Bfr_arg__bry_fmtr(v, arg_ary);} + public static final Bfr_arg Noop = new Bfr_arg___noop(); + public static void Clear(Bfr_arg... ary) { + for (Bfr_arg arg : ary) + arg.Bfr_arg__clear(); + } +} +class Bfr_arg___noop implements gplx.core.brys.Bfr_arg { + public void Bfr_arg__clear() {} + public boolean Bfr_arg__exists() {return false;} + public void Bfr_arg__add(Bry_bfr bfr) {} +} diff --git a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_byt.java b/100_core/src/gplx/core/brys/Bfr_arg_base.java similarity index 71% rename from 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_byt.java rename to 100_core/src/gplx/core/brys/Bfr_arg_base.java index c4367a8ec..235790e5f 100644 --- a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_byt.java +++ b/100_core/src/gplx/core/brys/Bfr_arg_base.java @@ -15,9 +15,9 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx.brys; import gplx.*; -public class Bry_fmtr_arg_byt implements Bry_fmtr_arg { - public Bry_fmtr_arg_byt(byte byt) {this.byt = byt;} private byte byt; - public Bry_fmtr_arg_byt Data_(byte v) {byt = v; return this;} - public void Fmt__do(Bry_bfr bfr) {bfr.Add_byte(byt);} +package gplx.core.brys; import gplx.*; import gplx.core.*; +public abstract class Bfr_arg_base implements Bfr_arg { + @gplx.Virtual public void Bfr_arg__clear() {} + @gplx.Virtual public boolean Bfr_arg__exists() {return true;} + public abstract void Bfr_arg__add(Bry_bfr bfr); } diff --git a/100_core/src_130_brys/gplx/core/brys/Bry_split_wkr.java b/100_core/src/gplx/core/brys/Bry_split_wkr.java similarity index 100% rename from 100_core/src_130_brys/gplx/core/brys/Bry_split_wkr.java rename to 100_core/src/gplx/core/brys/Bry_split_wkr.java diff --git a/100_core/src/gplx/core/brys/args/Bfr_arg__bry.java b/100_core/src/gplx/core/brys/args/Bfr_arg__bry.java new file mode 100644 index 000000000..6eb4ea97f --- /dev/null +++ b/100_core/src/gplx/core/brys/args/Bfr_arg__bry.java @@ -0,0 +1,23 @@ +/* +XOWA: the XOWA Offline Wiki Application +Copyright (C) 2012 gnosygnu@gmail.com + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as +published by the Free Software Foundation, either version 3 of the +License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see . +*/ +package gplx.core.brys.args; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +public class Bfr_arg__bry extends gplx.core.brys.Bfr_arg_base { + private final byte[] bry; + public Bfr_arg__bry(byte[] v) {this.bry = v;} + @Override public void Bfr_arg__add(Bry_bfr bfr) {bfr.Add(bry);} +} diff --git a/100_core/src/gplx/core/brys/args/Bfr_arg__bry_ary.java b/100_core/src/gplx/core/brys/args/Bfr_arg__bry_ary.java new file mode 100644 index 000000000..00571d658 --- /dev/null +++ b/100_core/src/gplx/core/brys/args/Bfr_arg__bry_ary.java @@ -0,0 +1,26 @@ +/* +XOWA: the XOWA Offline Wiki Application +Copyright (C) 2012 gnosygnu@gmail.com + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as +published by the Free Software Foundation, either version 3 of the +License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see . +*/ +package gplx.core.brys.args; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +public class Bfr_arg__bry_ary extends gplx.core.brys.Bfr_arg_base { + private byte[][] bry_ary; + public Bfr_arg__bry_ary Set(byte[][] v) {this.bry_ary = v; return this;} + @Override public void Bfr_arg__add(Bry_bfr bfr) { + for (byte[] bry : bry_ary) + bfr.Add(bry); + } +} diff --git a/100_core/src/gplx/core/brys/args/Bfr_arg__bry_fmtr.java b/100_core/src/gplx/core/brys/args/Bfr_arg__bry_fmtr.java new file mode 100644 index 000000000..c2edd2961 --- /dev/null +++ b/100_core/src/gplx/core/brys/args/Bfr_arg__bry_fmtr.java @@ -0,0 +1,28 @@ +/* +XOWA: the XOWA Offline Wiki Application +Copyright (C) 2012 gnosygnu@gmail.com + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as +published by the Free Software Foundation, either version 3 of the +License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see . +*/ +package gplx.core.brys.args; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +import gplx.core.brys.fmtrs.*; +public class Bfr_arg__bry_fmtr extends gplx.core.brys.Bfr_arg_base { + private Bry_fmtr fmtr; private Object[] arg_ary; + public Bfr_arg__bry_fmtr(Bry_fmtr fmtr, Object[] arg_ary) {Set(fmtr, arg_ary);} + public Bfr_arg__bry_fmtr Set(Bry_fmtr fmtr, Object... arg_ary) { + this.fmtr = fmtr; this.arg_ary = arg_ary; + return this; + } + @Override public void Bfr_arg__add(Bry_bfr bfr) {fmtr.Bld_bfr_many(bfr, arg_ary);} +} diff --git a/100_core/src/gplx/core/brys/args/Bfr_arg__byte.java b/100_core/src/gplx/core/brys/args/Bfr_arg__byte.java new file mode 100644 index 000000000..f6c707935 --- /dev/null +++ b/100_core/src/gplx/core/brys/args/Bfr_arg__byte.java @@ -0,0 +1,23 @@ +/* +XOWA: the XOWA Offline Wiki Application +Copyright (C) 2012 gnosygnu@gmail.com + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as +published by the Free Software Foundation, either version 3 of the +License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see . +*/ +package gplx.core.brys.args; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +public class Bfr_arg__byte extends gplx.core.brys.Bfr_arg_base { + private final byte byt; + public Bfr_arg__byte(byte byt) {this.byt = byt;} + @Override public void Bfr_arg__add(Bry_bfr bfr) {bfr.Add_byte(byt);} +} diff --git a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_decimal_int.java b/100_core/src/gplx/core/brys/args/Bfr_arg__decimal_int.java similarity index 64% rename from 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_decimal_int.java rename to 100_core/src/gplx/core/brys/args/Bfr_arg__decimal_int.java index b5086a122..fa38559c0 100644 --- a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_decimal_int.java +++ b/100_core/src/gplx/core/brys/args/Bfr_arg__decimal_int.java @@ -15,11 +15,11 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx.brys; import gplx.*; -public class Bry_fmtr_arg_decimal_int implements Bry_fmtr_arg { - public int Val() {return val;} public Bry_fmtr_arg_decimal_int Val_(int v) {val = v; return this;} int val; - public Bry_fmtr_arg_decimal_int Places_(int v) {places = v; multiple = (int)Math_.Pow(10, v); return this;} int multiple = 1000, places = 3; - public void Fmt__do(Bry_bfr bfr) { +package gplx.core.brys.args; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +public class Bfr_arg__decimal_int extends gplx.core.brys.Bfr_arg_base { + public int Val() {return val;} public Bfr_arg__decimal_int Val_(int v) {val = v; return this;} int val; + public Bfr_arg__decimal_int Places_(int v) {places = v; multiple = (int)Math_.Pow(10, v); return this;} int multiple = 1000, places = 3; + @Override public void Bfr_arg__add(Bry_bfr bfr) { bfr.Add_int_variable(val / multiple).Add_byte(Byte_ascii.Dot).Add_int_fixed(val % multiple, places); } } diff --git a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_ary_dim2.java b/100_core/src/gplx/core/brys/args/Bfr_arg__int.java similarity index 62% rename from 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_ary_dim2.java rename to 100_core/src/gplx/core/brys/args/Bfr_arg__int.java index bfc78b3a6..5c6089d53 100644 --- a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_ary_dim2.java +++ b/100_core/src/gplx/core/brys/args/Bfr_arg__int.java @@ -15,13 +15,14 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx.brys; import gplx.*; -public class Bry_fmtr_arg_ary_dim2 implements Bry_fmtr_arg { - public Bry_fmtr_arg_ary_dim2 Data_(byte[][] v) {ary_dim2 = v; return this;} - public Bry_fmtr_arg_ary_dim2 Ary_dim2_(byte[][] v) {this.ary_dim2 = v; return this;} - public void Fmt__do(Bry_bfr bfr) { - for (byte[] ary : ary_dim2) - bfr.Add(ary); +package gplx.core.brys.args; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +public class Bfr_arg__int extends gplx.core.brys.Bfr_arg_base { + private int val, val_digits; + public Bfr_arg__int(int v) {Set(v);} + public Bfr_arg__int Set(int v) { + this.val = Int_.cast(v); + this.val_digits = Int_.DigitCount(val); + return this; } - public Bry_fmtr_arg_ary_dim2() {} byte[][] ary_dim2 = new byte[0][]; + @Override public void Bfr_arg__add(Bry_bfr bfr) {bfr.Add_int_digits(val_digits, val);} } diff --git a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_time.java b/100_core/src/gplx/core/brys/args/Bfr_arg__time.java similarity index 80% rename from 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_time.java rename to 100_core/src/gplx/core/brys/args/Bfr_arg__time.java index 6c1c4b4be..f3a27a64f 100644 --- a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_time.java +++ b/100_core/src/gplx/core/brys/args/Bfr_arg__time.java @@ -15,12 +15,12 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx.brys; import gplx.*; -public class Bry_fmtr_arg_time implements Bry_fmtr_arg { - public Bry_fmtr_arg_time() { +package gplx.core.brys.args; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +public class Bfr_arg__time extends gplx.core.brys.Bfr_arg_base { + public Bfr_arg__time() { units_len = units.length; } - public long Seconds() {return seconds;} public Bry_fmtr_arg_time Seconds_(long v) {seconds = v; return this;} long seconds; + public long Seconds() {return seconds;} public Bfr_arg__time Seconds_(long v) {seconds = v; return this;} long seconds; byte[][] segs = new byte[][] { Bry_.new_a7("d") , Bry_.new_a7("h") @@ -30,7 +30,7 @@ public class Bry_fmtr_arg_time implements Bry_fmtr_arg { int[] units = new int[] {86400, 3600, 60, 1}; int units_len; byte[] spr = new byte[] {Byte_ascii.Space}; - public void Fmt__do(Bry_bfr bfr) { + @Override public void Bfr_arg__add(Bry_bfr bfr) { if (seconds == 0) { // handle 0 separately (since it will always be < than units[*] bfr.Add_int_fixed(0, 2).Add(segs[units_len - 1]); return; diff --git a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_time_tst.java b/100_core/src/gplx/core/brys/args/Bfr_arg__time_tst.java similarity index 85% rename from 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_time_tst.java rename to 100_core/src/gplx/core/brys/args/Bfr_arg__time_tst.java index 853318d0a..380b89a1c 100644 --- a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_time_tst.java +++ b/100_core/src/gplx/core/brys/args/Bfr_arg__time_tst.java @@ -15,9 +15,9 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx.brys; import gplx.*; +package gplx.core.brys.args; import gplx.*; import gplx.core.*; import gplx.core.brys.*; import org.junit.*; -public class Bry_fmtr_arg_time_tst { +public class Bfr_arg__time_tst { @Test public void Basic() { Time_fmtr_arg_fxt fxt = new Time_fmtr_arg_fxt().Clear(); fxt.XferAry( 1, "01s"); // seconds @@ -30,13 +30,13 @@ public class Bry_fmtr_arg_time_tst { } class Time_fmtr_arg_fxt { public Time_fmtr_arg_fxt Clear() { - if (arg == null) arg = new Bry_fmtr_arg_time(); + if (arg == null) arg = new Bfr_arg__time(); return this; - } Bry_fmtr_arg_time arg; + } Bfr_arg__time arg; public void XferAry(int seconds, String expd) { Bry_bfr bfr = Bry_bfr.reset_(255); arg.Seconds_(seconds); - arg.Fmt__do(bfr); + arg.Bfr_arg__add(bfr); Tfds.Eq(expd, bfr.To_str()); } } diff --git a/100_core/src_130_brys/gplx/Bry_fmtr.java b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr.java similarity index 94% rename from 100_core/src_130_brys/gplx/Bry_fmtr.java rename to 100_core/src/gplx/core/brys/fmtrs/Bry_fmtr.java index 36e56de01..25c54ffd3 100644 --- a/100_core/src_130_brys/gplx/Bry_fmtr.java +++ b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr.java @@ -15,8 +15,8 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; -import gplx.core.primitives.*; import gplx.core.strings.*; +package gplx.core.brys.fmtrs; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +import gplx.core.brys.*; import gplx.core.primitives.*; import gplx.core.strings.*; public class Bry_fmtr { public byte[] Fmt() {return fmt;} private byte[] fmt = Bry_.Empty; public boolean Fmt_null() {return fmt.length == 0;} @@ -27,7 +27,7 @@ public class Bry_fmtr { else keys.Clear(); int ary_len = ary.length; for (int i = 0; i < ary_len; i++) - keys.Add(Bry_obj_ref.new_(Bry_.new_u8(ary[i])), Int_obj_val.new_(i)); + keys.Add(Bry_obj_ref.New(Bry_.new_u8(ary[i])), Int_obj_val.new_(i)); dirty = true; return this; } Hash_adp keys = null; @@ -57,12 +57,12 @@ public class Bry_fmtr { bfr.Add(itm.Dat); } } - public void Bld_bfr(Bry_bfr bfr, Bry_fmtr_arg... args) { + public void Bld_bfr(Bry_bfr bfr, Bfr_arg... args) { if (dirty) Compile(); for (int i = 0; i < itms_len; i++) { Bry_fmtr_itm itm = itms[i]; if (itm.Arg) - args[itm.ArgIdx].Fmt__do(bfr); + args[itm.ArgIdx].Bfr_arg__add(bfr); else bfr.Add(itm.Dat); } @@ -137,7 +137,7 @@ public class Bry_fmtr { list.Add(Bry_fmtr_itm.arg_(lkp_bfr.To_int(0) - baseInt)); else { byte[] key_fmt = lkp_bfr.To_bry(); - Object idx_ref = keys.Get_by(Bry_obj_ref.new_(key_fmt)); + Object idx_ref = keys.Get_by(Bry_obj_ref.New(key_fmt)); if (idx_ref == null) { int lkp_bfr_len = lkp_bfr.Len(); byte[] lkp_bry = lkp_bfr.Bfr(); diff --git a/100_core/src_130_brys/gplx/Bry_fmtr_eval_mgr.java b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_eval_mgr.java similarity index 89% rename from 100_core/src_130_brys/gplx/Bry_fmtr_eval_mgr.java rename to 100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_eval_mgr.java index 83abe2873..a531534f8 100644 --- a/100_core/src_130_brys/gplx/Bry_fmtr_eval_mgr.java +++ b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_eval_mgr.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.brys.fmtrs; import gplx.*; import gplx.core.*; import gplx.core.brys.*; public interface Bry_fmtr_eval_mgr { boolean Enabled(); void Enabled_(boolean v); byte[] Eval(byte[] cmd); diff --git a/100_core/src_130_brys/gplx/Bry_fmtr_eval_mgr_.java b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_eval_mgr_.java similarity index 91% rename from 100_core/src_130_brys/gplx/Bry_fmtr_eval_mgr_.java rename to 100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_eval_mgr_.java index b88b5c386..830f1fb8c 100644 --- a/100_core/src_130_brys/gplx/Bry_fmtr_eval_mgr_.java +++ b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_eval_mgr_.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.brys.fmtrs; import gplx.*; import gplx.core.*; import gplx.core.brys.*; public class Bry_fmtr_eval_mgr_ { public static Io_url Eval_url(Bry_fmtr_eval_mgr eval_mgr, byte[] fmt) { if (eval_mgr == null) return Io_url_.new_any_(String_.new_u8(fmt)); diff --git a/100_core/src_130_brys/gplx/Bry_fmtr_eval_mgr_gfs.java b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_eval_mgr_gfs.java similarity index 90% rename from 100_core/src_130_brys/gplx/Bry_fmtr_eval_mgr_gfs.java rename to 100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_eval_mgr_gfs.java index 78320d9c1..a81514b57 100644 --- a/100_core/src_130_brys/gplx/Bry_fmtr_eval_mgr_gfs.java +++ b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_eval_mgr_gfs.java @@ -15,7 +15,8 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.brys.fmtrs; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +import gplx.langs.gfs.*; public class Bry_fmtr_eval_mgr_gfs implements Bry_fmtr_eval_mgr { public boolean Enabled() {return enabled;} public void Enabled_(boolean v) {enabled = v;} private boolean enabled; public byte[] Eval(byte[] cmd) { diff --git a/100_core/src_130_brys/gplx/Bry_fmtr_itm.java b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_itm.java similarity index 92% rename from 100_core/src_130_brys/gplx/Bry_fmtr_itm.java rename to 100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_itm.java index 4cbeacdda..14366ba76 100644 --- a/100_core/src_130_brys/gplx/Bry_fmtr_itm.java +++ b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_itm.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.brys.fmtrs; import gplx.*; import gplx.core.*; import gplx.core.brys.*; public class Bry_fmtr_itm { public boolean Arg; public int ArgIdx; diff --git a/100_core/src_130_brys/gplx/Bry_fmtr_tst.java b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_tst.java similarity index 95% rename from 100_core/src_130_brys/gplx/Bry_fmtr_tst.java rename to 100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_tst.java index 8367a5d22..e04221dc1 100644 --- a/100_core/src_130_brys/gplx/Bry_fmtr_tst.java +++ b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_tst.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.brys.fmtrs; import gplx.*; import gplx.core.*; import gplx.core.brys.*; import org.junit.*; public class Bry_fmtr_tst { @Test public void Idx_text() {tst_Format("a", "a");} diff --git a/100_core/src_130_brys/gplx/Bry_fmtr_vals.java b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_vals.java similarity index 82% rename from 100_core/src_130_brys/gplx/Bry_fmtr_vals.java rename to 100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_vals.java index 927ece379..ac725b616 100644 --- a/100_core/src_130_brys/gplx/Bry_fmtr_vals.java +++ b/100_core/src/gplx/core/brys/fmtrs/Bry_fmtr_vals.java @@ -15,12 +15,13 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; -public class Bry_fmtr_vals implements Bry_fmtr_arg { +package gplx.core.brys.fmtrs; import gplx.*; import gplx.core.*; import gplx.core.brys.*; +import gplx.core.brys.*; +public class Bry_fmtr_vals extends gplx.core.brys.Bfr_arg_base { private final Bry_fmtr fmtr; private Object[] vals; Bry_fmtr_vals(Bry_fmtr fmtr) {this.fmtr = fmtr;} public Bry_fmtr_vals Vals_(Object... v) {this.vals = v; return this;} - public void Fmt__do(Bry_bfr bfr) { + @Override public void Bfr_arg__add(Bry_bfr bfr) { fmtr.Bld_bfr_ary(bfr, vals); } public static Bry_fmtr_vals new_fmt(String fmt, String... keys) { diff --git a/100_core/src_310_gfoNde/gplx/GfoFld.java b/100_core/src/gplx/core/gfo_ndes/GfoFld.java similarity index 93% rename from 100_core/src_310_gfoNde/gplx/GfoFld.java rename to 100_core/src/gplx/core/gfo_ndes/GfoFld.java index 0071d3772..afe2ee690 100644 --- a/100_core/src_310_gfoNde/gplx/GfoFld.java +++ b/100_core/src/gplx/core/gfo_ndes/GfoFld.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_ndes; import gplx.*; import gplx.core.*; public class GfoFld { public String Key() {return key;} private String key; public ClassXtn Type() {return type;} ClassXtn type; diff --git a/100_core/src_310_gfoNde/gplx/GfoFldList.java b/100_core/src/gplx/core/gfo_ndes/GfoFldList.java similarity index 92% rename from 100_core/src_310_gfoNde/gplx/GfoFldList.java rename to 100_core/src/gplx/core/gfo_ndes/GfoFldList.java index 5b66da7fe..0218c6f83 100644 --- a/100_core/src_310_gfoNde/gplx/GfoFldList.java +++ b/100_core/src/gplx/core/gfo_ndes/GfoFldList.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_ndes; import gplx.*; import gplx.core.*; public interface GfoFldList { int Count(); boolean Has(String key); diff --git a/100_core/src_310_gfoNde/gplx/GfoFldList_.java b/100_core/src/gplx/core/gfo_ndes/GfoFldList_.java similarity index 95% rename from 100_core/src_310_gfoNde/gplx/GfoFldList_.java rename to 100_core/src/gplx/core/gfo_ndes/GfoFldList_.java index 7dd762a2d..d15bc4ab9 100644 --- a/100_core/src_310_gfoNde/gplx/GfoFldList_.java +++ b/100_core/src/gplx/core/gfo_ndes/GfoFldList_.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_ndes; import gplx.*; import gplx.core.*; import gplx.core.strings.*; public class GfoFldList_ { public static final GfoFldList Null = new GfoFldList_null(); diff --git a/100_core/src_310_gfoNde/gplx/GfoNde.java b/100_core/src/gplx/core/gfo_ndes/GfoNde.java similarity index 96% rename from 100_core/src_310_gfoNde/gplx/GfoNde.java rename to 100_core/src/gplx/core/gfo_ndes/GfoNde.java index ab7cec34b..155fa48b1 100644 --- a/100_core/src_310_gfoNde/gplx/GfoNde.java +++ b/100_core/src/gplx/core/gfo_ndes/GfoNde.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_ndes; import gplx.*; import gplx.core.*; import gplx.core.strings.*; public class GfoNde implements GfoInvkAble { public GfoFldList Flds() {return flds;} GfoFldList flds; diff --git a/100_core/src_310_gfoNde/gplx/GfoNdeFxt.java b/100_core/src/gplx/core/gfo_ndes/GfoNdeFxt.java similarity index 95% rename from 100_core/src_310_gfoNde/gplx/GfoNdeFxt.java rename to 100_core/src/gplx/core/gfo_ndes/GfoNdeFxt.java index 159baf59c..542d486b4 100644 --- a/100_core/src_310_gfoNde/gplx/GfoNdeFxt.java +++ b/100_core/src/gplx/core/gfo_ndes/GfoNdeFxt.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_ndes; import gplx.*; import gplx.core.*; public class GfoNdeFxt { public GfoNde root_(GfoNde... subs) {return GfoNde_.root_(subs);} public GfoNde tbl_(String name, GfoNde... rows) {return GfoNde_.tbl_(name, GfoFldList_.Null, rows);} diff --git a/100_core/src_310_gfoNde/gplx/GfoNdeList.java b/100_core/src/gplx/core/gfo_ndes/GfoNdeList.java similarity index 92% rename from 100_core/src_310_gfoNde/gplx/GfoNdeList.java rename to 100_core/src/gplx/core/gfo_ndes/GfoNdeList.java index fd6b96a2e..320763097 100644 --- a/100_core/src_310_gfoNde/gplx/GfoNdeList.java +++ b/100_core/src/gplx/core/gfo_ndes/GfoNdeList.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_ndes; import gplx.*; import gplx.core.*; import gplx.lists.*; /*ComparerAble*/ public interface GfoNdeList { int Count(); diff --git a/100_core/src_310_gfoNde/gplx/GfoNdeList_.java b/100_core/src/gplx/core/gfo_ndes/GfoNdeList_.java similarity index 95% rename from 100_core/src_310_gfoNde/gplx/GfoNdeList_.java rename to 100_core/src/gplx/core/gfo_ndes/GfoNdeList_.java index 03bce5556..269b951f4 100644 --- a/100_core/src_310_gfoNde/gplx/GfoNdeList_.java +++ b/100_core/src/gplx/core/gfo_ndes/GfoNdeList_.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_ndes; import gplx.*; import gplx.core.*; import gplx.lists.*; /*ComparerAble*/ public class GfoNdeList_ { public static final GfoNdeList Null = new GfoNdeList_null(); diff --git a/100_core/src_310_gfoNde/gplx/GfoNde_.java b/100_core/src/gplx/core/gfo_ndes/GfoNde_.java similarity index 96% rename from 100_core/src_310_gfoNde/gplx/GfoNde_.java rename to 100_core/src/gplx/core/gfo_ndes/GfoNde_.java index cd2641a05..3118532ee 100644 --- a/100_core/src_310_gfoNde/gplx/GfoNde_.java +++ b/100_core/src/gplx/core/gfo_ndes/GfoNde_.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_ndes; import gplx.*; import gplx.core.*; public class GfoNde_ { public static final GfoNde[] Ary_empty = new GfoNde[0]; public static GfoNde[] ary_(GfoNde... ary) {return ary;} diff --git a/100_core/src_410_gfoCfg/gplx/GfoMsgParser.java b/100_core/src/gplx/core/gfo_regys/GfoMsgParser.java similarity index 92% rename from 100_core/src_410_gfoCfg/gplx/GfoMsgParser.java rename to 100_core/src/gplx/core/gfo_regys/GfoMsgParser.java index a149505f1..5e940cf5d 100644 --- a/100_core/src_410_gfoCfg/gplx/GfoMsgParser.java +++ b/100_core/src/gplx/core/gfo_regys/GfoMsgParser.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_regys; import gplx.*; import gplx.core.*; public interface GfoMsgParser { GfoMsg ParseToMsg(String s); } diff --git a/100_core/src_410_gfoCfg/gplx/GfoRegy.java b/100_core/src/gplx/core/gfo_regys/GfoRegy.java similarity index 96% rename from 100_core/src_410_gfoCfg/gplx/GfoRegy.java rename to 100_core/src/gplx/core/gfo_regys/GfoRegy.java index 49fbdc56d..260cb892f 100644 --- a/100_core/src_410_gfoCfg/gplx/GfoRegy.java +++ b/100_core/src/gplx/core/gfo_regys/GfoRegy.java @@ -15,7 +15,8 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_regys; import gplx.*; import gplx.core.*; +import gplx.langs.gfs.*; public class GfoRegy implements GfoInvkAble { public int Count() {return hash.Count();} public Hash_adp Parsers() {return parsers;} Hash_adp parsers = Hash_adp_.new_(); diff --git a/100_core/src_410_gfoCfg/gplx/GfoRegyItm.java b/100_core/src/gplx/core/gfo_regys/GfoRegyItm.java similarity index 93% rename from 100_core/src_410_gfoCfg/gplx/GfoRegyItm.java rename to 100_core/src/gplx/core/gfo_regys/GfoRegyItm.java index afada9f7c..aeb235994 100644 --- a/100_core/src_410_gfoCfg/gplx/GfoRegyItm.java +++ b/100_core/src/gplx/core/gfo_regys/GfoRegyItm.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_regys; import gplx.*; import gplx.core.*; public class GfoRegyItm { public String Key() {return key;} private String key; public Object Val() {return val;} Object val; diff --git a/100_core/src_410_gfoCfg/gplx/GfoRegy_RegDir_tst.java b/100_core/src/gplx/core/gfo_regys/GfoRegy_RegDir_tst.java similarity index 95% rename from 100_core/src_410_gfoCfg/gplx/GfoRegy_RegDir_tst.java rename to 100_core/src/gplx/core/gfo_regys/GfoRegy_RegDir_tst.java index ca1d7054b..155c9e914 100644 --- a/100_core/src_410_gfoCfg/gplx/GfoRegy_RegDir_tst.java +++ b/100_core/src/gplx/core/gfo_regys/GfoRegy_RegDir_tst.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_regys; import gplx.*; import gplx.core.*; import org.junit.*; public class GfoRegy_RegDir_tst { @Before public void setup() { diff --git a/100_core/src_410_gfoCfg/gplx/GfoRegy_basic_tst.java b/100_core/src/gplx/core/gfo_regys/GfoRegy_basic_tst.java similarity index 93% rename from 100_core/src_410_gfoCfg/gplx/GfoRegy_basic_tst.java rename to 100_core/src/gplx/core/gfo_regys/GfoRegy_basic_tst.java index b28c0c0c9..5dd32d923 100644 --- a/100_core/src_410_gfoCfg/gplx/GfoRegy_basic_tst.java +++ b/100_core/src/gplx/core/gfo_regys/GfoRegy_basic_tst.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.core.gfo_regys; import gplx.*; import gplx.core.*; import org.junit.*; public class GfoRegy_basic_tst { @Before public void setup() { diff --git a/100_core/src/gplx/core/ios/IoEngine_xrg_downloadFil.java b/100_core/src/gplx/core/ios/IoEngine_xrg_downloadFil.java index 8a9ab7388..5eecfa406 100644 --- a/100_core/src/gplx/core/ios/IoEngine_xrg_downloadFil.java +++ b/100_core/src/gplx/core/ios/IoEngine_xrg_downloadFil.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.ios; import gplx.*; import gplx.core.*; +import gplx.core.brys.fmtrs.*; public class IoEngine_xrg_downloadFil { public String Src() {return src;} public IoEngine_xrg_downloadFil Src_(String v) {src = v; return this;} private String src; public Io_url Trg() {return trg;} public IoEngine_xrg_downloadFil Trg_(Io_url v) {trg = v; return this;} private Io_url trg; diff --git a/100_core/src/gplx/core/ios/IoItmFil.java b/100_core/src/gplx/core/ios/IoItmFil.java index cd291c822..74a53cb76 100644 --- a/100_core/src/gplx/core/ios/IoItmFil.java +++ b/100_core/src/gplx/core/ios/IoItmFil.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.ios; import gplx.*; import gplx.core.*; +import gplx.langs.gfs.*; public class IoItmFil extends IoItm_base { @Override public int TypeId() {return IoItmFil.Type_Fil;} @Override public boolean Type_dir() {return false;} @Override public boolean Type_fil() {return true;} public static final int Type_Fil = 2; public boolean Exists() {return size != Size_invalid;} // NOTE: questionable logic, but preserved for historical reasons; requires that length be set to -1 if !.exists diff --git a/100_core/src/gplx/core/ios/IoItm_base.java b/100_core/src/gplx/core/ios/IoItm_base.java index a95c1072b..94d5079f9 100644 --- a/100_core/src/gplx/core/ios/IoItm_base.java +++ b/100_core/src/gplx/core/ios/IoItm_base.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.ios; import gplx.*; import gplx.core.*; +import gplx.langs.gfs.*; public abstract class IoItm_base implements GfoInvkAble, CompareAble { public abstract int TypeId(); public abstract boolean Type_dir(); public abstract boolean Type_fil(); public Io_url Url() {return ownerDir == null ? url : ownerDir.Url().GenSubFil(name); /*NOTE: must call .Url*/} Io_url url; diff --git a/100_core/src/gplx/core/ios/IoUrlInfoRegy.java b/100_core/src/gplx/core/ios/IoUrlInfoRegy.java index a54821cab..a9787951e 100644 --- a/100_core/src/gplx/core/ios/IoUrlInfoRegy.java +++ b/100_core/src/gplx/core/ios/IoUrlInfoRegy.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.ios; import gplx.*; import gplx.core.*; +import gplx.langs.gfs.*; public class IoUrlInfoRegy implements GfoInvkAble { public void Reg(IoUrlInfo info) {hash.Add_if_dupe_use_nth(info.Key(), info);} public IoUrlInfo Match(String raw) { diff --git a/100_core/src/gplx/core/ios/IoUrlTypeRegy.java b/100_core/src/gplx/core/ios/IoUrlTypeRegy.java index ccf6cb4cc..1852de81c 100644 --- a/100_core/src/gplx/core/ios/IoUrlTypeRegy.java +++ b/100_core/src/gplx/core/ios/IoUrlTypeRegy.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.ios; import gplx.*; import gplx.core.*; -import gplx.core.strings.*; +import gplx.core.strings.*; import gplx.langs.gfs.*; public class IoUrlTypeRegy implements GfoInvkAble { public String[] FetchAryOr(String key, String... or) { IoUrlTypeGrp itm = (IoUrlTypeGrp)hash.Get_by(key); diff --git a/100_core/src/gplx/core/ios/IoZipWkr.java b/100_core/src/gplx/core/ios/IoZipWkr.java index 37f66feb9..0ee5062d6 100644 --- a/100_core/src/gplx/core/ios/IoZipWkr.java +++ b/100_core/src/gplx/core/ios/IoZipWkr.java @@ -17,6 +17,7 @@ along with this program. If not, see . */ package gplx.core.ios; import gplx.*; import gplx.core.*; import gplx.stores.*; /*GfoNdeRdr_*/ +import gplx.core.gfo_regys.*; public class IoZipWkr { public Io_url ExeUrl() {return (Io_url)GfoRegy.Instance.FetchValOrFail(Regy_ExeUrl);} public String ExeArgFmt() {return (String)GfoRegy.Instance.FetchValOrFail(Regy_ExeArgFmt);} diff --git a/100_core/src/gplx/core/ios/Io_download_fmt.java b/100_core/src/gplx/core/ios/Io_download_fmt.java index 4c3f23c80..d0bd2487a 100644 --- a/100_core/src/gplx/core/ios/Io_download_fmt.java +++ b/100_core/src/gplx/core/ios/Io_download_fmt.java @@ -16,10 +16,10 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.ios; import gplx.*; import gplx.core.*; -import gplx.brys.*; +import gplx.core.brys.args.*; import gplx.core.brys.fmtrs.*; public class Io_download_fmt { private final Io_size_fmtr_arg size_fmtr_arg = new Io_size_fmtr_arg(), rate_fmtr_arg = new Io_size_fmtr_arg().Suffix_(Bry_.new_a7("ps")); - private final Bry_fmtr_arg_time prog_left_fmtr_arg = new Bry_fmtr_arg_time(); private final Bry_fmtr_arg_decimal_int prog_pct_fmtr_arg = new Bry_fmtr_arg_decimal_int().Places_(2); + private final Bfr_arg__time prog_left_fmtr_arg = new Bfr_arg__time(); private final Bfr_arg__decimal_int prog_pct_fmtr_arg = new Bfr_arg__decimal_int().Places_(2); private long time_checkpoint_interval = 250; private long time_checkpoint = 0; private long time_prv = 0; diff --git a/100_core/src/gplx/core/ios/Io_size_.java b/100_core/src/gplx/core/ios/Io_size_.java index f1bd4e0d4..cf90d4839 100644 --- a/100_core/src/gplx/core/ios/Io_size_.java +++ b/100_core/src/gplx/core/ios/Io_size_.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.ios; import gplx.*; import gplx.core.*; +import gplx.core.brys.*; public class Io_size_ { public static String To_str(long val) { long cur = val; int pow = 0; @@ -98,10 +99,10 @@ public class Io_size_ { return val == Int_.Min_value ? cur : (val * Io_mgr.Len_mb_long); } } -class Io_size_fmtr_arg implements Bry_fmtr_arg { +class Io_size_fmtr_arg extends gplx.core.brys.Bfr_arg_base { public long Val() {return val;} public Io_size_fmtr_arg Val_(long v) {val = v; return this;} long val; public byte[] Suffix() {return suffix;} public Io_size_fmtr_arg Suffix_(byte[] v) {suffix = v; return this;} private byte[] suffix; - public void Fmt__do(Bry_bfr bfr) { + @Override public void Bfr_arg__add(Bry_bfr bfr) { long cur = val; int pow = 0; while (cur >= 1024) { cur /= 1024; diff --git a/100_core/src/gplx/core/log_msgs/Gfo_msg_itm.java b/100_core/src/gplx/core/log_msgs/Gfo_msg_itm.java index 8827a7bf0..e6b09da73 100644 --- a/100_core/src/gplx/core/log_msgs/Gfo_msg_itm.java +++ b/100_core/src/gplx/core/log_msgs/Gfo_msg_itm.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.log_msgs; import gplx.*; import gplx.core.*; +import gplx.core.brys.fmtrs.*; public class Gfo_msg_itm implements Gfo_msg_obj { public Gfo_msg_itm(Gfo_msg_grp owner, int uid, byte cmd, byte[] key_bry, byte[] fmt, boolean add_to_owner) { this.owner = owner; this.uid = uid; this.cmd = cmd; this.key_bry = key_bry; this.fmt = fmt; diff --git a/100_core/src/gplx/core/primitives/Bry_obj_ref.java b/100_core/src/gplx/core/primitives/Bry_obj_ref.java index 7ada3a493..b4f53bb07 100644 --- a/100_core/src/gplx/core/primitives/Bry_obj_ref.java +++ b/100_core/src/gplx/core/primitives/Bry_obj_ref.java @@ -16,20 +16,31 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.primitives; import gplx.*; import gplx.core.*; -public class Bry_obj_ref { - public byte[] Val() {return val;} public Bry_obj_ref Val_(byte[] v) {val = v; return this;} private byte[] val; - @Override public int hashCode() {return CalcHashCode(val, 0, val.length);} - @Override public boolean equals(Object obj) {return obj == null ? false : Bry_.Eq(val, ((Bry_obj_ref)obj).Val());} // NOTE: strange, but null check needed; throws null error; EX.WP: File:Eug�ne Delacroix - La libert� guidant le peuple.jpg +import gplx.core.brys.*; +public class Bry_obj_ref implements gplx.core.brys.Bfr_arg { + public byte[] Val() {return val;} private byte[] val; + public int Val_bgn() {return val_bgn;} private int val_bgn; + public int Val_end() {return val_end;} private int val_end; + public Bry_obj_ref Val_(byte[] val) {this.val = val; this.val_bgn = 0; this.val_end = val.length; return this;} + public Bry_obj_ref Mid_(byte[] val, int val_bgn, int val_end) {this.val = val; this.val_bgn = val_bgn; this.val_end = val_end; return this;} + @Override public int hashCode() {return CalcHashCode(val, val_bgn, val_end);} + @Override public boolean equals(Object obj) { + if (obj == null) return false; // NOTE: strange, but null check needed; throws null error; EX.WP: File:Eug�ne Delacroix - La libert� guidant le peuple.jpg + Bry_obj_ref comp = (Bry_obj_ref)obj; + return Bry_.Match(val, val_bgn, val_end, comp.val, comp.val_bgn, comp.val_end); + } + public void Bfr_arg__clear() {val = null;} + public boolean Bfr_arg__exists() {return val != null && val_end > val_bgn;} + public void Bfr_arg__add(Bry_bfr bfr) { + if (Bfr_arg__exists()) + bfr.Add_mid(val, val_bgn, val_end); + } public static int CalcHashCode(byte[] ary, int bgn, int end) { int rv = 0; for (int i = bgn; i < end; i++) rv = (31 * rv) + ary[i]; return rv; } - public static Bry_obj_ref null_() {return new_(null);} - public static Bry_obj_ref new_(byte[] val) { - Bry_obj_ref rv = new Bry_obj_ref(); - rv.val = val; - return rv; - } private Bry_obj_ref() {} + public static Bry_obj_ref New_empty() {return New(Bry_.Empty);} + public static Bry_obj_ref New(byte[] val) {return new Bry_obj_ref().Val_(val);} } diff --git a/100_core/src/gplx/langs/dsvs/DsvDataRdrOpts.java b/100_core/src/gplx/langs/dsvs/DsvDataRdrOpts.java index df8660f3f..635eaeb79 100644 --- a/100_core/src/gplx/langs/dsvs/DsvDataRdrOpts.java +++ b/100_core/src/gplx/langs/dsvs/DsvDataRdrOpts.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.dsvs; import gplx.*; import gplx.langs.*; +import gplx.core.gfo_ndes.*; public class DsvDataRdrOpts { public boolean HasHeader() {return hasHeader;} public DsvDataRdrOpts HasHeader_(boolean val) {hasHeader = val; return this;} private boolean hasHeader = false; public String NewLineSep() {return newLineSep;} public DsvDataRdrOpts NewLineSep_(String val) {newLineSep = val; return this;} private String newLineSep = String_.CrLf; diff --git a/100_core/src/gplx/langs/dsvs/DsvDataRdr_.java b/100_core/src/gplx/langs/dsvs/DsvDataRdr_.java index bbae049e8..5f591d0ec 100644 --- a/100_core/src/gplx/langs/dsvs/DsvDataRdr_.java +++ b/100_core/src/gplx/langs/dsvs/DsvDataRdr_.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.dsvs; import gplx.*; import gplx.langs.*; -import gplx.core.strings.*; import gplx.stores.*; +import gplx.core.strings.*; import gplx.core.gfo_ndes.*; import gplx.stores.*; import gplx.core.texts.*; /*CharStream*/ public class DsvDataRdr_ { public static DataRdr dsv_(String text) {return DsvParser.dsv_().ParseAsRdr(text);} diff --git a/100_core/src/gplx/langs/dsvs/DsvDataRdr_csv_dat_tst.java b/100_core/src/gplx/langs/dsvs/DsvDataRdr_csv_dat_tst.java index 4abe242cb..30fc7bc65 100644 --- a/100_core/src/gplx/langs/dsvs/DsvDataRdr_csv_dat_tst.java +++ b/100_core/src/gplx/langs/dsvs/DsvDataRdr_csv_dat_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.dsvs; import gplx.*; import gplx.langs.*; -import org.junit.*; import gplx.core.strings.*; +import org.junit.*; import gplx.core.strings.*; import gplx.core.gfo_ndes.*; public class DsvDataRdr_csv_dat_tst { @Before public void setup() { fx.Parser_(DsvParser.csv_(false, GfoFldList_.Null)); diff --git a/100_core/src/gplx/langs/dsvs/DsvDataRdr_dsv_hdr_tst.java b/100_core/src/gplx/langs/dsvs/DsvDataRdr_dsv_hdr_tst.java index ee159c54c..26c94ce77 100644 --- a/100_core/src/gplx/langs/dsvs/DsvDataRdr_dsv_hdr_tst.java +++ b/100_core/src/gplx/langs/dsvs/DsvDataRdr_dsv_hdr_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.dsvs; import gplx.*; import gplx.langs.*; -import org.junit.*; +import org.junit.*; import gplx.core.gfo_ndes.*; public class DsvDataRdr_dsv_hdr_tst { @Before public void setup() {fx.Clear();} DsvDataRdr_fxt fx = DsvDataRdr_fxt.new_(); @Test public void Names() { diff --git a/100_core/src/gplx/langs/dsvs/DsvDataRdr_dsv_misc_tst.java b/100_core/src/gplx/langs/dsvs/DsvDataRdr_dsv_misc_tst.java index 890eb0873..b4a90ec04 100644 --- a/100_core/src/gplx/langs/dsvs/DsvDataRdr_dsv_misc_tst.java +++ b/100_core/src/gplx/langs/dsvs/DsvDataRdr_dsv_misc_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.dsvs; import gplx.*; import gplx.langs.*; -import org.junit.*; +import org.junit.*; import gplx.core.gfo_ndes.*; public class DsvDataRdr_dsv_misc_tst { @Before public void setup() {fx.Clear();} DsvDataRdr_fxt fx = DsvDataRdr_fxt.new_(); @Test public void CmdDlm_NearMatches() { diff --git a/100_core/src/gplx/langs/dsvs/DsvDataRdr_layout_tst.java b/100_core/src/gplx/langs/dsvs/DsvDataRdr_layout_tst.java index b2b5ed63c..5d8e50a80 100644 --- a/100_core/src/gplx/langs/dsvs/DsvDataRdr_layout_tst.java +++ b/100_core/src/gplx/langs/dsvs/DsvDataRdr_layout_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.dsvs; import gplx.*; import gplx.langs.*; -import org.junit.*; +import org.junit.*; import gplx.core.gfo_ndes.*; public class DsvDataRdr_layout_tst { @Test public void TableName() { run_parse_lines("table0, ,\" \",#"); diff --git a/100_core/src/gplx/langs/dsvs/DsvDataWtr.java b/100_core/src/gplx/langs/dsvs/DsvDataWtr.java index 4f815a3e9..41a228a74 100644 --- a/100_core/src/gplx/langs/dsvs/DsvDataWtr.java +++ b/100_core/src/gplx/langs/dsvs/DsvDataWtr.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.dsvs; import gplx.*; import gplx.langs.*; -import gplx.core.strings.*; +import gplx.core.strings.*; import gplx.core.gfo_ndes.*; public class DsvDataWtr extends DataWtr_base implements DataWtr { public void InitWtr(String key, Object val) { if (key == DsvStoreLayout.Key_const) layout = (DsvStoreLayout)val; diff --git a/100_core/src/gplx/langs/dsvs/DsvDataWtr_csv_tst.java b/100_core/src/gplx/langs/dsvs/DsvDataWtr_csv_tst.java index 4612ee827..ebc14d024 100644 --- a/100_core/src/gplx/langs/dsvs/DsvDataWtr_csv_tst.java +++ b/100_core/src/gplx/langs/dsvs/DsvDataWtr_csv_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.dsvs; import gplx.*; import gplx.langs.*; -import org.junit.*; +import org.junit.*; import gplx.core.gfo_ndes.*; public class DsvDataWtr_csv_tst { @Test public void Dat_Val_0() { root = fx_nde.csv_dat_(); this.AddCsvRow(root); diff --git a/100_core/src/gplx/langs/dsvs/DsvDataWtr_tbls_tst.java b/100_core/src/gplx/langs/dsvs/DsvDataWtr_tbls_tst.java index 4adbaec36..302028273 100644 --- a/100_core/src/gplx/langs/dsvs/DsvDataWtr_tbls_tst.java +++ b/100_core/src/gplx/langs/dsvs/DsvDataWtr_tbls_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.dsvs; import gplx.*; import gplx.langs.*; -import org.junit.*; +import org.junit.*; import gplx.core.gfo_ndes.*; public class DsvDataWtr_tbls_tst { @Before public void setup() { DsvStoreLayout layout = DsvStoreLayout.dsv_brief_(); diff --git a/100_core/src/gplx/langs/gfs/GfsCore.java b/100_core/src/gplx/langs/gfs/GfsCore.java new file mode 100644 index 000000000..88cfbe461 --- /dev/null +++ b/100_core/src/gplx/langs/gfs/GfsCore.java @@ -0,0 +1,90 @@ +/* +XOWA: the XOWA Offline Wiki Application +Copyright (C) 2012 gnosygnu@gmail.com + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as +published by the Free Software Foundation, either version 3 of the +License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see . +*/ +package gplx.langs.gfs; import gplx.*; import gplx.langs.*; +import gplx.core.gfo_regys.*; +public class GfsCore implements GfoInvkAble { + public GfoInvkAble Root() {return root;} + @gplx.Internal protected GfsRegy Root_as_regy() {return root;} GfsRegy root = GfsRegy.new_(); + public void Clear() {root.Clear();} + public GfoMsgParser MsgParser() {return msgParser;} public GfsCore MsgParser_(GfoMsgParser v) {msgParser = v; return this;} GfoMsgParser msgParser; + public void Del(String key) {root.Del(key);} + public void AddLib(GfsLibIni... ary) {for (GfsLibIni itm : ary) itm.Ini(this);} + public void AddCmd(GfoInvkAble invk, String key) {root.AddCmd(invk, key);} + public void AddObj(GfoInvkAble invk, String key) {root.AddObj(invk, key);} + public void AddDeep(GfoInvkAble invk, String... ary) { + GfoInvkCmdMgrOwner cur = (GfoInvkCmdMgrOwner)((GfsRegyItm)root.Get_by(ary[0])).InvkAble(); + for (int i = 1; i < ary.length - 1; i++) + cur = (GfoInvkCmdMgrOwner)cur.InvkMgr().Invk(GfsCtx.Instance, 0, ary[i], GfoMsg_.Null, cur); + cur.InvkMgr().Add_cmd(ary[ary.length - 1], invk); + } + public String FetchKey(GfoInvkAble invk) {return root.FetchByType(invk).Key();} + public Object ExecOne(GfsCtx ctx, GfoMsg msg) {return GfsCore_.Exec(ctx, root, msg, null, 0);} + public Object ExecOne_to(GfsCtx ctx, GfoInvkAble invk, GfoMsg msg) {return GfsCore_.Exec(ctx, invk, msg, null, 0);} + public Object ExecMany(GfsCtx ctx, GfoMsg rootMsg) { + Object rv = null; + for (int i = 0; i < rootMsg.Subs_count(); i++) { + GfoMsg subMsg = (GfoMsg)rootMsg.Subs_getAt(i); + rv = GfsCore_.Exec(ctx, root, subMsg, null, 0); + } + return rv; + } + public void ExecRegy(String key) { + GfoRegyItm itm = GfoRegy.Instance.FetchOrNull(key); + if (itm == null) {UsrDlg_.Instance.Warn(UsrMsg.new_("could not find script for key").Add("key", key)); return;} + Io_url url = itm.Url(); + if (!Io_mgr.Instance.ExistsFil(url)) { + UsrDlg_.Instance.Warn(UsrMsg.new_("script url does not exist").Add("key", key).Add("url", url)); + return; + } + this.ExecText(Io_mgr.Instance.LoadFilStr(url)); + } + public Object ExecFile_ignoreMissing(Io_url url) {if (!Io_mgr.Instance.ExistsFil(url)) return null; return ExecText(Io_mgr.Instance.LoadFilStr(url));} + public Object ExecFile(Io_url url) {return ExecText(Io_mgr.Instance.LoadFilStr(url));} + public Object ExecFile_ignoreMissing(GfoInvkAble root, Io_url url) { + if (!Io_mgr.Instance.ExistsFil(url)) return null; + if (msgParser == null) throw Err_.new_wo_type("msgParser is null"); + return Exec_bry(Io_mgr.Instance.LoadFilBry(url), root); + } + public Object Exec_bry(byte[] bry) {return Exec_bry(bry, root);} + public Object Exec_bry(byte[] bry, GfoInvkAble root) { + GfoMsg rootMsg = msgParser.ParseToMsg(String_.new_u8(bry)); + Object rv = null; + GfsCtx ctx = GfsCtx.new_(); + for (int i = 0; i < rootMsg.Subs_count(); i++) { + GfoMsg subMsg = (GfoMsg)rootMsg.Subs_getAt(i); + rv = GfsCore_.Exec(ctx, root, subMsg, null, 0); + } + return rv; + } + public Object ExecText(String text) { + if (msgParser == null) throw Err_.new_wo_type("msgParser is null"); + GfsCtx ctx = GfsCtx.new_(); + return ExecMany(ctx, msgParser.ParseToMsg(text)); + } + public Object Invk(GfsCtx ctx, int ikey, String k, GfoMsg m) { + if (ctx.Match(k, Invk_ExecFil)) { + Io_url url = m.ReadIoUrl("url"); + if (ctx.Deny()) return this; + return ExecFile(url); + } + else return GfoInvkAble_.Rv_unhandled; +// return this; + } public static final String Invk_ExecFil = "ExecFil"; + public static final GfsCore Instance = new GfsCore(); + @gplx.Internal protected static GfsCore new_() {return new GfsCore();} +} diff --git a/100_core/src_400_gfs/gplx/GfsCoreHelp.java b/100_core/src/gplx/langs/gfs/GfsCoreHelp.java similarity index 96% rename from 100_core/src_400_gfs/gplx/GfsCoreHelp.java rename to 100_core/src/gplx/langs/gfs/GfsCoreHelp.java index 386b7ef2a..b75a63d8e 100644 --- a/100_core/src_400_gfs/gplx/GfsCoreHelp.java +++ b/100_core/src/gplx/langs/gfs/GfsCoreHelp.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.langs.gfs; import gplx.*; import gplx.langs.*; import gplx.core.strings.*; class GfsCoreHelp implements GfoInvkAble { public Object Invk(GfsCtx ctx, int ikey, String k, GfoMsg m) { diff --git a/100_core/src_400_gfs/gplx/GfsCore.java b/100_core/src/gplx/langs/gfs/GfsCore_.java similarity index 54% rename from 100_core/src_400_gfs/gplx/GfsCore.java rename to 100_core/src/gplx/langs/gfs/GfsCore_.java index 76396278f..f90ba1e9b 100644 --- a/100_core/src_400_gfs/gplx/GfsCore.java +++ b/100_core/src/gplx/langs/gfs/GfsCore_.java @@ -15,79 +15,8 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; -public class GfsCore implements GfoInvkAble { - public GfoInvkAble Root() {return root;} - @gplx.Internal protected GfsRegy Root_as_regy() {return root;} GfsRegy root = GfsRegy.new_(); - public void Clear() {root.Clear();} - public GfoMsgParser MsgParser() {return msgParser;} public GfsCore MsgParser_(GfoMsgParser v) {msgParser = v; return this;} GfoMsgParser msgParser; - public void Del(String key) {root.Del(key);} - public void AddLib(GfsLibIni... ary) {for (GfsLibIni itm : ary) itm.Ini(this);} - public void AddCmd(GfoInvkAble invk, String key) {root.AddCmd(invk, key);} - public void AddObj(GfoInvkAble invk, String key) {root.AddObj(invk, key);} - public void AddDeep(GfoInvkAble invk, String... ary) { - GfoInvkCmdMgrOwner cur = (GfoInvkCmdMgrOwner)((GfsRegyItm)root.Get_by(ary[0])).InvkAble(); - for (int i = 1; i < ary.length - 1; i++) - cur = (GfoInvkCmdMgrOwner)cur.InvkMgr().Invk(GfsCtx.Instance, 0, ary[i], GfoMsg_.Null, cur); - cur.InvkMgr().Add_cmd(ary[ary.length - 1], invk); - } - public String FetchKey(GfoInvkAble invk) {return root.FetchByType(invk).Key();} - public Object ExecOne(GfsCtx ctx, GfoMsg msg) {return GfsCore_.Exec(ctx, root, msg, null, 0);} - public Object ExecOne_to(GfsCtx ctx, GfoInvkAble invk, GfoMsg msg) {return GfsCore_.Exec(ctx, invk, msg, null, 0);} - public Object ExecMany(GfsCtx ctx, GfoMsg rootMsg) { - Object rv = null; - for (int i = 0; i < rootMsg.Subs_count(); i++) { - GfoMsg subMsg = (GfoMsg)rootMsg.Subs_getAt(i); - rv = GfsCore_.Exec(ctx, root, subMsg, null, 0); - } - return rv; - } - public void ExecRegy(String key) { - GfoRegyItm itm = GfoRegy.Instance.FetchOrNull(key); - if (itm == null) {UsrDlg_.Instance.Warn(UsrMsg.new_("could not find script for key").Add("key", key)); return;} - Io_url url = itm.Url(); - if (!Io_mgr.Instance.ExistsFil(url)) { - UsrDlg_.Instance.Warn(UsrMsg.new_("script url does not exist").Add("key", key).Add("url", url)); - return; - } - this.ExecText(Io_mgr.Instance.LoadFilStr(url)); - } - public Object ExecFile_ignoreMissing(Io_url url) {if (!Io_mgr.Instance.ExistsFil(url)) return null; return ExecText(Io_mgr.Instance.LoadFilStr(url));} - public Object ExecFile(Io_url url) {return ExecText(Io_mgr.Instance.LoadFilStr(url));} - public Object ExecFile_ignoreMissing(GfoInvkAble root, Io_url url) { - if (!Io_mgr.Instance.ExistsFil(url)) return null; - if (msgParser == null) throw Err_.new_wo_type("msgParser is null"); - return Exec_bry(Io_mgr.Instance.LoadFilBry(url), root); - } - public Object Exec_bry(byte[] bry) {return Exec_bry(bry, root);} - public Object Exec_bry(byte[] bry, GfoInvkAble root) { - GfoMsg rootMsg = msgParser.ParseToMsg(String_.new_u8(bry)); - Object rv = null; - GfsCtx ctx = GfsCtx.new_(); - for (int i = 0; i < rootMsg.Subs_count(); i++) { - GfoMsg subMsg = (GfoMsg)rootMsg.Subs_getAt(i); - rv = GfsCore_.Exec(ctx, root, subMsg, null, 0); - } - return rv; - } - public Object ExecText(String text) { - if (msgParser == null) throw Err_.new_wo_type("msgParser is null"); - GfsCtx ctx = GfsCtx.new_(); - return ExecMany(ctx, msgParser.ParseToMsg(text)); - } - public Object Invk(GfsCtx ctx, int ikey, String k, GfoMsg m) { - if (ctx.Match(k, Invk_ExecFil)) { - Io_url url = m.ReadIoUrl("url"); - if (ctx.Deny()) return this; - return ExecFile(url); - } - else return GfoInvkAble_.Rv_unhandled; -// return this; - } public static final String Invk_ExecFil = "ExecFil"; - public static final GfsCore Instance = new GfsCore(); - @gplx.Internal protected static GfsCore new_() {return new GfsCore();} -} -class GfsCore_ { +package gplx.langs.gfs; import gplx.*; import gplx.langs.*; +public class GfsCore_ { public static final String Arg_primitive = "v"; public static Object Exec(GfsCtx ctx, GfoInvkAble owner_invk, GfoMsg owner_msg, Object owner_primitive, int depth) { if (owner_msg.Args_count() == 0 && owner_msg.Subs_count() == 0 && String_.Eq(owner_msg.Key(), "")) {UsrDlg_.Instance.Warn("empty msg"); return GfoInvkAble_.Rv_unhandled;} diff --git a/100_core/src_400_gfs/gplx/GfsCore_tst.java b/100_core/src/gplx/langs/gfs/GfsCore_tst.java similarity index 96% rename from 100_core/src_400_gfs/gplx/GfsCore_tst.java rename to 100_core/src/gplx/langs/gfs/GfsCore_tst.java index 158f265d7..f8a9ef8f2 100644 --- a/100_core/src_400_gfs/gplx/GfsCore_tst.java +++ b/100_core/src/gplx/langs/gfs/GfsCore_tst.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.langs.gfs; import gplx.*; import gplx.langs.*; import org.junit.*; public class GfsCore_tst { @Before public void setup() { diff --git a/100_core/src_400_gfs/gplx/GfsLibIni.java b/100_core/src/gplx/langs/gfs/GfsLibIni.java similarity index 92% rename from 100_core/src_400_gfs/gplx/GfsLibIni.java rename to 100_core/src/gplx/langs/gfs/GfsLibIni.java index da359de29..82ea544e9 100644 --- a/100_core/src_400_gfs/gplx/GfsLibIni.java +++ b/100_core/src/gplx/langs/gfs/GfsLibIni.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.langs.gfs; import gplx.*; import gplx.langs.*; public interface GfsLibIni { void Ini(GfsCore core); } diff --git a/100_core/src_400_gfs/gplx/GfsLibIni_core.java b/100_core/src/gplx/langs/gfs/GfsLibIni_core.java similarity index 93% rename from 100_core/src_400_gfs/gplx/GfsLibIni_core.java rename to 100_core/src/gplx/langs/gfs/GfsLibIni_core.java index 2716a6a70..d1c5a9f2f 100644 --- a/100_core/src_400_gfs/gplx/GfsLibIni_core.java +++ b/100_core/src/gplx/langs/gfs/GfsLibIni_core.java @@ -15,7 +15,8 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.langs.gfs; import gplx.*; import gplx.langs.*; +import gplx.core.gfo_regys.*; public class GfsLibIni_core implements GfsLibIni { public void Ini(GfsCore core) { core.AddCmd(GfsCoreHelp.new_(core), "help"); diff --git a/100_core/src_400_gfs/gplx/GfsRegy.java b/100_core/src/gplx/langs/gfs/GfsRegy.java similarity index 96% rename from 100_core/src_400_gfs/gplx/GfsRegy.java rename to 100_core/src/gplx/langs/gfs/GfsRegy.java index 71acd80b8..ea016e4bf 100644 --- a/100_core/src_400_gfs/gplx/GfsRegy.java +++ b/100_core/src/gplx/langs/gfs/GfsRegy.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.langs.gfs; import gplx.*; import gplx.langs.*; class GfsRegy implements GfoInvkAble { public int Count() {return hash.Count();} public void Clear() {hash.Clear(); typeHash.Clear();} diff --git a/100_core/src_400_gfs/gplx/GfsTypeNames.java b/100_core/src/gplx/langs/gfs/GfsTypeNames.java similarity index 92% rename from 100_core/src_400_gfs/gplx/GfsTypeNames.java rename to 100_core/src/gplx/langs/gfs/GfsTypeNames.java index 70c581f50..4581f4ecd 100644 --- a/100_core/src_400_gfs/gplx/GfsTypeNames.java +++ b/100_core/src/gplx/langs/gfs/GfsTypeNames.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.langs.gfs; import gplx.*; import gplx.langs.*; public class GfsTypeNames { public static final String String = "string" diff --git a/100_core/src_400_gfs/gplx/Gfs_Date_tst.java b/100_core/src/gplx/langs/gfs/Gfs_Date_tst.java similarity index 95% rename from 100_core/src_400_gfs/gplx/Gfs_Date_tst.java rename to 100_core/src/gplx/langs/gfs/Gfs_Date_tst.java index d98177f83..49538c93f 100644 --- a/100_core/src_400_gfs/gplx/Gfs_Date_tst.java +++ b/100_core/src/gplx/langs/gfs/Gfs_Date_tst.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; +package gplx.langs.gfs; import gplx.*; import gplx.langs.*; import org.junit.*; public class Gfs_Date_tst { @Before public void setup() { diff --git a/100_core/src_101_types_object/gplx/String_.java b/100_core/src_101_types_object/gplx/String_.java index 7a658de2f..189a7306f 100644 --- a/100_core/src_101_types_object/gplx/String_.java +++ b/100_core/src_101_types_object/gplx/String_.java @@ -17,7 +17,7 @@ along with this program. If not, see . */ package gplx; import java.lang.*; -import gplx.core.strings.*; +import gplx.core.strings.*; import gplx.langs.gfs.*; public class String_ implements GfoInvkAble { public static final Class Cls_ref_type = String.class; public static final String Cls_val_name = "str" + "ing"; diff --git a/100_core/src_130_brys/gplx/Bry_bfr.java b/100_core/src_130_brys/gplx/Bry_bfr.java index 61cc77459..1e8f07e19 100644 --- a/100_core/src_130_brys/gplx/Bry_bfr.java +++ b/100_core/src_130_brys/gplx/Bry_bfr.java @@ -16,8 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx; -import gplx.core.primitives.*; -import gplx.core.encoders.*; +import gplx.core.primitives.*; import gplx.core.brys.*; import gplx.core.encoders.*; public class Bry_bfr { private Bry_bfr_mkr_mgr mkr_mgr; private int reset; public byte[] Bfr() {return bfr;} private byte[] bfr; @@ -419,7 +418,7 @@ public class Bry_bfr { else if (o_type == Boolean.class) Add_yn(Bool_.cast(o)); else if (o_type == Double.class) Add_double(Double_.cast(o)); else if (o_type == Float.class) Add_float(Float_.cast(o)); - else ((Bry_fmtr_arg)o).Fmt__do(this); + else ((Bfr_arg)o).Bfr_arg__add(this); return this; } public Bry_bfr Add_obj_strict(Object o) { @@ -436,7 +435,7 @@ public class Bry_bfr { else if (o_type == Boolean.class) Add_bool(Bool_.cast(o)); else if (o_type == Double.class) Add_double(Double_.cast(o)); else if (o_type == Float.class) Add_float(Float_.cast(o)); - else ((Bry_fmtr_arg)o).Fmt__do(this); + else ((Bfr_arg)o).Bfr_arg__add(this); return this; } public Bry_bfr Add_yn(boolean v) {Add_byte(v ? Byte_ascii.Ltr_y : Byte_ascii.Ltr_n); return this;} @@ -556,7 +555,11 @@ public class Bry_bfr { this.Mkr_rls(); } @Override public int hashCode() {return Bry_obj_ref.CalcHashCode(bfr, 0, bfr_len);} - @Override public boolean equals(Object obj) {return obj == null ? false : Bry_.Match(bfr, 0, bfr_len, ((Bry_obj_ref)obj).Val());} // NOTE: strange, but null check needed; throws null error; PAGE:c:File:Eug�ne_Delacroix_-_La_libert�_guidant_le_peuple.jpg + @Override public boolean equals(Object obj) { + if (obj == null) return false; // NOTE: strange, but null check needed; throws null error; EX.WP: File:Eug�ne Delacroix - La libert� guidant le peuple.jpg + Bry_obj_ref comp = (Bry_obj_ref)obj; + return Bry_.Match(bfr, 0, bfr_len, comp.Val(), comp.Val_bgn(), comp.Val_end()); + } public void Resize(int v) { bfr_max = v; bfr = Bry_.Resize(bfr, 0, v); diff --git a/100_core/src_130_brys/gplx/Bry_fmtr_arg_.java b/100_core/src_130_brys/gplx/Bry_fmtr_arg_.java deleted file mode 100644 index fc9f95caf..000000000 --- a/100_core/src_130_brys/gplx/Bry_fmtr_arg_.java +++ /dev/null @@ -1,33 +0,0 @@ -/* -XOWA: the XOWA Offline Wiki Application -Copyright (C) 2012 gnosygnu@gmail.com - -This program is free software: you can redistribute it and/or modify -it under the terms of the GNU Affero General Public License as -published by the Free Software Foundation, either version 3 of the -License, or (at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Affero General Public License for more details. - -You should have received a copy of the GNU Affero General Public License -along with this program. If not, see . -*/ -package gplx; -import gplx.brys.*; -public class Bry_fmtr_arg_ { - public static Bry_fmtr_arg_bry bry_(String v) {return new Bry_fmtr_arg_bry(Bry_.new_u8(v));} - public static Bry_fmtr_arg_bry bry_(byte[] v) {return new Bry_fmtr_arg_bry(v);} - public static Bry_fmtr_arg_byt byt_(byte v) {return new Bry_fmtr_arg_byt(v);} - public static Bry_fmtr_arg_int int_(int v) {return new Bry_fmtr_arg_int(v);} - public static Bry_fmtr_arg_bfr bfr_(Bry_bfr v) {return new Bry_fmtr_arg_bfr(v);} - public static Bry_fmtr_arg_bfr_preserve bfr_retain_(Bry_bfr v) {return new Bry_fmtr_arg_bfr_preserve(v);} - public static Bry_fmtr_arg fmtr_(Bry_fmtr v, Bry_fmtr_arg... arg_ary) {return new Bry_fmtr_arg_fmtr(v, arg_ary);} - public static Bry_fmtr_arg_fmtr_objs fmtr_null_() {return new Bry_fmtr_arg_fmtr_objs(null, null);} - public static final Bry_fmtr_arg Noop = new Bry_fmtr_arg__noop(); -} -class Bry_fmtr_arg__noop implements Bry_fmtr_arg { - public void Fmt__do(Bry_bfr bfr) {} -} diff --git a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_fmtr.java b/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_fmtr.java deleted file mode 100644 index 8dddaffd3..000000000 --- a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_fmtr.java +++ /dev/null @@ -1,23 +0,0 @@ -/* -XOWA: the XOWA Offline Wiki Application -Copyright (C) 2012 gnosygnu@gmail.com - -This program is free software: you can redistribute it and/or modify -it under the terms of the GNU Affero General Public License as -published by the Free Software Foundation, either version 3 of the -License, or (at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Affero General Public License for more details. - -You should have received a copy of the GNU Affero General Public License -along with this program. If not, see . -*/ -package gplx.brys; import gplx.*; -public class Bry_fmtr_arg_fmtr implements Bry_fmtr_arg { - public Bry_fmtr_arg_fmtr Data_(Bry_fmtr v) {fmtr = v; return this;} - public void Fmt__do(Bry_bfr bfr) {fmtr.Bld_bfr(bfr, arg_ary);} - public Bry_fmtr_arg_fmtr(Bry_fmtr fmtr, Bry_fmtr_arg... arg_ary) {this.fmtr = fmtr; this.arg_ary = arg_ary;} Bry_fmtr fmtr; Bry_fmtr_arg[] arg_ary; -} diff --git a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_int.java b/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_int.java deleted file mode 100644 index 61a849484..000000000 --- a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_int.java +++ /dev/null @@ -1,23 +0,0 @@ -/* -XOWA: the XOWA Offline Wiki Application -Copyright (C) 2012 gnosygnu@gmail.com - -This program is free software: you can redistribute it and/or modify -it under the terms of the GNU Affero General Public License as -published by the Free Software Foundation, either version 3 of the -License, or (at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU Affero General Public License for more details. - -You should have received a copy of the GNU Affero General Public License -along with this program. If not, see . -*/ -package gplx.brys; import gplx.*; -public class Bry_fmtr_arg_int implements Bry_fmtr_arg { - public Bry_fmtr_arg_int Data_(int v) {val = Int_.cast(v); val_digits = Int_.DigitCount(val); return this;} - public void Fmt__do(Bry_bfr bfr) {bfr.Add_int_fixed(val, val_digits);} - public Bry_fmtr_arg_int(int v) {this.val = v; this.val_digits = Int_.DigitCount(v);} int val, val_digits; -} diff --git a/100_core/src_140_list/gplx/Ordered_hash_.java b/100_core/src_140_list/gplx/Ordered_hash_.java index f452958fd..a4c1c9a8e 100644 --- a/100_core/src_140_list/gplx/Ordered_hash_.java +++ b/100_core/src_140_list/gplx/Ordered_hash_.java @@ -22,8 +22,8 @@ public class Ordered_hash_ { public static Ordered_hash New_bry() {return new Ordered_hash_bry();} } class Ordered_hash_bry extends Ordered_hash_base { - private final Bry_obj_ref tmp_ref = Bry_obj_ref.null_(); - @Override protected void Add_base(Object key, Object val) {super.Add_base(Bry_obj_ref.new_((byte[])key), val);} + private final Bry_obj_ref tmp_ref = Bry_obj_ref.New_empty(); + @Override protected void Add_base(Object key, Object val) {super.Add_base(Bry_obj_ref.New((byte[])key), val);} @Override protected void Del_base(Object key) {synchronized (tmp_ref) {super.Del_base(tmp_ref.Val_((byte[])key));}} @Override protected boolean Has_base(Object key) {synchronized (tmp_ref) {return super.Has_base(tmp_ref.Val_((byte[])key));}} @Override protected Object Fetch_base(Object key) {synchronized (tmp_ref) {return super.Fetch_base(tmp_ref.Val_((byte[])key));}} diff --git a/100_core/src_311_gfoObj/gplx/GfoInvkXtoStr.java b/100_core/src_311_gfoObj/gplx/GfoInvkXtoStr.java index 924aa6242..5926d0fc8 100644 --- a/100_core/src_311_gfoObj/gplx/GfoInvkXtoStr.java +++ b/100_core/src_311_gfoObj/gplx/GfoInvkXtoStr.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx; +import gplx.langs.gfs.*; public class GfoInvkXtoStr { public static GfoMsg ReadMsg(GfoInvkAble invk, String k) { GfsCtx ctx = GfsCtx.wtr_(); diff --git a/100_core/src_311_gfoObj/gplx/GfoMsg_tst.java b/100_core/src_311_gfoObj/gplx/GfoMsg_tst.java index 97fe90abf..cd09af2ce 100644 --- a/100_core/src_311_gfoObj/gplx/GfoMsg_tst.java +++ b/100_core/src_311_gfoObj/gplx/GfoMsg_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx; -import org.junit.*; +import org.junit.*; import gplx.langs.gfs.*; public class GfoMsg_tst { @Before public void setup() { GfsCore.Instance.AddObj(new Mok(), "Mok"); diff --git a/100_core/src_330_store/gplx/DataWtr.java b/100_core/src_330_store/gplx/DataWtr.java index 158218177..a5bf82298 100644 --- a/100_core/src_330_store/gplx/DataWtr.java +++ b/100_core/src_330_store/gplx/DataWtr.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx; +import gplx.core.gfo_ndes.*; public interface DataWtr extends SrlMgr { Hash_adp EnvVars(); diff --git a/100_core/src_330_store/gplx/DataWtr_.java b/100_core/src_330_store/gplx/DataWtr_.java index b000838d9..b2d21da47 100644 --- a/100_core/src_330_store/gplx/DataWtr_.java +++ b/100_core/src_330_store/gplx/DataWtr_.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx; -import gplx.stores.*; /*DsvDataWtr_*/ +import gplx.stores.*; /*DsvDataWtr_*/ import gplx.core.gfo_ndes.*; public class DataWtr_ { public static final DataWtr Null = new DataWtr_null(); } diff --git a/100_core/src_330_store/gplx/stores/DataRdr_mem.java b/100_core/src_330_store/gplx/stores/DataRdr_mem.java index ed81660f7..082f32914 100644 --- a/100_core/src_330_store/gplx/stores/DataRdr_mem.java +++ b/100_core/src_330_store/gplx/stores/DataRdr_mem.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.stores; import gplx.*; +import gplx.core.gfo_ndes.*; public class DataRdr_mem extends DataRdr_base implements GfoNdeRdr { @Override public String NameOfNode() {return cur.Name();} public GfoNde UnderNde() {return cur;} diff --git a/100_core/src_330_store/gplx/stores/GfoNdeRdr.java b/100_core/src_330_store/gplx/stores/GfoNdeRdr.java index e0547a337..6ccecf592 100644 --- a/100_core/src_330_store/gplx/stores/GfoNdeRdr.java +++ b/100_core/src_330_store/gplx/stores/GfoNdeRdr.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.stores; import gplx.*; +import gplx.core.gfo_ndes.*; public interface GfoNdeRdr extends DataRdr { GfoNde UnderNde(); } diff --git a/100_core/src_330_store/gplx/stores/GfoNdeRdr_.java b/100_core/src_330_store/gplx/stores/GfoNdeRdr_.java index 37ca13e46..b6e5e4e66 100644 --- a/100_core/src_330_store/gplx/stores/GfoNdeRdr_.java +++ b/100_core/src_330_store/gplx/stores/GfoNdeRdr_.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.stores; import gplx.*; +import gplx.core.gfo_ndes.*; public class GfoNdeRdr_ { public static GfoNdeRdr kvs_(KeyValList kvList) { GfoFldList flds = GfoFldList_.new_(); diff --git a/100_core/src_330_store/gplx/stores/xmls/XmlDataWtr_.java b/100_core/src_330_store/gplx/stores/xmls/XmlDataWtr_.java index 1b0d547ac..6cee66940 100644 --- a/100_core/src_330_store/gplx/stores/xmls/XmlDataWtr_.java +++ b/100_core/src_330_store/gplx/stores/xmls/XmlDataWtr_.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.stores.xmls; import gplx.*; import gplx.stores.*; -import gplx.core.strings.*; +import gplx.core.strings.*; import gplx.core.gfo_ndes.*; public class XmlDataWtr_ { public static DataWtr new_() {return XmlDataWtr.new_();} } diff --git a/100_core/src_420_usrMsg/gplx/Gfo_usr_dlg__log_base.java b/100_core/src_420_usrMsg/gplx/Gfo_usr_dlg__log_base.java index bea725451..8c4fdd0cc 100644 --- a/100_core/src_420_usrMsg/gplx/Gfo_usr_dlg__log_base.java +++ b/100_core/src_420_usrMsg/gplx/Gfo_usr_dlg__log_base.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx; -import gplx.core.strings.*; import gplx.core.consoles.*; +import gplx.core.strings.*; import gplx.core.consoles.*; import gplx.core.brys.fmtrs.*; public class Gfo_usr_dlg__log_base implements Gfo_usr_dlg__log { private int archive_dirs_max = 8; private Io_url log_dir, err_fil; diff --git a/100_core/src_420_usrMsg/gplx/Gfo_usr_dlg_base.java b/100_core/src_420_usrMsg/gplx/Gfo_usr_dlg_base.java index 29a167b23..4d1071ba2 100644 --- a/100_core/src_420_usrMsg/gplx/Gfo_usr_dlg_base.java +++ b/100_core/src_420_usrMsg/gplx/Gfo_usr_dlg_base.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx; +import gplx.core.brys.fmtrs.*; public class Gfo_usr_dlg_base implements Gfo_usr_dlg { private final Bry_bfr tmp_bfr = Bry_bfr.reset_(255); private final Bry_fmtr tmp_fmtr = Bry_fmtr.tmp_().Fail_when_invalid_escapes_(false); // do not fail b/c msgs may contain excerpt of random text; EX:[[User:A|~A~]] DATE:2014-11-28 diff --git a/100_core/tst/gplx/stores/GfoNdeRdr_read_tst.java b/100_core/tst/gplx/stores/GfoNdeRdr_read_tst.java index 51939e43c..98632eeb9 100644 --- a/100_core/tst/gplx/stores/GfoNdeRdr_read_tst.java +++ b/100_core/tst/gplx/stores/GfoNdeRdr_read_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.stores; import gplx.*; -import org.junit.*; +import org.junit.*; import gplx.core.gfo_ndes.*; public class GfoNdeRdr_read_tst { @Test public void ReadInt() { rdr = rdr_(IntClassXtn.Instance, "id", 1); diff --git a/100_core/tst/gplx/stores/GfoNdeRdr_tst.java b/100_core/tst/gplx/stores/GfoNdeRdr_tst.java index fa3a9d4d7..c4ba9fd98 100644 --- a/100_core/tst/gplx/stores/GfoNdeRdr_tst.java +++ b/100_core/tst/gplx/stores/GfoNdeRdr_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.stores; import gplx.*; -import org.junit.*; +import org.junit.*; import gplx.core.gfo_ndes.*; public class GfoNdeRdr_tst { @Test public void Subs_leafs() { root = diff --git a/110_gfml/src_600_rdrWtr/gplx/gfml/GfmlDataNde.java b/110_gfml/src_600_rdrWtr/gplx/gfml/GfmlDataNde.java index a2274c66b..b257edcf5 100644 --- a/110_gfml/src_600_rdrWtr/gplx/gfml/GfmlDataNde.java +++ b/110_gfml/src_600_rdrWtr/gplx/gfml/GfmlDataNde.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.gfml; import gplx.*; -import gplx.stores.*; +import gplx.stores.*; import gplx.core.gfo_ndes.*; public class GfmlDataNde { public GfmlDoc Doc() {return gdoc;} GfmlDoc gdoc; public DataRdr XtoRdr() { diff --git a/110_gfml/src_600_rdrWtr/gplx/gfml/GfmlDataWtr.java b/110_gfml/src_600_rdrWtr/gplx/gfml/GfmlDataWtr.java index ca170417c..a4f40b7ec 100644 --- a/110_gfml/src_600_rdrWtr/gplx/gfml/GfmlDataWtr.java +++ b/110_gfml/src_600_rdrWtr/gplx/gfml/GfmlDataWtr.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.gfml; import gplx.*; -import gplx.lists.*; /*StackAdp*/ +import gplx.lists.*; /*StackAdp*/ import gplx.core.gfo_ndes.*; public class GfmlDataWtr extends DataWtr_base implements DataWtr { public void InitWtr(String key, Object val) { if (!String_.Eq(key, GfmlDataWtrOpts.Key_const)) return; diff --git a/110_gfml/src_600_rdrWtr/gplx/gfml/GfoMsgParser_gfml.java b/110_gfml/src_600_rdrWtr/gplx/gfml/GfoMsgParser_gfml.java index 03c12e27a..9d93403ff 100644 --- a/110_gfml/src_600_rdrWtr/gplx/gfml/GfoMsgParser_gfml.java +++ b/110_gfml/src_600_rdrWtr/gplx/gfml/GfoMsgParser_gfml.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.gfml; import gplx.*; +import gplx.core.gfo_regys.*; public class GfoMsgParser_gfml implements GfoMsgParser { public GfoMsg ParseToMsg(String s) {return GfmlDataNde.XtoMsg(s);} public static final GfoMsgParser_gfml Instance = new GfoMsgParser_gfml(); GfoMsgParser_gfml() {} diff --git a/140_dbs/src/gplx/dbs/Db_crt_tst.java b/140_dbs/src/gplx/dbs/Db_crt_tst.java index 387f385d4..a230eaf47 100644 --- a/140_dbs/src/gplx/dbs/Db_crt_tst.java +++ b/140_dbs/src/gplx/dbs/Db_crt_tst.java @@ -16,8 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs; import gplx.*; -import org.junit.*; -import gplx.core.criterias.*; +import org.junit.*; import gplx.core.criterias.*; import gplx.core.gfo_ndes.*; public class Db_crt_tst { @Before public void setup() { row = GfoNde_.vals_(GfoFldList_.new_().Add("id", IntClassXtn.Instance).Add("name", StringClassXtn.Instance), Object_.Ary(1, "me")); diff --git a/140_dbs/src/gplx/dbs/engines/tdbs/TdbDbLoadMgr_tst.java b/140_dbs/src/gplx/dbs/engines/tdbs/TdbDbLoadMgr_tst.java index 3fa761b61..5778aca75 100644 --- a/140_dbs/src/gplx/dbs/engines/tdbs/TdbDbLoadMgr_tst.java +++ b/140_dbs/src/gplx/dbs/engines/tdbs/TdbDbLoadMgr_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.engines.tdbs; import gplx.*; import gplx.dbs.*; import gplx.dbs.engines.*; -import org.junit.*; +import org.junit.*; import gplx.core.gfo_ndes.*; import gplx.stores.*; /*DsvDataRdr*/ import gplx.langs.dsvs.*; /*DsvDataWtr*/ public class TdbDbLoadMgr_tst { @Before public void setup() { diff --git a/140_dbs/src/gplx/dbs/engines/tdbs/TdbDelete.java b/140_dbs/src/gplx/dbs/engines/tdbs/TdbDelete.java index 4b43e28c7..a202fc49e 100644 --- a/140_dbs/src/gplx/dbs/engines/tdbs/TdbDelete.java +++ b/140_dbs/src/gplx/dbs/engines/tdbs/TdbDelete.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.engines.tdbs; import gplx.*; import gplx.dbs.*; import gplx.dbs.engines.*; -import gplx.core.criterias.*; import gplx.lists.*; /*GfoNde*/ import gplx.dbs.qrys.*; +import gplx.core.criterias.*; import gplx.lists.*; /*GfoNde*/ import gplx.dbs.qrys.*; import gplx.core.gfo_ndes.*; class TdbDeleteWkr implements Db_qryWkr { public Object Exec(Db_engine engineObj, Db_qry cmdObj) { TdbEngine engine = TdbEngine.cast(engineObj); Db_qry_delete cmd = (Db_qry_delete)cmdObj; diff --git a/140_dbs/src/gplx/dbs/engines/tdbs/TdbFileList.java b/140_dbs/src/gplx/dbs/engines/tdbs/TdbFileList.java index 65acfcf29..c4c84bb9a 100644 --- a/140_dbs/src/gplx/dbs/engines/tdbs/TdbFileList.java +++ b/140_dbs/src/gplx/dbs/engines/tdbs/TdbFileList.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.engines.tdbs; import gplx.*; import gplx.dbs.*; import gplx.dbs.engines.*; +import gplx.core.gfo_ndes.*; import gplx.lists.*; /*Ordered_hash_base*/ import gplx.langs.dsvs.*; /*DsvStoreLayout*/ public class TdbFileList extends Ordered_hash_base { public TdbFile Get_by_or_fail(int id) {return TdbFile.as_(Get_by_or_fail_base(id));} diff --git a/140_dbs/src/gplx/dbs/engines/tdbs/TdbInsert.java b/140_dbs/src/gplx/dbs/engines/tdbs/TdbInsert.java index 8a178f09d..3c2537d8d 100644 --- a/140_dbs/src/gplx/dbs/engines/tdbs/TdbInsert.java +++ b/140_dbs/src/gplx/dbs/engines/tdbs/TdbInsert.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.engines.tdbs; import gplx.*; import gplx.dbs.*; import gplx.dbs.engines.*; +import gplx.core.gfo_ndes.*; import gplx.lists.*; import gplx.dbs.qrys.*; import gplx.dbs.sqls.*; class TdbInsertWkr implements Db_qryWkr { public Object Exec(Db_engine engineObj, Db_qry cmdObj) { diff --git a/140_dbs/src/gplx/dbs/engines/tdbs/TdbSelect.java b/140_dbs/src/gplx/dbs/engines/tdbs/TdbSelect.java index 62f9c40c0..35f46ae9b 100644 --- a/140_dbs/src/gplx/dbs/engines/tdbs/TdbSelect.java +++ b/140_dbs/src/gplx/dbs/engines/tdbs/TdbSelect.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.engines.tdbs; import gplx.*; import gplx.dbs.*; import gplx.dbs.engines.*; -import gplx.core.criterias.*; import gplx.dbs.qrys.*; import gplx.dbs.sqls.*; +import gplx.core.criterias.*; import gplx.core.gfo_ndes.*; import gplx.dbs.qrys.*; import gplx.dbs.sqls.*; import gplx.lists.*; /*ComparerAble*/ import gplx.stores.*; /*GfoNdeRdr*/ class TdbSelectWkr implements Db_qryWkr { public Object Exec(Db_engine engineObj, Db_qry cmdObj) { diff --git a/140_dbs/src/gplx/dbs/engines/tdbs/TdbTable.java b/140_dbs/src/gplx/dbs/engines/tdbs/TdbTable.java index a38595898..8bbd3565f 100644 --- a/140_dbs/src/gplx/dbs/engines/tdbs/TdbTable.java +++ b/140_dbs/src/gplx/dbs/engines/tdbs/TdbTable.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.engines.tdbs; import gplx.*; import gplx.dbs.*; import gplx.dbs.engines.*; -import gplx.*; /*GfoNdeList*/ import gplx.stores.*; import gplx.langs.dsvs.*; /*DsvStoreLayout*/ +import gplx.*; /*GfoNdeList*/ import gplx.stores.*; import gplx.langs.dsvs.*; /*DsvStoreLayout*/ import gplx.core.gfo_ndes.*; public class TdbTable { public int Id() {return id;} int id; public String Name() {return name;} private String name; diff --git a/140_dbs/src/gplx/dbs/engines/tdbs/TdbTableList.java b/140_dbs/src/gplx/dbs/engines/tdbs/TdbTableList.java index c13809f90..01c53a92e 100644 --- a/140_dbs/src/gplx/dbs/engines/tdbs/TdbTableList.java +++ b/140_dbs/src/gplx/dbs/engines/tdbs/TdbTableList.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.engines.tdbs; import gplx.*; import gplx.dbs.*; import gplx.dbs.engines.*; -import gplx.lists.*; /*Ordered_hash_base*/ import gplx.langs.dsvs.*; /*DsvStoreLayout*/ +import gplx.lists.*; /*Ordered_hash_base*/ import gplx.langs.dsvs.*; /*DsvStoreLayout*/ import gplx.core.gfo_ndes.*; public class TdbTableList extends Ordered_hash_base { public TdbTable Get_by(String name) {return TdbTable.as_(Fetch_base(name));} public TdbTable Get_by_or_fail(String name) { diff --git a/140_dbs/src/gplx/dbs/engines/tdbs/TdbUpdate.java b/140_dbs/src/gplx/dbs/engines/tdbs/TdbUpdate.java index 4591ddacc..034f9b4e0 100644 --- a/140_dbs/src/gplx/dbs/engines/tdbs/TdbUpdate.java +++ b/140_dbs/src/gplx/dbs/engines/tdbs/TdbUpdate.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.engines.tdbs; import gplx.*; import gplx.dbs.*; import gplx.dbs.engines.*; -import gplx.core.criterias.*; import gplx.lists.*; /*GfoNde*/ +import gplx.core.criterias.*; import gplx.lists.*; /*GfoNde*/ import gplx.core.gfo_ndes.*; import gplx.dbs.qrys.*; class TdbUpdateWkr implements Db_qryWkr { public Object Exec(Db_engine engineObj, Db_qry cmdObj) { diff --git a/140_dbs/src/gplx/dbs/metas/Meta_tbl_mgr.java b/140_dbs/src/gplx/dbs/metas/Meta_tbl_mgr.java index 01964ae7a..b9ab47c06 100644 --- a/140_dbs/src/gplx/dbs/metas/Meta_tbl_mgr.java +++ b/140_dbs/src/gplx/dbs/metas/Meta_tbl_mgr.java @@ -18,7 +18,9 @@ along with this program. If not, see . package gplx.dbs.metas; import gplx.*; import gplx.dbs.*; public class Meta_tbl_mgr { private final Ordered_hash hash = Ordered_hash_.New(); + public int Len() {return hash.Count();} public void Add(Meta_tbl_itm itm) {hash.Add(itm.Name(), itm);} public boolean Has(String name) {return hash.Has(name);} - public Meta_tbl_itm Get_by(String name) {return (Meta_tbl_itm)hash.Get_by(name);} + public Meta_tbl_itm Get_at(int i) {return (Meta_tbl_itm)hash.Get_at(i);} + public Meta_tbl_itm Get_by(String name) {return (Meta_tbl_itm)hash.Get_by(name);} } diff --git a/140_dbs/src/gplx/dbs/qrys/Db_qry__select_cmd.java b/140_dbs/src/gplx/dbs/qrys/Db_qry__select_cmd.java index c9377d83c..6651f02c5 100644 --- a/140_dbs/src/gplx/dbs/qrys/Db_qry__select_cmd.java +++ b/140_dbs/src/gplx/dbs/qrys/Db_qry__select_cmd.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.qrys; import gplx.*; import gplx.dbs.*; -import gplx.core.criterias.*; import gplx.dbs.sqls.*; +import gplx.core.criterias.*; import gplx.dbs.sqls.*; import gplx.core.gfo_ndes.*; public class Db_qry__select_cmd implements Db_qry { public int Tid() {return Db_qry_.Tid_select;} public boolean Exec_is_rdr() {return true;} diff --git a/140_dbs/src/gplx/dbs/qrys/Db_stmt_sql.java b/140_dbs/src/gplx/dbs/qrys/Db_stmt_sql.java index 1a86f9a5f..17cc0d8f0 100644 --- a/140_dbs/src/gplx/dbs/qrys/Db_stmt_sql.java +++ b/140_dbs/src/gplx/dbs/qrys/Db_stmt_sql.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.qrys; import gplx.*; import gplx.dbs.*; +import gplx.core.brys.fmtrs.*; import gplx.dbs.engines.*; public class Db_stmt_sql implements Db_stmt {// used for formatting SQL statements; not used for actual insert into database private static final String Key_na = ""; // key is not_available; only called by procs with signature of Val( v); diff --git a/140_dbs/src/gplx/dbs/sqls/Db_sqlbldr__sqlite.java b/140_dbs/src/gplx/dbs/sqls/Db_sqlbldr__sqlite.java index 2562a758e..da02041ef 100644 --- a/140_dbs/src/gplx/dbs/sqls/Db_sqlbldr__sqlite.java +++ b/140_dbs/src/gplx/dbs/sqls/Db_sqlbldr__sqlite.java @@ -18,7 +18,8 @@ along with this program. If not, see . package gplx.dbs.sqls; import gplx.*; import gplx.dbs.*; interface Db_sqlbldr {} public class Db_sqlbldr__sqlite implements Db_sqlbldr { - private final Bry_bfr tmp_bfr = Bry_bfr.reset_(1024); + private Bry_bfr tmp_bfr = Bry_bfr.reset_(1024); + public Db_sqlbldr__sqlite Bfr_(Bry_bfr bfr) {this.tmp_bfr = bfr; return this;} public String Bld_create_idx(Db_meta_idx idx) { tmp_bfr.Add_str_a7("CREATE "); if (idx.Unique()) @@ -95,5 +96,5 @@ public class Db_sqlbldr__sqlite implements Db_sqlbldr { default: throw Err_.new_unhandled(tid); } } - public static final Db_sqlbldr__sqlite Instance = new Db_sqlbldr__sqlite(); Db_sqlbldr__sqlite() {} + public static final Db_sqlbldr__sqlite Instance = new Db_sqlbldr__sqlite(); } diff --git a/140_dbs/src/gplx/dbs/sqls/Sql_order_by_sorter.java b/140_dbs/src/gplx/dbs/sqls/Sql_order_by_sorter.java index 73d736ebe..93d837202 100644 --- a/140_dbs/src/gplx/dbs/sqls/Sql_order_by_sorter.java +++ b/140_dbs/src/gplx/dbs/sqls/Sql_order_by_sorter.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.sqls; import gplx.*; import gplx.dbs.*; +import gplx.core.gfo_ndes.*; import gplx.lists.*; public class Sql_order_by_sorter implements ComparerAble { public int compare(Object lhsObj, Object rhsObj) { diff --git a/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_.java b/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_.java index 2ecd2e661..f6f28e91d 100644 --- a/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_.java +++ b/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.sqls; import gplx.*; import gplx.dbs.*; +import gplx.core.gfo_ndes.*; public class Sql_select_fld_ { public static Sql_select_fld_base new_fld(String tbl, String fld, String alias) {return new Sql_select_fld_fld(tbl, fld, alias);} public static Sql_select_fld_base new_count(String tbl, String fld, String alias) {return new Sql_select_fld_count(tbl, fld, alias);} diff --git a/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_base.java b/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_base.java index e9b7454c9..4a089258a 100644 --- a/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_base.java +++ b/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_base.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.sqls; import gplx.*; import gplx.dbs.*; +import gplx.core.gfo_ndes.*; public abstract class Sql_select_fld_base { public String Tbl() {return tbl;} public void Tbl_set(String val) {tbl = val;} private String tbl; public String Fld() {return fld;} public void Fld_set(String val) {fld = val;} private String fld; diff --git a/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_list.java b/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_list.java index 2bd7ad5ba..9ebb23e95 100644 --- a/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_list.java +++ b/140_dbs/src/gplx/dbs/sqls/Sql_select_fld_list.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.sqls; import gplx.*; import gplx.dbs.*; -import gplx.core.strings.*; +import gplx.core.strings.*; import gplx.core.gfo_ndes.*; import gplx.dbs.engines.tdbs.*; public class Sql_select_fld_list { public int Count() {return hash.Count();} diff --git a/140_dbs/src/gplx/stores/DbMaprRdr.java b/140_dbs/src/gplx/stores/DbMaprRdr.java index b22ca202b..96d45b450 100644 --- a/140_dbs/src/gplx/stores/DbMaprRdr.java +++ b/140_dbs/src/gplx/stores/DbMaprRdr.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.stores; import gplx.*; -import gplx.core.criterias.*; import gplx.dbs.*; +import gplx.core.criterias.*; import gplx.dbs.*; import gplx.core.gfo_ndes.*; public class DbMaprRdr extends DataRdr_base implements SrlMgr { @Override public String NameOfNode() {return "DbMaprRdr";} @Override public Object StoreRoot(SrlObj subProto, String key) { diff --git a/140_dbs/src/gplx/stores/DbMaprWtr.java b/140_dbs/src/gplx/stores/DbMaprWtr.java index 11ad0e98a..b2a8f3aef 100644 --- a/140_dbs/src/gplx/stores/DbMaprWtr.java +++ b/140_dbs/src/gplx/stores/DbMaprWtr.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.stores; import gplx.*; -import gplx.core.criterias.*; +import gplx.core.criterias.*; import gplx.core.gfo_ndes.*; import gplx.dbs.*; import gplx.dbs.qrys.*; public class DbMaprWtr extends DataWtr_base implements DataWtr { public void InitWtr(String key, Object val) {} diff --git a/140_dbs/tst/gplx/dbs/Db_conn_fxt.java b/140_dbs/tst/gplx/dbs/Db_conn_fxt.java index 0ff33ea44..f1ede83ba 100644 --- a/140_dbs/tst/gplx/dbs/Db_conn_fxt.java +++ b/140_dbs/tst/gplx/dbs/Db_conn_fxt.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs; import gplx.*; -import gplx.dbs.engines.sqlite.*; import gplx.dbs.engines.mysql.*; import gplx.dbs.engines.postgres.*; +import gplx.dbs.engines.sqlite.*; import gplx.dbs.engines.mysql.*; import gplx.dbs.engines.postgres.*; import gplx.core.gfo_ndes.*; public class Db_conn_fxt implements RlsAble { public Db_conn Conn() {return conn;} public Db_conn_fxt Conn_(Db_conn v) {conn = v; return this;} Db_conn conn; public void DmlAffectedAvailable_(boolean v) {dmlAffectedAvailable = v;} private boolean dmlAffectedAvailable = true; diff --git a/140_dbs/tst/gplx/dbs/Db_qry_fxt.java b/140_dbs/tst/gplx/dbs/Db_qry_fxt.java index 5a6ba9843..9c5bd8dbc 100644 --- a/140_dbs/tst/gplx/dbs/Db_qry_fxt.java +++ b/140_dbs/tst/gplx/dbs/Db_qry_fxt.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs; import gplx.*; -import gplx.dbs.qrys.*; +import gplx.dbs.qrys.*; import gplx.core.gfo_ndes.*; public class Db_qry_fxt { public static void Insert_kvo(Db_conn conn, String tblName, KeyValList kvList) { Db_qry_insert qry = Db_qry_.insert_(tblName); diff --git a/140_dbs/tst/gplx/dbs/GfoNdeTstr.java b/140_dbs/tst/gplx/dbs/GfoNdeTstr.java index 5c35fa8fc..c8c806ecf 100644 --- a/140_dbs/tst/gplx/dbs/GfoNdeTstr.java +++ b/140_dbs/tst/gplx/dbs/GfoNdeTstr.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs; import gplx.*; +import gplx.core.gfo_ndes.*; public class GfoNdeTstr { public static void tst_ValsByCol(GfoNde nde, String fld, Object... expdAry) { List_adp expd = List_adp_.new_(); diff --git a/140_dbs/tst/gplx/dbs/groupBys/GroupBys_base_tst.java b/140_dbs/tst/gplx/dbs/groupBys/GroupBys_base_tst.java index 15a61d41c..51d8e1af9 100644 --- a/140_dbs/tst/gplx/dbs/groupBys/GroupBys_base_tst.java +++ b/140_dbs/tst/gplx/dbs/groupBys/GroupBys_base_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.groupBys; import gplx.*; import gplx.dbs.*; -import org.junit.*; import gplx.dbs.qrys.*; +import org.junit.*; import gplx.dbs.qrys.*; import gplx.core.gfo_ndes.*; public abstract class GroupBys_base_tst { protected abstract Db_conn provider_(); protected Db_conn conn; diff --git a/140_dbs/tst/gplx/dbs/insertIntos/InsertIntos_base_tst.java b/140_dbs/tst/gplx/dbs/insertIntos/InsertIntos_base_tst.java index ff490f313..45f8d6d72 100644 --- a/140_dbs/tst/gplx/dbs/insertIntos/InsertIntos_base_tst.java +++ b/140_dbs/tst/gplx/dbs/insertIntos/InsertIntos_base_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.insertIntos; import gplx.*; import gplx.dbs.*; -import org.junit.*; import gplx.dbs.qrys.*; +import org.junit.*; import gplx.core.gfo_ndes.*; import gplx.dbs.qrys.*; public abstract class InsertIntos_base_tst { protected abstract Db_conn provider_(); protected Db_conn conn; diff --git a/140_dbs/tst/gplx/dbs/joins/Joins_base_tst.java b/140_dbs/tst/gplx/dbs/joins/Joins_base_tst.java index 865720827..6fa8bb7e6 100644 --- a/140_dbs/tst/gplx/dbs/joins/Joins_base_tst.java +++ b/140_dbs/tst/gplx/dbs/joins/Joins_base_tst.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.dbs.joins; import gplx.*; import gplx.dbs.*; -import org.junit.*; import gplx.dbs.qrys.*; import gplx.dbs.sqls.*; +import org.junit.*; import gplx.core.gfo_ndes.*; import gplx.dbs.qrys.*; import gplx.dbs.sqls.*; public abstract class Joins_base_tst { protected Db_conn conn; @Before public void setup() { diff --git a/150_gfui/src_400_win/gplx/gfui/GfoConsoleWin.java b/150_gfui/src_400_win/gplx/gfui/GfoConsoleWin.java index 9bbcdb936..39d9fb9c5 100644 --- a/150_gfui/src_400_win/gplx/gfui/GfoConsoleWin.java +++ b/150_gfui/src_400_win/gplx/gfui/GfoConsoleWin.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.gfui; import gplx.*; -import gplx.gfml.*; +import gplx.gfml.*; import gplx.langs.gfs.*; public class GfoConsoleWin implements GfoInvkAble, UsrMsgWkr { GfuiWin win; GfoConsoleWinCmds cmds; GfuiTextBox statusBox, resultBox; GfuiTextBoxLogger logger; public boolean Enabled() {return enabled;} public GfoConsoleWin Enabled_(boolean v) {enabled = v; return this;} private boolean enabled = true; diff --git a/150_gfui/src_400_win/gplx/gfui/GfuiMenuBar.java b/150_gfui/src_400_win/gplx/gfui/GfuiMenuBar.java index ddc84da2a..a6377892b 100644 --- a/150_gfui/src_400_win/gplx/gfui/GfuiMenuBar.java +++ b/150_gfui/src_400_win/gplx/gfui/GfuiMenuBar.java @@ -29,6 +29,7 @@ import javax.swing.JMenuBar; import javax.swing.JMenuItem; import javax.swing.JSeparator; import javax.swing.border.EmptyBorder; +import gplx.langs.gfs.*; public class GfuiMenuBar implements GfoInvkAble { public Object Under() {return winMenu;} public boolean Visible() {return visible;} private boolean visible; diff --git a/150_gfui/src_420_box_basic/gplx/gfui/GfuiBtn.java b/150_gfui/src_420_box_basic/gplx/gfui/GfuiBtn.java index ec2e6386f..d3e13f3ad 100644 --- a/150_gfui/src_420_box_basic/gplx/gfui/GfuiBtn.java +++ b/150_gfui/src_420_box_basic/gplx/gfui/GfuiBtn.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.gfui; import gplx.*; +import gplx.langs.gfs.*; public class GfuiBtn extends GfuiElemBase { @Override public boolean Click_able() {return true;} @Override public void Click() {GfuiBtn.DoThis(this, clickMsg, clickInvkCmd);} diff --git a/150_gfui/src_600_adp/gplx/gfui/IconAdp.java b/150_gfui/src_600_adp/gplx/gfui/IconAdp.java index 895cec318..53f8efb50 100644 --- a/150_gfui/src_600_adp/gplx/gfui/IconAdp.java +++ b/150_gfui/src_600_adp/gplx/gfui/IconAdp.java @@ -21,6 +21,7 @@ import javax.swing.ImageIcon; import java.awt.Image; import java.net.MalformedURLException; import java.net.URL; +import gplx.core.gfo_regys.*; public class IconAdp { public Icon UnderIcon() {return icon;} private final Icon icon; public Image XtoImage() {return ((ImageIcon)icon).getImage();} diff --git a/150_gfui/src_700_env/gplx/gfui/GfsLibIni_gfui.java b/150_gfui/src_700_env/gplx/gfui/GfsLibIni_gfui.java index b23496dfb..a0108b60c 100644 --- a/150_gfui/src_700_env/gplx/gfui/GfsLibIni_gfui.java +++ b/150_gfui/src_700_env/gplx/gfui/GfsLibIni_gfui.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.gfui; import gplx.*; +import gplx.langs.gfs.*; public class GfsLibIni_gfui implements GfsLibIni { public void Ini(GfsCore core) { core.AddCmd(IptCfgRegy.Instance, "IptBndMgr_"); diff --git a/150_gfui/src_700_env/gplx/gfui/GfuiEnv_.java b/150_gfui/src_700_env/gplx/gfui/GfuiEnv_.java index f70acc4dc..c8053d938 100644 --- a/150_gfui/src_700_env/gplx/gfui/GfuiEnv_.java +++ b/150_gfui/src_700_env/gplx/gfui/GfuiEnv_.java @@ -16,7 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.gfui; import gplx.*; -import gplx.gfml.*; +import gplx.gfml.*; import gplx.langs.gfs.*; import gplx.core.threads.*; import java.awt.AWTKeyStroke; import java.awt.Font; diff --git a/150_gfui/src_700_env/gplx/gfui/Swing_kit.java b/150_gfui/src_700_env/gplx/gfui/Swing_kit.java index e2799934c..689012dce 100644 --- a/150_gfui/src_700_env/gplx/gfui/Swing_kit.java +++ b/150_gfui/src_700_env/gplx/gfui/Swing_kit.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.gfui; import gplx.*; +import gplx.core.brys.fmtrs.*; public class Swing_kit extends Gfui_kit_base { private Bry_fmtr ask_fmtr = Bry_fmtr.new_(); private Bry_bfr ask_bfr = Bry_bfr.new_(); @Override public byte Tid() {return Gfui_kit_.Swing_tid;} diff --git a/150_gfui/src_700_env/gplx/gfui/Swt_kit.java b/150_gfui/src_700_env/gplx/gfui/Swt_kit.java index 212443f0f..17380eddd 100644 --- a/150_gfui/src_700_env/gplx/gfui/Swt_kit.java +++ b/150_gfui/src_700_env/gplx/gfui/Swt_kit.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.gfui; import gplx.*; +import gplx.core.brys.fmtrs.*; import org.eclipse.swt.SWT; import org.eclipse.swt.widgets.Control; import org.eclipse.swt.widgets.Display; diff --git a/400_xowa/src/gplx/core/brys/Bry_rdr.java b/400_xowa/src/gplx/core/brys/Bry_rdr.java index fb8b1ee03..80936fb90 100644 --- a/400_xowa/src/gplx/core/brys/Bry_rdr.java +++ b/400_xowa/src/gplx/core/brys/Bry_rdr.java @@ -24,11 +24,10 @@ public class Bry_rdr { public int Src_end() {return src_end;} private int src_end; public Bry_rdr Dflt_dlm_(byte b) {this.dflt_dlm = b; return this;} private byte dflt_dlm; public Bry_rdr Fail_throws_err_(boolean v) {this.fail_throws_err = v; return this;} private boolean fail_throws_err = true; - public Bry_rdr Ctor_by_page(byte[] ctx, byte[] src, int src_len) {this.ctx = Quote(String_.new_u8(ctx)); this.src = src; this.src_end = src_len; this.pos = 0; return this;} + public Bry_rdr Init_by_page(byte[] ctx, byte[] src, int src_len) {this.ctx = Quote(String_.new_u8(ctx)); this.src = src; this.src_end = src_len; this.pos = 0; return this;} public Bry_rdr Init_by_hook(String wkr, int err_bgn, int pos) {this.wkr = Quote(wkr); this.err_bgn = err_bgn; this.pos = pos; return this;} public Bry_rdr Init_by_sub(Bry_rdr rdr, String wkr, int pos, int src_end) { this.src = rdr.src; this.ctx = rdr.ctx; this.wkr = Quote(wkr); this.err_bgn = pos; this.pos = pos; this.src_end = src_end; - this.dflt_dlm = Byte_ascii.Null; return this; } public int Move_to(int v) {this.pos = v; return pos;} @@ -157,15 +156,15 @@ public class Bry_rdr { arg_val = Quote(Object_.Xto_str_strict_or_null_mark(arg_val)); String err_msg = Msg_make(msg, arg_key, arg_val, excerpt_bgn, excerpt_end); Gfo_usr_dlg_.Instance.Warn_many("", "", err_msg); - if (fail_throws_err) throw Err_.new_("Bry_rdr", err_msg); + if (fail_throws_err) throw Err_.new_("Bry_rdr", err_msg).Logged_y_(); return Bry_find_.Not_found; } public Err Err_make(String msg, String arg_key, Object arg_val, int excerpt_bgn, int excerpt_end) {return Err_.new_("Bry_rdr", Msg_make(msg, arg_key, arg_val, excerpt_bgn, excerpt_end));} private String Msg_make(String msg, String arg_key, Object arg_val, int excerpt_bgn, int excerpt_end) { if (String_.EqEmpty(arg_key)) - return Err_msg.To_str(msg, "ctx", ctx, "wkr", wkr, "excerpt", Bry_.Mid_safe(src, excerpt_bgn, excerpt_end)); + return String_.Replace(Err_msg.To_str(msg, "ctx", ctx, "wkr", wkr, "excerpt", Bry_.Mid_safe(src, excerpt_bgn, excerpt_end)), "\n", "\\n"); else - return Err_msg.To_str(msg, arg_key, arg_val, "ctx", ctx, "wkr", wkr, "excerpt", Quote(String_.new_u8(Bry_.Mid_by_len_safe(src, excerpt_bgn, excerpt_end)))); + return String_.Replace(Err_msg.To_str(msg, arg_key, arg_val, "ctx", ctx, "wkr", wkr, "excerpt", Quote(String_.new_u8(Bry_.Mid_safe(src, excerpt_bgn, excerpt_end)))), "\n", "\\n"); } private static String Quote(String v) {return "'" + v + "'";} } diff --git a/100_core/src_130_brys/gplx/Bry_fmtr_arg.java b/400_xowa/src/gplx/core/brys/Clear_able.java similarity index 86% rename from 100_core/src_130_brys/gplx/Bry_fmtr_arg.java rename to 400_xowa/src/gplx/core/brys/Clear_able.java index eb1284c55..e37013d6d 100644 --- a/100_core/src_130_brys/gplx/Bry_fmtr_arg.java +++ b/400_xowa/src/gplx/core/brys/Clear_able.java @@ -15,7 +15,7 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx; -public interface Bry_fmtr_arg { - void Fmt__do(Bry_bfr bfr); +package gplx.core.brys; import gplx.*; import gplx.core.*; +public interface Clear_able { + void Clear(); } diff --git a/400_xowa/src/gplx/core/brys/Int_flag_bldr.java b/400_xowa/src/gplx/core/brys/Int_flag_bldr.java index ad82639bb..eed01fb5b 100644 --- a/400_xowa/src/gplx/core/brys/Int_flag_bldr.java +++ b/400_xowa/src/gplx/core/brys/Int_flag_bldr.java @@ -24,6 +24,12 @@ public class Int_flag_bldr { this.val_ary = new int[pow_ary.length]; return this; } - public int Encode() {return Int_flag_bldr_.To_int(pow_ary, val_ary);} - public void Decode(int v) {Int_flag_bldr_.To_int_ary(val_ary, pow_ary, v);} + public Int_flag_bldr Set(int idx, int val) {val_ary[idx] = val; return this;} + public Int_flag_bldr Set(int idx, byte val) {val_ary[idx] = val; return this;} + public Int_flag_bldr Set(int idx, boolean val) {val_ary[idx] = val ? 1 : 0; return this;} + public int Get_as_int(int idx) {return val_ary[idx];} + public byte Get_as_byte(int idx) {return (byte)val_ary[idx];} + public boolean Get_as_bool(int idx) {return val_ary[idx] == 1;} + public int Encode() {return Int_flag_bldr_.To_int(pow_ary, val_ary);} + public void Decode(int v) {Int_flag_bldr_.To_int_ary(val_ary, pow_ary, v);} } diff --git a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_bfr.java b/400_xowa/src/gplx/core/brys/Mid_able.java similarity index 70% rename from 100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_bfr.java rename to 400_xowa/src/gplx/core/brys/Mid_able.java index 6a04891bf..9db77133c 100644 --- a/100_core/src_130_brys/gplx/brys/Bry_fmtr_arg_bfr.java +++ b/400_xowa/src/gplx/core/brys/Mid_able.java @@ -15,9 +15,9 @@ GNU Affero General Public License for more details. You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ -package gplx.brys; import gplx.*; -public class Bry_fmtr_arg_bfr implements Bry_fmtr_arg { - public Bry_fmtr_arg_bfr Data_(Bry_bfr v) {bfr = v; return this;} - public void Fmt__do(Bry_bfr trg) {trg.Add_bfr_and_clear(bfr);} - public Bry_fmtr_arg_bfr(Bry_bfr bfr) {this.bfr = bfr;} Bry_bfr bfr; +package gplx.core.brys; import gplx.*; import gplx.core.*; +public interface Mid_able { + byte[] Mid__src(); + int Mid__bgn(); + int Mid__end(); } diff --git a/400_xowa/src/gplx/core/intls/Gfo_i18n_itm.java b/400_xowa/src/gplx/core/intls/Gfo_i18n_itm.java index 43b4ec97c..07459c30e 100644 --- a/400_xowa/src/gplx/core/intls/Gfo_i18n_itm.java +++ b/400_xowa/src/gplx/core/intls/Gfo_i18n_itm.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.intls; import gplx.*; import gplx.core.*; +import gplx.core.brys.fmtrs.*; class Gfo_i18n_itm { public Gfo_i18n_itm(int src, byte[] key, byte[] val, boolean val_fmt_exists, Gfo_i18n_val_cmd val_cmd) { this.src = src; this.key = key; this.val = val; this.val_fmt_exists = val_fmt_exists; this.val_cmd = val_cmd; diff --git a/400_xowa/src/gplx/core/primitives/Bry_cache.java b/400_xowa/src/gplx/core/primitives/Bry_cache.java index fafdcf9b4..72119a237 100644 --- a/400_xowa/src/gplx/core/primitives/Bry_cache.java +++ b/400_xowa/src/gplx/core/primitives/Bry_cache.java @@ -16,19 +16,20 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.primitives; import gplx.*; import gplx.core.*; +import gplx.core.brys.*; public class Bry_cache { + private final Hash_adp hash = Hash_adp_.new_(); private final Bry_obj_ref hash_ref = Bry_obj_ref.New_empty(); public byte[] Get_or_new(String v) {return Get_or_new(Bry_.new_u8(v));} public byte[] Get_or_new(byte[] v) { if (v.length == 0) return Bry_.Empty; Object rv = hash.Get_by(hash_ref.Val_(v)); if (rv == null) { - Bry_obj_ref bry = Bry_obj_ref.new_(v); + Bry_obj_ref bry = Bry_obj_ref.New(v); hash.Add_as_key_and_val(bry); return v; } else return ((Bry_obj_ref)rv).Val(); } - Hash_adp hash = Hash_adp_.new_(); Bry_obj_ref hash_ref = Bry_obj_ref.null_(); public static final Bry_cache Instance = new Bry_cache(); Bry_cache() {} } diff --git a/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_base.java b/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_base.java index d5a6536b0..ddbe2cfe4 100644 --- a/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_base.java +++ b/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_base.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.threads; import gplx.*; import gplx.core.*; +import gplx.core.brys.fmtrs.*; import gplx.gfui.*; public class Gfo_thread_cmd_base implements Gfo_thread_cmd { @gplx.Virtual public String Async_key() {return "undefined";} diff --git a/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_download.java b/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_download.java index d22c13f46..391da9985 100644 --- a/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_download.java +++ b/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_download.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.threads; import gplx.*; import gplx.core.*; +import gplx.core.brys.fmtrs.*; import gplx.gfui.*; public class Gfo_thread_cmd_download implements Gfo_thread_cmd { public Gfo_thread_cmd Ctor(Gfo_usr_dlg usr_dlg, Gfui_kit kit) {this.usr_dlg = usr_dlg; this.kit = kit; xrg.Prog_dlg_(usr_dlg); return this;} diff --git a/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_replace.java b/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_replace.java index 1b2ecf563..8468f5c23 100644 --- a/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_replace.java +++ b/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_replace.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.threads; import gplx.*; import gplx.core.*; +import gplx.core.brys.fmtrs.*; import gplx.gfui.*; public class Gfo_thread_cmd_replace implements Gfo_thread_cmd { public Gfo_thread_cmd Init(Gfo_usr_dlg usr_dlg, Gfui_kit kit, Io_url fil) { diff --git a/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_unzip.java b/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_unzip.java index e74c38da0..8ad51fd8b 100644 --- a/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_unzip.java +++ b/400_xowa/src/gplx/core/threads/Gfo_thread_cmd_unzip.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.core.threads; import gplx.*; import gplx.core.*; +import gplx.core.brys.fmtrs.*; import gplx.gfui.*; import gplx.xowa.bldrs.cmds.utils.*; public class Gfo_thread_cmd_unzip implements Gfo_thread_cmd { public Gfo_thread_cmd_unzip Init(Gfo_usr_dlg usr_dlg, Gfui_kit kit, ProcessAdp bzip2_process, ProcessAdp zip_process, ProcessAdp gz_process, Io_url src, Io_url trg) { diff --git a/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_itm.java b/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_itm.java index 52e9d3e48..a8d9ff5ef 100644 --- a/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_itm.java +++ b/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_itm.java @@ -19,5 +19,6 @@ package gplx.core.threads.poolables; import gplx.*; import gplx.core.*; import g public interface Gfo_poolable_itm { int Pool__idx(); void Pool__clear (Object[] args); - Gfo_poolable_itm Pool__make (int idx, Object[] args); + Gfo_poolable_itm Pool__make (Gfo_poolable_mgr mgr, int idx, Object[] args); + void Pool__rls(); } diff --git a/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr.java b/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr.java index f12ec1849..d9fb0d11e 100644 --- a/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr.java +++ b/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr.java @@ -29,7 +29,7 @@ public class Gfo_poolable_mgr { public void Clear_fast() { this.pool = new Gfo_poolable_itm[pool_len]; for (int i = 0; i < pool_len; ++i) - pool[i] = prototype.Pool__make(i, make_args); + pool[i] = prototype.Pool__make(this, i, make_args); this.free_ary = new int[pool_len]; pool_nxt = free_len = 0; } @@ -47,7 +47,7 @@ public class Gfo_poolable_mgr { pool_idx = pool_nxt++; rv = pool[pool_idx]; if (rv == null) { - rv = prototype.Pool__make(pool_idx, make_args); + rv = prototype.Pool__make(this, pool_idx, make_args); pool[pool_idx] = rv; } } diff --git a/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_.java b/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_.java new file mode 100644 index 000000000..897a3903d --- /dev/null +++ b/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_.java @@ -0,0 +1,21 @@ +/* +XOWA: the XOWA Offline Wiki Application +Copyright (C) 2012 gnosygnu@gmail.com + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as +published by the Free Software Foundation, either version 3 of the +License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see . +*/ +package gplx.core.threads.poolables; import gplx.*; import gplx.core.*; import gplx.core.threads.*; +public class Gfo_poolable_mgr_ { + public static Gfo_poolable_mgr New(int len, int max, Gfo_poolable_itm prototype) {return new Gfo_poolable_mgr(prototype, Object_.Ary_empty, Object_.Ary_empty, len, max);} +} diff --git a/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_tst.java b/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_tst.java index 346874730..9fd5a52da 100644 --- a/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_tst.java +++ b/400_xowa/src/gplx/core/threads/poolables/Gfo_poolable_mgr_tst.java @@ -61,7 +61,7 @@ public class Gfo_poolable_mgr_tst { } } class Gfo_poolable_mgr_tstr { - private final Gfo_poolable_mgr mgr = new Gfo_poolable_mgr(new Sample_poolable_itm(-1, Object_.Ary_empty), Object_.Ary("make"), Object_.Ary("clear"), 2, 8); + private final Gfo_poolable_mgr mgr = new Gfo_poolable_mgr(new Sample_poolable_itm(null, -1, Object_.Ary_empty), Object_.Ary("make"), Object_.Ary("clear"), 2, 8); public void Clear() {mgr.Clear_fast();} public void Test__get(int expd_idx) { Sample_poolable_itm actl_itm = (Sample_poolable_itm)mgr.Get_fast(); @@ -74,10 +74,12 @@ class Gfo_poolable_mgr_tstr { public void Exec__rls(int idx) {mgr.Rls_fast(idx);} } class Sample_poolable_itm implements Gfo_poolable_itm { - public Sample_poolable_itm(int pool_idx, Object[] make_args) {this.pool_idx = pool_idx; this.pool__make_args = make_args;} + private Gfo_poolable_mgr pool_mgr; + public Sample_poolable_itm(Gfo_poolable_mgr pool_mgr, int pool_idx, Object[] make_args) {this.pool_mgr = pool_mgr; this.pool_idx = pool_idx; this.pool__make_args = make_args;} public int Pool__idx() {return pool_idx;} private final int pool_idx; public Object[] Pool__make_args() {return pool__make_args;} private final Object[] pool__make_args; public Object[] Pool__clear_args() {return pool__clear_args;} private Object[] pool__clear_args; public void Pool__clear (Object[] args) {this.pool__clear_args = args;} - public Gfo_poolable_itm Pool__make (int idx, Object[] args) {return new Sample_poolable_itm(idx, args);} + public void Pool__rls() {pool_mgr.Rls_safe(pool_idx);} + public Gfo_poolable_itm Pool__make (Gfo_poolable_mgr mgr, int idx, Object[] args) {return new Sample_poolable_itm(pool_mgr, idx, args);} } diff --git a/400_xowa/src/gplx/dbs/Db_diff_bldr.java b/400_xowa/src/gplx/dbs/Db_diff_bldr.java new file mode 100644 index 000000000..ab6de8ed5 --- /dev/null +++ b/400_xowa/src/gplx/dbs/Db_diff_bldr.java @@ -0,0 +1,54 @@ +/* +XOWA: the XOWA Offline Wiki Application +Copyright (C) 2012 gnosygnu@gmail.com + +This program is free software: you can redistribute it and/or modify +it under the terms of the GNU Affero General Public License as +published by the Free Software Foundation, either version 3 of the +License, or (at your option) any later version. + +This program is distributed in the hope that it will be useful, +but WITHOUT ANY WARRANTY; without even the implied warranty of +MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +GNU Affero General Public License for more details. + +You should have received a copy of the GNU Affero General Public License +along with this program. If not, see . +*/ +package gplx.dbs; import gplx.*; +import gplx.dbs.metas.*; import gplx.dbs.sqls.*; +class Db_diff_bldr { + private final Bry_bfr bfr = Bry_bfr.new_(); + private final Db_sqlbldr__sqlite sql_bldr = new Db_sqlbldr__sqlite(); + public Db_diff_bldr() {sql_bldr.Bfr_(bfr);} + public String Compare_db(String src_str, String trg_str) { +// Io_url src_url = Io_url_.new_fil_(src_str); +// Io_url trg_url = Io_url_.new_fil_(trg_str); +// Db_conn src_conn = Db_conn_bldr.Instance.Get_or_new(src_url).Conn(); +// Db_conn trg_conn = Db_conn_bldr.Instance.Get_or_new(trg_url).Conn(); + Meta_tbl_mgr src_tbls = new Meta_tbl_mgr(); + Meta_tbl_mgr trg_tbls = new Meta_tbl_mgr(); + return Compare_tbls(src_tbls, trg_tbls); + } + public String Compare_tbls(Meta_tbl_mgr src_tbls, Meta_tbl_mgr trg_tbls) { + int src_len = src_tbls.Len(); + for (int i = 0; i < src_len; ++i) { + Meta_tbl_itm src_tbl = src_tbls.Get_at(i); + Meta_tbl_itm trg_tbl = trg_tbls.Get_by(src_tbl.Name()); + if (trg_tbl == null) Tbl_delete(src_tbl); + } + int trg_len = trg_tbls.Len(); + for (int i = 0; i < trg_len; ++i) { + Meta_tbl_itm trg_tbl = src_tbls.Get_at(i); + Meta_tbl_itm src_tbl = trg_tbls.Get_by(trg_tbl.Name()); + if (src_tbl == null) Tbl_create(trg_tbl); + } + return bfr.To_str_and_clear(); + } + private void Tbl_delete(Meta_tbl_itm tbl) { + bfr.Add_str_a7("DROP TABLE ").Add_str_u8(tbl.Name()).Add_byte_nl(); + } + private void Tbl_create(Meta_tbl_itm tbl) { +// sql_bldr.Bld_create_tbl(tbl); + } +} diff --git a/400_xowa/src/gplx/langs/gfs/Gfs_msg_bldr.java b/400_xowa/src/gplx/langs/gfs/Gfs_msg_bldr.java index 9922c530a..30ffe966d 100644 --- a/400_xowa/src/gplx/langs/gfs/Gfs_msg_bldr.java +++ b/400_xowa/src/gplx/langs/gfs/Gfs_msg_bldr.java @@ -16,6 +16,7 @@ You should have received a copy of the GNU Affero General Public License along with this program. If not, see . */ package gplx.langs.gfs; import gplx.*; import gplx.langs.*; +import gplx.core.gfo_regys.*; public class Gfs_msg_bldr implements GfoMsgParser { private final Gfs_parser parser = new Gfs_parser(); public GfoMsg ParseToMsg(String s) {return Bld(s);} diff --git a/400_xowa/src/gplx/langs/htmls/Html_bldr_.java b/400_xowa/src/gplx/langs/htmls/Html_bldr_.java index 213c8a9fa..bd8f3ae9c 100644 --- a/400_xowa/src/gplx/langs/htmls/Html_bldr_.java +++ b/400_xowa/src/gplx/langs/htmls/Html_bldr_.java @@ -23,8 +23,11 @@ public class Html_bldr_ { , Bry__a_lhs_w_href = Bry_.new_a7("") , Bry__id__1st = Bry_.new_a7(" id=\"") , Bry__id__nth = Bry_.new_a7("\" id=\"") + , Bry__cls__1st = Bry_.new_a7(" class=\"") , Bry__cls__nth = Bry_.new_a7("\" class=\"") , Bry__title__nth = Bry_.new_a7("\" title=\"") , Bry__alt__nth = Bry_.new_a7("\" alt=\"") diff --git a/400_xowa/src/gplx/langs/htmls/Html_tag_.java b/400_xowa/src/gplx/langs/htmls/Html_tag_.java index 890e96a68..171044e0b 100644 --- a/400_xowa/src/gplx/langs/htmls/Html_tag_.java +++ b/400_xowa/src/gplx/langs/htmls/Html_tag_.java @@ -31,6 +31,9 @@ public class Html_tag_ { , Id__span = 8 , Id__div = 9 , Id__img = 10 + , Id__ul = 11 + , Id__li = 12 + , Id__p = 13 ; public static final byte[] Bry__a = Bry_.new_a7("a") @@ -47,6 +50,24 @@ public class Html_tag_ { .Add_str_int("div" , Id__div) .Add_str_int("img" , Id__img) ; + public static String To_str(int tid) { + switch (tid) { + case Id__eos: return "EOS"; + case Id__any: return "any"; + case Id__unknown: return "unknown"; + case Id__comment: return "comment"; + case Id__h2: return "h2"; + case Id__h3: return "h2"; + case Id__h4: return "h2"; + case Id__h5: return "h2"; + case Id__h6: return "h2"; + case Id__a: return "a"; + case Id__span: return "span"; + case Id__div: return "div"; + case Id__img: return "img"; + default: throw Err_.new_unhandled(tid); + } + } public static final byte[] Br_inl = Bry_.new_a7("
") , Hr_inl = Bry_.new_a7("
") diff --git a/400_xowa/src/gplx/langs/htmls/Html_utl.java b/400_xowa/src/gplx/langs/htmls/Html_utl.java index 7615fe73c..e49eb3e77 100644 --- a/400_xowa/src/gplx/langs/htmls/Html_utl.java +++ b/400_xowa/src/gplx/langs/htmls/Html_utl.java @@ -177,4 +177,5 @@ public class Html_utl { } return bfr.To_bry_and_clear(); } + public static String Replace_apos(String s) {return String_.Replace(s, "'", "\"");} } diff --git a/400_xowa/src/gplx/langs/htmls/Html_utl_tst.java b/400_xowa/src/gplx/langs/htmls/Html_utl_tst.java index b98e34c95..22713df7b 100644 --- a/400_xowa/src/gplx/langs/htmls/Html_utl_tst.java +++ b/400_xowa/src/gplx/langs/htmls/Html_utl_tst.java @@ -18,7 +18,7 @@ along with this program. If not, see . package gplx.langs.htmls; import gplx.*; import gplx.langs.*; import org.junit.*; public class Html_utl_tst { - @Before public void init() {fxt.Clear();} private Html_atr_cls_fxt fxt = new Html_atr_cls_fxt(); + @Before public void init() {fxt.Clear();} private Html_atr_class_fxt fxt = new Html_atr_class_fxt(); @Test public void Basic() {fxt.Test_del_comments("ac" , "ac");} @Test public void Bgn_missing() {fxt.Test_del_comments("a b c" , "a b c");} @Test public void End_missing() {fxt.Test_del_comments("a