|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectto.etc.domui.component.tbl.AbstractRowRenderer<T>
public class AbstractRowRenderer<T>
Field Summary | |
---|---|
protected java.util.List<SimpleColumnDef> |
m_columnList
|
Constructor Summary | |
---|---|
AbstractRowRenderer(java.lang.Class<T> data)
|
|
AbstractRowRenderer(java.lang.Class<T> data,
ClassMetaModel cmm)
|
Method Summary | ||
---|---|---|
void |
beforeQuery(TableModelTableBase<T> tbl)
This gets called by the data table component just before it starts to render a new page. |
|
protected void |
check()
Throws an exception if this renderer has been completed and is unmutable. |
|
protected void |
complete(TableModelTableBase<T> tbl)
Complete this object if it is not already complete (internal). |
|
protected java.lang.Class<?> |
getActualClass()
Returns the record type being rendered. |
|
ICellClicked<?> |
getCellClicked(int col)
Get the cell clicked handler for the specified column. |
|
SimpleColumnDef |
getColumn(int ix)
Return the definition for the nth column. |
|
SimpleColumnDef |
getColumnByName(java.lang.String propertyName)
Find a column by the property it is displaying. |
|
int |
getColumnCount()
Return the #of columns in this renderer. |
|
INodeContentRenderer<?> |
getNodeRenderer(int index)
Convenience method to get the column's cell renderer; replacement for getColumn(index).getRenderer(). |
|
IRowButtonFactory<T> |
getRowButtonFactory()
|
|
ICellClicked<?> |
getRowClicked()
When set each row will be selectable (will react when the mouse hovers over it), and when clicked will call this handler. |
|
protected SimpleColumnDef |
getSortColumn()
|
|
java.lang.String |
getUnknownColumnCaption()
|
|
protected boolean |
isComplete()
Check if this object is used (completed) and thereby unmodifyable (internal). |
|
protected ClassMetaModel |
model()
Returns the metamodel used. |
|
protected
|
renderColumn(TableModelTableBase<T> tbl,
ColumnContainer<T> cc,
int index,
T instance,
SimpleColumnDef cd)
Render a single column fully. |
|
void |
renderHeader(TableModelTableBase<T> tbl,
HeaderContainer<T> cc)
Render the header for a table, using the simple column metadata provided. |
|
void |
renderRow(TableModelTableBase<T> tbl,
ColumnContainer<T> cc,
int index,
T instance)
|
|
void |
setCellClicked(int col,
ICellClicked<?> cellClicked)
Set the cell clicked handler for the specified column. |
|
void |
setColumnWidth(int index,
java.lang.String width)
Convenience method to set the column width; replacement for getColumn(index).setWidth(). |
|
void |
setColumnWidths(java.lang.String... widths)
Quickly set the widths of all columns in the same order as defined. |
|
void |
setNodeRenderer(int index,
INodeContentRenderer<?> renderer)
Convenience method to set the column's cell renderer; replacement for getColumn(index).setRenderer(). |
|
void |
setRowButtonFactory(IRowButtonFactory<T> rowButtonFactory)
|
|
void |
setRowClicked(ICellClicked<?> rowClicked)
When set each row will be selectable (will react when the mouse hovers over it), and when clicked will call this handler. |
|
protected void |
setSortColumn(SimpleColumnDef cd)
|
|
void |
setUnknownColumnCaption(java.lang.String unknownColumnCaption)
|
Methods inherited from class java.lang.Object |
---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
Field Detail |
---|
protected final java.util.List<SimpleColumnDef> m_columnList
Constructor Detail |
---|
public AbstractRowRenderer(java.lang.Class<T> data)
public AbstractRowRenderer(java.lang.Class<T> data, ClassMetaModel cmm)
Method Detail |
---|
protected ClassMetaModel model()
protected java.lang.Class<?> getActualClass()
protected void check()
protected void complete(TableModelTableBase<T> tbl)
protected boolean isComplete()
protected void setSortColumn(SimpleColumnDef cd)
protected SimpleColumnDef getSortColumn()
public SimpleColumnDef getColumn(int ix)
ix
-
public int getColumnCount()
public SimpleColumnDef getColumnByName(java.lang.String propertyName)
propertyName
-
public void setColumnWidths(java.lang.String... widths)
widths
- public void setColumnWidth(int index, java.lang.String width)
index
- width
- public void setNodeRenderer(int index, INodeContentRenderer<?> renderer)
index
- renderer
- public INodeContentRenderer<?> getNodeRenderer(int index)
index
-
public ICellClicked<?> getRowClicked()
public void setRowClicked(ICellClicked<?> rowClicked)
rowClicked
- public ICellClicked<?> getCellClicked(int col)
col
-
public void setCellClicked(int col, ICellClicked<?> cellClicked)
col
- cellClicked
- public void renderHeader(TableModelTableBase<T> tbl, HeaderContainer<T> cc) throws java.lang.Exception
java.lang.Exception
to.etc.domui.component.tbl.IRowRenderer#renderHeader(to.etc.domui.component.tbl.HeaderContainer)
public void beforeQuery(TableModelTableBase<T> tbl) throws java.lang.Exception
java.lang.Exception
to.etc.domui.component.tbl.IRowRenderer#beforeQuery(to.etc.domui.component.tbl.DataTable)
public void renderRow(TableModelTableBase<T> tbl, ColumnContainer<T> cc, int index, T instance) throws java.lang.Exception
java.lang.Exception
to.etc.domui.component.tbl.IRowRenderer#renderRow(to.etc.domui.component.tbl.ColumnContainer, int, java.lang.Object)
protected <X> void renderColumn(TableModelTableBase<T> tbl, ColumnContainer<T> cc, int index, T instance, SimpleColumnDef cd) throws java.lang.Exception
tbl
- cc
- index
- instance
- cd
-
java.lang.Exception
public IRowButtonFactory<T> getRowButtonFactory()
public void setRowButtonFactory(IRowButtonFactory<T> rowButtonFactory)
public void setUnknownColumnCaption(java.lang.String unknownColumnCaption)
public java.lang.String getUnknownColumnCaption()
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |