Line | |
---|
1 | package eu.clarin.cmdi.virtualcollectionregistry.gui.pages; |
---|
2 | |
---|
3 | import org.apache.wicket.PageReference; |
---|
4 | import org.apache.wicket.RestartResponseAtInterceptPageException; |
---|
5 | import org.apache.wicket.authorization.strategies.role.Roles; |
---|
6 | import org.apache.wicket.authorization.strategies.role.annotations.AuthorizeInstantiation; |
---|
7 | |
---|
8 | /** |
---|
9 | * Only serves as a target for the 'login' link of the |
---|
10 | * {@link AuthenticationStatePanel} |
---|
11 | * |
---|
12 | * @author twagoo |
---|
13 | */ |
---|
14 | @AuthorizeInstantiation(Roles.USER) |
---|
15 | public class DummyLoginPage extends BasePage { |
---|
16 | |
---|
17 | private final PageReference pageRef; |
---|
18 | |
---|
19 | public DummyLoginPage(PageReference pageRef) { |
---|
20 | this.pageRef = pageRef; |
---|
21 | } |
---|
22 | |
---|
23 | @Override |
---|
24 | protected void onBeforeRender() { |
---|
25 | throw new RestartResponseAtInterceptPageException(pageRef.getPage()); |
---|
26 | } |
---|
27 | |
---|
28 | } |
---|
Note: See
TracBrowser
for help on using the repository browser.