private Map < String , Class < ? > > createPropertyMap ( Class < ? > clz ) throws Exception { Map < String , Class < ? > > result = new HashMap <> ( ) ; for ( Method m : clz . getMethods ( ) ) { if ( m . getName ( ) . startsWith ( "set" ) ) { if ( m . getReturnType ( ) . equals ( Void . TYPE ) && m . getParameterCount ( ) == 1 && isSupported ( m . getParameterTypes ( ) [ 0 ] ) ) result . put ( m . getName ( ) . substring ( 3 ) , m . getParameterTypes ( ) [ 0 ] ) ; } } return result ; }
Get property map