Hi everybody, I'm basically starting to learn T5 all over again. I'm trying to implement an AccessController based on Chris Lewis' articles and have hit a roadblock. http://wiki.apache.org/tapestry/Tapestry5HowToCreateADispatcher Dispatcher1 http://wiki.apache.org/tapestry/Tapestry5HowToCreateADispatcher2 Dispatcher2
I can't seem to access the requestGlobals Service in either the dispatcher or any of the User classes. I've tried adding the following to each of the classes: @Inject @Service("RequestGlobals") private RequestGlobals requestGlobals; Inside the dispatcher I try to create a UserPermissions object. This object requires things from the session and request. I thought I would try to inject the requestGlobals into the UserPermissions class. The reason I need the RequestGlobals service is that Request does not contain the remote IP address of the current request, only the HttpServletRequest object does. Each time this results in a null value for requestGlobals. According to the wiki, "RequestGlobals" is a readily available service I should just be able to inject into any other page. Am I interpreting this wrong? Is there something I need to do in the AppModule class in order to make the RequestGlobals service available to my classes? Thanks, Michael btw, I've uploaded a copy of my "UserPermissions" class ( its called UserSettings now) for reference. http://www.nabble.com/file/p16495148/UserSettings.java UserSettings.java -- View this message in context: http://www.nabble.com/accessing-requestglobals-inside-dispatcher-and-other-data-support-classes-tp16495148p16495148.html Sent from the Tapestry - User mailing list archive at Nabble.com. --------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]