56 label final = touches ? 1 : 0;
85 else if (!range.size_)
92 const label sz = upper - lower + 1;
113 size_ = upper - lower + 1;
125 is >> range.start_ >> range.size_;
128 is.
check(
"operator>>(Istream&, labelRange&)");
131 if (range.size_ <= 0)
151 os.
check(
"operator<<(Ostream&, const labelRange&)");
Istream & readBegin(const char *funcName)
intWM_LABEL_SIZE_t label
A label is an int32_t or int64_t as specified by the pre-processor macro WM_LABEL_SIZE.
dimensioned< Type > max(const dimensioned< Type > &, const dimensioned< Type > &)
void clear()
Reset to zero size.
An Istream is an abstract base class for all input systems (streams, files, token lists etc)...
virtual bool check(const char *operation) const
Check IOstream status for given operation.
label size() const
Return the effective size of the range.
label first() const
The (inclusive) lower value of the range.
Istream & readEnd(const char *funcName)
Istream & operator>>(Istream &, directionInfo &)
bool intersects(const labelRange &, const bool touches=false) const
Return true if the ranges intersect.
int debugSwitch(const char *name, const int defaultValue=0)
Lookup debug switch or add default value.
labelRange()
Construct an empty range.
An Ostream is an abstract base class for all output systems (streams, files, token lists...
dimensioned< Type > min(const dimensioned< Type > &, const dimensioned< Type > &)
labelRange join(const labelRange &) const
Return a joined range, squashing any gaps in between.
labelRange & operator+=(const labelRange &)
Join ranges, squashing any gaps in between.
Ostream & operator<<(Ostream &, const ensightPart &)
label last() const
The (inclusive) upper value of the range.