Documentation
¶
Index ¶
- type UintInterval
- func (r *UintInterval) Contains(o *UintInterval) bool
- func (r *UintInterval) ContainsValue(v uint) bool
- func (r *UintInterval) End() uint
- func (r *UintInterval) Equal(o *UintInterval) bool
- func (r *UintInterval) First() uint
- func (r *UintInterval) Last() uint
- func (r *UintInterval) Overlaps(o *UintInterval) bool
- func (r *UintInterval) Size() uint
- func (r *UintInterval) Start() uint
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type UintInterval ¶
type UintInterval struct {
// contains filtered or unexported fields
}
UintInterval represents an unsigned integer interval.
func NewUint ¶
func NewUint(start uint, size uint) UintInterval
NewUint constructs a new UintInterval instance.
func (*UintInterval) Contains ¶
func (r *UintInterval) Contains(o *UintInterval) bool
Contains returns true iff `o` is contained within the interval.
func (*UintInterval) ContainsValue ¶
func (r *UintInterval) ContainsValue(v uint) bool
ContainsValue returns true iff the value is contained within the interval.
func (*UintInterval) End ¶
func (r *UintInterval) End() uint
End returns the first value outside of (past) the interval. (i.e. exclusive interval end)
func (*UintInterval) Equal ¶
func (r *UintInterval) Equal(o *UintInterval) bool
Equal returns true iff two intervals are equal.
func (*UintInterval) First ¶
func (r *UintInterval) First() uint
First returns the start/first value within the interval.
func (*UintInterval) Last ¶
func (r *UintInterval) Last() uint
Last returns the last value within the interval. (i.e. inclusive interval end)
func (*UintInterval) Overlaps ¶
func (r *UintInterval) Overlaps(o *UintInterval) bool
Overlaps returns true iff there is some overlap between `o` and the interval.
func (*UintInterval) Size ¶
func (r *UintInterval) Size() uint
Size returns the size of the interval.
func (*UintInterval) Start ¶
func (r *UintInterval) Start() uint
Start returns the start/first value within the interval.