question: public JComponent createPropertyGUI ( String prefix , Properties props , Properties info ) { JComponent component = createEmbeddedPropertyGUI ( prefix , props , info ) ; JButton doneButton = null , cancelButton = null ; JPanel buttons = new JPanel ( ) ; if ( print ) { doneButton = new JButton ( i18n . get ( Inspector . class , "Print" , "Print" ) ) ; cancelButton = new JButton ( i18n . get ( Inspector . class , "Quit" , "Quit" ) ) ; } else { doneButton = new JButton ( i18n . get ( Inspector . class , "Ok" , "Ok" ) ) ; cancelButton = new JButton ( i18n . get ( Inspector . class , "Cancel" , "Cancel" ) ) ; } doneButton . addActionListener ( this ) ; doneButton . setActionCommand ( doneCommand ) ; cancelButton . addActionListener ( this ) ; cancelButton . setActionCommand ( cancelCommand ) ; buttons . add ( doneButton ) ; buttons . add ( cancelButton ) ; component . add ( buttons , BorderLayout . SOUTH ) ; component . validate ( ) ; return component ; }
target:  Creates a JComponent with the properties to be changed. This component is suitable for inclusion into a GUI. Don't use this method directly! Use the createPropertyGUI(PropertyConsumer) instead. You will get a NullPointerException if you use this method without setting the PropertyConsumer in the Inspector.