Code example for CaseFormat

Methods: to

0
	 * @return 
	 */ 
	protected String getGetterName(Method method, boolean checkGetter) {
		String name = method.getName();
		if (name.startsWith("get")) {
			return CaseFormat.UPPER_CAMEL.to(CaseFormat.LOWER_CAMEL, name.substring(3));
		} 
		if (! checkGetter) {
			return name;
		} 
		throw new IllegalArgumentException("Method - " + method.getName() + " is not a getter");
	} 
	 
	/** 
	 * Returns the element type of the collection. If the collection is a map, returns the value type. If its not a collection returns Object 
	 *  
	 * @param type 
	 * @return 
	 */ 
	protected Class<?> getElementType(Type type) {
Contextual code suggestions in your IDE  Get Codota for Java