vidakovic commented on code in PR #3321:
URL: https://github.com/apache/fineract/pull/3321#discussion_r1281109886


##########
fineract-core/src/main/java/org/apache/fineract/infrastructure/core/service/database/DatabaseType.java:
##########
@@ -19,5 +19,16 @@
 package org.apache.fineract.infrastructure.core.service.database;
 
 public enum DatabaseType {
-    MYSQL, POSTGRESQL
+
+    MYSQL, //
+    POSTGRESQL, //
+    ;
+
+    public boolean isMySql() {

Review Comment:
   Is there any added value of having these "convenience functions"? I think 
they hide more than they actually help... what happens if we add support for 10 
more databases? We have other examples in the code base where these things 
quickly went out of hand and people started adding all kind of functionality to 
enums... whereas these files should be really simple and readable. My 2 cents.
   Is a simple `MYSQL.equals(dbType)` so much worse (for me it's more 
readable... imagine static imports of those enums)?
   BTW: we should really use "equals" instead "==".



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to