Here you can find the source of toIntPlusOneString(Object object)
public static String toIntPlusOneString(Object object)
//package com.java2s; //License from project: Open Source License public class Main { public static String toIntPlusOneString(Object object) { if (object == null) { return null; } else {// ww w. j a v a2 s. c om return toIntString(toInt(object) + 1); } } public static String toIntString(Object object) { if (object == null) { return null; } else if (object instanceof Number) { return String.valueOf(((Number) object).intValue()); } else { return object.toString(); } } public static int toInt(Object object) { if (object == null) { return -1; } else if (object instanceof Number) { return ((Number) object).intValue(); } else { return Integer.parseInt(object.toString()); } } }