KickJava   Java API By Example, From Geeks To Geeks.

Java > Open Source Codes > org > columba > chat > AlturaComponent


1 // The contents of this file are subject to the Mozilla Public License Version
2
// 1.1
3
//(the "License"); you may not use this file except in compliance with the
4
//License. You may obtain a copy of the License at http://www.mozilla.org/MPL/
5
//
6
//Software distributed under the License is distributed on an "AS IS" basis,
7
//WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
8
//for the specific language governing rights and
9
//limitations under the License.
10
//
11
//The Original Code is "The Columba Project"
12
//
13
//The Initial Developers of the Original Code are Frederik Dietz and Timo
14
// Stich.
15
//Portions created by Frederik Dietz and Timo Stich are Copyright (C) 2003.
16
//
17
//All Rights Reserved.
18
package org.columba.chat;
19
20 import java.io.InputStream JavaDoc;
21
22 import org.apache.commons.cli.CommandLine;
23 import org.columba.api.plugin.IExtensionHandlerKeys;
24 import org.columba.api.plugin.PluginHandlerNotFoundException;
25 import org.columba.api.plugin.PluginMetadata;
26 import org.columba.core.component.api.IComponentPlugin;
27 import org.columba.core.plugin.PluginManager;
28
29 /**
30  * @author fdietz
31  *
32  */

33 public class AlturaComponent implements IComponentPlugin {
34
35     public final static String JavaDoc PLUGIN_ID = "org.columba.chat.altura";
36     
37     /**
38      *
39      */

40     public AlturaComponent() {
41         super();
42
43     }
44
45     /**
46      * @see org.columba.core.component.api.IComponentPlugin#init()
47      */

48     public void init() {
49         try {
50             PluginMetadata metadata = PluginManager.getInstance().getPluginMetadata(PLUGIN_ID);
51             
52             InputStream JavaDoc is = this.getClass().getResourceAsStream(
53                     "/org/columba/chat/action/action.xml");
54
55             PluginManager.getInstance().getExtensionHandler(
56                     IExtensionHandlerKeys.ORG_COLUMBA_CORE_ACTION).loadExternalExtensionsFromStream(metadata, is);
57
58         } catch (PluginHandlerNotFoundException ex) {
59         }
60
61     }
62
63     /**
64      * @see org.columba.core.component.api.IComponentPlugin#postStartup()
65      */

66     public void postStartup() {
67
68     }
69
70     /**
71      * @see org.columba.core.component.api.IComponentPlugin#registerCommandLineArguments()
72      */

73     public void registerCommandLineArguments() {
74
75     }
76
77     /**
78      * @see org.columba.core.component.api.IComponentPlugin#handleCommandLineParameters(org.apache.commons.cli.CommandLine)
79      */

80     public void handleCommandLineParameters(CommandLine commandLine) {
81
82     }
83
84 }
Popular Tags