[ofbiz-framework] branch trunk updated: Improved: Enforce noninstantiability to JobUtil Class. (#176)

Previous Topic Next Topic
 
classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

[ofbiz-framework] branch trunk updated: Improved: Enforce noninstantiability to JobUtil Class. (#176)

surajk
This is an automated email from the ASF dual-hosted git repository.

surajk pushed a commit to branch trunk
in repository https://gitbox.apache.org/repos/asf/ofbiz-framework.git


The following commit(s) were added to refs/heads/trunk by this push:
     new 65c2357  Improved: Enforce noninstantiability to JobUtil Class. (#176)
65c2357 is described below

commit 65c235704cf472a20b1ff51999ccb80040f369ec
Author: Suraj Khurana <[hidden email]>
AuthorDate: Wed Jun 3 16:08:49 2020 +0530

    Improved: Enforce noninstantiability to JobUtil Class. (#176)
   
    (OFBIZ-11749)
    Made class as final and added private constructor.
---
 .../service/src/main/java/org/apache/ofbiz/service/job/JobUtil.java    | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/framework/service/src/main/java/org/apache/ofbiz/service/job/JobUtil.java b/framework/service/src/main/java/org/apache/ofbiz/service/job/JobUtil.java
index 4d5c5a5..7f8b94e 100644
--- a/framework/service/src/main/java/org/apache/ofbiz/service/job/JobUtil.java
+++ b/framework/service/src/main/java/org/apache/ofbiz/service/job/JobUtil.java
@@ -26,9 +26,10 @@ import org.apache.ofbiz.entity.GenericValue;
 import org.apache.ofbiz.entity.transaction.GenericTransactionException;
 import org.apache.ofbiz.entity.transaction.TransactionUtil;
 
-public class JobUtil {
+public final class JobUtil {
 
     private static final String MODULE = JobUtil.class.getName();
+    protected JobUtil() { }
 
     public static void removeJob(GenericValue jobValue) {
         // always suspend the current transaction; use the one internally