Skip to content

Commit

Permalink
WW-3714 Add alternative constructors in InterceptorMapping
Browse files Browse the repository at this point in the history
  • Loading branch information
kusalk committed Oct 22, 2024
1 parent 9e23fbe commit f95f9a7
Showing 1 changed file with 9 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -36,8 +36,16 @@ public class InterceptorMapping implements Serializable {
private Interceptor interceptor;
private final Map<String, String> params;

public InterceptorMapping(String name, org.apache.struts2.interceptor.Interceptor interceptor) {
this(name, Interceptor.adapt(interceptor));
}

public InterceptorMapping(String name, org.apache.struts2.interceptor.Interceptor interceptor, Map<String, String> params) {
this(name, Interceptor.adapt(interceptor), params);
}

public InterceptorMapping(String name, Interceptor interceptor) {
this(name, interceptor, new HashMap<String, String>());
this(name, interceptor, new HashMap<>());
}

public InterceptorMapping(String name, Interceptor interceptor, Map<String, String> params) {
Expand Down

0 comments on commit f95f9a7

Please sign in to comment.