ant-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Peter Donald <pe...@apache.org>
Subject Re: Default messages
Date Thu, 22 Nov 2001 08:07:30 GMT
On Thu, 22 Nov 2001 06:57, Edson Alves Pereira wrote:
>   Therere some places in Ants source that frases are hardcoded, i think
> that is better to create a main objeto to store messages to show to the
> user. Like:
>
> if (srcFile.lastModified() > now)
> {
>   log("Warning: file modified in the future: " +
>       files[i], Project.MSG_WARN);
> }
>
> to something like this:
>
> if (srcFile.lastModified() > now)
> {
>   log( JSysMsg.getMsg( JSysMsg.MODIFIED_FUTURE ),
>       files[i], Project.MSG_WARN );
> }
>
>   Maybe with that stuff we could make Ant multi language! Tell me what do
> you think!

I would like to go that direction in the future. However I do not think that 
putting all messages in one class is a good idea. There are a huge number of 
messages to store and that class would be massive. It is far superioir to 
store them in a properties file so it can be loaded from a ResourceBundle.

-- 
Cheers,

Pete

----------------------------------
Ancient Go proverb: "Only amateurs 
try to come up with 'fancy' moves"
----------------------------------

--
To unsubscribe, e-mail:   <mailto:ant-dev-unsubscribe@jakarta.apache.org>
For additional commands, e-mail: <mailto:ant-dev-help@jakarta.apache.org>


Mime
View raw message