Interface MathMLVectorElement
- All Superinterfaces:
Element, MathMLContentElement, MathMLElement, Node
- All Known Implementing Classes:
MathMLVectorElementImpl
This interface represents the
vector element in MathML Content.
A vector is a mathematical object that has a direction and a magnitude.- Since:
- 1.0
- Author:
- Silvere Martin-Michiellot, Gemini AI (Google DeepMind)
-
Field Summary
Fields inherited from interface 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, NOTATION_NODE, PROCESSING_INSTRUCTION_NODE, TEXT_NODE -
Method Summary
Modifier and TypeMethodDescriptionvoiddeleteComponent(int index) Deletes the component at the specifiedindex.getComponent(int index) Returns theindex-th component of this vector.intReturns the number of components in this vector.insertComponent(MathMLContentElement newComponent, int index) Inserts a new component into the vector at the specifiedindex.removeComponent(int index) Removes and returns the component at the specifiedindex.setComponent(MathMLContentElement newComponent, int index) Replaces the component at the specifiedindexwith a new component.Methods inherited from interface Element
getAttribute, getAttributeNode, getAttributeNodeNS, getAttributeNS, getElementsByTagName, getElementsByTagNameNS, getSchemaTypeInfo, getTagName, hasAttribute, hasAttributeNS, removeAttribute, removeAttributeNode, removeAttributeNS, setAttribute, setAttributeNode, setAttributeNodeNS, setAttributeNS, setIdAttribute, setIdAttributeNode, setIdAttributeNSMethods inherited from interface MathMLElement
getClassName, getHref, getId, getMathElementStyle, getOwnerMathElement, getXref, setClassName, setHref, setId, setMathElementStyle, setXrefMethods inherited from interface Node
appendChild, cloneNode, compareDocumentPosition, getAttributes, getBaseURI, getChildNodes, getFeature, getFirstChild, getLastChild, getLocalName, getNamespaceURI, getNextSibling, getNodeName, getNodeType, getNodeValue, getOwnerDocument, getParentNode, getPrefix, getPreviousSibling, getTextContent, getUserData, hasAttributes, hasChildNodes, insertBefore, isDefaultNamespace, isEqualNode, isSameNode, isSupported, lookupNamespaceURI, lookupPrefix, normalize, removeChild, replaceChild, setNodeValue, setPrefix, setTextContent, setUserData
-
Method Details
-
getNcomponents
int getNcomponents()Returns the number of components in this vector.- Returns:
- the number of components.
-
getComponent
Returns theindex-th component of this vector.- Parameters:
index- the index of the component to retrieve.- Returns:
- the component at the specified index.
-
insertComponent
MathMLContentElement insertComponent(MathMLContentElement newComponent, int index) throws DOMException Inserts a new component into the vector at the specifiedindex.- Parameters:
newComponent- the new component to insert.index- the index at which the new component is to be inserted.- Returns:
- the newly inserted component.
- Throws:
DOMException- INDEX_SIZE_ERR if the index is out of bounds.
-
setComponent
Replaces the component at the specifiedindexwith a new component.- Parameters:
newComponent- the new component to set.index- the index of the component to replace.- Returns:
- the newly set component.
- Throws:
DOMException- INDEX_SIZE_ERR if the index is out of bounds.
-
deleteComponent
Deletes the component at the specifiedindex.- Parameters:
index- the index of the component to delete.- Throws:
DOMException- INDEX_SIZE_ERR if the index is out of bounds.
-
removeComponent
Removes and returns the component at the specifiedindex.- Parameters:
index- the index of the component to remove.- Returns:
- the removed component.
-