Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » JFace » Factor out logic from Dialog?(Is it worth the effort factoring out that bit of logic from a Dialog?)
icon5.gif  Factor out logic from Dialog? [message #1712275] Thu, 22 October 2015 15:11
Stephan Druskat is currently offline Stephan DruskatFriend
Messages: 102
Registered: October 2011
Location: Berlin, Germany
Senior Member

I'm implementing a custom dialog for selecting workspaces in an RCP application (extends TitleAreaDialog).

The implementation is pretty straightforward, albeit, it includes some "logic". This is mainly (if you can call this logic at all?!?) reading from java.util.prefs.Preferences, knocking together String[] from these preferences to display in a combo box, a bit of file permissions checking, writing to Preferences.

Generally I'd like to keep my code clean, so was thinking about factoring out some of the afore-mentioned "logic". However, I'm unsure as to whether the refactoring would be worth it, especially since I'd probably just write all the procedural stuff into a util class, itself to be avoided.

The class itself is ~380 LOC, so not too big to be understandable.

Could I have some opinions on whether a refactoring would make sense, or even better, best practices/examples of how this could be done (avoiding a util class in the process)?

Many thanks!
Previous Topic:connected lists widget
Next Topic:64-bit applications don't respond when a 32-bit Java application displays a dialog in 64bit windows7
Goto Forum:
  


Current Time: Mon Nov 19 00:28:16 GMT 2018

Powered by FUDForum. Page generated in 0.02421 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top