19 package org.turro.www.describeit;
21 import java.io.PrintWriter;
22 import java.io.StringWriter;
23 import java.util.Collection;
24 import org.turro.contacts.DescribeIt;
25 import org.turro.describeit.DescribeItUtil;
26 import org.turro.elephant.context.IConstructor;
27 import org.turro.html.HTMLHelper;
28 import org.turro.util.IdGenerator;
29 import org.zkoss.lang.Strings;
38 private String entityPath;
42 this.constructor = constructor;
46 this.entityPath = entityPath;
54 Collection<DescribeIt> descriptions = Strings.isBlank(describeId) ?
57 if(!descriptions.isEmpty()) {
59 String
id = container ?
"dic_" + IdGenerator.generate() : constructor.
getParameter(
"domid");
61 html.
startTag(
"div",
"id='" +
id +
"'");
64 html.
startTag(
"div",
"class='describeit'")
75 Collection<DescribeIt> descriptions = Strings.isBlank(describeId) ?
78 StringWriter sw =
new StringWriter();
79 if(!descriptions.isEmpty()) {
81 String
id = container ?
"dic_" + IdGenerator.generate() : constructor.
getParameter(
"domid");
83 html.
startTag(
"div",
"id='" +
id +
"'");
86 html.
startTag(
"div",
"class='describeit'")
static Collection< DescribeIt > descriptions(Object entity)
HTMLGenerator endAllTags()
HTMLGenerator write(String value)
HTMLGenerator startTag(String tag)
void renderDescriptions(boolean container)
void renderDescriptions(String describeId, boolean container)
String parseDescriptions(String describeId, boolean container)
DescribeItCtrl(IConstructor constructor)
void setEntityPath(String entityPath)
String getParameter(String param)