Re: Re: Is this an 'ok' way to setup commonly used collections??
[email protected] Wed, 28 May 2003 15:49:42 +1000
| Newsgroups | gmane.comp.java.mvc.devel |
|---|---|
| Message-ID | <OF9136D550.E6DFA6A4-ONCA256D34.001FFD36-CA256D34.001FBAB2@multitask.com.au> |
Not too sure if it is too much of an overhead. -- Kristen Gillard Multitask Consulting Pty Ltd Lvl 8, 20 Loftus Street, Circular Quay, NSW, 2000 -- Ph: 61-2-9252-1462 Fx: 61-2-9252-4636 Mo: 0409-000-123 -- http://www.multitask.com.au/ "Rick Reumann" <[email protected]> Sent by: [email protected] 27/05/2003 01:36 PM Please respond to [email protected] To [email protected] cc Subject Re: [MVC-Programmers] Re: Is this an 'ok' way to setup commonly used collections?? On Fri, 23 May 2003 14:59:18 +1000, kriste wrote: > You can get the servlet context by just using getServletContext() in your > servlet... you shouldn't need to declare as a (private class variable) it > as it is derived from the super class. Right, I understand that. I just thought it was less overhead rather than calling, over and over again in my servlet ... getServletContext().setAttribute("someThing"), to first get the HttpServletContext as a variable and then populate all the attributes ie: ServletContext servletContext = getServletContext(); servletContext.setAttribute("itGroups", itGroups ); servletContext.setAttribute("projectPriorities", projectPriorities ); servletContext.setAttribute("projectStatus", projectStatus ); I guess I'm just being picky:) I'm sure calling getServletContext() in each of the above cases isn't that big of a deal. -- Rick _______________________________________________ MVC-Programmers mailing list [email protected] http://www.basebeans.net:8080/mailman/listinfo/mvc-programmers