Initial source code
[oam/tr069-adapter.git] / acs / common / src / main / java / org / commscope / tr069adapter / acs / common / dto / ParameterAttributeDTO.java
diff --git a/acs/common/src/main/java/org/commscope/tr069adapter/acs/common/dto/ParameterAttributeDTO.java b/acs/common/src/main/java/org/commscope/tr069adapter/acs/common/dto/ParameterAttributeDTO.java
new file mode 100644 (file)
index 0000000..1ba3b63
--- /dev/null
@@ -0,0 +1,98 @@
+/*\r
+ * ============LICENSE_START========================================================================\r
+ * ONAP : tr-069-adapter\r
+ * =================================================================================================\r
+ * Copyright (C) 2020 CommScope Inc Intellectual Property.\r
+ * =================================================================================================\r
+ * This tr-069-adapter software file is distributed by CommScope Inc under the Apache License,\r
+ * Version 2.0 (the "License"); you may not use this file except in compliance with the License. You\r
+ * may obtain a copy of the License at\r
+ *\r
+ * http://www.apache.org/licenses/LICENSE-2.0\r
+ *\r
+ * This file is distributed on an "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND,\r
+ * either express or implied. See the License for the specific language governing permissions and\r
+ * limitations under the License.\r
+ * ===============LICENSE_END=======================================================================\r
+ */\r
+\r
+package org.commscope.tr069adapter.acs.common.dto;\r
+\r
+import java.util.Arrays;\r
+\r
+import org.commscope.tr069adapter.acs.common.ParameterDTO;\r
+\r
+public class ParameterAttributeDTO extends ParameterDTO {\r
+\r
+  private static final long serialVersionUID = 3036245080206860431L;\r
+\r
+  private boolean notificationChange;\r
+\r
+  private boolean accesslistChange;\r
+\r
+  private int notification;\r
+\r
+  private String[] accessList;\r
+\r
+  public boolean getNotificationChange() {\r
+    return notificationChange;\r
+  }\r
+\r
+  public void setNotificationChange(boolean notificationChange) {\r
+    this.notificationChange = notificationChange;\r
+  }\r
+\r
+  public boolean getAccesslistChange() {\r
+    return accesslistChange;\r
+  }\r
+\r
+  public void setAccesslistChange(boolean accesslistChange) {\r
+    this.accesslistChange = accesslistChange;\r
+  }\r
+\r
+  public int getNotification() {\r
+    return notification;\r
+  }\r
+\r
+  public void setNotification(int notification) {\r
+    this.notification = notification;\r
+  }\r
+\r
+  public String[] getAccessList() {\r
+    return accessList;\r
+  }\r
+\r
+  public void setAccessList(String[] accessList) {\r
+    this.accessList = accessList;\r
+  }\r
+\r
+  @Override\r
+  public int hashCode() {\r
+    final int prime = 31;\r
+    int result = super.hashCode();\r
+    result = prime * result + Arrays.hashCode(accessList);\r
+    result = prime * result + (accesslistChange ? 1231 : 1237);\r
+    result = prime * result + notification;\r
+    result = prime * result + (notificationChange ? 1231 : 1237);\r
+    return result;\r
+  }\r
+\r
+  @Override\r
+  public boolean equals(Object obj) {\r
+    if (this == obj)\r
+      return true;\r
+    if (!super.equals(obj))\r
+      return false;\r
+    if (getClass() != obj.getClass())\r
+      return false;\r
+    ParameterAttributeDTO other = (ParameterAttributeDTO) obj;\r
+    if (!Arrays.equals(accessList, other.accessList))\r
+      return false;\r
+    if (accesslistChange != other.accesslistChange)\r
+      return false;\r
+    if (notification != other.notification)\r
+      return false;\r
+    return (notificationChange != other.notificationChange);\r
+  }\r
+\r
+}\r