You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
39 lines
1.2 KiB
39 lines
1.2 KiB
#ifndef STORM_LOGIC_BOUND_H_
|
|
#define STORM_LOGIC_BOUND_H_
|
|
|
|
#include "storm/logic/ComparisonType.h"
|
|
#include "storm/utility/constants.h"
|
|
|
|
namespace storm {
|
|
namespace logic {
|
|
template<typename ValueType>
|
|
struct Bound {
|
|
Bound(ComparisonType comparisonType, ValueType const& threshold) : comparisonType(comparisonType), threshold(threshold) {
|
|
// Intentionally left empty.
|
|
}
|
|
|
|
template<typename OtherValueType>
|
|
Bound<OtherValueType> convertToOtherValueType() const {
|
|
return Bound<OtherValueType>(comparisonType, storm::utility::convertNumber<OtherValueType>(threshold));
|
|
}
|
|
|
|
ComparisonType comparisonType;
|
|
ValueType threshold;
|
|
|
|
template<typename ValueTypePrime>
|
|
friend std::ostream& operator<<(std::ostream& out, Bound<ValueTypePrime> const& bound);
|
|
};
|
|
|
|
template<typename ValueType>
|
|
std::ostream& operator<<(std::ostream& out, Bound<ValueType> const& bound) {
|
|
out << bound.comparisonType << bound.threshold;
|
|
return out;
|
|
}
|
|
}
|
|
|
|
template<typename ValueType>
|
|
using Bound = typename logic::Bound<ValueType>;
|
|
}
|
|
|
|
#endif /* STORM_LOGIC_BOUND_H_ */
|
|
|