From: Stefan B. <bo...@ap...> - 2015-02-21 20:34:50
|
No, I don't think I've seen that pattern used in the wild. If we wanted a singleton we could put it into DefaultComparisonFormatter. Thanks Stefan On 2015-02-21, Will Herrmann wrote: > I'm not sure that I've ever seen that design pattern before; having a public static final variable of a concrete implementation within an interface. There's the benefit of being a singleton to be sure, but it just seems like an odd construct to me especially since core Java never uses it. If we want to go that route, I think I'd prefer a static method (c.f. java.lang.Charset.defaultCharset()). Then again, interfaces can't have implementations. > Thanks, > -Will Herrmann > On Feb 19, 2015, at 5:54 AM, Stefan Bodewig <bo...@ap...> wrote: >> On 2015-02-18, Will Herrmann wrote: >>> I finally got a chance to make this change. I created a pull request for >>> GitHub. >> Many thanks. >>> I'm still new to open source stuff, so let me know if I missed >>> something about the procedure. >> All is fine. >> Harald's original ComparisonFormatter proposal had a static final >> ComparisonFormatter field (DEFAULT, I think) which contained a >> DefaultComparisonFormatter - ah, yes - >> https://github.com/xmlunit/xmlunit/commit/e457399addf2db7d399e2d06d07064d3bee5ca03#diff-417caeda82b46db9f1bafca5765b3ff4R26 >> I later removed it because I thought only Diff would need it. With your >> change maybe it is time to bring it back and use it from Difference and >> Comparison as well? >> Stefan > ------------------------------------------------------------------------------ > Download BIRT iHub F-Type - The Free Enterprise-Grade BIRT Server > from Actuate! Instantly Supercharge Your Business Reports and Dashboards > with Interactivity, Sharing, Native Excel Exports, App Integration & more > Get technology previously reserved for billion-dollar corporations, FREE > http://pubads.g.doubleclick.net/gampad/clk?id=190641631&iu=/4140/ostg.clktrk > _______________________________________________ > Xmlunit-general mailing list > Xml...@li... > https://lists.sourceforge.net/lists/listinfo/xmlunit-general |