1 19 20 package org.netbeans.beaninfo; 21 22 import java.beans.*; 23 24 import org.openide.ServiceType; 25 import org.openide.util.Exceptions; 26 import org.openide.util.NbBundle; 27 28 31 public class ServiceTypeBeanInfo extends SimpleBeanInfo { 32 33 public PropertyDescriptor[] getPropertyDescriptors () { 34 try { 35 PropertyDescriptor name = new PropertyDescriptor ("name", ServiceType.class); name.setDisplayName (NbBundle.getBundle (ServiceTypeBeanInfo.class).getString ("PROP_ServiceType_name")); 37 name.setShortDescription (NbBundle.getBundle (ServiceTypeBeanInfo.class).getString ("HINT_ServiceType_name")); 38 PropertyDescriptor helpCtx = new PropertyDescriptor ("helpCtx", ServiceType.class, "getHelpCtx", null); helpCtx.setHidden (true); 41 return new PropertyDescriptor[] { name, helpCtx }; 42 } catch (IntrospectionException ie) { 43 Exceptions.printStackTrace(ie); 44 return null; 45 } 46 } 47 48 } 49 | Popular Tags |