| java.lang.Object java.beans.SimpleBeanInfo org.apache.jmeter.testbeans.BeanInfoSupport
All known Subclasses: org.apache.jmeter.util.BeanShellBeanInfoSupport, org.apache.jmeter.sampler.DebugSamplerBeanInfo, org.apache.jmeter.protocol.jdbc.config.DataSourceElementBeanInfo, org.apache.jmeter.timers.SyncTimerBeanInfo, org.apache.jmeter.protocol.jdbc.sampler.JDBCSamplerBeanInfo, org.apache.jmeter.protocol.http.sampler.AccessLogSamplerBeanInfo, org.apache.jmeter.extractor.DebugPostProcessorBeanInfo, org.apache.jmeter.examples.testbeans.example2.Example2BeanInfo, org.apache.jmeter.config.CSVDataSetBeanInfo, org.apache.jmeter.timers.ConstantThroughputTimerBeanInfo,
BeanInfoSupport | abstract public class BeanInfoSupport extends SimpleBeanInfo (Code) | | Support class for test bean beanInfo objects. It will help using the
introspector to get most of the information, to then modify it at will.
To use, subclass it, create a subclass with a parameter-less constructor
that:
- Calls super(beanClass)
- Modifies the property descriptors, bean descriptor, etc. at will.
Even before any such modifications, a resource bundle named xxxResources
(where xxx is the fully qualified bean class name) will be obtained if
available and used to localize the following:
- Bean's display name -- from property displayName.
- Properties' display names -- from properties propertyName.displayName.
- Properties' short descriptions -- from properties propertyName.shortDescription.
The resource bundle will be stored as the bean descriptor's "resourceBundle"
attribute, so that it can be used for further localization. TestBeanGUI, for
example, uses it to obtain the group's display names from properties groupName.displayName.
author: Jordi Salvat i Alabart version: $Revision: 577345 $ updated on $Date: 2007-09-19 17:29:45 +0100 (Wed, 19 Sep 2007) $ |
Constructor Summary | |
protected | BeanInfoSupport(Class beanClass) Construct a BeanInfo for the given class. |
NOT_EXPRESSION | final public static String NOT_EXPRESSION(Code) | | |
RESOURCE_BUNDLE | final public static String RESOURCE_BUNDLE(Code) | | |
BeanInfoSupport | protected BeanInfoSupport(Class beanClass)(Code) | | Construct a BeanInfo for the given class.
|
createPropertyGroup | protected void createPropertyGroup(String group, String[] names)(Code) | | Utility method to group and order properties.
It will assing the given group name to each of the named properties, and
set their order attribute so that they are shown in the given order.
The created groups will get order 1, 2, 3,... in the order in which they
are created.
Parameters: group - name of the group Parameters: names - property names in the desired order |
getDefaultEventIndex | public int getDefaultEventIndex()(Code) | | |
getDefaultPropertyIndex | public int getDefaultPropertyIndex()(Code) | | |
property | protected PropertyDescriptor property(String name)(Code) | | Get the property descriptor for the property of the given name.
Parameters: name - property name descriptor for a property of that name, or null if there's none |
setIcon | protected void setIcon(String resourceName)(Code) | | Set the bean's 16x16 colour icon.
Parameters: resourceName - A pathname relative to the directory holding the class file ofthe current class. |
|
|