DetSkipOctree

sealed trait DetSkipOctree[T <: Exec[T], P, H, A] extends SkipOctree[T, P, H, A]
Companion
object
trait SkipOctree[T, P, H, A]
trait Mutable[T]
trait Disposable[T]
trait Writable
trait Identified[T]
class Object
trait Matchable
class Any

Value members

Abstract methods

def headTree: LeftTopBranch[T, P, H, A]
def lastTree(tx: T): TopBranch[T, P, H, A]
def verifyConsistency(reportOnly: Boolean)(tx: T): IndexedSeq[String]

Inherited methods

def +=(elem: A)(tx: T): DetSkipOctree[T, P, H, A]

Adds an element to the tree. If there is already an element stored at the point represented by the new element, it will be replaced.

Adds an element to the tree. If there is already an element stored at the point represented by the new element, it will be replaced.

Inherited from
SkipOctree
def -=(elem: A)(tx: T): DetSkipOctree[T, P, H, A]

Removes an element from the tree. If the element is not found, this operation does nothing.

Removes an element from the tree. If the element is not found, this operation does nothing.

Inherited from
SkipOctree
def add(elem: A)(tx: T): Boolean

Adds an element to the tree (or replaces a given element with the same point location).

Adds an element to the tree (or replaces a given element with the same point location).

Value Params
elem

the element to add

Returns

true if the element is new in the tree. If a previous entry with the same point view is overwritten, this is true if the elements were '''not equal''', false if they were equal

Inherited from
SkipOctree
def clear(tx: T): Unit
Inherited from
SkipOctree
def contains(elem: A)(tx: T): Boolean

Tests whether the tree contains an element.

Tests whether the tree contains an element.

Inherited from
SkipOctree
def debugPrint(tx: T): String

Returns a string debug representation of the octree.

Returns a string debug representation of the octree.

Inherited from
SkipOctree
def dispose(tx: T): Unit
Inherited from
Disposable
override def equals(that: Any): Boolean
Definition Classes
Identified -> Any
Inherited from
Identified
def get(point: P)(tx: T): Option[A]

Queries the element at a given point.

Queries the element at a given point.

Value Params
point

the point to look up.

Returns

Some element if found, None if the point was not present.

Inherited from
SkipOctree
override def hashCode: Int
Definition Classes
Identified -> Any
Inherited from
Identified
def hyperCube: H

The base square of the tree. No point can lie outside this square (or hyper-cube).

The base square of the tree. No point can lie outside this square (or hyper-cube).

Inherited from
SkipOctree
def id: Ident[T]
Inherited from
Identified
def isDefinedAt(point: P)(tx: T): Boolean

Queries whether an element is stored at a given point.

Queries whether an element is stored at a given point.

Value Params
point

the point to query

Returns

true if an element is associated with the query point, false otherwise

Inherited from
SkipOctree
def isEmpty(tx: T): Boolean

Tests whether the tree is empty (true) or whether it contains any elements (false).

Tests whether the tree is empty (true) or whether it contains any elements (false).

Inherited from
SkipOctree
def iterator(tx: T): Iterator[A]

An Iterator which iterates over the points stored in the octree, using an in-order traversal directed by the orthant indices of the nodes of the tree.

An Iterator which iterates over the points stored in the octree, using an in-order traversal directed by the orthant indices of the nodes of the tree.

Great care has to be taken as the iterator might be corrupted if the tree is successively changed before the iterator is exhausted.

Inherited from
SkipOctree
def nearestNeighbor[M](point: P, metric: DistanceMeasure[M, P, H])(tx: T): A

Reports the nearest neighbor entry with respect to a given point.

Reports the nearest neighbor entry with respect to a given point.

Note: There is a potential numeric overflow if the squared distance of the query point towards the furthest corner of the tree's root hyper-cube exceeds 63 bits. For a root IntSquare(0x40000000, 0x40000000, 0x40000000), this happens for example for any point going more towards north-west than IntPoint2DLike(-1572067139, -1572067139).

Value Params
metric

(description missing)

point

the point of which the nearest neighbor is to be found

Throws
NoSuchElementException

if the tree is empty

Inherited from
SkipOctree
def nearestNeighborOption[M](point: P, metric: DistanceMeasure[M, P, H])(tx: T): Option[A]

Same as nearestNeighbor but returning an Option, thus not throwing an exception if no neighbor is found.

Same as nearestNeighbor but returning an Option, thus not throwing an exception if no neighbor is found.

Inherited from
SkipOctree
def numLevels(tx: T): Int

Reports the number of decimation levels in the tree.

Reports the number of decimation levels in the tree.

Inherited from
SkipOctree
def numOrthants: Int

The number of orthants in each hyperCube. This is equal to 1 << numDimensions and gives the upper bound of the index to QNode.child().

The number of orthants in each hyperCube. This is equal to 1 << numDimensions and gives the upper bound of the index to QNode.child().

Inherited from
SkipOctree
def pointView: (A, T) => P

A function which maps an element (possibly through transactional access) to a geometric point coordinate.

A function which maps an element (possibly through transactional access) to a geometric point coordinate.

Inherited from
SkipOctree
def rangeQuery[Area](qs: QueryShape[Area, P, H])(tx: T): Iterator[A]
Inherited from
SkipOctree
def remove(elem: A)(tx: T): Boolean

Removes an element from the tree

Removes an element from the tree

Value Params
elem

the element to remove

Returns

true if the element had been found in the tree and thus been removed.

Inherited from
SkipOctree
def removeAt(point: P)(tx: T): Option[A]

Removes the element stored under a given point view.

Removes the element stored under a given point view.

Value Params
point

the location of the element to remove

Returns

the element removed, wrapped as Some, or None if no element was found for the given point.

Inherited from
SkipOctree
def size(tx: T): Int

Queries the number of leaves in the tree. This may be a very costly action, so it is recommended to only use it for debugging purposes.

Queries the number of leaves in the tree. This may be a very costly action, so it is recommended to only use it for debugging purposes.

Inherited from
SkipOctree
def space: Space[P, H]

The space (i.e., resolution and dimensionality) underlying the tree.

The space (i.e., resolution and dimensionality) underlying the tree.

Inherited from
SkipOctree
def toIndexedSeq(tx: T): IndexedSeq[A]

Converts the tree into a linearized indexed sequence. This is not necessarily a very efficient method, and should usually just be used for debugging.

Converts the tree into a linearized indexed sequence. This is not necessarily a very efficient method, and should usually just be used for debugging.

Inherited from
SkipOctree
def toList(tx: T): List[A]

Converts the tree into a linearized list. This is not necessarily a very efficient method, and should usually just be used for debugging.

Converts the tree into a linearized list. This is not necessarily a very efficient method, and should usually just be used for debugging.

Inherited from
SkipOctree
def toSeq(tx: T): Seq[A]

Converts the tree into a linearized sequence. This is not necessarily a very efficient method, and should usually just be used for debugging. To avoid surprises, this does not call iterator.toSeq because that would produce a Stream and thus subject to further changes to the tree while traversing. The returned seq instead is 'forced' and thus stable.

Converts the tree into a linearized sequence. This is not necessarily a very efficient method, and should usually just be used for debugging. To avoid surprises, this does not call iterator.toSeq because that would produce a Stream and thus subject to further changes to the tree while traversing. The returned seq instead is 'forced' and thus stable.

Inherited from
SkipOctree
def toSet(tx: T): Set[A]

Converts the tree into a non-transactional set. This is not necessarily a very efficient method, and should usually just be used for debugging.

Converts the tree into a non-transactional set. This is not necessarily a very efficient method, and should usually just be used for debugging.

Inherited from
SkipOctree
def transformAt(point: P)(fun: Option[A] => Option[A])(tx: T): Option[A]

Looks up a point and applies a transformation to the entry associated with it. This can be used to update an element in-place, or used for maintaining a spatial multi-map.

Looks up a point and applies a transformation to the entry associated with it. This can be used to update an element in-place, or used for maintaining a spatial multi-map.

Value Params
fun

a function to transform the element found, or generate a new element. The argument is the element previously stored with the point, or None if no element is found. The result is expected to be Some new element to be stored, or None if no element is to be stored (in this case, if an element was previously stored, it is removed)

point

the location at which to perform the transformation

Returns

the previously stored element (if any)

Inherited from
SkipOctree
def update(elem: A)(tx: T): Option[A]

Adds an element to the tree (or replaces a given element with the same point location).

Adds an element to the tree (or replaces a given element with the same point location).

Value Params
elem

the element to add to the tree

Returns

the old element stored for the same point view, if it existed

Inherited from
SkipOctree
def write(out: DataOutput): Unit
Inherited from
Writable