Futurescale, Inc. PureMVC Home

The PureMVC Framework Code at the Speed of Thought


Over 10 years of community discussion and knowledge are maintained here as a read-only archive.

New discussions should be taken up in issues on the appropriate projects at https://github.com/PureMVC

Pages: [1]
Print
Author Topic: Q: Best practice, where to store constants?  (Read 3394 times)
eco_bach
Courseware Beta
Sr. Member
***
Posts: 81


View Profile Email
« on: August 10, 2009, 06:04:51 »


Constants used by notifications that are mapped to commands, and might be used by more than one mediator, I store  in the Appplication Facade.

Other constants NOT mapped to any commands, I keep in the relevant view component. The latter would be used in both events dispatched by the component as well as the component's mediator.

Can anyone share their rationale for storing public constants and-or provide feedback on whether the above is recommended?
 
Logged
Jason MacDonald
Sr. Member
****
Posts: 243


View Profile Email
« Reply #1 on: August 11, 2009, 06:03:07 »

I store all my constants in a seperate constants file with the exception of notifications sent by proxies, which are stored in the proxies themseleves.
Logged
Pages: [1]
Print