parent
d0cd1df978
commit
879b31f370
|
|
@ -22,6 +22,7 @@ import java.util.Map;
|
|||
import javax.servlet.Registration;
|
||||
|
||||
import org.springframework.core.Conventions;
|
||||
import org.springframework.core.Ordered;
|
||||
import org.springframework.util.Assert;
|
||||
|
||||
/**
|
||||
|
|
@ -32,10 +33,12 @@ import org.springframework.util.Assert;
|
|||
* @see FilterRegistrationBean
|
||||
* @see ServletListenerRegistrationBean
|
||||
*/
|
||||
public abstract class RegistrationBean implements ServletContextInitializer {
|
||||
public abstract class RegistrationBean implements ServletContextInitializer, Ordered {
|
||||
|
||||
private String name;
|
||||
|
||||
private int order = Ordered.LOWEST_PRECEDENCE;
|
||||
|
||||
private boolean asyncSupported = true;
|
||||
|
||||
private Map<String, String> initParameters = new LinkedHashMap<String, String>();
|
||||
|
|
@ -113,4 +116,19 @@ public abstract class RegistrationBean implements ServletContextInitializer {
|
|||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* @param order the order to set
|
||||
*/
|
||||
public void setOrder(int order) {
|
||||
this.order = order;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return the order
|
||||
*/
|
||||
@Override
|
||||
public int getOrder() {
|
||||
return this.order;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue