public static Properties createDefault ( Object comp ) { Properties p = new Properties ( ) ; ComponentAccess ca = new ComponentAccess ( comp ) ; // over all input slots. for ( Access in : ca . inputs ( ) ) { try { String name = in . getField ( ) . getName ( ) ; Object o = in . getField ( ) . get ( comp ) ; if ( o != null ) { String value = o . toString ( ) ; p . put ( name , value ) ; } } catch ( Exception ex ) { throw new ComponentException ( "Failed access to field: " + in . getField ( ) . getName ( ) ) ; } } return p ; }
Create a default parameter set