Martin Peřina has uploaded a new change for review. Change subject: core: Provide copy constructor for FenceAgent ......................................................................
core: Provide copy constructor for FenceAgent Provides copy contsructor for FenceAgent Change-Id: I382e01d35af79a3600e34e9a74757c2eba831482 Bug-Url: https://bugzilla.redhat.com/1182510 Signed-off-by: Martin Perina <mper...@redhat.com> --- M backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/FenceAgent.java 1 file changed, 23 insertions(+), 0 deletions(-) git pull ssh://gerrit.ovirt.org:29418/ovirt-engine refs/changes/63/38163/1 diff --git a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/FenceAgent.java b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/FenceAgent.java index 50147ef..6da2529 100644 --- a/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/FenceAgent.java +++ b/backend/manager/modules/common/src/main/java/org/ovirt/engine/core/common/businessentities/FenceAgent.java @@ -49,6 +49,29 @@ @Size(max = BusinessEntitiesDefinitions.GENERAL_MAX_SIZE) private String options; + public FenceAgent() { + } + + public FenceAgent(FenceAgent other) { + if (other != null) { + this.id = other.id; + this.hostId = other.hostId; + this.order = other.order; + this.type = other.type; + this.ip = other.ip; + this.port = other.port; + this.user = other.user; + this.password = other.password; + this.options = other.options; + if (other.optionsMap != null) { + this.optionsMap = new HashMap<>(); + for (Map.Entry<String, String> entry : other.optionsMap.entrySet()) { + this.optionsMap.put(entry.getKey(), entry.getValue()); + } + } + + } + } public Guid getId() { return id; } -- To view, visit https://gerrit.ovirt.org/38163 To unsubscribe, visit https://gerrit.ovirt.org/settings Gerrit-MessageType: newchange Gerrit-Change-Id: I382e01d35af79a3600e34e9a74757c2eba831482 Gerrit-PatchSet: 1 Gerrit-Project: ovirt-engine Gerrit-Branch: master Gerrit-Owner: Martin Peřina <mper...@redhat.com> _______________________________________________ Engine-patches mailing list Engine-patches@ovirt.org http://lists.ovirt.org/mailman/listinfo/engine-patches