2018-01-30 02:49:49 +00:00
|
|
|
//
|
2018-07-11 01:32:28 +00:00
|
|
|
// MultiMediaTarget.hpp
|
2018-01-30 02:49:49 +00:00
|
|
|
// Clock Signal
|
|
|
|
//
|
|
|
|
// Created by Thomas Harte on 29/01/2018.
|
2018-05-13 19:19:52 +00:00
|
|
|
// Copyright 2018 Thomas Harte. All rights reserved.
|
2018-01-30 02:49:49 +00:00
|
|
|
//
|
|
|
|
|
2024-01-17 04:34:46 +00:00
|
|
|
#pragma once
|
2018-01-30 02:49:49 +00:00
|
|
|
|
2018-07-11 01:32:28 +00:00
|
|
|
#include "../../../../Machines/MediaTarget.hpp"
|
2018-01-30 02:49:49 +00:00
|
|
|
#include "../../../../Machines/DynamicMachine.hpp"
|
|
|
|
|
|
|
|
#include <memory>
|
|
|
|
#include <vector>
|
|
|
|
|
2023-05-10 21:02:18 +00:00
|
|
|
namespace Analyser::Dynamic {
|
2018-01-30 02:49:49 +00:00
|
|
|
|
2018-02-19 21:03:17 +00:00
|
|
|
/*!
|
2018-07-11 01:42:09 +00:00
|
|
|
Provides a class that multiplexes the media target interface to multiple machines.
|
2018-02-19 21:03:17 +00:00
|
|
|
|
|
|
|
Makes a static internal copy of the list of machines; makes no guarantees about the
|
|
|
|
order of delivered messages.
|
|
|
|
*/
|
2020-04-02 03:19:34 +00:00
|
|
|
struct MultiMediaTarget: public MachineTypes::MediaTarget {
|
2024-11-29 22:23:05 +00:00
|
|
|
public:
|
|
|
|
MultiMediaTarget(const std::vector<std::unique_ptr<::Machine::DynamicMachine>> &);
|
2018-01-30 02:49:49 +00:00
|
|
|
|
2024-11-29 22:23:05 +00:00
|
|
|
// Below is the standard MediaTarget::Machine interface; see there for documentation.
|
|
|
|
bool insert_media(const Analyser::Static::Media &) final;
|
2018-01-30 02:49:49 +00:00
|
|
|
|
2024-11-29 22:23:05 +00:00
|
|
|
private:
|
|
|
|
std::vector<MachineTypes::MediaTarget *> targets_;
|
2018-01-30 02:49:49 +00:00
|
|
|
};
|
|
|
|
|
|
|
|
}
|