Simplicity: it's just an @Inject.

On Mon, Oct 25, 2010 at 2:55 AM, SudhirJava <sudhi...@gmail.com> wrote:
>
> Struts Constants.
> I can define in web.xml and get the value in Action class too.
> Then what is the use of Struts Constants?
>
>
> ~SK
>
>
> Maurizio Cucchiara wrote:
>>
>> I'm not sure what you mean.
>> What's the benefit of inversion of control? or struts constant?
>>
>> 2010/10/25 SudhirJava <sudhi...@gmail.com>:
>>>
>>> Can anybody please tell me
>>> What is the Benefit of this ?
>>> I can define it in web.xml can retrieve it.
>>>
>>> What is the main purpose of this??
>>>
>>>
>>> ~SK
>>>
>>>
>>> SudhirJava wrote:
>>>>
>>>> Thanks.
>>>> That works...
>>>>
>>>> I think it should be value instead of name
>>>> i.e.
>>>> @Inject(value="myConstant")
>>>> instead of
>>>> @Inject(name="myConstant")
>>>>
>>>>
>>>> ~SK
>>>>
>>>>
>>>> rahulmohan wrote:
>>>>>
>>>>> Just put an @Inject(name="MYCONSTANTVARIABLE") annotation on the setter
>>>>> in
>>>>> action class.
>>>>>
>>>>> - RM
>>>>>
>>>>>
>>>>>
>>>>> From:
>>>>> SudhirJava <sudhi...@gmail.com>
>>>>> To:
>>>>> user@struts.apache.org
>>>>> Date:
>>>>> 21-10-2010 17:58
>>>>> Subject:
>>>>> How to get the value of Constants defined in struts.xml
>>>>>
>>>>>
>>>>>
>>>>>
>>>>> I am sorry, if this thread is repeated.
>>>>>
>>>>> Please tell tell me how get the value of Constants defined in
>>>>> struts.xml.
>>>>> Is it possible to get the value of "MYCONSTANTVARIABLE" in action
>>>>> class.
>>>>> <constant name="MYCONSTANTVARIABLE" value="MYCONSTANTVALUE" />
>>>>>
>>>>>
>>>>>
>>>>> Thanks
>>>>> Sudhir
>>>>> --
>>>>> View this message in context:
>>>>> http://old.nabble.com/How-to-get-the-value-of-Constants-defined-in-struts.xml-tp30019022p30019022.html
>>>>>
>>>>> Sent from the Struts - User mailing list archive at Nabble.com.
>>>>>
>>>>>
>>>>> ---------------------------------------------------------------------
>>>>> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
>>>>> For additional commands, e-mail: user-h...@struts.apache.org
>>>>>
>>>>>
>>>>>
>>>>> =====-----=====-----=====
>>>>> Notice: The information contained in this e-mail
>>>>> message and/or attachments to it may contain
>>>>> confidential or privileged information. If you are
>>>>> not the intended recipient, any dissemination, use,
>>>>> review, distribution, printing or copying of the
>>>>> information contained in this e-mail message
>>>>> and/or attachments to it are strictly prohibited. If
>>>>> you have received this communication in error,
>>>>> please notify us by reply e-mail or telephone and
>>>>> immediately and permanently delete the message
>>>>> and any attachments. Thank you
>>>>>
>>>>>
>>>>>
>>>>>
>>>>
>>>>
>>>
>>> --
>>> View this message in context:
>>> http://old.nabble.com/How-to-get-the-value-of-Constants-defined-in-struts.xml-tp30019022p30044983.html
>>> Sent from the Struts - User mailing list archive at Nabble.com.
>>>
>>>
>>> ---------------------------------------------------------------------
>>> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
>>> For additional commands, e-mail: user-h...@struts.apache.org
>>>
>>>
>>
>>
>>
>> --
>> Maurizio Cucchiara
>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
>> For additional commands, e-mail: user-h...@struts.apache.org
>>
>>
>>
>
> --
> View this message in context: 
> http://old.nabble.com/How-to-get-the-value-of-Constants-defined-in-struts.xml-tp30019022p30045254.html
> Sent from the Struts - User mailing list archive at Nabble.com.
>
>
> ---------------------------------------------------------------------
> To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
> For additional commands, e-mail: user-h...@struts.apache.org
>
>

---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscr...@struts.apache.org
For additional commands, e-mail: user-h...@struts.apache.org

Reply via email to