Skip to main content
summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java7
1 files changed, 7 insertions, 0 deletions
diff --git a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java
index 9a2daf6b35b..a307c4c9409 100644
--- a/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java
+++ b/plugins/org.eclipse.osee.framework.core/src/org/eclipse/osee/framework/core/util/Conditions.java
@@ -94,6 +94,13 @@ public final class Conditions {
}
}
+ public static void checkNotNullOrEmpty(Object[] array, String objectName) throws OseeCoreException {
+ checkNotNull(array, objectName);
+ if (array.length <= 0) {
+ throw new OseeArgumentException("%s cannot be empty", objectName);
+ }
+ }
+
public static void checkNotNullOrEmpty(Collection<? extends Object> collection, String objectName) throws OseeCoreException {
checkNotNull(collection, objectName);
if (collection.isEmpty()) {

Back to the top