| |
|
| org.eclipse.ui.views.properties.IPropertyDescriptor
All known Subclasses: org.eclipse.ui.views.properties.PropertyDescriptor,
IPropertyDescriptor | public interface IPropertyDescriptor (Code) | | A descriptor for a property to be presented by a standard property sheet page
(PropertySheetPage ). These descriptors originate with property
sources (IPropertySource ).
A property descriptor carries the following information:
- property id (required)
- display name (required)
- brief description of the property (optional)
- category for grouping related properties (optional)
- label provider used to display the property value (optional)
- cell editor for changing the property value (optional)
- help context id (optional)
Clients may implement this interface to provide specialized property
descriptors; however, there are standard implementations declared in
this package that take care of the most common cases:
PropertyDescriptor - read-only property
TextPropertyDescriptor - edits with a
TextCellEditor
CheckboxPropertyDescriptor - edits with a
CheckboxCellEditor
ComboBoxPropertyDescriptor - edits with a
ComboBoxCellEditor
ColorPropertyDescriptor - edits with a
ColorCellEditor
See Also: IPropertySource.getPropertyDescriptors |
Method Summary | |
public CellEditor | createPropertyEditor(Composite parent) Creates and returns a new cell editor for editing this property. | public String | getCategory() Returns the name of the category to which this property belongs. | public String | getDescription() Returns a brief description of this property. | public String | getDisplayName() Returns the display name for this property. | public String[] | getFilterFlags() Returns a list of filter types to which this property belongs. | public Object | getHelpContextIds() Returns the help context id for this property or
null if this property has no help context id.
NOTE: Help support system API's changed since 2.0 and arrays
of contexts are no longer supported.
Thus the only valid non-null return type for this method
is a String representing a context id. | public Object | getId() Returns the id for this property. | public ILabelProvider | getLabelProvider() Returns the label provider for this property. | public boolean | isCompatibleWith(IPropertyDescriptor anotherProperty) Returns whether this property descriptor and the given one are compatible. |
createPropertyEditor | public CellEditor createPropertyEditor(Composite parent)(Code) | | Creates and returns a new cell editor for editing this property. Returns
null if the property is not editable.
Parameters: parent - the parent widget for the cell editor the cell editor for this property, or null if thisproperty cannot be edited |
getCategory | public String getCategory()(Code) | | Returns the name of the category to which this property belongs. Properties
belonging to the same category are grouped together visually. This localized
string is shown to the user
the category name, or null if the default category is tobe used |
getDescription | public String getDescription()(Code) | | Returns a brief description of this property. This localized string is shown
to the user when this property is selected.
a brief description, or null if none |
getDisplayName | public String getDisplayName()(Code) | | Returns the display name for this property. This localized string is shown to
the user as the name of this property.
a displayable name |
getFilterFlags | public String[] getFilterFlags()(Code) | | Returns a list of filter types to which this property belongs.
The user is able to toggle the filters to show/hide properties belonging to
a filter type.
Valid values for these flags are declared as constants on
IPropertySheetEntry
a list of filter types to which this property belongs, ornull if none |
getHelpContextIds | public Object getHelpContextIds()(Code) | | Returns the help context id for this property or
null if this property has no help context id.
NOTE: Help support system API's changed since 2.0 and arrays
of contexts are no longer supported.
Thus the only valid non-null return type for this method
is a String representing a context id. The previously
valid return types are deprecated. The plural name for this method
is unfortunate.
the help context id for this entry |
getId | public Object getId()(Code) | | Returns the id for this property. This object is
used internally to distinguish one property descriptor
from another.
the property id |
getLabelProvider | public ILabelProvider getLabelProvider()(Code) | | Returns the label provider for this property. The label provider is used
to obtain the text (and possible image) for displaying the value
of this property.
the label provider used to display this property |
isCompatibleWith | public boolean isCompatibleWith(IPropertyDescriptor anotherProperty)(Code) | | Returns whether this property descriptor and the given one are compatible.
The property sheet uses this method during multiple selection to determine
whether two property descriptors with the same id are in fact the same
property and can be displayed as a single entry in the property sheet.
Parameters: anotherProperty - the other property descriptor true if the property descriptors are compatible, and false otherwise |
|
|
|