public static void printIfErrorsOccured(Context context) {
    if (context == null) {
      throw new IllegalArgumentException("Context argument cannot be null");
    }

    StatusManager sm = context.getStatusManager();
    if (sm == null) {
      ps.println("WARN: Context named \"" + context.getName()
          + "\" has no status manager");
    } else {
      StatusUtil statusUtil = new StatusUtil(context);
      if (statusUtil.getHighestLevel(0) == ErrorStatus.ERROR) {
        print(sm);
      }
    }
  }
public static void printIfErrorsOccured(Context context) {
    if (context == null) {
      throw new IllegalArgumentException("Context argument cannot be null");
    }

    StatusManager sm = context.getStatusManager();
    if (sm == null) {
      ps.println("WARN: Context named \"" + context.getName()
          + "\" has no status manager");
    } else {
      StatusUtil statusUtil = new StatusUtil(context);
      if (statusUtil.getHighestLevel(0) == ErrorStatus.ERROR) {
        print(sm);
      }
    }
  }
public static void printIfErrorsOccured ( Context context ) { if ( context == null ) { throw new IllegalArgumentException ( "Context argument cannot be null" ) ; } StatusManager sm = context . getStatusManager ( ) ; if ( sm == null ) { ps . println ( "WARN: Context named \"" + context . getName ( ) + "\" has no status manager" ) ; } else { StatusUtil statusUtil = new StatusUtil ( context ) ; if ( statusUtil . getHighestLevel ( 0 ) == ErrorStatus . ERROR ) { print ( sm ) ; } } }
Print the contents of the context statuses, but only if they contain
errors.

@param context
Print the contents of the context statuses but only if they contain errors .