From a5cbc4ede9aa05e8e9589f75141e54993fbfdf74 Mon Sep 17 00:00:00 2001 From: gnosygnu Date: Mon, 17 Feb 2020 08:42:25 -0500 Subject: [PATCH] ParserFunctions: Add constructor for future use [#661] --- .../src/gplx/xowa/xtns/pfuncs/times/Dbx_strtotime_tst.java | 4 ++-- 400_xowa/src/gplx/xowa/xtns/pfuncs/times/Pxd_parser.java | 5 +++++ 2 files changed, 7 insertions(+), 2 deletions(-) diff --git a/400_xowa/src/gplx/xowa/xtns/pfuncs/times/Dbx_strtotime_tst.java b/400_xowa/src/gplx/xowa/xtns/pfuncs/times/Dbx_strtotime_tst.java index 50b13ff0d..4af475a4b 100644 --- a/400_xowa/src/gplx/xowa/xtns/pfuncs/times/Dbx_strtotime_tst.java +++ b/400_xowa/src/gplx/xowa/xtns/pfuncs/times/Dbx_strtotime_tst.java @@ -90,7 +90,7 @@ class Dbx_strtotime_fxt { // private String fmt, tz; // public Dbx_strtotime_fxt() { // Btrie_slim_mgr trie = Pxd_parser_.Trie(); -// Dbx_scan_support.Init(trie); +// Dbx_scan_support.Init(trie); // } // public Dbx_strtotime_fxt Init__format() {return Init__format("yyyy-MM-dd'T'HH:mm:ssZ", "CET");} // public Dbx_strtotime_fxt Init__format(String fmt) {return Init__format(fmt, "UTC");} @@ -104,7 +104,7 @@ class Dbx_strtotime_fxt { // public void Test__date(String raw, String expd) { // DateAdp date = Dbx_scan_support.Parse(Bry_.new_u8(raw)); // Gftest.Eq__str(expd, date.XtoStr_fmt_iso_8561()); -// } +// } // public void Test__strtotime__ary(String[] raw, String[] expd) { // int len = raw.length; // String[] actl = new String[len]; diff --git a/400_xowa/src/gplx/xowa/xtns/pfuncs/times/Pxd_parser.java b/400_xowa/src/gplx/xowa/xtns/pfuncs/times/Pxd_parser.java index 39b89eee1..fb2eddac8 100644 --- a/400_xowa/src/gplx/xowa/xtns/pfuncs/times/Pxd_parser.java +++ b/400_xowa/src/gplx/xowa/xtns/pfuncs/times/Pxd_parser.java @@ -15,6 +15,7 @@ Apache License: https://github.com/gnosygnu/xowa/blob/master/LICENSE-APACHE2.txt */ package gplx.xowa.xtns.pfuncs.times; import gplx.*; import gplx.xowa.*; import gplx.xowa.xtns.*; import gplx.xowa.xtns.pfuncs.*; import gplx.core.brys.*; import gplx.core.brys.fmtrs.*; import gplx.core.btries.*; import gplx.core.log_msgs.*; +import gplx.xowa.parsers.*; class Pxd_parser { private final Btrie_rv trv = new Btrie_rv(); private byte[] src; int cur_pos, tkn_bgn_pos, src_len, tkn_type; @@ -25,6 +26,10 @@ class Pxd_parser { public int Colon_count; public int[] Seg_idxs() {return seg_idxs;} private int[] seg_idxs = new int[DateAdp_.SegIdx__max]; // temp ary for storing current state public byte[] Src() {return src;} +// public Pxd_parser(Xop_ctx ctx) { +// this.trie = Pxd_parser_.Trie(ctx); +// Dbx_scan_support.Init(trie); +// } public boolean Seg_idxs_chk(int... ary) { int len = ary.length; for (int i = 0; i < len; i++)