update
This commit is contained in:
@@ -3,6 +3,21 @@ package com.mgm.mcrm;
|
||||
|
||||
public class TestRun {
|
||||
public static void main(String[] args) {
|
||||
|
||||
|
||||
Object[] arr = {"asdas", "null", 23, "asd", 's', 90L, 3.4F, 3.3};
|
||||
|
||||
System.out.println(nonNullAll(arr));
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
static boolean nonNullAll(Object ...arr) {
|
||||
if (arr == null) return false;
|
||||
|
||||
if (arr.length == 0) return false;
|
||||
|
||||
for (Object o : arr) {
|
||||
if (o == null) return false;
|
||||
}
|
||||
return true;
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user