\section{DOM::HTMLTable\-Element Class Reference}
\label{classDOM_1_1HTMLTableElement}\index{DOM::HTMLTableElement@{DOM::HTMLTableElement}}
The create$\ast$ and delete$\ast$ methods on the table allow authors to construct and modify tables.  


{\tt \#include $<$html\_\-table.h$>$}

Inheritance diagram for DOM::HTMLTable\-Element:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=85pt]{classDOM_1_1HTMLTableElement__inherit__graph}
\end{center}
\end{figure}
Collaboration diagram for DOM::HTMLTable\-Element:\begin{figure}[H]
\begin{center}
\leavevmode
\includegraphics[width=85pt]{classDOM_1_1HTMLTableElement__coll__graph}
\end{center}
\end{figure}
\subsection*{Public Member Functions}
\begin{CompactItemize}
\item 
{\bf HTMLTable\-Element} (const {\bf HTMLTable\-Element} \&other)\label{classDOM_1_1HTMLTableElement_a1}

\item 
{\bf HTMLTable\-Element} (const {\bf Node} \&other)\label{classDOM_1_1HTMLTableElement_a2}

\item 
{\bf HTMLTable\-Element} \& {\bf operator=} (const {\bf HTMLTable\-Element} \&other)\label{classDOM_1_1HTMLTableElement_a3}

\item 
{\bf HTMLTable\-Element} \& {\bf operator=} (const {\bf Node} \&other)\label{classDOM_1_1HTMLTableElement_a4}

\item 
{\bf HTMLTable\-Caption\-Element} {\bf caption} () const 
\item 
void {\bf set\-Caption} (const {\bf HTMLTable\-Caption\-Element} \&)
\item 
{\bf HTMLTable\-Section\-Element} {\bf t\-Head} () const 
\item 
void {\bf set\-THead} (const {\bf HTMLTable\-Section\-Element} \&)
\item 
{\bf HTMLTable\-Section\-Element} {\bf t\-Foot} () const 
\item 
void {\bf set\-TFoot} (const {\bf HTMLTable\-Section\-Element} \&)
\item 
{\bf HTMLCollection} {\bf rows} () const 
\item 
{\bf HTMLCollection} {\bf t\-Bodies} () const 
\item 
{\bf DOMString} {\bf align} () const 
\item 
void {\bf set\-Align} (const {\bf DOMString} \&)
\item 
{\bf DOMString} {\bf bg\-Color} () const 
\item 
void {\bf set\-Bg\-Color} (const {\bf DOMString} \&)
\item 
{\bf DOMString} {\bf border} () const 
\item 
void {\bf set\-Border} (const {\bf DOMString} \&)
\item 
{\bf DOMString} {\bf cell\-Padding} () const 
\item 
void {\bf set\-Cell\-Padding} (const {\bf DOMString} \&)
\item 
{\bf DOMString} {\bf cell\-Spacing} () const 
\item 
void {\bf set\-Cell\-Spacing} (const {\bf DOMString} \&)
\item 
{\bf DOMString} {\bf frame} () const 
\item 
void {\bf set\-Frame} (const {\bf DOMString} \&)
\item 
{\bf DOMString} {\bf rules} () const 
\item 
void {\bf set\-Rules} (const {\bf DOMString} \&)
\item 
{\bf DOMString} {\bf summary} () const 
\item 
void {\bf set\-Summary} (const {\bf DOMString} \&)
\item 
{\bf DOMString} {\bf width} () const 
\item 
void {\bf set\-Width} (const {\bf DOMString} \&)
\item 
{\bf HTMLElement} {\bf create\-THead} ()
\item 
void {\bf delete\-THead} ()
\item 
{\bf HTMLElement} {\bf create\-TFoot} ()
\item 
void {\bf delete\-TFoot} ()
\item 
{\bf HTMLElement} {\bf create\-Caption} ()
\item 
void {\bf delete\-Caption} ()
\item 
{\bf HTMLElement} {\bf insert\-Row} (long index)
\item 
void {\bf delete\-Row} (long index)
\end{CompactItemize}
\subsection*{Protected Member Functions}
\begin{CompactItemize}
\item 
{\bf HTMLTable\-Element} (HTMLTable\-Element\-Impl $\ast$impl)\label{classDOM_1_1HTMLTableElement_b0}

\end{CompactItemize}


\subsection{Detailed Description}
The create$\ast$ and delete$\ast$ methods on the table allow authors to construct and modify tables. 

HTML 4.0 specifies that only one of each of the {\tt CAPTION} , {\tt THEAD} , and {\tt TFOOT} elements may exist in a table. Therefore, if one exists, and the {\bf create\-THead()}{\rm (p.\,\pageref{classDOM_1_1HTMLTableElement_a32})} or {\bf create\-TFoot()}{\rm (p.\,\pageref{classDOM_1_1HTMLTableElement_a34})} method is called, the method returns the existing THead or TFoot element. See the {\tt TABLE element definition } in HTML 4.0. 



Definition at line 441 of file html\_\-table.h.

\subsection{Member Function Documentation}
\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!caption@{caption}}
\index{caption@{caption}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf HTMLTable\-Caption\-Element} HTMLTable\-Element::caption () const}\label{classDOM_1_1HTMLTableElement_a6}


Returns the table's {\tt CAPTION} , or void if none exists. 



Definition at line 418 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setCaption@{setCaption}}
\index{setCaption@{setCaption}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Caption (const {\bf HTMLTable\-Caption\-Element} \&)}\label{classDOM_1_1HTMLTableElement_a7}


see caption 



Definition at line 424 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!tHead@{tHead}}
\index{tHead@{tHead}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf HTMLTable\-Section\-Element} HTMLTable\-Element::t\-Head () const}\label{classDOM_1_1HTMLTableElement_a8}


Returns the table's {\tt THEAD} , or {\tt null} if none exists. 



Definition at line 431 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setTHead@{setTHead}}
\index{setTHead@{setTHead}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-THead (const {\bf HTMLTable\-Section\-Element} \&)}\label{classDOM_1_1HTMLTableElement_a9}


see t\-Head 



Definition at line 437 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!tFoot@{tFoot}}
\index{tFoot@{tFoot}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf HTMLTable\-Section\-Element} HTMLTable\-Element::t\-Foot () const}\label{classDOM_1_1HTMLTableElement_a10}


Returns the table's {\tt TFOOT} , or {\tt null} if none exists. 



Definition at line 445 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setTFoot@{setTFoot}}
\index{setTFoot@{setTFoot}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-TFoot (const {\bf HTMLTable\-Section\-Element} \&)}\label{classDOM_1_1HTMLTableElement_a11}


see t\-Foot 



Definition at line 451 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!rows@{rows}}
\index{rows@{rows}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf HTMLCollection} HTMLTable\-Element::rows () const}\label{classDOM_1_1HTMLTableElement_a12}


Returns a collection of all the rows in the table, including all in {\tt THEAD} , {\tt TFOOT} , all {\tt TBODY} elements. 



Definition at line 459 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!tBodies@{tBodies}}
\index{tBodies@{tBodies}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf HTMLCollection} HTMLTable\-Element::t\-Bodies () const}\label{classDOM_1_1HTMLTableElement_a13}


Returns a collection of the table bodies (including implicit ones). 



Definition at line 465 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!align@{align}}
\index{align@{align}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DOMString} HTMLTable\-Element::align () const}\label{classDOM_1_1HTMLTableElement_a14}


Specifies the table's position with respect to the rest of the document. 

See the {\tt align attribute definition } in HTML 4.0. This attribute is deprecated in HTML 4.0. 

Definition at line 471 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setAlign@{setAlign}}
\index{setAlign@{setAlign}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Align (const {\bf DOMString} \&)}\label{classDOM_1_1HTMLTableElement_a15}


see align 



Definition at line 477 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!bgColor@{bgColor}}
\index{bgColor@{bgColor}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DOMString} HTMLTable\-Element::bg\-Color () const}\label{classDOM_1_1HTMLTableElement_a16}


Cell background color. 

See the {\tt bgcolor attribute definition } in HTML 4.0. This attribute is deprecated in HTML 4.0. 

Definition at line 482 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setBgColor@{setBgColor}}
\index{setBgColor@{setBgColor}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Bg\-Color (const {\bf DOMString} \&)}\label{classDOM_1_1HTMLTableElement_a17}


see bg\-Color 



Definition at line 488 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!border@{border}}
\index{border@{border}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DOMString} HTMLTable\-Element::border () const}\label{classDOM_1_1HTMLTableElement_a18}


The width of the border around the table. 

See the {\tt border attribute definition } in HTML 4.0. 

Definition at line 493 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setBorder@{setBorder}}
\index{setBorder@{setBorder}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Border (const {\bf DOMString} \&)}\label{classDOM_1_1HTMLTableElement_a19}


see border 



Definition at line 499 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!cellPadding@{cellPadding}}
\index{cellPadding@{cellPadding}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DOMString} HTMLTable\-Element::cell\-Padding () const}\label{classDOM_1_1HTMLTableElement_a20}


Specifies the horizontal and vertical space between cell content and cell borders. 

See the {\tt cellpadding attribute definition } in HTML 4.0. 

Definition at line 504 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setCellPadding@{setCellPadding}}
\index{setCellPadding@{setCellPadding}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Cell\-Padding (const {\bf DOMString} \&)}\label{classDOM_1_1HTMLTableElement_a21}


see cell\-Padding 



Definition at line 510 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!cellSpacing@{cellSpacing}}
\index{cellSpacing@{cellSpacing}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DOMString} HTMLTable\-Element::cell\-Spacing () const}\label{classDOM_1_1HTMLTableElement_a22}


Specifies the horizontal and vertical separation between cells. 

See the {\tt cellspacing attribute definition } in HTML 4.0. 

Definition at line 515 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setCellSpacing@{setCellSpacing}}
\index{setCellSpacing@{setCellSpacing}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Cell\-Spacing (const {\bf DOMString} \&)}\label{classDOM_1_1HTMLTableElement_a23}


see cell\-Spacing 



Definition at line 521 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!frame@{frame}}
\index{frame@{frame}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DOMString} HTMLTable\-Element::frame () const}\label{classDOM_1_1HTMLTableElement_a24}


Specifies which external table borders to render. 

See the {\tt frame attribute definition } in HTML 4.0. 

Definition at line 526 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setFrame@{setFrame}}
\index{setFrame@{setFrame}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Frame (const {\bf DOMString} \&)}\label{classDOM_1_1HTMLTableElement_a25}


see frame 



Definition at line 532 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!rules@{rules}}
\index{rules@{rules}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DOMString} HTMLTable\-Element::rules () const}\label{classDOM_1_1HTMLTableElement_a26}


Specifies which internal table borders to render. 

See the {\tt rules attribute definition } in HTML 4.0. 

Definition at line 537 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setRules@{setRules}}
\index{setRules@{setRules}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Rules (const {\bf DOMString} \&)}\label{classDOM_1_1HTMLTableElement_a27}


see rules 



Definition at line 543 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!summary@{summary}}
\index{summary@{summary}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DOMString} HTMLTable\-Element::summary () const}\label{classDOM_1_1HTMLTableElement_a28}


Supplementary description about the purpose or structure of a table. 

See the {\tt summary attribute definition } in HTML 4.0. 

Definition at line 548 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setSummary@{setSummary}}
\index{setSummary@{setSummary}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Summary (const {\bf DOMString} \&)}\label{classDOM_1_1HTMLTableElement_a29}


see summary 



Definition at line 554 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!width@{width}}
\index{width@{width}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf DOMString} HTMLTable\-Element::width () const}\label{classDOM_1_1HTMLTableElement_a30}


Specifies the desired table width. 

See the {\tt width attribute definition } in HTML 4.0. 

Definition at line 559 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!setWidth@{setWidth}}
\index{setWidth@{setWidth}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::set\-Width (const {\bf DOMString} \&)}\label{classDOM_1_1HTMLTableElement_a31}


see width 



Definition at line 565 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!createTHead@{createTHead}}
\index{createTHead@{createTHead}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf HTMLElement} HTMLTable\-Element::create\-THead ()}\label{classDOM_1_1HTMLTableElement_a32}


Create a table header row or return an existing one. 

\begin{Desc}
\item[Returns:]A new table header element ( {\tt THEAD} ). \end{Desc}


Definition at line 570 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!deleteTHead@{deleteTHead}}
\index{deleteTHead@{deleteTHead}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::delete\-THead ()}\label{classDOM_1_1HTMLTableElement_a33}


Delete the header from the table, if one exists. 

\begin{Desc}
\item[Returns:]\end{Desc}


Definition at line 576 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!createTFoot@{createTFoot}}
\index{createTFoot@{createTFoot}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf HTMLElement} HTMLTable\-Element::create\-TFoot ()}\label{classDOM_1_1HTMLTableElement_a34}


Create a table footer row or return an existing one. 

\begin{Desc}
\item[Returns:]A footer element ( {\tt TFOOT} ). \end{Desc}


Definition at line 582 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!deleteTFoot@{deleteTFoot}}
\index{deleteTFoot@{deleteTFoot}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::delete\-TFoot ()}\label{classDOM_1_1HTMLTableElement_a35}


Delete the footer from the table, if one exists. 

\begin{Desc}
\item[Returns:]\end{Desc}


Definition at line 588 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!createCaption@{createCaption}}
\index{createCaption@{createCaption}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf HTMLElement} HTMLTable\-Element::create\-Caption ()}\label{classDOM_1_1HTMLTableElement_a36}


Create a new table caption object or return an existing one. 

\begin{Desc}
\item[Returns:]A {\tt CAPTION} element. \end{Desc}


Definition at line 594 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!deleteCaption@{deleteCaption}}
\index{deleteCaption@{deleteCaption}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::delete\-Caption ()}\label{classDOM_1_1HTMLTableElement_a37}


Delete the table caption, if one exists. 

\begin{Desc}
\item[Returns:]\end{Desc}


Definition at line 600 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!insertRow@{insertRow}}
\index{insertRow@{insertRow}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}{\bf HTMLElement} HTMLTable\-Element::insert\-Row (long {\em index})}\label{classDOM_1_1HTMLTableElement_a38}


Insert a new empty row in the table. 

The new row is inserted immediately before and in the same section as the current indexth row in the table. If index is -1 or equal to the number of rows, the new row is appended. In addition, when the table is empty the row is inserted into a TBODY which is created and inserted into the table. Note. A table row cannot be empty according to HTML 4.0 Recommendation.

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em index}]The row number where to insert a new row. The index starts from 0 and is relative to the logical order (not document order) of all the rows contained inside the table.\end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]The newly created row. \end{Desc}


Definition at line 606 of file html\_\-table.cpp.\index{DOM::HTMLTableElement@{DOM::HTMLTable\-Element}!deleteRow@{deleteRow}}
\index{deleteRow@{deleteRow}!DOM::HTMLTableElement@{DOM::HTMLTable\-Element}}
\subsubsection{\setlength{\rightskip}{0pt plus 5cm}void HTMLTable\-Element::delete\-Row (long {\em index})}\label{classDOM_1_1HTMLTableElement_a39}


Delete a table row. 

\begin{Desc}
\item[Parameters:]
\begin{description}
\item[{\em index}]The index of the row to be deleted. This index starts from 0 and is relative to the logical order (not document order) of all the rows contained inside the table. If the index is -1 the last row in the table is deleted.\end{description}
\end{Desc}
\begin{Desc}
\item[Returns:]\end{Desc}


Definition at line 616 of file html\_\-table.cpp.

The documentation for this class was generated from the following files:\begin{CompactItemize}
\item 
html\_\-table.h\item 
html\_\-table.cpp\end{CompactItemize}
