@TagName(value="table") public class TableElement extends Element
Modifier and Type | Field and Description |
---|---|
static String |
TAG |
DRAGGABLE_AUTO, DRAGGABLE_FALSE, DRAGGABLE_TRUE
DOCUMENT_NODE, ELEMENT_NODE, TEXT_NODE
Modifier | Constructor and Description |
---|---|
protected |
TableElement() |
Modifier and Type | Method and Description |
---|---|
static TableElement |
as(Element elem)
Assert that the given
Element is compatible with this class and
automatically typecast it. |
TableCaptionElement |
createCaption()
Create a new table caption object or return an existing one.
|
TableSectionElement |
createTFoot()
Create a table footer row or return an existing one.
|
TableSectionElement |
createTHead()
Create a table header row or return an existing one.
|
void |
deleteCaption()
Delete the table caption, if one exists.
|
void |
deleteRow(int index)
Delete a table row.
|
void |
deleteTFoot()
Delete the header from the table, if one exists.
|
void |
deleteTHead()
Delete the header from the table, if one exists.
|
int |
getBorder()
The width of the border around the table.
|
TableCaptionElement |
getCaption()
The table's CAPTION, or null if none exists.
|
int |
getCellPadding()
Specifies the horizontal and vertical space between cell content and cell
borders.
|
int |
getCellSpacing()
Specifies the horizontal and vertical separation between cells.
|
String |
getFrame()
Specifies which external table borders to render.
|
NodeList<TableRowElement> |
getRows()
Returns a collection of all the rows in the table, including all in THEAD,
TFOOT, all TBODY elements.
|
String |
getRules()
Specifies which internal table borders to render.
|
NodeList<TableSectionElement> |
getTBodies()
Returns a collection of the table bodies (including implicit ones).
|
TableSectionElement |
getTFoot()
The table's TFOOT, or null if none exists.
|
TableSectionElement |
getTHead()
The table's THEAD, or null if none exists.
|
String |
getWidth()
Specifies the desired table width.
|
TableRowElement |
insertRow(int index)
Insert a new empty row in the table.
|
static boolean |
is(Element elem)
Determine whether the given
Element can be cast to this class. |
static boolean |
is(JavaScriptObject o)
Determines whether the given
JavaScriptObject can be cast to
this class. |
static boolean |
is(Node node)
Determine whether the given
Node can be cast to this class. |
void |
setBorder(int border)
The width of the border around the table.
|
void |
setCaption(TableCaptionElement caption)
The table's CAPTION, or null if none exists.
|
void |
setCellPadding(int cellPadding)
Specifies the horizontal and vertical space between cell content and cell
borders.
|
void |
setCellSpacing(int cellSpacing)
Specifies the horizontal and vertical separation between cells.
|
void |
setFrame(String frame)
Specifies which external table borders to render.
|
void |
setRules(String rules)
Specifies which internal table borders to render.
|
void |
setTFoot(TableSectionElement tFoot)
The table's TFOOT, or null if none exists.
|
void |
setTHead(TableSectionElement tHead)
The table's THEAD, or null if none exists.
|
void |
setWidth(String width)
Specifies the desired table width.
|
addClassName, as, as, blur, dispatchEvent, focus, getAbsoluteBottom, getAbsoluteLeft, getAbsoluteRight, getAbsoluteTop, getAttribute, getClassName, getClientHeight, getClientWidth, getDir, getDraggable, getElementsByTagName, getFirstChildElement, getId, getInnerHTML, getInnerText, getLang, getNextSiblingElement, getOffsetHeight, getOffsetLeft, getOffsetParent, getOffsetTop, getOffsetWidth, getPreviousSiblingElement, getPropertyBoolean, getPropertyDouble, getPropertyInt, getPropertyJSO, getPropertyObject, getPropertyString, getScrollHeight, getScrollLeft, getScrollTop, getScrollWidth, getString, getStyle, getTabIndex, getTagName, getTitle, hasAttribute, hasClassName, hasTagName, removeAttribute, removeClassName, replaceClassName, scrollIntoView, setAttribute, setClassName, setDir, setDraggable, setId, setInnerHTML, setInnerSafeHtml, setInnerText, setLang, setPropertyBoolean, setPropertyDouble, setPropertyInt, setPropertyJSO, setPropertyObject, setPropertyString, setScrollLeft, setScrollTop, setTabIndex, setTitle, toggleClassName
appendChild, cloneNode, getChild, getChildCount, getChildNodes, getFirstChild, getLastChild, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentElement, getParentNode, getPreviousSibling, hasChildNodes, hasParentElement, insertAfter, insertBefore, insertFirst, isOrHasChild, removeAllChildren, removeChild, removeFromParent, replaceChild, setNodeValue
cast, createArray, createArray, createFunction, createObject, equals, hashCode, toSource, toString
public static final String TAG
public static TableElement as(Element elem)
Element
is compatible with this class and
automatically typecast it.public static boolean is(JavaScriptObject o)
JavaScriptObject
can be cast to
this class. A null
object will cause this method to
return false
.public static boolean is(Node node)
Node
can be cast to this class.
A null
node will cause this method to return
false
.public static boolean is(Element elem)
Element
can be cast to this class.
A null
node will cause this method to return
false
.public final TableCaptionElement createCaption()
public final TableSectionElement createTFoot()
public final TableSectionElement createTHead()
public final void deleteCaption()
public final void deleteRow(int index)
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 deletedpublic final void deleteTFoot()
public final void deleteTHead()
public final int getBorder()
public final TableCaptionElement getCaption()
public final int getCellPadding()
public final int getCellSpacing()
public final String getFrame()
public final NodeList<TableRowElement> getRows()
public final String getRules()
public final NodeList<TableSectionElement> getTBodies()
public final TableSectionElement getTFoot()
public final TableSectionElement getTHead()
public final String getWidth()
public final TableRowElement insertRow(int index)
index
- The row number where to insert a new row. This index starts
from 0 and is relative to the logical order (not document order)
of all the rows contained inside the tablepublic final void setBorder(int border)
public final void setCaption(TableCaptionElement caption)
public final void setCellPadding(int cellPadding)
public final void setCellSpacing(int cellSpacing)
public final void setFrame(String frame)
public final void setRules(String rules)
public final void setTFoot(TableSectionElement tFoot)
public final void setTHead(TableSectionElement tHead)
public final void setWidth(String width)
Copyright © 2018. All rights reserved.