Package org.loboevolution.html.dom
Interface HTMLTableElement
- All Superinterfaces:
Element
,EventTarget
,HTMLElement
,InnerHTML
,Node
,NonDocumentTypeChildNode
,ParentNode
- All Known Implementing Classes:
HTMLTableElementImpl
Provides special properties and methods (beyond the regular HTMLElement object interface it also has available to it by inheritance) for manipulating the layout and presentation of tables in an HTML document.
-
Field Summary
Fields inherited from interface org.loboevolution.html.node.Node
ATTRIBUTE_NODE, CDATA_SECTION_NODE, COMMENT_NODE, DOCUMENT_FRAGMENT_NODE, DOCUMENT_NODE, DOCUMENT_POSITION_CONTAINED_BY, DOCUMENT_POSITION_CONTAINS, DOCUMENT_POSITION_DISCONNECTED, DOCUMENT_POSITION_FOLLOWING, DOCUMENT_POSITION_IMPLEMENTATION_SPECIFIC, DOCUMENT_POSITION_PRECEDING, DOCUMENT_TYPE_NODE, ELEMENT_NODE, ENTITY_NODE, ENTITY_REFERENCE_NODE, NONE, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE
-
Method Summary
Modifier and TypeMethodDescriptionCreates an empty caption element in the table.Creates an empty tBody element in the table.Creates an empty tFoot element in the table.Returns the tHead element object if successful, or null otherwise.void
Deletes the caption element and its contents from the table.void
deleteRow
(int index) Removes the specified row (tr) from the element and from the rows collection.void
Deletes the tBody element and its contents from the table.void
Deletes the tFoot element and its contents from the table.void
Deletes the tHead element and its contents from the table.getAlign()
Deprecated.Deprecated.Deprecated.Retrieves the caption object of a table.Deprecated.Deprecated.getFrame()
Deprecated.getRows()
Sets or retrieves the number of horizontal rows contained in the object.getRules()
Deprecated.Deprecated.Retrieves a collection of all tBody objects in the table.gettFoot()
Retrieves the tFoot object of the table.gettHead()
Retrieves the tHead object of the table.getWidth()
Deprecated.insertRow.insertRow
(int index) Creates a new row (tr) in the table, and adds the row to the rows collection.void
setAlign.void
setBgColor
(String bgColor) setBgColor.void
setBorder.void
setCaption
(HTMLTableCaptionElement caption) setCaption.void
setCellPadding
(String cellPadding) setCellPadding.void
setCellSpacing
(String cellSpacing) setCellSpacing.void
setFrame.void
setRules.void
setSummary
(String summary) setSummary.void
settFoot
(HTMLTableSectionElement tFoot) settFoot.void
settHead
(HTMLTableSectionElement tHead) settHead.void
setWidth.Methods inherited from interface org.loboevolution.html.node.Element
closest, getAttribute, getAttributeNames, getAttributeNode, getAttributeNodeNS, getAttributeNS, getBoundingClientRect, getClassList, getClassName, getClientHeight, getClientLeft, getClientRects, getClientTop, getClientWidth, getElementsByClassName, getElementsByTagName, getElementsByTagNameNS, getId, getInnerHTML, getLocalName, getNamespaceURI, getOuterHTML, getPrefix, getSchemaTypeInfo, getScrollHeight, getScrollLeft, getScrollTop, getScrollWidth, getSlot, getTagName, hasAttribute, hasAttributeNS, hasPointerCapture, insertAdjacentElement, insertAdjacentHTML, matches, releasePointerCapture, removeAttribute, removeAttributeNode, removeAttributeNS, requestPointerLock, scroll, scrollBy, scrollIntoView, scrollIntoView, scrollTo, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setClassName, setId, setIdAttribute, setIdAttributeNode, setIdAttributeNS, setOuterHTML, setPointerCapture, setScrollLeft, setScrollTop, setSlot, toggleAttribute, toggleAttribute
Methods inherited from interface org.loboevolution.events.EventTarget
addEventListener, addEventListener, dispatchEvent, dispatchEvent, removeEventListener, removeEventListener
Methods inherited from interface org.loboevolution.html.dom.HTMLElement
click, getAccessKey, getAccessKeyLabel, getAutocapitalize, getContentEditable, getDir, getInnerText, getLang, getOffsetHeight, getOffsetLeft, getOffsetParent, getOffsetTop, getOffsetWidth, getTitle, isDraggable, isHidden, isSpellcheck, isTranslate, setAccessKey, setAutocapitalize, setContentEditable, setDir, setDraggable, setHidden, setInnerText, setLang, setSpellcheck, setTitle, setTranslate
Methods inherited from interface org.loboevolution.html.node.InnerHTML
setInnerHTML
Methods inherited from interface org.loboevolution.html.node.Node
appendChild, cloneNode, cloneNode, compareDocumentPosition, contains, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentElement, getParentNode, getPreviousSibling, getRootNode, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isIsConnected, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, prepend, prependChild, removeChild, replaceChild, setNodeValue, setOwnerDocument, setPrefix, setTextContent, setUserData
Methods inherited from interface org.loboevolution.html.node.NonDocumentTypeChildNode
getNextElementSibling, getPreviousElementSibling
Methods inherited from interface org.loboevolution.html.node.ParentNode
getChildElementCount, getChildren, getFirstElementChild, getLastElementChild, querySelector, querySelectorAll
-
Method Details
-
getAlign
Deprecated.Sets or retrieves a value that indicates the table alignment.- Returns:
- a
String
object.
-
setAlign
setAlign.
- Parameters:
align
- aString
object.
-
getBgColor
Deprecated.getBgColor.
- Returns:
- a
String
object.
-
setBgColor
setBgColor.
- Parameters:
bgColor
- aString
object.
-
getBorder
Deprecated.Sets or retrieves the width of the border to draw around the object.- Returns:
- a
String
object.
-
setBorder
setBorder.
- Parameters:
border
- aString
object.
-
getCaption
HTMLTableCaptionElement getCaption()Retrieves the caption object of a table.- Returns:
- a
HTMLTableCaptionElement
object.
-
setCaption
setCaption.
- Parameters:
caption
- aHTMLTableCaptionElement
object.
-
getCellPadding
Deprecated.Sets or retrieves the amount of space between the border of the cell and the content of the cell.- Returns:
- a
String
object.
-
setCellPadding
setCellPadding.
- Parameters:
cellPadding
- aString
object.
-
getCellSpacing
Deprecated.Sets or retrieves the amount of space between cells in a table.- Returns:
- a
String
object.
-
setCellSpacing
setCellSpacing.
- Parameters:
cellSpacing
- aString
object.
-
getFrame
Deprecated.Sets or retrieves the way the border frame around the table is displayed.- Returns:
- a
String
object.
-
setFrame
setFrame.
- Parameters:
frame
- aString
object.
-
getRows
HTMLCollection getRows()Sets or retrieves the number of horizontal rows contained in the object.- Returns:
- a
HTMLCollection
object.
-
getRules
Deprecated.Sets or retrieves which dividing lines (inner borders) are displayed.- Returns:
- a
String
object.
-
setRules
setRules.
- Parameters:
rules
- aString
object.
-
getSummary
Deprecated.Sets or retrieves a description and/or structure of the object.- Returns:
- a
String
object.
-
setSummary
setSummary.
- Parameters:
summary
- aString
object.
-
gettBodies
HTMLCollection gettBodies()Retrieves a collection of all tBody objects in the table. Objects in this collection are in source order.- Returns:
- a
HTMLCollection
object.
-
gettFoot
HTMLTableSectionElement gettFoot()Retrieves the tFoot object of the table.- Returns:
- a
HTMLTableSectionElement
object.
-
settFoot
settFoot.
- Parameters:
tFoot
- aHTMLTableSectionElement
object.
-
gettHead
HTMLTableSectionElement gettHead()Retrieves the tHead object of the table.- Returns:
- a
HTMLTableSectionElement
object.
-
settHead
settHead.
- Parameters:
tHead
- aHTMLTableSectionElement
object.
-
getWidth
Deprecated.Sets or retrieves the width of the object.- Returns:
- a
String
object.
-
setWidth
setWidth.
- Parameters:
width
- aString
object.
-
createCaption
HTMLElement createCaption()Creates an empty caption element in the table.- Returns:
- a
HTMLElement
object.
-
createTBody
HTMLElement createTBody()Creates an empty tBody element in the table.- Returns:
- a
HTMLElement
object.
-
createTFoot
HTMLElement createTFoot()Creates an empty tFoot element in the table.- Returns:
- a
HTMLElement
object.
-
createTHead
HTMLElement createTHead()Returns the tHead element object if successful, or null otherwise.- Returns:
- a
HTMLElement
object.
-
deleteCaption
void deleteCaption()Deletes the caption element and its contents from the table. -
deleteRow
void deleteRow(int index) Removes the specified row (tr) from the element and from the rows collection.- Parameters:
index
- Number that specifies the zero-based position in the rows collection of the row to remove.
-
deleteTFoot
void deleteTFoot()Deletes the tFoot element and its contents from the table. -
deleteTHead
void deleteTHead()Deletes the tHead element and its contents from the table. -
deleteTBody
void deleteTBody()Deletes the tBody element and its contents from the table. -
insertRow
Creates a new row (tr) in the table, and adds the row to the rows collection.- Parameters:
index
- Number that specifies where to insert the row in the rows collection. The default value is -1, which appends the new row to the end of the rows collection.- Returns:
- a
HTMLTableRowElement
object. - Throws:
Exception
- if any.
-
insertRow
HTMLTableRowElement insertRow()insertRow.
- Returns:
- a
HTMLTableRowElement
object.
-