[rfc][icedtea-web] PolicyEditor gains a real parser

Andrew Azores aazores at redhat.com
Fri Dec 26 19:09:26 UTC 2014


Hi all,

Long time no see!

I started this patch several months ago, but my school work became far 
too heavy and I had to put off any further work to finish off this 
patch. Today I've managed to finish it to a point that I think it's 
worth submitting for review.

It's a big, long patch, so review will probably take quite some time, 
and may be difficult at times. I know I've appeared to be completely 
gone for many weeks, but I have actually been checking on my emails 
fairly often, just haven't had time to reply to any patch reviews. But 
right now I should have at least a few weeks before school really picks 
back up again.

The gist of this patch is basically that I discovered that policytool's 
parser is actually available to use without any dirty reflection hacks 
or anything like that, but it's hidden away and not really documented, 
and is marked as an internal API. But it's open and so I think the worst 
case scenario if it's removed later is that we just fork and maintain an 
older copy. It's much easier and IMHO smarter than writing a whole new 
parser from scratch to duplicate the one that policytool uses, anyhow. 
This patch just rips out the old, crappy code that used horrible regex 
to try to parse policy files, and plops in the policytool parser 
instead. Anything else pretty much comes down to reconciling the 
existing PolicyEditor code and structures with the new ones that the 
parser gives and expects.

Nice side effect: all policyeditor tests now pass, even the tricky 
comments handling ones ;)

Thanks,
-- 
Andrew Azores
-------------- next part --------------
A non-text attachment was scrubbed...
Name: policyeditor-real-parser.patch
Type: text/x-patch
Size: 184390 bytes
Desc: not available
URL: <http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20141226/d84f7762/policyeditor-real-parser-0001.patch>


More information about the distro-pkg-dev mailing list