public static String checkHasText ( String argument , String errorMessage ) { if ( argument == null || argument . isEmpty ( ) ) { throw new IllegalArgumentException ( errorMessage ) ; } return argument ; }
Tests if a string contains text .