| 49 | } |
| 50 | |
| 51 | bool StreamDBOperator::HasStream(const std::string& stream_id) { |
| 52 | using Storage = decltype(db_->GetStorageTypeValue()); |
| 53 | auto storage = std::any_cast<Storage>(db_->GetDbStorage()); |
| 54 | auto streams = storage.get_all<spvr::SpvrStream>(where(c(&spvr::SpvrStream::stream_id_) == stream_id)); |
| 55 | return !streams.empty(); |
| 56 | } |
| 57 | |
| 58 | bool StreamDBOperator::UpdateStream(std::shared_ptr<spvr::SpvrStream> stream) { |
| 59 | stream->updated_timestamp_ = (int64_t)TimeUtil::GetCurrentTimestamp(); |
nothing calls this directly
no test coverage detected