#pragma once #include "fmt/AbstractBean.hpp" #include "fmt/V2RayStreamSettings.hpp" namespace NekoGui_fmt { class ShadowSocksBean : public AbstractBean { public: QString method = "aes-128-gcm"; QString password = ""; QString plugin = ""; bool uot = false; std::shared_ptr stream = std::make_shared(); ShadowSocksBean() : AbstractBean(0) { _add(new configItem("method", &method, itemType::string)); _add(new configItem("pass", &password, itemType::string)); _add(new configItem("plugin", &plugin, itemType::string)); _add(new configItem("uot", &uot, itemType::boolean)); _add(new configItem("stream", dynamic_cast(stream.get()), itemType::jsonStore)); }; QString DisplayType() override { return "Shadowsocks"; }; CoreObjOutboundBuildResult BuildCoreObjV2Ray() override; CoreObjOutboundBuildResult BuildCoreObjSingBox() override; bool TryParseLink(const QString &link); QString ToShareLink() override; }; } // namespace NekoGui_fmt