N
news.t-com.hr
Is it better to define some constants this way and what are pros and cons ?
String[] currency = {"US","EUR"....};
or to do this
public enum CURRENCY{
CURR1("US"),
CURR2("EUR")....
;
String currency ;
public CURRENCY(String tmp){
currency = tmp;
}
public getCurrency(){
return currency;
}
}
__________ Information from ESET NOD32 Antivirus, version of virus signature database 4096 (20090522) __________
The message was checked by ESET NOD32 Antivirus.
http://www.eset.com
String[] currency = {"US","EUR"....};
or to do this
public enum CURRENCY{
CURR1("US"),
CURR2("EUR")....
;
String currency ;
public CURRENCY(String tmp){
currency = tmp;
}
public getCurrency(){
return currency;
}
}
__________ Information from ESET NOD32 Antivirus, version of virus signature database 4096 (20090522) __________
The message was checked by ESET NOD32 Antivirus.
http://www.eset.com