Hi.........
i am trying find out the best way of handling exception for the below method
public String changeString(String source) throws SomeException{
String target;
.....i am modifying source string here and assigning to target
.
.............
.........
return target;
}
now calling method gets the String as return type even if in exception occurs.
what am trying to get here is if exception occurs method should not return target ,it should return exception