KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > ejbca > core > model > services > IAction


1 /*************************************************************************
2  * *
3  * EJBCA: The OpenSource Certificate Authority *
4  * *
5  * This software is free software; you can redistribute it and/or *
6  * modify it under the terms of the GNU Lesser General Public *
7  * License as published by the Free Software Foundation; either *
8  * version 2.1 of the License, or any later version. *
9  * *
10  * See terms of license at gnu.org. *
11  * *
12  *************************************************************************/

13 package org.ejbca.core.model.services;
14
15 import java.util.Properties JavaDoc;
16
17 /**
18  * Interface used to define a service action. An action could be to generate
19  * a email, report, write to file.
20  *
21  * Its main method is perormAction() that should do the work.
22  *
23  * @author Philip Vendil 2006 sep 27
24  *
25  * @version $Id: IAction.java,v 1.2 2006/10/01 17:46:25 herrvendil Exp $
26  */

27 public interface IAction {
28     
29     /**
30      * Method that should initialize the action according to the
31      * configured properties.
32      *
33      * This method should be called before the any action calls are made.
34      */

35     public void init(Properties JavaDoc properties, String JavaDoc serviceName);
36     
37     
38     /**
39      * The main method used to signal that it's time to perform an action according
40      * to the data sent in the parameter IActionInfo
41      *
42      * @param optional parameter used to send data to the action
43      * @throws ActionException if the action failed in any way.
44      */

45     public void performAction(ActionInfo actionInfo) throws ActionException;
46
47 }
48
Popular Tags