public static String decapitalize(String name) { try { if (!Character.isUpperCase(name.charAt(0))) { return name; } else { try { if (Character.isUpperCase(name.charAt(1))) { return name; } else { char[] c = name.toCharArray(); c[0] = Character.toLowerCase(c[0]); return new String(c); } } catch (StringIndexOutOfBoundsException E) { char[] c = new char[1]; c[0] = Character.toLowerCase(name.charAt(0)); return new String(c); } } } catch (StringIndexOutOfBoundsException E) { return name; } catch (NullPointerException E) { return null; }
public static String decapitalize(String name) { try { if(!Character.isUpperCase(name.charAt(0))) { return name; } else { try { if(Character.isUpperCase(name.charAt(1))) { return name; } else { char[] c = name.toCharArray(); c[0] = Character.toLowerCase(c[0]); return new String(c); } } catch(StringIndexOutOfBoundsException E) { char[] c = new char[1]; c[0] = Character.toLowerCase(name.charAt(0)); return new String(c); }
	public static String decapitalize(String name) {		try {			if (!Character.isUpperCase(name.charAt(0))) {				return name;			} else {				try {					if (Character.isUpperCase(name.charAt(1))) {						return name;					} else {						char[] c = name.toCharArray();						c[0] = Character.toLowerCase(c[0]);						return new String(c);					}				} catch (StringIndexOutOfBoundsException E) {					char[] c = new char[1];					c[0] = Character.toLowerCase(name.charAt(0));					return new String(c);				}			}		} catch (StringIndexOutOfBoundsException E) {			return name;		} catch (NullPointerException E) {			return null;		}	}