mirror of
https://github.com/slsdetectorgroup/slsDetectorPackage.git
synced 2025-06-13 21:37:13 +02:00
replace udpDestination struct with a class that accepts ipaddr
This commit is contained in:
@ -148,31 +148,6 @@ std::ostream &operator<<(std::ostream &os,
|
||||
return os << ToString(r);
|
||||
}
|
||||
|
||||
std::string ToString(const slsDetectorDefs::udpDestination &r) {
|
||||
std::ostringstream oss;
|
||||
oss << '[' << std::endl
|
||||
<< "entry " << r.entry_ << std::endl
|
||||
<< "ip " << IpAddr(r.ip_) << std::endl
|
||||
<< "mac " << MacAddr(r.mac_) << std::endl
|
||||
<< "port " << r.port_ << std::endl;
|
||||
if (r.port2_ != 0) {
|
||||
oss << "port2 " << r.port2_ << std::endl;
|
||||
}
|
||||
if (r.ip2_ != 0) {
|
||||
oss << "ip2 " << IpAddr(r.ip2_) << std::endl;
|
||||
}
|
||||
if (r.mac2_ != 0) {
|
||||
oss << "mac2 " << MacAddr(r.mac2_) << std::endl;
|
||||
}
|
||||
oss << ']';
|
||||
return oss.str();
|
||||
}
|
||||
|
||||
std::ostream &operator<<(std::ostream &os,
|
||||
const slsDetectorDefs::udpDestination &r) {
|
||||
return os << ToString(r);
|
||||
}
|
||||
|
||||
std::string ToString(const defs::runStatus s) {
|
||||
switch (s) {
|
||||
case defs::ERROR:
|
||||
|
Reference in New Issue
Block a user