/*
* Copyright (c), Huawei Technologies Co., Ltd. 2025-2025.All rights reserved.
 */
#include "WebSocketExamplePlugin.h"
#include "WebSocketExampleModule.h"
#include "WebSocketPluginExampleProtocol.h"
using namespace Insight::Example;

WebSocketExamplePlugin::WebSocketExamplePlugin(): BasePlugin("WebSocketExamplePlugin")
{
}

std::vector<std::string> WebSocketExamplePlugin::GetModuleConfig()
{
    return {
        R"(
        {
            "name":"WebSocketExamplePlugin",
            "requestName":"WebSocketExample",
            "attributes":{
                "src":"./plugin/WebSocketExample/index.html",
                "isDefault":true
            }
        }
)"
    };
}

std::unique_ptr<Dic::Module::BaseModule> WebSocketExamplePlugin::GetModule()
{
    return std::make_unique<WebSocketExampleModule>();
}

std::unique_ptr<Dic::Protocol::ProtocolUtil> WebSocketExamplePlugin::GetProtocolUtil()
{
    return std::make_unique<WebSocketPluginExampleProtocol>();
}

PluginRegister pluginRegister(std::move(std::make_unique<WebSocketExamplePlugin>()));