![]() |
XRootD
|
#include <BufferUtils.hh>
Public Member Functions | |
Extent (off_t offset, size_t len) | |
Ecapsulates an offsets and length, with added functionaliyu Class that represents an offset possition and a length. Simplest usecase is to avoid passing two values around, however this class provides additional funcationality for manipulation of extends (e.g. merging, splitting) which may prove useful. More... | |
bool | allInExtent (off_t pos, size_t len) const |
is all the range in this extent More... | |
off_t | begin () const |
Same as offset, but a bit more stl container like. More... | |
Extent | containedExtent (const Extent &in) const |
Extent | containedExtent (off_t pos, size_t len) const |
return the subset of range that is in this extent More... | |
bool | empty () const |
off_t | end () const |
similar to stl vector end. More... | |
bool | in_extent (off_t pos) const |
is this position within the range of this extent More... | |
bool | isContiguous (const Extent &rhs) const |
off_t | last_pos () const |
last real position More... | |
size_t | len () const |
off_t | offset () const |
bool | operator< (const Extent &rhs) const |
bool | operator== (const Extent &rhs) const |
bool | someInExtent (off_t pos, size_t len) const |
is some of the range in this extent More... | |
Definition at line 53 of file BufferUtils.hh.
|
inline |
Ecapsulates an offsets and length, with added functionaliyu Class that represents an offset possition and a length. Simplest usecase is to avoid passing two values around, however this class provides additional funcationality for manipulation of extends (e.g. merging, splitting) which may prove useful.
Definition at line 64 of file BufferUtils.hh.
Referenced by containedExtent().
bool Extent::allInExtent | ( | off_t | pos, |
size_t | len | ||
) | const |
is all the range in this extent
Definition at line 28 of file BufferUtils.cc.
References begin(), end(), and len().
|
inline |
Same as offset, but a bit more stl container like.
Definition at line 67 of file BufferUtils.hh.
Referenced by allInExtent(), containedExtent(), in_extent(), isContiguous(), operator<(), operator==(), XrdCephBuffer::ExtentHolder::push_back(), and someInExtent().
Definition at line 53 of file BufferUtils.cc.
References begin(), containedExtent(), and len().
Extent Extent::containedExtent | ( | off_t | pos, |
size_t | len | ||
) | const |
return the subset of range that is in this extent
Definition at line 45 of file BufferUtils.cc.
References Extent(), begin(), end(), and len().
Referenced by containedExtent().
|
inline |
Definition at line 69 of file BufferUtils.hh.
|
inline |
similar to stl vector end.
Definition at line 68 of file BufferUtils.hh.
Referenced by allInExtent(), containedExtent(), in_extent(), isContiguous(), operator<(), operator==(), XrdCephBuffer::ExtentHolder::push_back(), and someInExtent().
bool Extent::in_extent | ( | off_t | pos | ) | const |
bool Extent::isContiguous | ( | const Extent & | rhs | ) | const |
Does the start of the rhs continue directly from the end of this Extent
Definition at line 20 of file BufferUtils.cc.
References begin(), and end().
|
inline |
last real position
Definition at line 77 of file BufferUtils.hh.
|
inline |
Definition at line 66 of file BufferUtils.hh.
Referenced by allInExtent(), XrdCephBuffer::ExtentHolder::bytesMissing(), containedExtent(), and someInExtent().
|
inline |
Definition at line 65 of file BufferUtils.hh.
bool Extent::operator< | ( | const Extent & | rhs | ) | const |
Definition at line 58 of file BufferUtils.cc.
References begin(), and end().
bool Extent::operator== | ( | const Extent & | rhs | ) | const |
bool Extent::someInExtent | ( | off_t | pos, |
size_t | len | ||
) | const |