smolnar82 commented on a change in pull request #297: KNOX-2301 and KNOX-2302
URL: https://github.com/apache/knox/pull/297#discussion_r396342594
 
 

 ##########
 File path: 
gateway-spi/src/main/java/org/apache/knox/gateway/topology/Topology.java
 ##########
 @@ -153,4 +161,106 @@ public void addProvider( Provider provider ) {
     nameMap.put( provider.getName(), provider );
   }
 
+  @Override
+  public int hashCode() {
+    return (new HashCodeBuilder(17, 31)).append(name)
+                                        .append(providerList)
+                                        .append(services)
+                                        .append(applications)
+                                        .build();
+  }
+
+  @Override
+  public boolean equals(Object obj) {
 
 Review comment:
   If `Provider`, `Service` and `Application` implements `hashCode` and 
`equals` properly you do not need the private methods below and you can simply 
use `EqualsBuilder` here too.

----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

Reply via email to