01: /**
02: * Licensed to the Apache Software Foundation (ASF) under one or more
03: * contributor license agreements. See the NOTICE file distributed with
04: * this work for additional information regarding copyright ownership.
05: * The ASF licenses this file to You under the Apache License, Version 2.0
06: * (the "License"); you may not use this file except in compliance with
07: * the License. You may obtain a copy of the License at
08: *
09: * http://www.apache.org/licenses/LICENSE-2.0
10: *
11: * Unless required by applicable law or agreed to in writing, software
12: * distributed under the License is distributed on an "AS IS" BASIS,
13: * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
14: * See the License for the specific language governing permissions and
15: * limitations under the License.
16: */package org.apache.geronimo.connector;
17:
18: import java.util.Map;
19:
20: import org.apache.geronimo.gbean.GBeanData;
21: import org.apache.geronimo.gbean.GBeanInfo;
22: import org.apache.geronimo.gbean.GBeanInfoBuilder;
23: import org.apache.geronimo.j2ee.j2eeobjectnames.NameFactory;
24: import org.apache.geronimo.management.J2EEApplication;
25: import org.apache.geronimo.management.J2EEServer;
26: import org.apache.geronimo.management.geronimo.ResourceAdapter;
27: import org.apache.geronimo.management.geronimo.ResourceAdapterModule;
28:
29: /**
30: * @version $Revision: 476049 $
31: */
32: public class ResourceAdapterModuleImplGBean {
33:
34: public static final GBeanInfo GBEAN_INFO;
35:
36: static {
37: GBeanInfoBuilder infoBuilder = GBeanInfoBuilder.createStatic(
38: ResourceAdapterModuleImplGBean.class,
39: ResourceAdapterModuleImpl.class,
40: NameFactory.RESOURCE_ADAPTER_MODULE);
41: infoBuilder.addReference("J2EEServer", J2EEServer.class, null);
42: infoBuilder.addReference("J2EEApplication",
43: J2EEApplication.class, null);
44:
45: infoBuilder.addAttribute("deploymentDescriptor", String.class,
46: true);
47:
48: infoBuilder.addReference("ResourceAdapter",
49: ResourceAdapter.class, NameFactory.RESOURCE_ADAPTER);
50: infoBuilder.addAttribute("objectName", String.class, false);
51: infoBuilder.addAttribute("server", String.class, false);
52: infoBuilder.addAttribute("application", String.class, false);
53: infoBuilder.addAttribute("javaVMs", String[].class, false);
54: infoBuilder.addAttribute("resourceAdapters", String[].class,
55: false);
56:
57: infoBuilder.addAttribute("resourceAdapterGBeanData",
58: GBeanData.class, true);
59: infoBuilder.addAttribute("activationSpecInfoMap", Map.class,
60: true);
61: infoBuilder.addAttribute("adminObjectInfoMap", Map.class, true);
62: infoBuilder.addAttribute("managedConnectionFactoryInfoMap",
63: Map.class, true);
64:
65: infoBuilder.addAttribute("displayName", String.class, true,
66: false);
67: infoBuilder.addAttribute("description", String.class, true,
68: false);
69: infoBuilder.addAttribute("vendorName", String.class, true,
70: false);
71: infoBuilder.addAttribute("EISType", String.class, true, false);
72: infoBuilder.addAttribute("resourceAdapterVersion",
73: String.class, true, false);
74:
75: infoBuilder.addInterface(ResourceAdapterModule.class);
76:
77: infoBuilder.setConstructor(new String[] { "objectName",
78: "ResourceAdapter", "J2EEServer", "J2EEApplication",
79: "deploymentDescriptor", "resourceAdapterGBeanData",
80: "activationSpecInfoMap", "adminObjectInfoMap",
81: "managedConnectionFactoryInfoMap", "displayName",
82: "description", "vendorName", "resourceAdapterVersion",
83: "EISType" });
84:
85: GBEAN_INFO = infoBuilder.getBeanInfo();
86: }
87:
88: public static GBeanInfo getGBeanInfo() {
89: return GBEAN_INFO;
90: }
91:
92: }
|