18 package org.turro.file.zul.tree;
20 import java.text.DateFormat;
21 import java.util.Date;
22 import org.turro.action.Plugins;
23 import org.turro.i18n.I_;
24 import org.turro.plugin.acceptance.IAcceptanceCtrl;
25 import org.zkoss.zk.ui.Component;
26 import org.zkoss.zul.Space;
27 import org.zkoss.zul.Treecell;
28 import org.zkoss.zul.Treecol;
43 super(label ==
null ?
I_.
byKey(type.toString()) : label);
56 Treecell cell =
new Treecell(
60 if(fileItem.
getFile().isFile()) {
61 cell.appendChild(
new Space());
64 cell.appendChild((Component) accept);
68 if(fileItem.
getFile().isDirectory()) {
69 return new Treecell(
"");
71 return new Treecell(
new org.turro.formatter.BytesFormatter(fileItem.
getFile().length()).toString());
74 DateFormat df = DateFormat.getDateInstance();
75 return new Treecell(df.format(
new Date(fileItem.
getFile().lastModified())));
static< T > T loadImplementation(Class< T > jclass)
Treecell getCell(FileItem fileItem)
FileColumn(FileColumnType type)
FileColumn(String label, FileColumnType type)
static String byKey(String key)
void setEntity(Object entity)