KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > java > plugin > boot > ApplicationPlugin


1 /*****************************************************************************
2  * Java Plug-in Framework (JPF)
3  * Copyright (C) 2004-2005 Dmitry Olshansky
4  *
5  * This library 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 (at your option) any later version.
9  *
10  * This library is distributed in the hope that it will be useful,
11  * but WITHOUT ANY WARRANTY; without even the implied warranty of
12  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
13  * Lesser General Public License for more details.
14  *
15  * You should have received a copy of the GNU Lesser General Public
16  * License along with this library; if not, write to the Free Software
17  * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA
18  *****************************************************************************/

19 package org.java.plugin.boot;
20
21 import org.java.plugin.Plugin;
22 import org.java.plugin.util.ExtendedProperties;
23
24 /**
25  * This class is for "application" plug-ins - a JPF based program entry point.
26  * The class is part of "standard boot scenario" when
27  * {@link org.java.plugin.boot.DefaultApplicationInitializer} is used for
28  * application initializing.
29  *
30  * @version $Id: ApplicationPlugin.java,v 1.4 2006/01/27 20:52:15 ddimon Exp $
31  */

32 public abstract class ApplicationPlugin extends Plugin {
33     /**
34      * This method should instantiate and configure application instance that
35      * will then be started.
36      * @param config application configuration data, see
37      * {@link DefaultApplicationInitializer} for description on
38      * how plug-in configuration data composed from
39      * <code>boot.properties</code>
40      * @param args command line arguments as they passed to program
41      * <code>main</code> method
42      * @return initialized ready to start application instance
43      * @throws Exception if any error has occurred during application
44      * initializing
45      */

46     protected abstract Application initApplication(ExtendedProperties config,
47             String JavaDoc[] args) throws Exception JavaDoc;
48 }
49
Popular Tags