blob: be8d0616594f684d3ebeca87b81135bad87c61e6 [file] [log] [blame]
Austin Schuh75263e32022-02-22 18:05:32 -08001// Copyright (c) FIRST and other WPILib contributors.
2// Open Source Software; you can modify and/or share it under the terms of
3// the WPILib BSD license file in the root directory of this project.
4
5#pragma once
6
7#include <memory>
8
9#include "wpi/DenseMap.h"
10#include "wpi/MulticastServiceAnnouncer.h"
11#include "wpi/MulticastServiceResolver.h"
12#include "wpi/UidVector.h"
13
14namespace wpi {
15struct MulticastHandleManager {
16 wpi::mutex mutex;
17 wpi::UidVector<int, 8> handleIds;
18 wpi::DenseMap<size_t, std::unique_ptr<wpi::MulticastServiceResolver>>
19 resolvers;
20 wpi::DenseMap<size_t, std::unique_ptr<wpi::MulticastServiceAnnouncer>>
21 announcers;
22};
23
24MulticastHandleManager& GetMulticastManager();
25} // namespace wpi