Hi all...
I have several modules, each of them with configurations, set of
preloaded data...
I've created a "moduleManager", with "domain methods" callable also from
other modules.
Some of them, are basically only configurations, loaded from JCR,
database, running classes...
How can I register my class to be used as Singleton?
I need this class to be created when Magnolia start and maybe updated /
destroyed / recreated some time (scheduler, maybe, or on my request).
SCENARIO:
I have a NewsManager which load from JCR news categories and stores them
within an Array, with a getCategories() public method.
I need this array everytime I want to load categories on the front-end
(editing, update, viewing, menus...).
So, I would like to call NewsManager.getInstance().getCategories()
whenever I want but I don't want to go down on JCR everytime.
I've manage this with standard Singletons, but I've heard that Magnolia
has its own way to manage singletons, isn't it?
Matteo
----------------------------------------------------------------
For list details see
http://www.magnolia-cms.com/home/community/mailing-lists.html
To unsubscribe, E-mail to: <[email protected]>
----------------------------------------------------------------