public static Integer[] deserializeInt(String string) {
        if (string == null) {
            return new Integer[0];
        }
        return Arrays.stream(string.split(","))
                .filter(s -> !s.equals(""))
                .map(Integer::parseInt).toArray(Integer[]::new);
    }
public static Integer[] deserializeInt(String string) {
        if (string == null) {
            return new Integer[0];
        }
        return Arrays.stream(string.split(","))
                .filter(s -> !s.equals(""))
                .map(Integer::parseInt).toArray(Integer[]::new);
    }
public static Integer [ ] deserializeInt ( String string ) { if ( string == null ) { return new Integer [ 0 ] ; } return Arrays . stream ( string . split ( "," ) ) . filter ( s -> ! s . equals ( "" ) ) . map ( Integer :: parseInt ) . toArray ( Integer [ ] :: new ) ; }
Parse comma separated string to Integer array.
@return An empty array when the string parameter is empty or null.
Parse comma separated string to Integer array .