| 330 | // subscriber subscribe |
| 331 | template <class T, concepts::SupportedSubscriber<T> TCallback> |
| 332 | void OpSub::DoSubscribe(const res::Subscriber<T>& ch, TCallback callback, aimrt::executor::ExecutorRef exe) { |
| 333 | auto& channel_ctx = ctx_.GetChannelResource(ch, loc_); |
| 334 | auto& sub_fn = std::any_cast<typename Context::SubscribeFunction<T>&>(channel_ctx.sub_f); |
| 335 | auto ctx = details::GetCurrentContext(); |
| 336 | const bool ok = sub_fn(channel_ctx.sub, |
| 337 | StandardizeSubscriber<T>(std::move(callback)), |
| 338 | std::move(exe)); |
| 339 | AIMRT_ASSERT_WITH_LOC(loc_, ok, "Subscribe [{}] failed.", ch.GetName()); |
| 340 | } |
| 341 | |
| 342 | // subscriber subscribe function |
| 343 | template <class T> |
nothing calls this directly
no test coverage detected