Class Region
java.lang.Object
org.terracotta.offheapstore.util.AATreeSet.AbstractTreeNode<Region>
org.terracotta.offheapstore.disk.storage.Region
- All Implemented Interfaces:
Comparable<Comparable<?>>, AATreeSet.Node<Region>
Class that represents the regions held within this set.
-
Field Summary
FieldsModifier and TypeFieldDescriptionprivate longprivate longprivate long -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescription(package private) long(package private) longintcompareTo(Comparable<?> other) Order this region relative to another.longend()booleaninthashCode()protected booleanisNull()voidMerge the supplied region into this region (if they are adjoining).voidvoidlongsize()Returns the size of this range (the number of values within its bounds).longstart()Returns the start of this range (inclusive).voidswapPayload(AATreeSet.Node<Region> other) toString()private voidMethods inherited from class AATreeSet.AbstractTreeNode
decrementLevel, getLeft, getLevel, getRight, incrementLevel, setLevel
-
Field Details
-
start
private long start -
end
private long end -
availableBitSet
private long availableBitSet
-
-
Constructor Details
-
Region
Region(long value) -
Region
Region(long start, long end) Creates a region containing the given range of values (inclusive). -
Region
Region(Region r) Create a shallow copy of a region.The new Region has NULL left and right children.
-
-
Method Details
-
available
long available() -
availableHere
long availableHere() -
updateAvailable
private void updateAvailable() -
setLeft
- Specified by:
setLeftin interfaceAATreeSet.Node<Region>- Overrides:
setLeftin classAATreeSet.AbstractTreeNode<Region>
-
setRight
- Specified by:
setRightin interfaceAATreeSet.Node<Region>- Overrides:
setRightin classAATreeSet.AbstractTreeNode<Region>
-
toString
-
size
public long size()Returns the size of this range (the number of values within its bounds). -
isNull
protected boolean isNull() -
remove
-
merge
Merge the supplied region into this region (if they are adjoining).- Parameters:
r- region to merge
-
compareTo
Order this region relative to another.- Specified by:
compareToin interfaceComparable<Comparable<?>>
-
equals
-
hashCode
-
getPayload
- Specified by:
getPayloadin interfaceAATreeSet.Node<Region>
-
swapPayload
- Specified by:
swapPayloadin interfaceAATreeSet.Node<Region>
-
start
public long start()Returns the start of this range (inclusive). -
end
public long end()
-