01: package org.drools.brms.client;
02:
03: /*
04: * Copyright 2005 JBoss Inc
05: *
06: * Licensed under the Apache License, Version 2.0 (the "License");
07: * you may not use this file except in compliance with the License.
08: * You may obtain a copy of the License at
09: *
10: * http://www.apache.org/licenses/LICENSE-2.0
11: *
12: * Unless required by applicable law or agreed to in writing, software
13: * distributed under the License is distributed on an "AS IS" BASIS,
14: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
15: * See the License for the specific language governing permissions and
16: * limitations under the License.
17: */
18:
19: import org.drools.brms.client.admin.ArchivedAssetManager;
20: import org.drools.brms.client.admin.BackupManager;
21: import org.drools.brms.client.admin.CategoryManager;
22: import org.drools.brms.client.admin.StateManager;
23:
24: import com.google.gwt.user.client.ui.TabPanel;
25:
26: /**
27: * This feature contains the administrative functions of the BRMS.
28: */
29: public class AdminFeature extends JBRMSFeature {
30:
31: private TabPanel tab;
32:
33: public AdminFeature() {
34: tab = new TabPanel();
35: tab.setWidth("100%");
36: tab.setHeight("100%");
37:
38: tab
39: .add(
40: new CategoryManager(),
41: "<img src='images/category_small.gif'/>Manage categories",
42: true);
43: tab.add(new StateManager(),
44: "<img src='images/status_small.gif'/>Manage states",
45: true);
46: tab
47: .add(
48: new ArchivedAssetManager(),
49: "<img src='images/backup_small.gif'/>Manage Archived Assets",
50: true);
51: tab.add(new BackupManager(),
52: "<img src='images/backup_small.gif'/>Import Export",
53: true);
54:
55: tab.selectTab(0);
56:
57: initWidget(tab);
58:
59: }
60:
61: public static ComponentInfo init() {
62: return new ComponentInfo("Admin", "Administer the repository") {
63: public JBRMSFeature createInstance() {
64: return new AdminFeature();
65: }
66:
67: };
68: }
69:
70: public void onShow() {
71: }
72: }
|