public static boolean containsStatus(final Status status, final Status[] statusArray) {
    if (status == null) {
      return false;
    }

    for (Status currentStatus : statusArray) {
      if (currentStatus == status) {
        return true;
      }
    }

    return false;
  }
public static boolean containsStatus ( final Status status , final Status [ ] statusArray ) { if ( status == null ) { return false ; } for ( Status currentStatus : statusArray ) { if ( currentStatus == status ) { return true ; } } return false ; }
Checks whether a given status is contained in an array of status.
@param status the status to be looked for
@param statusArray the status array.
@return true if the given status is contained in the array.