190 }
191 }
192 return true;
193 }
194
195 static boolean isAlphaNumeric(char c) {
196 return isAlpha(c) || isNumeric(c);
197 }
198
199 public static boolean isAlphaNumericString(String s) {
200 int len = s.length();
201 for (int i = 0; i < len; i++) {
202 if (!isAlphaNumeric(s.charAt(i))) {
203 return false;
204 }
205 }
206 return true;
207 }
208
209 static boolean isEmpty(String str) {
210 return str == null || str.length() == 0;
211 }
212
213 static boolean isEmpty(Set<?> set) {
214 return set == null || set.isEmpty();
215 }
216
217 static boolean isEmpty(Map<?, ?> map) {
218 return map == null || map.isEmpty();
219 }
220
221 static boolean isEmpty(List<?> list) {
222 return list == null || list.isEmpty();
223 }
224 }
|
190 }
191 }
192 return true;
193 }
194
195 static boolean isAlphaNumeric(char c) {
196 return isAlpha(c) || isNumeric(c);
197 }
198
199 public static boolean isAlphaNumericString(String s) {
200 int len = s.length();
201 for (int i = 0; i < len; i++) {
202 if (!isAlphaNumeric(s.charAt(i))) {
203 return false;
204 }
205 }
206 return true;
207 }
208
209 static boolean isEmpty(String str) {
210 return str == null || str.isEmpty();
211 }
212
213 static boolean isEmpty(Set<?> set) {
214 return set == null || set.isEmpty();
215 }
216
217 static boolean isEmpty(Map<?, ?> map) {
218 return map == null || map.isEmpty();
219 }
220
221 static boolean isEmpty(List<?> list) {
222 return list == null || list.isEmpty();
223 }
224 }
|