Classes in this File | Line Coverage | Branch Coverage | Complexity | ||||
IAuthenticationPlugin |
|
| 1.0;1 |
1 | /** | |
2 | * 2009, Digitalis Informatica. All rights reserved. Distribuicao e Gestao de Informatica, Lda. Estrada de Paco de Arcos | |
3 | * num.9 - Piso -1 2780-666 Paco de Arcos Telefone: (351) 21 4408990 Fax: (351) 21 4408999 http://www.digitalis.pt | |
4 | */ | |
5 | ||
6 | package pt.digitalis.dif.controller.interfaces; | |
7 | ||
8 | import pt.digitalis.dif.exception.controller.ControllerException; | |
9 | ||
10 | /** | |
11 | * Defines the Authentication integrations API | |
12 | * | |
13 | * @author Galaio da Silva <a href="mailto:jgalaio@digitalis.pt">jgalaio@digitalis.pt</a><br/> | |
14 | * @created Dec 14, 2010 | |
15 | */ | |
16 | public interface IAuthenticationPlugin { | |
17 | ||
18 | /** | |
19 | * Executes the necessary action after a login is executed by the DIF Dispatcher Authentication step | |
20 | * | |
21 | * @param context | |
22 | * the current executing context | |
23 | */ | |
24 | public void doAfterLogin(IDIFContext context); | |
25 | ||
26 | /** | |
27 | * Executes the necessary action after a logout is executed by the DIF Dispatcher Authentication step | |
28 | * | |
29 | * @param context | |
30 | * the current executing context | |
31 | */ | |
32 | public void doAfterLogout(IDIFContext context); | |
33 | ||
34 | /** | |
35 | * Executes the necessary action before a login is executed by the DIF Dispatcher Authentication step | |
36 | * | |
37 | * @param context | |
38 | * the current executing context | |
39 | */ | |
40 | public void doBeforeLogin(IDIFContext context); | |
41 | ||
42 | /** | |
43 | * Executes the necessary action before a logout is executed by the DIF Dispatcher Authentication step | |
44 | * | |
45 | * @param context | |
46 | * the current executing context | |
47 | */ | |
48 | public void doBeforeLogout(IDIFContext context); | |
49 | ||
50 | /** | |
51 | * Executes the user validation | |
52 | * | |
53 | * @param context | |
54 | * the current executing context | |
55 | * @param user | |
56 | * the user id | |
57 | * @param password | |
58 | * the user password | |
59 | * @return <code>true</code> if the user is valid | |
60 | * @throws ControllerException | |
61 | * the exception that prevents the authentication to be performed | |
62 | */ | |
63 | public boolean validateUser(IDIFContext context, String user, String password) throws ControllerException; | |
64 | } |