java - Single used class vs. 'static class' -


i have program handles different objects have own sort of instructions set (say own program), , main class want run these programs. have 2 choices:

  • make class instructionhandler, create instance of in main class , pass requests 1 object [singleton pattern - mark peters]
  • make class instructionhandler static methods , make use of these in main class

what way go software - design point of view?

have considered using interpreter pattern? can instruction sets combined each of objects create kind of grammar?


Comments

Popular posts from this blog

Add email recipient to all new Trac tickets -

400 Bad Request on Apache/PHP AddHandler wrapper -

php - Change action and image src url's with jQuery -