Header menu logo B2R2

IntervalSet Module

Provides functions for creating or manipulating interval sets.

Functions and values

Function or value Description

IntervalSet.add i arg2

Full Usage: IntervalSet.add i arg2

Parameters:
Returns: IntervalSet

Adds an interval to the interval set. Overlapping intervals are allowed, but an exact duplicate range is not.

i : AddrRange
arg1 : IntervalSet
Returns: IntervalSet

IntervalSet.containsAddr addr s

Full Usage: IntervalSet.containsAddr addr s

Parameters:
Returns: bool

Checks whether the given address exists in the interval set.

addr : Addr
s : IntervalSet
Returns: bool

IntervalSet.containsRange i arg2

Full Usage: IntervalSet.containsRange i arg2

Parameters:
Returns: bool

Checks whether the exact interval exists in the interval set.

i : AddrRange
arg1 : IntervalSet
Returns: bool

IntervalSet.count arg1

Full Usage: IntervalSet.count arg1

Parameters:
Returns: int

Returns the number of intervals in the interval set.

arg0 : IntervalSet
Returns: int

IntervalSet.empty

Full Usage: IntervalSet.empty

Returns: IntervalSet

Empty interval tree.

Returns: IntervalSet

IntervalSet.findAll range arg2

Full Usage: IntervalSet.findAll range arg2

Parameters:
Returns: AddrRange list

Finds all intervals that overlap with the given range. The returned list follows the interval tree traversal order.

range : AddrRange
arg1 : IntervalSet
Returns: AddrRange list

IntervalSet.findExactlyOneByMin addr s

Full Usage: IntervalSet.findExactlyOneByMin addr s

Parameters:
Returns: AddrRange

Finds the interval whose low bound (Min) equals the given address when there is exactly one such interval; raises KeyNotFoundException otherwise.

addr : Addr
s : IntervalSet
Returns: AddrRange

IntervalSet.findOverlappingOne range s

Full Usage: IntervalSet.findOverlappingOne range s

Parameters:
Returns: AddrRange

Finds the interval that overlaps with the given range when there is exactly one such interval; raises KeyNotFoundException otherwise.

range : AddrRange
s : IntervalSet
Returns: AddrRange

IntervalSet.findOverlappingOneByAddr addr s

Full Usage: IntervalSet.findOverlappingOneByAddr addr s

Parameters:
Returns: AddrRange

Finds the interval that contains the given address when there is exactly one such interval; raises KeyNotFoundException otherwise.

addr : Addr
s : IntervalSet
Returns: AddrRange

IntervalSet.fold fn acc arg3

Full Usage: IntervalSet.fold fn acc arg3

Parameters:
Returns: 'a
Type parameters: 'a

Folds the elements in the interval set.

fn : 'a -> AddrRange -> 'a
acc : 'a
arg2 : IntervalSet
Returns: 'a

IntervalSet.isEmpty s

Full Usage: IntervalSet.isEmpty s

Parameters:
Returns: bool

Checks if the given interval tree is empty.

s : IntervalSet
Returns: bool

IntervalSet.iter fn s

Full Usage: IntervalSet.iter fn s

Parameters:

Iterates the elements in the interval set.

fn : AddrRange -> unit
s : IntervalSet

IntervalSet.overlapsRange range arg2

Full Usage: IntervalSet.overlapsRange range arg2

Parameters:
Returns: bool

Checks whether the given address interval overlaps with any of the intervals in the interval set.

range : AddrRange
arg1 : IntervalSet
Returns: bool

IntervalSet.remove range arg2

Full Usage: IntervalSet.remove range arg2

Parameters:
Returns: IntervalSet

Removes the interval that exactly matches the given range. Raises InvalidAddrRangeException if there is no such interval.

range : AddrRange
arg1 : IntervalSet
Returns: IntervalSet

IntervalSet.tryFindExactlyOneByMin addr arg2

Full Usage: IntervalSet.tryFindExactlyOneByMin addr arg2

Parameters:
Returns: AddrRange option

Finds the interval whose low bound (Min) equals the given address only when there is exactly one such interval.

addr : Addr
arg1 : IntervalSet
Returns: AddrRange option

IntervalSet.tryFindOverlappingOne range s

Full Usage: IntervalSet.tryFindOverlappingOne range s

Parameters:
Returns: AddrRange option

Finds the interval that overlaps with the given range only when there is exactly one such interval.

range : AddrRange
s : IntervalSet
Returns: AddrRange option

IntervalSet.tryFindOverlappingOneByAddr addr s

Full Usage: IntervalSet.tryFindOverlappingOneByAddr addr s

Parameters:
Returns: AddrRange option

Finds the interval that contains the given address only when there is exactly one such interval.

addr : Addr
s : IntervalSet
Returns: AddrRange option

Type something to start searching.