All Downloads are FREE. Search and download functionalities are using the official Maven repository.

com.hfg.html.TFoot Maven / Gradle / Ivy

There is a newer version: 20240423
Show newest version
package com.hfg.html;

import java.util.List;


import com.hfg.html.attribute.Align;
import com.hfg.html.attribute.VAlign;
import com.hfg.css.CssUtil;

//------------------------------------------------------------------------------
/**
 * Represents a table footer (<tfoot>) tag.
 *
 * @author J. Alex Taylor, hairyfatguy.com
 */
//------------------------------------------------------------------------------
// com.hfg XML/HTML Coding Library
//
// This library is free software; you can redistribute it and/or
// modify it under the terms of the GNU Lesser General Public
// License as published by the Free Software Foundation; either
// version 2.1 of the License, or (at your option) any later version.
//
// This library is distributed in the hope that it will be useful,
// but WITHOUT ANY WARRANTY; without even the implied warranty of
// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
// Lesser General Public License for more details.
//
// You should have received a copy of the GNU Lesser General Public
// License along with this library; if not, write to the Free Software
// Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA  02111-1307  USA
//
// J. Alex Taylor, President, Founder, CEO, COO, CFO, OOPS hairyfatguy.com
// [email protected]
//------------------------------------------------------------------------------

public class TFoot extends HTMLTag
{

    //##########################################################################
    // PRIVATE FIELDS
    //##########################################################################


    //##########################################################################
    // CONSTRUCTORS
    //##########################################################################

    //--------------------------------------------------------------------------
    public TFoot()
    {
        super(HTML.TFOOT);
    }

    //##########################################################################
    // PUBLIC METHODS
    //##########################################################################


    //--------------------------------------------------------------------------
    public Tr addRow()
    {
        Tr tr = new Tr();
        addSubtag(tr);
        return tr;
    }

    //--------------------------------------------------------------------------
    public void addRow(Tr inRow)
    {
        addSubtag(inRow);
    }

    //--------------------------------------------------------------------------
    public List getRows()
    {
        return (List) (Object) getSubtagsByName(HTML.TR);
    }

    //---------------------------------------------------------------------------
    public TFoot setOnClick(String inValue)
    {
        setAttribute(HTML.ONCLICK, inValue);
        return this;
    }

    //--------------------------------------------------------------------------
    @Override
    public TFoot setClass(String inValue)
    {
        setAttribute(HTML.CLASS, inValue);
        return this;
    }


    //--------------------------------------------------------------------------
    @Override
    public TFoot setId(String inValue)
    {
        setAttribute(HTML.ID, inValue);
        return this;
    }

    //--------------------------------------------------------------------------
    @Override
    public TFoot setStyle(CharSequence inValue)
    {
        setAttribute(HTML.STYLE, inValue);
        return this;
    }

    //--------------------------------------------------------------------------
    @Override
    public TFoot addStyle(String inValue)
    {
       CssUtil.addStyle(this, inValue);
        return this;
    }

   //--------------------------------------------------------------------------
   public TFoot setAlign(Align inValue)
   {
      setAttribute(inValue.getHTMLAttributeName(), inValue.toString());
      return this;
   }

   //--------------------------------------------------------------------------
   public TFoot setVAlign(VAlign inValue)
   {
      setAttribute(inValue.getHTMLAttributeName(), inValue.toString());
      return this;
   }

   //--------------------------------------------------------------------------
   /**
    Alignment char, e.g. char=':'.
    */
   public TFoot setChar(char inValue)
   {
      setAttribute(HTML.CHAR, inValue);
      return this;
   }

   //--------------------------------------------------------------------------
   /**
    Offset for the alignment char.
    */
   public TFoot setCharOffset(int inValue)
   {
      setAttribute(HTML.CHAROFF, inValue);
      return this;
   }

}




© 2015 - 2024 Weber Informatics LLC | Privacy Policy