1 23 24 package com.sun.enterprise.tools.common.beans; 25 26 import java.beans.*; 27 28 public class IasConnectorOneZeroBeanInfo extends SimpleBeanInfo { 29 30 private static java.util.ResourceBundle bundle = 31 java.util.ResourceBundle.getBundle("com.sun.enterprise.tools.common.beans.Bundle"); 33 private static BeanDescriptor beanDescriptor = null; 35 private static BeanDescriptor getBdescriptor(){ 36 38 40 return beanDescriptor; } 42 43 private static PropertyDescriptor[] properties = null; 45 private static PropertyDescriptor[] getPdescriptor(){ try { 47 properties = new PropertyDescriptor[8]; 48 properties[0] = getPropDesc("description", IasConnectorOneZero.class); properties[1] = getPropDesc("idleTimeoutInSeconds", IasConnectorOneZero.class); properties[2] = getPropDesc("jndiName", IasConnectorOneZero.class); properties[3] = getPropDesc("maxPoolSize", IasConnectorOneZero.class); properties[4] = getPropDesc("maxWaitTimeInMillis", IasConnectorOneZero.class); properties[5] = getPropDesc("propertyElements", IasConnectorOneZero.class); properties[6] = getPropDesc("roleMap", IasConnectorOneZero.class); properties[7] = getPropDesc("steadyPoolSize", IasConnectorOneZero.class); } 58 catch (Throwable t) { 59 t.printStackTrace(); 60 } 61 return properties; } 63 private static PropertyDescriptor getPropDesc(String propName, Class bc) 64 throws java.beans.IntrospectionException { 65 PropertyDescriptor pd = new PropertyDescriptor(propName,bc); 66 pd.setDisplayName(bundle.getString("DISPNAME_"+propName)); 67 pd.setName(bundle.getString("NAME_"+propName)); 68 pd.setShortDescription(bundle.getString("SHORTDESC_"+propName)); 69 return pd; 70 } 71 private static EventSetDescriptor[] eventSets = null; 73 private static EventSetDescriptor[] getEdescriptor(){ 75 77 return eventSets; } 79 private static MethodDescriptor[] methods = null; 81 private static MethodDescriptor[] getMdescriptor(){ 83 85 return methods; } 87 88 private static int defaultPropertyIndex = -1; private static int defaultEventIndex = -1; 91 92 94 96 98 108 109 121 public PropertyDescriptor[] getPropertyDescriptors() { 122 return getPdescriptor(); 123 } 124 125 169 } 170 171 | Popular Tags |