79236735

Date: 2024-11-29 10:34:46
Score: 1.5
Natty:
Report link

Instead TreeSet I would able to achieve using HashSet.

Set<TestFoo> existingItems = readsFromDb(syncGuid);

Set<TestFoo> newItemsSet = new HashSet<newItems>;


if (!newItemsSet.equals(existingItems)) {
  
}

In TestFoo Pojo I have just override the equals and hash method

Reasons:
  • Low length (0.5):
  • Has code block (-0.5):
  • Self-answer (0.5):
  • Low reputation (1):
Posted by: Anandharaj Anandharaj