In ss the if statements are two times. Either In the finally block instead of all if statements write out.close() or remove null if possible share ss again hope it works
int is not an object it is a primitive data type and objects are reference type. So instead of equals use == and return obj1 and obj2 separately. hope it solves your problem
How to solve null pointers should not be dereferenced sonar fix
neha
In ss the if statements are two times. Either In the finally block instead of all if statements write out.close() or remove null if possible share ss again hope it works
java equals int cannot be dereferenced how to fix
neha
int is not an object it is a primitive data type and objects are reference type. So instead of equals use == and return obj1 and obj2 separately. hope it solves your problem