For Global value, can I use static variable ?

Shing Hing Man 写道:
It works using symbol. Thanks!
The following is what I have done.

Add the following to  AppModule.java :

  public static void contributeApplicationDefaults(
            MappedConfiguration<String, String>
configuration)
{ configuration.add("tempDir",
"/tmp/tapestry5/");
    }


In a Tapestry page, to retrieve the value for
'tempDir' :
 @Inject
 private SymbolSource symbolSource;

 symbolSource.expandSymbols("${tempDir}");


Shing

--- Robert Zeigler <[EMAIL PROTECTED]> wrote:

how about contributing your key/value pair to the
application defaults, and resolving your meta information later
via symbols?

Robert

On Aug 11, 2007, at 6:14 AM, Shing Hing Man wrote:

In T4, I can use <meta> tag in .application to
specify a global meta key/value pair.
How can this be done in T5 ?

Thanks in advance for any assistance!

Shing

Home page : http://www.lombok.demon.co.uk/



___________________________________________________________
Yahoo! Answers - Got a question? Someone out there
knows the
answer. Try it
now.
http://uk.answers.yahoo.com/


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



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




Home page : http://www.lombok.demon.co.uk/



      ___________________________________________________________
Yahoo! Answers - Got a question? Someone out there knows the answer. Try it
now.
http://uk.answers.yahoo.com/
---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




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

Reply via email to