Java Assert assertInputNotEmpty(final String input, final String message)

Here you can find the source of assertInputNotEmpty(final String input, final String message)

Description

assert Input Not Empty

License

Apache License

Declaration

public static String assertInputNotEmpty(final String input, final String message) 

Method Source Code

//package com.java2s;
//License from project: Apache License 

public class Main {
    public static String assertInputNotEmpty(final String input, final String message) {
        if (input == null || input.isEmpty()) {
            throw new IllegalArgumentException(message);
        }// w  w w  .  j  a va2 s  .  co  m
        return input;
    }
}

Related

  1. assertInBounds(final String param, final int value, final int min, final int max)
  2. assertInBounds(int[] coordinates)
  3. assertIndex(final int size, final int index)
  4. assertIndex(final String s, final int index)
  5. assertIndex(int index, String msg)
  6. assertInstance(final Object object, final Class c)
  7. assertInstance(Object object, Class c)
  8. assertInstanceOf(Object obj, Class classType)
  9. assertInstanceOf(Object obj, Class expClass)