Package org.apache.empire.struts2.html.HtmlWriter

Examples of org.apache.empire.struts2.html.HtmlWriter.HtmlTag.endTag()


                // The value
                HtmlTag s = htmlWriter.startTag(disabledTag);
                s.addAttribute("class",    this.cssClass);
                s.addAttribute("style",    this.cssStyle);
                s.beginBody(text);
                s.endTag(body);
            }
            return false;
           
        } catch (Exception e) {
            log.error("error when rendering", e);
View Full Code Here


        // Body append
        if (usesBody() && "append".equalsIgnoreCase(bodyUsage))
            hw.print(body);
        // close anchor
        if (anchor!=null)
            anchor.endTag();
        // close td
        td.endTag();
    }

    public void setHtmlTag(String htmlTag)
View Full Code Here

        int result = super.doEndTag();
        // Write End Tag
        HtmlTagDictionary dic = HtmlTagDictionary.getInstance();
        HtmlWriter w = new HtmlWriter(pageContext.getOut());
        HtmlTag td = w.continueTag(dic.ButtonTag(), true);
        td.endTag();
        // done
        return result;
    }

    // ------- Property accessors -------
View Full Code Here

            {   // add an empty entry
                HtmlTag option = w.startTag("option");
                option.addAttributeNoCheck("value", "", false);
                option.addAttribute("selected", ObjectUtils.isEmpty(current));
                option.beginBody("");
                option.endTag(true);
            }
            for (OptionEntry entry : options)
            {
                Object value = entry.getValue();
                boolean isCurrent = ObjectUtils.compareEqual(current, value);
View Full Code Here

                // Add Option entry
                HtmlTag option = w.startTag("option");
                option.addAttributeNoCheck("value", value, true);
                option.addAttribute("selected", isCurrent);
                option.beginBody(getTranslation(entry.getText()));
                option.endTag(true);
            }
        }
        else
        {   // No Option list available
            log.error("No options available for select tag.");
View Full Code Here

            String msg = provider.getLocalizedErrorMessage(lastActionError);
            renderError(w, actionErrClass, msg);
        }

        // done
        list.endTag();
    }

    private void renderError(HtmlWriter w, String cssClassName, String msg)
    {
        HtmlTagDictionary dic = HtmlTagDictionary.getInstance();
View Full Code Here

        if (wrapTag!=null && wrapTag.length()>0)
        {   tag.beginBody();
            // Item wrapper tag
            HtmlTag wrap = w.startTag(wrapTag);
            wrap.addAttribute("class", cssClassName);
            wrap.endTag(msg);
        }
        else
        {   // No additional error wrapper tag
            tag.addAttribute("class", cssClassName);
            tag.beginBody(msg);
View Full Code Here

        if (renderWrapperTag())
        {   // Close Form Wrapper Tag
            HtmlTagDictionary dic = HtmlTagDictionary.getInstance()
            HtmlWriter w = new HtmlWriter(pageContext.getOut());
            HtmlTag wrap = w.continueTag(dic.FormPartWrapperTag(), true);
            wrap.endTag();
        }
        // NullValue
        if (nullValue!=null)
            removePageAttribute(NULLVALUE_ATTRIBUTE, oldNullValue);
        oldNullValue = null;
View Full Code Here

    {
        HtmlTag item = w.startTag("input");
        item.addAttribute("type", "hidden");
        item.addAttribute("name",  name);
        item.addAttribute("value", value);
        item.endTag(true);
    }

    private void renderReadOnlyColumns(HtmlWriter w)
    {
        if (record instanceof Record && ((Record)record).isValid())
View Full Code Here

        // Event Attributes
        input.addAttribute("onclick",   ci.getOnclick());
        input.addAttribute("onchange",  ci.getOnchange());
        input.addAttribute("onfocus",   ci.getOnfocus());
        input.addAttribute("onblur",    ci.getOnblur());
        input.endTag();
    }
   
}
View Full Code Here

TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.