mirror of
https://github.com/hyperion-project/hyperion.ng.git
synced 2025-03-01 10:33:28 +00:00
IPv6 support (#1369)
* hyperion-remote - Support IPv6 * LEDDevices - Remove IPv6 limitations * Separate JsonEditorHostValidation * Standalone grabbers & JSON/Flatbuffer forwarder: IPv6 support * remote: Fix setting multiple colors via Hex, add standard logging * IPv6 Updates -Add db migration activities * Addressing non-Windows compile issues * Code cleanup, address clang feedback * Update address (hostname, IPv4/IPv6) help text * Apply migration steps to "old" configurations imported * Show user the UI-Url, if hyperion is already running, address clang findings * Windows Cmake OpenSLL output * Minor Text update
This commit is contained in:
@@ -324,6 +324,14 @@ public slots:
|
||||
///
|
||||
bool saveSettings(const QJsonObject& config, bool correct = false);
|
||||
|
||||
///
|
||||
/// @brief Restore a complete json config
|
||||
/// @param config The entire config object
|
||||
/// @param correct If true will correct json against schema before save
|
||||
/// @return True on success else false
|
||||
///
|
||||
bool restoreSettings(const QJsonObject& config, bool correct = false);
|
||||
|
||||
/// ############
|
||||
/// COMPONENTREGISTER
|
||||
///
|
||||
|
@@ -36,8 +36,8 @@ public:
|
||||
MessageForwarder(Hyperion* hyperion);
|
||||
~MessageForwarder() override;
|
||||
|
||||
void addJsonSlave(const QString& slave);
|
||||
void addFlatbufferSlave(const QString& slave);
|
||||
void addJsonTarget(const QJsonObject& targetConfig);
|
||||
void addFlatbufferTarget(const QJsonObject& targetConfig);
|
||||
|
||||
private slots:
|
||||
///
|
||||
@@ -61,25 +61,36 @@ private slots:
|
||||
void handlePriorityChanges(quint8 priority);
|
||||
|
||||
///
|
||||
/// @brief Forward message to all json slaves
|
||||
/// @brief Forward message to all json target hosts
|
||||
/// @param message The JSON message to send
|
||||
///
|
||||
void forwardJsonMessage(const QJsonObject &message);
|
||||
|
||||
///
|
||||
/// @brief Forward image to all flatbuffer slaves
|
||||
/// @brief Forward image to all flatbuffer target hosts
|
||||
/// @param image The flatbuffer image to send
|
||||
///
|
||||
void forwardFlatbufferMessage(const QString& name, const Image<ColorRgb> &image);
|
||||
|
||||
///
|
||||
/// @brief Forward message to a single json slave
|
||||
/// @brief Forward message to a single json target host
|
||||
/// @param message The JSON message to send
|
||||
/// @param socket The TCP-Socket with the connection to the slave
|
||||
/// @param socket The TCP-Socket with the connection to the target host
|
||||
///
|
||||
void sendJsonMessage(const QJsonObject &message, QTcpSocket *socket);
|
||||
|
||||
private:
|
||||
|
||||
struct TargetHost {
|
||||
QHostAddress host;
|
||||
quint16 port;
|
||||
|
||||
bool operator == (TargetHost const& a) const
|
||||
{
|
||||
return ((host == a.host) && (port == a.port));
|
||||
}
|
||||
};
|
||||
|
||||
/// Hyperion instance
|
||||
Hyperion *_hyperion;
|
||||
|
||||
@@ -89,11 +100,11 @@ private:
|
||||
/// Muxer instance
|
||||
PriorityMuxer *_muxer;
|
||||
|
||||
// JSON connection for forwarding
|
||||
QStringList _jsonSlaves;
|
||||
// JSON connections for forwarding
|
||||
QList<TargetHost> _jsonTargets;
|
||||
|
||||
/// Proto connection for forwarding
|
||||
QStringList _flatSlaves;
|
||||
/// Flatbuffer connection for forwarding
|
||||
QList<TargetHost> _flatbufferTargets;
|
||||
QList<FlatBufferConnection*> _forwardClients;
|
||||
|
||||
/// Flag if forwarder is enabled
|
||||
|
@@ -36,6 +36,14 @@ public:
|
||||
///
|
||||
bool saveSettings(QJsonObject config, bool correct = false);
|
||||
|
||||
///
|
||||
/// @brief Restore a complete json configuration
|
||||
/// @param config The entire config object
|
||||
/// @param correct If true will correct json against schema before save
|
||||
/// @return True on success else false
|
||||
///
|
||||
bool restoreSettings(QJsonObject config, bool correct = false);
|
||||
|
||||
///
|
||||
/// @brief get a single setting json from configuration
|
||||
/// @param type The settings::type from enum
|
||||
|
Reference in New Issue
Block a user