[forge-dev] Create a ResourceBundle.

George Gastaldi ggastald at redhat.com
Fri May 2 12:16:37 EDT 2014


I see. 
In this case it would be better to have an interface (eg. GitConstants) and add the constants there. I don't think a ResourceBundle would be of good use in this case.

Best Regards,

George

> Em 02/05/2014, às 13:03, Daniel Cunha <danielsoro at gmail.com> escreveu:
> 
> The ResourceBundle is a alternative, but I can to create a Class that share this values.
> 
> With:
> I have 2 files: [1][2]
> I need to create a two static final String GIT_DICTORY = ".git" per file.
> 
> 1) I can remove all static final string in my code (Code more clean)
> 2) I don't need duplicate this string in any files. I use a unique reference and I can to do a import static, with this: [3]
> 
> WDYT?
> 
> [1]https://github.com/danielsoro/core/blob/afaf5e620bbebc3b50dc7e656e3b02cf4f04f8c9/git/impl/src/main/java/org/jboss/forge/addon/git/facet/GitFacetImpl.java
> [2]https://github.com/danielsoro/core/blob/afaf5e620bbebc3b50dc7e656e3b02cf4f04f8c9/git/impl/src/main/java/org/jboss/forge/addon/git/facet/GitIgnoreFacetImpl.java
> [3]https://github.com/forge/core/blob/15a264c9392063b1d18ef8ec494a7884b340cb40/scaffold/spi/src/main/java/org/jboss/forge/addon/scaffold/metawidget/inspector/ForgeInspector.java
> 
> 
>> On Fri, May 2, 2014 at 12:52 PM, George Gastaldi <ggastald at redhat.com> wrote:
>> Hi Daniel,
>> Welcome! Thanks again for your contribution.
>> 
>> Why do you think a ResourceBundle would be a better choice?  I don't see where i18n could be used there.
>> 
>> Best Regards,
>> George
>> 
>>> Em 02/05/2014, às 12:48, Daniel Cunha <danielsoro at gmail.com> escreveu:
>>> 
>>> Hi guys,
>>> 
>>> My name is Daniel and I'm newbie here and I hope help the project with something.
>>> I looked code and I see that exists many string references, with git directory: ".git"
>>> 
>>> I sent a PR yesterday [1], but I thought in other solution. Create a ResourceBundle.
>>> 
>>> WDYT? 
>>> 
>>> [1] https://github.com/forge/core/commit/3cfa43168ac5486882b52dea32e8096b55b258fe
>>> 
>>> -- 
>>> Att;
>>> Daniel Cunha (soro)
>>> _______________________________________________
>>> forge-dev mailing list
>>> forge-dev at lists.jboss.org
>>> https://lists.jboss.org/mailman/listinfo/forge-dev
>> 
>> _______________________________________________
>> forge-dev mailing list
>> forge-dev at lists.jboss.org
>> https://lists.jboss.org/mailman/listinfo/forge-dev
> 
> 
> 
> -- 
> Att;
> Daniel Cunha (soro)
> _______________________________________________
> forge-dev mailing list
> forge-dev at lists.jboss.org
> https://lists.jboss.org/mailman/listinfo/forge-dev
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.jboss.org/pipermail/forge-dev/attachments/20140502/77a47b96/attachment-0001.html 


More information about the forge-dev mailing list