Examples of HtmlWriter


Examples of org.apache.empire.struts2.html.HtmlWriter

    @Override
    public int doEndTag()
        throws JspException
    {
        // Write End Tag
        HtmlWriter w = new HtmlWriter(pageContext.getOut());
        HtmlTag wrap = w.continueTag (tag, true);
        wrap.endTag();
        // done
        resetParams();
        return EVAL_PAGE;
    }

Examples of org.apache.empire.struts2.html.HtmlWriter

        throws JspException
    {
        // Get Row Info
        TableRowTag.RowInfo ri = getRowInfo();
        // Start Tag
        HtmlWriter w = new HtmlWriter(pageContext.getOut());
        HtmlTag td = w.startTag("td");
        td.addAttribute("id", getId());
        td.addAttribute("class", getCssClass(ri));
        setStyleAndWrap(td, ri);
        td.addAttribute("width", width);
        td.addAttribute("height", height);

Examples of org.apache.empire.struts2.html.HtmlWriter

    public int doEndTag()
        throws JspException
    {
        int result = super.doEndTag();
        // Write End Tag
        HtmlWriter w = new HtmlWriter(pageContext.getOut());
        HtmlTag td = w.continueTag("td", true);
        td.endTag();
        // done
        return result;
    }

Examples of org.apache.empire.struts2.html.HtmlWriter

    @Override
    public int doStartTag()
        throws JspException
    {
        // Tabel cell tag
        HtmlWriter w = new HtmlWriter(pageContext.getOut());
        HtmlTag rb = w.startTag("input");
        addStandardAttributes(rb, null);
        rb.addAttribute("type", "radio");
        rb.addAttribute("name",  getTagName(name));
        rb.addAttributeNoCheck("value", getStringValue(), true);
        rb.addAttribute("checked", getChecked());

Examples of org.apache.empire.struts2.html.HtmlWriter

    {      
        // Get the action
        Object action = getAction();
        if (action instanceof ActionErrorProvider)
        {   // Tabel cell tag
            HtmlWriter w = new HtmlWriter(pageContext.getOut());
            renderMessage(w, (ActionErrorProvider)action);
        }
        else
        {   // Error: Action does implement ActionErrorProvider
            log.error("Cannot render message. Action does implement ActionErrorProvider.");

Examples of org.apache.empire.struts2.html.HtmlWriter

        // User-Agent
        HtmlTagDictionary dic = HtmlTagDictionary.getInstance();
        flexDivRenderInfo = dic.FlexDivTag(type, userAgent);
        if (flexDivRenderInfo!=null)
        {   // Render Flex Div
            HtmlWriter w = new HtmlWriter(pageContext.getOut());
            HtmlTag tag = w.startTag(flexDivRenderInfo.tag);
            tag.addAttribute("id", getId());
            tag.addAttribute("class", cssClass);
            tag.addAttributes(flexDivRenderInfo.attributes);
            tag.beginBody(flexDivRenderInfo.bodyBegin);
        }

Examples of org.apache.empire.struts2.html.HtmlWriter

        throws JspException
    {
        // Render End Tag
        if (flexDivRenderInfo!=null)
        {   // End flexible Tag
            HtmlWriter w = new HtmlWriter(pageContext.getOut());
            HtmlTag tag = w.continueTag(flexDivRenderInfo.tag, true);
            tag.endTag(flexDivRenderInfo.bodyEnd);
            flexDivRenderInfo = null;
        }
        // return super.doEndTag();
        resetParams();

Examples of org.apache.empire.struts2.html.HtmlWriter

    @Override
    public int doStartTag() throws JspException
    {
        // Tabel cell tag
        HtmlTagDictionary dic = HtmlTagDictionary.getInstance();
        HtmlWriter w = new HtmlWriter(pageContext.getOut());
        HtmlTag thr = w.startTag(dic.TableHeadRowTag());
        addStandardAttributes(thr, null);
        thr.beginBody(true);
        // Set current Column
        HeadRowInfo hri = new HeadRowInfo();
        // Is sorting Info supplied

Examples of org.apache.empire.struts2.html.HtmlWriter

        // Set current Column
        removePageAttribute(HEADROWINFO_ATTRIBUTE, oldHeadRowInfo);
        oldHeadRowInfo = null;
        // Write End Tag
        HtmlTagDictionary dic = HtmlTagDictionary.getInstance();
        HtmlWriter w = new HtmlWriter(pageContext.getOut());
        HtmlTag thr = w.continueTag (dic.TableHeadRowTag(), true);
        thr.endTag();
        // done
        resetParams();
        return EVAL_PAGE;
    }

Examples of org.apache.empire.struts2.html.HtmlWriter

        // Get Body
        String body = getBody();
        setBodyContent(null);
       
        HtmlTagDictionary dic = HtmlTagDictionary.getInstance();
        HtmlWriter w = new HtmlWriter(pageContext.getOut());
        // Padding Text
        if (padding==null)
            padding = dic.PagerPaddingText();
        String pbeg_e = dic.PagerFirstPageText();
        String prwd_e = dic.PagerRewindText();
        String pfwd_e = dic.PagerForwardText();
        String pend_e = dic.PagerLastPageText();
        String pbeg_d = dic.PagerFirstPageTextDisabled();
        String prwd_d = dic.PagerRewindTextDisabled();
        String pfwd_d = dic.PagerForwardTextDisabled();
        String pend_d = dic.PagerLastPageTextDisabled();
        // Class and Styles
        HtmlTag div = w.startTag(dic.PagerTag());
        addStandardAttributes(div, dic.PagerClass());
        // Body
        div.beginBody(body, true);
        this.cssClass = str(linkClass, dic.PagerLinkClass());
        this.cssStyle = null;
        // onclick
        if (onclick== null)
            onclick = dic.PagerLinkDefaultOnClickScript();
        // Label?
        String pagerLabel = getString(str(label, dic.PagerLabelText()));
        if (pagerLabel!=null)
        {   // There is text
            HtmlTag label = w.startTag( dic.PagerLabelTag());
            label.addAttribute("class", dic.PagerLabelClass());
            label.endTag(pagerLabel);
        }
        // Back and fast back
        renderButton(w, pbeg_e, pbeg_d, true, pageCnt, current, 0);
        renderButton(w, prwd_e, prwd_d, true, pageCnt, current, Math.max(current - 1, 0) );
        // The Pages
        for (int pageIndex=begIndex; pageIndex<endIndex; pageIndex++)
        {
            // Padding
            if (pageIndex>0 && padding!=null)
                w.println(padding);
            // The Page selection
            HtmlTag page = w.startTag(dic.PagerPageTag());
            div.addAttribute("class", dic.PagerPageClass());
            page.beginBody();
            // The Anchors
            String pageText = String.valueOf(pageIndex+1);
            if (pageIndex>=pageCnt)
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.