First of all - Happy new year!
2013 was very exiting year for mvcExpress framework! It evolved into version 2, and I see people using it more and more everywhere! I have a new year present for you.
I am adding new feature to mvcExpress, feature I like very much:
Idea is very simple – mediators should not be able to inject proxies, so by default mvcExpress will not allow it throwing an error if you try. But in some cases we want proxies in mediators(to avoid unnecessary commands, or just for convenience). In these cases you have to specifically allow proxy to be injected into mediators.
So basically this change keeps all options what you can do with proxies as before, but it trades some convenience for more control. And I think it is a good trade.
This is how you map proxies now:
proxyMap.map(proxyObject:Proxy, name:String = null, injectClass:Class = null, mediatorInjectClass:Class = null);
You can notice this function have changed a lot, and actually is not backward compatible. (Sorry about that, just change name with inject class in your code if you get an error then you compile your code.)
- name and injectClass parameter order switched. (more intuitive.)
- name is defaulted to null, null will be treated same as empty string.
- mediatorInjectClass parameter added. If it is set to null – this proxy will not be available for injection into proxies and will throw error. To enable it – just provide class you want your proxy to be injected into mediators as. (Best practice is to use get data only interface)
I also found and fixed lot of bugs with lazy proxies in this update, I rarely use those, so I missed it. Sorry.
mvcExpress logger is improved and updated to work with RC3 and up.
You can get RC3 from GitHub.
Thank you for your support and feedback! This gives me lot of motivation to continue working and improving the framework.
More and more people point out that mvcExpress lacks good learning material. I will focus on fixing that next year!