butler.swing.form
Class DetailForm

java.lang.Object
  extended by butler.swing.form.Form
      extended by butler.swing.form.DetailForm
All Implemented Interfaces:
RecordSelectionListener, java.awt.event.ActionListener, java.util.EventListener

public class DetailForm
extends Form
implements RecordSelectionListener

Simple swing frame for editing records from one table. The form can have the following components:
1. Record detail editor for editing one record
2. Tabbed pane for showing related records

Author:
Fredrik Bertilsson

Nested Class Summary
static class DetailForm.PopupDetailListener
           
 
Nested classes/interfaces inherited from class butler.swing.form.Form
Form.XMLFactory
 
Field Summary
static int PADDING
           
 
Fields inherited from class butler.swing.form.Form
CENTER, ONE_THIRD
 
Constructor Summary
DetailForm(DDetailForm desc)
           
 
Method Summary
 void actionPerformed(java.awt.event.ActionEvent event)
           
 java.awt.Component getComponent()
          Returns the physical component.
protected  javax.swing.JMenu getFileMenu()
           
protected  javax.swing.JMenuBar getMenuBar()
           
 java.awt.Container getPanel()
           
 RelatedTabbedPane getRelatedTabbedPane()
           
 void init()
           
 boolean isDirty()
           
 void recordListSelected(RecordList recList)
           
 void recordSelected(Record rec)
           
 void run()
           
 void save()
           
 void setModal(boolean modal)
           
 
Methods inherited from class butler.swing.form.Form
askSave, beforeClose, cancel, close, createForm, getDescriptor, getExitMenuItem, getFrame, getSaveAction, getTitle, main, populate, populate, registerFormFactory, setFrame
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
 

Field Detail

PADDING

public static final int PADDING
See Also:
Constant Field Values
Constructor Detail

DetailForm

public DetailForm(DDetailForm desc)
           throws java.lang.Exception
Throws:
java.lang.Exception
Method Detail

getComponent

public java.awt.Component getComponent()
Returns the physical component.


getRelatedTabbedPane

public RelatedTabbedPane getRelatedTabbedPane()

init

public void init()
          throws java.lang.Exception
Overrides:
init in class Form
Throws:
java.lang.Exception

recordSelected

public void recordSelected(Record rec)
                    throws java.lang.Exception
Specified by:
recordSelected in interface RecordSelectionListener
Throws:
java.lang.Exception

recordListSelected

public void recordListSelected(RecordList recList)
                        throws java.lang.Exception
Specified by:
recordListSelected in interface RecordSelectionListener
Throws:
java.lang.Exception

isDirty

public boolean isDirty()
Overrides:
isDirty in class Form

save

public void save()
          throws java.lang.Exception
Overrides:
save in class Form
Throws:
java.lang.Exception

getFileMenu

protected javax.swing.JMenu getFileMenu()
                                 throws java.lang.Exception
Overrides:
getFileMenu in class Form
Throws:
java.lang.Exception

actionPerformed

public void actionPerformed(java.awt.event.ActionEvent event)
Specified by:
actionPerformed in interface java.awt.event.ActionListener
Overrides:
actionPerformed in class Form

getPanel

public java.awt.Container getPanel()
                            throws java.lang.Exception
Specified by:
getPanel in class Form
Throws:
java.lang.Exception

setModal

public void setModal(boolean modal)

getMenuBar

protected javax.swing.JMenuBar getMenuBar()
                                   throws java.lang.Exception
Overrides:
getMenuBar in class Form
Throws:
java.lang.Exception

run

public void run()
         throws java.lang.Exception
Overrides:
run in class Form
Throws:
java.lang.Exception