mirror of
https://github.com/nsacyber/HIRS.git
synced 2025-02-07 11:50:14 +00:00
Missed updated constructor for Device
This commit is contained in:
parent
310102bc8a
commit
cb5b281d03
@ -58,6 +58,16 @@ public class Device extends AbstractEntity {
|
|||||||
@Column(name = "summary_id")
|
@Column(name = "summary_id")
|
||||||
private String summaryId;
|
private String summaryId;
|
||||||
|
|
||||||
|
public Device(final DeviceInfoReport deviceInfoReport) {
|
||||||
|
super();
|
||||||
|
if (deviceInfoReport != null) {
|
||||||
|
this.name = deviceInfoReport.getNetworkInfo().getHostname();
|
||||||
|
this.deviceInfo = deviceInfoReport;
|
||||||
|
} else {
|
||||||
|
name = "";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
public String toString() {
|
public String toString() {
|
||||||
return String.format("Device Name: %s%nStatus: %s%nSummary: %s",
|
return String.format("Device Name: %s%nStatus: %s%nSummary: %s",
|
||||||
name, healthStatus.getStatus(),
|
name, healthStatus.getStatus(),
|
||||||
|
Loading…
x
Reference in New Issue
Block a user