Best approach to refactor exceptions?

I have a package that uses a lot of custom exceptions. I want to simplify this to only use one custom exception (which all of the others currently extend). So, I need to replace all references to the other exceptions to use the parent and hopefully simplify (or at least flag) the catch blocks referencing the exceptions.

Is there a good way to accomplish this in IDEA?

0
Avatar
Permanently deleted user

You should look into Structural Search & Replace. It can probably do most
of the work for your case, but maybe not all.

-Keith

I have a package that uses a lot of custom exceptions. I want to
simplify this to only use one custom exception (which all of the
others currently extend). So, I need to replace all references to the
other exceptions to use the parent and hopefully simplify (or at least
flag) the catch blocks referencing the exceptions.

Is there a good way to accomplish this in IDEA?




0

请先登录再写评论。