| 3105 | */ |
| 3106 | template <class DataType> |
| 3107 | typename QCPDataContainer<DataType>::const_iterator QCPDataContainer<DataType>::findBegin(double sortKey, bool expandedRange) const |
| 3108 | { |
| 3109 | if (isEmpty()) |
| 3110 | return constEnd(); |
| 3111 | |
| 3112 | QCPDataContainer<DataType>::const_iterator it = std::lower_bound(constBegin(), constEnd(), DataType::fromSortKey(sortKey), qcpLessThanSortKey<DataType>); |
| 3113 | if (expandedRange && it != constBegin()) // also covers it == constEnd case, and we know --constEnd is valid because mData isn't empty |
| 3114 | --it; |
| 3115 | return it; |
| 3116 | } |
| 3117 | |
| 3118 | /*! |
| 3119 | Returns an iterator to the element after the data point with a (sort-)key that is equal to, just |
no test coverage detected