Last change
on this file since 507 was 507, checked in by George Lilly, 15 years ago |
NHIN gateway and adaptor for use on linux with VistA EHR and RPMS
|
File size:
825 bytes
|
Rev | Line | |
---|
[507] | 1 | /*
|
---|
| 2 | * To change this template, choose Tools | Templates
|
---|
| 3 | * and open the template in the editor.
|
---|
| 4 | */
|
---|
| 5 | package gov.hhs.fha.nhinc.nhinclib;
|
---|
| 6 |
|
---|
| 7 | import java.util.List;
|
---|
| 8 |
|
---|
| 9 | /**
|
---|
| 10 | *
|
---|
| 11 | * @author rayj
|
---|
| 12 | */
|
---|
| 13 | public class NullChecker {
|
---|
| 14 |
|
---|
| 15 | public static boolean isNullish(String value) {
|
---|
| 16 | boolean result = false;
|
---|
| 17 | if ((value == null) || (value.contentEquals(""))) {
|
---|
| 18 | result = true;
|
---|
| 19 | }
|
---|
| 20 | return result;
|
---|
| 21 | }
|
---|
| 22 | public static boolean isNotNullish(String value) {
|
---|
| 23 | return (!isNullish(value));
|
---|
| 24 | }
|
---|
| 25 |
|
---|
| 26 | public static boolean isNullish(List value) {
|
---|
| 27 | boolean result = false;
|
---|
| 28 | if ((value == null) || (value.size() == 0)) {
|
---|
| 29 | result = true;
|
---|
| 30 | }
|
---|
| 31 | return result;
|
---|
| 32 | }
|
---|
| 33 | public static boolean isNotNullish(List value) {
|
---|
| 34 | return (!isNullish(value));
|
---|
| 35 | }
|
---|
| 36 |
|
---|
| 37 |
|
---|
| 38 | }
|
---|
Note:
See
TracBrowser
for help on using the repository browser.