class EolHelper {

    public static String removeEol(String line) {
        if (line == null) {
            throw new IllegalArgumentException("Line argument cannot be null");
        }
        return line.replaceAll("(\\n)|(\\r)|(\\r\\n)", "");
    }

}