ParentNode

object ParentNode
Companion
class
class Object
trait Matchable
class Any

Type members

Types

type Base = ParentNode[Element]

Value members

Concrete methods

def appendChild(parent: Base, child: Base): Boolean

Note: can also be used to move children, even within the same parent

Note: can also be used to move children, even within the same parent

Returns

Whether child was successfully appended

def indexOfChild(parent: Base, child: Base): Int
def insertChild(parent: Base, child: Base, atIndex: Int): Boolean

Note: can also be used to move children, even within the same parent

Note: can also be used to move children, even within the same parent

Returns

Whether child was successfully inserted

def removeChild(parent: Base, child: Base): Boolean
Returns

Whether child was successfully removed

def replaceAllChildren(parent: Base, newChildren: Iterable[Base]): Unit
def replaceChild(parent: Base, oldChild: Base, newChild: Base): Boolean

Note: Does nothing if oldChild was not found in parent's children, or if oldChild==newChild

Note: Does nothing if oldChild was not found in parent's children, or if oldChild==newChild

Returns

Whether child was replaced

def replaceChildren(parent: Base, fromIndex: Int, toIndex: Int, newChildren: Iterable[Base]): Boolean

Note: Does nothing if fromIndex or toIndex are out of bounds or if fromIndex>toIndex

Note: Does nothing if fromIndex or toIndex are out of bounds or if fromIndex>toIndex

Returns

Whether children were replaced