|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectinfo.joseluismartin.gui.AbstractView<T>
info.joseluismartin.gui.TableEditor<T>
public class TableEditor<T>
Simple table editor
| Field Summary | |
|---|---|
static String |
DEFAULT_ADD_ICON
|
static String |
DEFAULT_ICON
|
static String |
DEFAULT_REFRESH_ICON
|
static String |
DEFAULT_REMOVE_ICON
|
static String |
DEFAULT_SAVE_ICON
|
| Fields inherited from class info.joseluismartin.gui.AbstractView |
|---|
DEFAULT_BINDER_FACTORY_NAME, errors, height, width |
| Constructor Summary | |
|---|---|
TableEditor()
Creates new TableEditor |
|
TableEditor(Class<T> clazz)
Creates new TableEditor |
|
| Method Summary | |
|---|---|
void |
add()
Add a new model to the table |
protected JComponent |
buildPanel()
Build the JComponent that hold controls. |
protected Container |
createHeader()
|
protected Container |
createTablePanel()
Creates a new Box with table and actions buttons |
void |
delete()
Delete selected table rows using persistent service |
void |
doRefresh()
Allow subclasses to do custom refresh |
Icon |
getAddIcon()
|
Icon |
getIcon()
|
org.springframework.context.MessageSource |
getMessageSource()
|
String |
getName()
Gets the view name |
Icon |
getRefreshIcon()
|
Icon |
getRemoveIcon()
|
Icon |
getSaveIcon()
|
PersistentService<T,Serializable> |
getService()
|
JTable |
getTable()
|
ListTableModel |
getTableModel()
|
void |
init()
Initiaze, usally called by container |
protected void |
loadIcons()
|
void |
setAddIcon(Icon addIcon)
|
void |
setIcon(Icon icon)
|
void |
setMessageSource(org.springframework.context.MessageSource messageSource)
|
void |
setName(String name)
|
void |
setRefreshIcon(Icon refreshIcon)
|
void |
setRemoveIcon(Icon removeIcon)
|
void |
setSaveIcon(Icon saveIcon)
|
void |
setService(PersistentService<T,Serializable> service)
|
void |
setTable(JTable table)
|
void |
setTableModel(ListTableModel tableModel)
|
void |
tableChanged(TableModelEvent e)
|
String |
toString()
|
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait |
| Field Detail |
|---|
public static String DEFAULT_ICON
public static String DEFAULT_ADD_ICON
public static String DEFAULT_REMOVE_ICON
public static String DEFAULT_SAVE_ICON
public static String DEFAULT_REFRESH_ICON
| Constructor Detail |
|---|
public TableEditor()
public TableEditor(Class<T> clazz)
clazz - entity class| Method Detail |
|---|
public void init()
protected JComponent buildPanel()
buildPanel in class AbstractView<T>protected Container createTablePanel()
public void doRefresh()
doRefresh in class AbstractView<T>protected Container createHeader()
public void add()
public void delete()
public JTable getTable()
public void setTable(JTable table)
public ListTableModel getTableModel()
public void setTableModel(ListTableModel tableModel)
public Icon getAddIcon()
public void setAddIcon(Icon addIcon)
public PersistentService<T,Serializable> getService()
public void setService(PersistentService<T,Serializable> service)
public Icon getSaveIcon()
public void setSaveIcon(Icon saveIcon)
public void tableChanged(TableModelEvent e)
tableChanged in interface TableModelListenerpublic String getName()
View
getName in interface View<T>getName in class AbstractView<T>public void setName(String name)
setName in class AbstractView<T>name - the name to setpublic String toString()
toString in class Objectpublic Icon getIcon()
public void setIcon(Icon icon)
icon - the icon to setprotected void loadIcons()
public Icon getRemoveIcon()
public void setRemoveIcon(Icon removeIcon)
removeIcon - the removeIcon to setpublic Icon getRefreshIcon()
public void setRefreshIcon(Icon refreshIcon)
refreshIcon - the refreshIcon to setpublic org.springframework.context.MessageSource getMessageSource()
getMessageSource in class AbstractView<T>@Autowired public void setMessageSource(org.springframework.context.MessageSource messageSource)
setMessageSource in class AbstractView<T>messageSource - the messageSource to set
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||