#pragma once

#include <memory>

#include <QHash>
#include <QString>

#include "core/plugin_system/IProtocolPlugin.h"

namespace softbus::core::plugin_system
{

class PluginManager
{
public:
    PluginManager() = default;

    void registerProtocolPlugin(std::shared_ptr<IProtocolPlugin> plugin);
    std::shared_ptr<IProtocolPlugin> selectProtocolPlugin(const QString& protocolHint) const;

private:
    QHash<QString, std::shared_ptr<IProtocolPlugin>> m_protocolPlugins;
};

} // namespace softbus::core::plugin_system
