Library: OSP
Package: Util
Header: Poco/OSP/VersionRange.h
This utility class represents a range of versions.
A version range can be an open, half closed or closed interval.
Member Functions: includeLower, includeUpper, isEmpty, isInRange, lowerBound, operator =, swap, toString, upperBound
VersionRange();
Creates an empty VersionRange.
VersionRange(
const VersionRange & range
);
Creates a VersionRange by copying another one.
VersionRange(
const Version & lower,
bool includeLower,
const Version & upper,
bool includeUpper
);
Creates the VersionRange.
~VersionRange();
Destroys the VersionRange.
bool includeLower() const;
Returns true if and only if the lower bound lies within the interval.
bool includeUpper() const;
Returns true if and only if the upper bound lies within the interval.
bool isEmpty() const;
Returns true if and only if the version range is empty.
bool isInRange(
const Version & version
) const;
Returns true if and only if the version lies within the range.
const Version & lowerBound() const;
Returns the lower bound of the interval.
VersionRange & operator = (
const VersionRange & range
);
Assigns another VersionRange.
void swap(
VersionRange & range
);
Swaps the VersionRange with another one.
std::string toString() const;
Returns a string representation of the version range.
const Version & upperBound() const;
Returns the upper bound of the interval.