94 lines
3.2 KiB
C++
94 lines
3.2 KiB
C++
/**
|
|
* Jungfraujoch
|
|
* API to control Jungfraujoch developed by the Paul Scherrer Institute (Switzerland). Jungfraujoch is a data acquisition and analysis system for pixel array detectors, primarly PSI JUNGFRAU. Jungfraujoch uses FPGA boards to acquire data at high data rates.
|
|
*
|
|
* The version of the OpenAPI document: 1.0.0-rc.23
|
|
* Contact: filip.leonarski@psi.ch
|
|
*
|
|
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
|
|
* https://openapi-generator.tech
|
|
* Do not edit the class manually.
|
|
*/
|
|
/*
|
|
* Zeromq_preview_settings.h
|
|
*
|
|
*
|
|
*/
|
|
|
|
#ifndef Zeromq_preview_settings_H_
|
|
#define Zeromq_preview_settings_H_
|
|
|
|
|
|
#include <string>
|
|
#include <nlohmann/json.hpp>
|
|
|
|
namespace org::openapitools::server::model
|
|
{
|
|
|
|
/// <summary>
|
|
///
|
|
/// </summary>
|
|
class Zeromq_preview_settings
|
|
{
|
|
public:
|
|
Zeromq_preview_settings();
|
|
virtual ~Zeromq_preview_settings() = default;
|
|
|
|
|
|
/// <summary>
|
|
/// Validate the current data in the model. Throws a ValidationException on failure.
|
|
/// </summary>
|
|
void validate() const;
|
|
|
|
/// <summary>
|
|
/// Validate the current data in the model. Returns false on error and writes an error
|
|
/// message into the given stringstream.
|
|
/// </summary>
|
|
bool validate(std::stringstream& msg) const;
|
|
|
|
/// <summary>
|
|
/// Helper overload for validate. Used when one model stores another model and calls it's validate.
|
|
/// Not meant to be called outside that case.
|
|
/// </summary>
|
|
bool validate(std::stringstream& msg, const std::string& pathPrefix) const;
|
|
|
|
bool operator==(const Zeromq_preview_settings& rhs) const;
|
|
bool operator!=(const Zeromq_preview_settings& rhs) const;
|
|
|
|
/////////////////////////////////////////////
|
|
/// Zeromq_preview_settings members
|
|
|
|
/// <summary>
|
|
/// ZeroMQ preview socket is enabled.
|
|
/// </summary>
|
|
bool isEnabled() const;
|
|
void setEnabled(bool const value);
|
|
/// <summary>
|
|
/// Period for generating preview image sent to the ZeroMQ interface in milliseconds. Default is 1 second. If set to zero, all images will be sent ZeroMQ (should be used only in case of relatively slow data collection). This has no effect on HTTP based preview, which updates always at rate of 1 second.
|
|
/// </summary>
|
|
int64_t getPeriodMs() const;
|
|
void setPeriodMs(int64_t const value);
|
|
/// <summary>
|
|
/// PUB ZeroMQ socket for preview images. This socket operates at a reduced frame rate. Images are serialized using CBOR. Address follows ZeroMQ convention for sockets - in practice ipc://<socket file> and tpc://<IP address>:<port> sockets are OK. 0.0.0.0 instead of IP address is accepted and means listening on all network interfaces.
|
|
/// </summary>
|
|
std::string getSocketAddress() const;
|
|
void setSocketAddress(std::string const& value);
|
|
bool socketAddressIsSet() const;
|
|
void unsetSocket_address();
|
|
|
|
friend void to_json(nlohmann::json& j, const Zeromq_preview_settings& o);
|
|
friend void from_json(const nlohmann::json& j, Zeromq_preview_settings& o);
|
|
protected:
|
|
bool m_Enabled;
|
|
|
|
int64_t m_Period_ms;
|
|
|
|
std::string m_Socket_address;
|
|
bool m_Socket_addressIsSet;
|
|
|
|
};
|
|
|
|
} // namespace org::openapitools::server::model
|
|
|
|
#endif /* Zeromq_preview_settings_H_ */
|