webtier@glassfish.java.net

Re: Best way to access javax.faces.PROJECT_STAGE in a Filter?

From: Lincoln Baxter, III <lincolnbaxter_at_gmail.com>
Date: Sun, 3 Jan 2010 13:29:44 -0500

ProjectStage.Production.equals(factory.getApplication().getProjectStage() ?

Would that be appropriate?

On Sun, Jan 3, 2010 at 1:11 PM, Lincoln Baxter, III
<lincolnbaxter_at_gmail.com> wrote:
> Question:
>
> FacesContext.getCurrentInstance().getApplication().getProjectStage()
> is the normal way to get a hold of the ProjectStage... however, in a
> Filter, FacesContext is not available (unless you build it.) What is
> the preferred way to access the project stage in a Servlet Filter?
>
> Thanks.
> Lincoln
>