You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ofbiz.apache.org by jl...@apache.org on 2015/09/23 10:15:50 UTC
svn commit: r1704771 -
/ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtil.java
Author: jleroux
Date: Wed Sep 23 08:15:50 2015
New Revision: 1704771
URL: http://svn.apache.org/viewvc?rev=1704771&view=rev
Log:
Referring to the excellent answer at https://stackoverflow.com/questions/14231037/java-safevarargs-annotation-does-a-standard-or-best-practice-exist it's safe to put SafeVarargs annotation here (it's only used to iterate over the elements). I was curious about that
Modified:
ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtil.java
Modified: ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtil.java
URL: http://svn.apache.org/viewvc/ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtil.java?rev=1704771&r1=1704770&r2=1704771&view=diff
==============================================================================
--- ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtil.java (original)
+++ ofbiz/trunk/framework/entity/src/org/ofbiz/entity/util/EntityUtil.java Wed Sep 23 08:15:50 2015
@@ -53,6 +53,7 @@ public class EntityUtil {
public static final String module = EntityUtil.class.getName();
+ @SafeVarargs
public static <V> Map<String, V> makeFields(V... args) {
Map<String, V> fields = new HashMap<String, V>();
if (args != null) {