Hi,

Thanks for the help, but I went for a non static method in the end:

    /**
     * @return Returns the sTATUS_ONGOING.
     */
    public String getSTATUS_ONGOING() {
        return STATUS_ONGOING;
    }

which works with the following JSP/JSTL

  <c:if test="${displayCase.caseStatus == displayCase.STATUS_FULFILLED}" >
    then it be draft etc....
 </c:if>

I don't like being forced to use capitals in my bean getXXX() but it looks right in 
the JSP I guess



-----Original Message-----
From: Paul McCulloch [mailto:[EMAIL PROTECTED]
Sent: 20 October 2004 15:32
To: 'Struts Users Mailing List'
Subject: RE: Bean Constants and JSP EL


See http://marc.theaimsgroup.com/?l=struts-user&m=109636066026332&w=2

> -----Original Message-----
> From: Robin Mannering [mailto:[EMAIL PROTECTED]
> Sent: Wednesday, October 20, 2004 3:21 PM
> To: [EMAIL PROTECTED]
> Subject: Bean Constants and JSP EL
> 
> 
> Hi,
> 
> Wondering if anyone has encountered this before and perhaps  
> a solution :)
> 
> I have constants defined in a regular Java bean class. ie.
> 
>     public static final String STATUS_DRAFT = "draft";
> 
> The bean has request scope in the page, no problem there, but 
> I can't reference this constant value using EL, ie.
> 
> ${myObject.STATUS_DRAFT}
> 
> Does anyone know how I can do this perhaps using a struts 
> tag, I'm miffed.  Have already tried adding gettters by they 
> are of course static and so don't work.
> 
> Any ideas would be great.
> 
> Many thanks
> 
> Robin
> 
> 
> 
> ====================================================================
> This e-mail and any attachments may be confidential and/or legally
> privileged. If you have received this e-mail and you are not a named
> addressee, please inform Landmark Information Group on 01491 413030
> and then delete the e-mail from your system. If you are not a named
> addressee you must not use, disclose, distribute, copy, print or rely 
> on this e-mail. This email and any attachments have been scanned for
> viruses and to the best of our knowledge are clean. To ensure 
> regulatory compliance and for the protection of our clients and 
> business, we may monitor and read e-mails sent to and from our 
> servers.
> 
> 
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: [EMAIL PROTECTED]
> For additional commands, e-mail: [EMAIL PROTECTED]
> 


**********************************************************************
Axios Email Confidentiality Footer
Privileged/Confidential Information may be contained in this message. If you are not 
the addressee indicated in this message (or responsible for delivery of the message to 
such person), you may not copy or deliver this message to anyone. In such case, you 
should destroy this message, and notify us immediately. If you or your employer does 
not consent to Internet email messages of this kind, please advise us immediately. 
Opinions, conclusions and other information expressed in this message are not given or 
endorsed by my Company or employer unless otherwise indicated by an authorised 
representative independent of this message.
WARNING:
While Axios Systems Ltd takes steps to prevent computer viruses from being transmitted 
via electronic mail attachments we cannot guarantee that attachments do not contain 
computer virus code.  You are therefore strongly advised to undertake anti virus 
checks prior to accessing the attachment to this electronic mail.  Axios Systems Ltd 
grants no warranties regarding performance use or quality of any attachment and 
undertakes no liability for loss or damage howsoever caused.
**********************************************************************


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]


====================================================================
This e-mail and any attachments may be confidential and/or legally
privileged. If you have received this e-mail and you are not a named
addressee, please inform Landmark Information Group on 01491 413030
and then delete the e-mail from your system. If you are not a named
addressee you must not use, disclose, distribute, copy, print or rely 
on this e-mail. This email and any attachments have been scanned for
viruses and to the best of our knowledge are clean. To ensure 
regulatory compliance and for the protection of our clients and 
business, we may monitor and read e-mails sent to and from our 
servers.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to