01: /*
02: * $Id: MockHomePage.java 461190 2006-06-28 06:35:51Z ehillenius $ $Revision: 461190 $
03: * $Date: 2006-06-28 08:35:51 +0200 (Wed, 28 Jun 2006) $
04: * ====================================================================
05: * Copyright (c) 2005, Topicus B.V. All rights reserved.
06: */
07:
08: package wicket.markup.html.form.login;
09:
10: import org.apache.commons.logging.Log;
11: import org.apache.commons.logging.LogFactory;
12:
13: import wicket.Session;
14: import wicket.markup.html.WebPage;
15: import wicket.markup.html.basic.Label;
16: import wicket.markup.html.form.login.InterceptTest.MySession;
17: import wicket.markup.html.link.PageLink;
18:
19: /**
20: * @author marrink
21: */
22: public class MockHomePage extends WebPage {
23: private static final long serialVersionUID = 1L;
24:
25: private static final Log log = LogFactory
26: .getLog(MockHomePage.class);
27:
28: /**
29: *
30: */
31: public MockHomePage() {
32: super ();
33: add(new Label("label", "this page is secured"));
34: add(new PageLink("link", PageA.class));
35: }
36:
37: /**
38: *
39: * @return boolean
40: */
41: public boolean logoff() {
42: ((MySession) Session.get()).setUsername(null);
43: return true;
44: }
45: }
|