本文整理汇总了Java中org.eclipse.ui.views.properties.PropertyDescriptor.setCategory方法的典型用法代码示例。如果您正苦于以下问题:Java PropertyDescriptor.setCategory方法的具体用法?Java PropertyDescriptor.setCategory怎么用?Java PropertyDescriptor.setCategory使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类org.eclipse.ui.views.properties.PropertyDescriptor
的用法示例。
在下文中一共展示了PropertyDescriptor.setCategory方法的11个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: createPropertyDescriptors
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
public static void createPropertyDescriptors(List<IPropertyDescriptor> desc, Map<String, Object> defaultsMap, String preID, String prefix) {
PropertyDescriptor pd = new DoublePropertyDescriptor(preID + PadUtil.PADDING_TOP, Messages.common_top);
pd.setDescription(Messages.common_top);
pd.setCategory(prefix);
desc.add(pd);
pd = new DoublePropertyDescriptor(preID + PadUtil.PADDING_BOTTOM, Messages.common_bottom);
pd.setDescription(Messages.common_bottom);
pd.setCategory(prefix);
desc.add(pd);
pd = new DoublePropertyDescriptor(preID + PadUtil.PADDING_LEFT, Messages.common_left);
pd.setDescription(Messages.common_left);
pd.setCategory(prefix);
desc.add(pd);
pd = new DoublePropertyDescriptor(preID + PadUtil.PADDING_RIGHT, Messages.common_right);
pd.setDescription(Messages.common_right);
pd.setCategory(prefix);
desc.add(pd);
defaultsMap.put(preID + PadUtil.PADDING_TOP, 0.0d);
defaultsMap.put(preID + PadUtil.PADDING_BOTTOM, 0.0d);
defaultsMap.put(preID + PadUtil.PADDING_LEFT, 0.0d);
defaultsMap.put(preID + PadUtil.PADDING_RIGHT, 0.0d);
}
示例2: getPropertyDescriptors
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
public IPropertyDescriptor[] getPropertyDescriptors()
{
List<IPropertyDescriptor> result = new ArrayList<IPropertyDescriptor>();
for (P p : getPropertyInfoSet())
{
PropertyDescriptor descriptor = new PropertyDescriptor(p, p.getHeader());
String category = p.getCategory();
if (!StringUtil.isEmpty(category))
{
descriptor.setCategory(category);
}
result.add(descriptor);
}
return result.toArray(new IPropertyDescriptor[result.size()]);
}
示例3: createPropertyDescriptor
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
/**
* create the property descriptor for the specified property
*
* @param propertyId
* @param metadata
* @return
*/
final PropertyDescriptor createPropertyDescriptor(String propertyId,
UIProperty metadata)
{
final PropertyDescriptor propertyDescriptor =
doCreatePropertyDescriptor(propertyId, metadata);
propertyDescriptor.setCategory(metadata.category());
return propertyDescriptor;
}
示例4: getPropertyDescriptors
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
@Override
public IPropertyDescriptor[] getPropertyDescriptors() {
List<IPropertyDescriptor> list = new ArrayList<>();
PropertyDescriptor name = new PropertyDescriptor("Name", "Name");
name.setCategory("General");
PropertyDescriptor version = new PropertyDescriptor("Version", "Version");
version.setCategory("General");
PropertyDescriptor exporter = new PropertyDescriptor("Export", "Exported By");
exporter.setCategory("General");
PropertyDescriptor reexporter = new PropertyDescriptor("Reexport",
"Reexported By");
reexporter.setCategory("General");
PropertyDescriptor log = new PropertyDescriptor("Log", "Log");
log.setCategory("General");
log.setLabelProvider(new LabelProvider() {
@Override
public String getText(Object element) {
if (element instanceof List<?>) {
List<?> logList = (List<?>) element;
StringBuilder out = new StringBuilder();
for (Object logEntry : logList) {
out.append(logEntry + "\n");
}
return out.toString();
}
return "";
}
});
PropertyDescriptor importedBy = new PropertyDescriptor("Import", "Imported By");
Collections.addAll(list, name, version, exporter, importedBy, reexporter, log);
return list.toArray(new IPropertyDescriptor[list.size()]);
}
示例5: createPropertyDescriptor
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
private static IPropertyDescriptor createPropertyDescriptor(String field, String label){
PropertyDescriptor descriptor = new PropertyDescriptor(field, label);
descriptor.setCategory("Cordova Plugin");
descriptor.setAlwaysIncompatible(true);
return descriptor;
}
示例6: createPropertyDescriptor
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
private static IPropertyDescriptor createPropertyDescriptor(String field, String label){
PropertyDescriptor descriptor = new PropertyDescriptor(field, label);
descriptor.setCategory("Cordova Platform");
descriptor.setAlwaysIncompatible(true);
return descriptor;
}
示例7: getPropertyDescriptors
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
public IPropertyDescriptor[] getPropertyDescriptors() {
List<IPropertyDescriptor> descciptors = new ArrayList<IPropertyDescriptor>();
for(String name: properties.keySet()){
PropertyDescriptor descriptor = new TextPropertyDescriptor(new PropertyId(name), name);
descriptor.setCategory("Properties");
descciptors.add(descriptor);
}
return descciptors.toArray(new IPropertyDescriptor[0]);
}
示例8: workloadDescriptor
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
/**
* @param descriptors
* @param propertyid
*/
private void workloadDescriptor(Collection descriptors, PropertyID propertyid) {
PropertyDescriptor pd = new PropertyDescriptor(propertyid, Messages.getString("URNElementPropertySource.workload")); //$NON-NLS-1$
pd.setCategory(Messages.getString("URNElementPropertySource.performance")); //$NON-NLS-1$
pd.setLabelProvider(new LabelProvider() {
public String getText(Object element) {
return ""; //$NON-NLS-1$
}
});
descriptors.add(pd);
}
示例9: createPropertyDescriptors
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
/**
* Creates the property descriptors.
*
* @param desc
* the desc
*/
@Override
public void createPropertyDescriptors(List<IPropertyDescriptor> desc, Map<String, Object> defaultsMap) {
PropertyDescriptor pd = new CheckBoxPropertyDescriptor(ChartSettings.PROPERTY_textAntiAlias, Messages.MChartSettings_textAATitle);
pd.setDescription(Messages.MChartSettings_textAADescription);
desc.add(pd);
pd = new CheckBoxPropertyDescriptor(ChartSettings.PROPERTY_antiAlias, Messages.MChartSettings_antiAliasTitle);
pd.setDescription(Messages.MChartSettings_antiAliasDescription);
desc.add(pd);
pd = new CheckBoxPropertyDescriptor(ChartSettings.PROPERTY_borderVisible, Messages.MChartSettings_borderVisibleTitle);
pd.setDescription(Messages.MChartSettings_borderVisibleDescription);
pd.setCategory("Borders"); //$NON-NLS-1$
desc.add(pd);
pd = new TransparencyPropertyDescriptor(ChartSettings.PROPERTY_backgroundImageAlpha, Messages.MChartSettings_imageAlphaTitle);
pd.setDescription(Messages.MChartSettings_imageAlphaDescription);
pd.setCategory("Background"); //$NON-NLS-1$
desc.add(pd);
bia = new JSSEnumPropertyDescriptor(ChartSettings.PROPERTY_backgroundImageAlignment, Messages.MChartSettings_imageAlignTitle, JFreeChartAlignEnum.class, NullEnum.NOTNULL);
bia.setDescription(Messages.MChartSettings_imageAlignDescription);
bia.setCategory("Background"); //$NON-NLS-1$
desc.add(bia);
PadUtil.createPropertyDescriptors(desc, defaultsMap);
pd = new PaintProviderPropertyDescriptor(ChartSettings.PROPERTY_backgroundPaint, Messages.MChartSettings_paintTitle);
pd.setDescription(Messages.MChartSettings_paintDescription);
pd.setCategory("Background"); //$NON-NLS-1$
desc.add(pd);
pd = new PaintProviderPropertyDescriptor(ChartSettings.PROPERTY_borderPaint, Messages.MChartSettings_borderColorTitle);
pd.setDescription(Messages.MChartSettings_borderColorDescription);
pd.setCategory("Borders"); //$NON-NLS-1$
desc.add(pd);
pd = new ImageProviderPropertyDescriptor(ChartSettings.PROPERTY_backgroundImage, Messages.MChartSettings_backgroundImageTitle);
pd.setDescription(Messages.MChartSettings_backgroundImageDescription);
pd.setCategory("Background"); //$NON-NLS-1$
desc.add(pd);
pd = new StrokePropertyDescriptor(ChartSettings.PROPERTY_borderStroke, Messages.MChartSettings_borderStrokeTitle);
pd.setDescription(Messages.MChartSettings_borderStrokeDescription);
pd.setCategory("Borders"); //$NON-NLS-1$
desc.add(pd);
defaultsMap.put(ChartSettings.PROPERTY_backgroundPaint, null);
defaultsMap.put(ChartSettings.PROPERTY_borderPaint, null);
defaultsMap.put(ChartSettings.PROPERTY_backgroundImage, null);
defaultsMap.put(ChartSettings.PROPERTY_borderStroke, null);
defaultsMap.put(ChartSettings.PROPERTY_textAntiAlias, Boolean.TRUE);
defaultsMap.put(ChartSettings.PROPERTY_antiAlias, Boolean.TRUE);
defaultsMap.put(ChartSettings.PROPERTY_borderVisible, Boolean.TRUE);
defaultsMap.put(ChartSettings.PROPERTY_backgroundImageAlignment, JFreeChartAlignEnum.TOP_LEFT);
setHelpPrefix(desc, "net.sf.jasperreports.doc/docs/sample.reference/chartthemes/index.html#chartthemes"); //$NON-NLS-1$
}
示例10: getPropertyDescriptors
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
@Override
public IPropertyDescriptor[] getPropertyDescriptors() {
List<IPropertyDescriptor> list = new ArrayList<>();
PropertyDescriptor name = new PropertyDescriptor("Id", "Id");
name.setCategory("General");
PropertyDescriptor version = new PropertyDescriptor("Version", "Version");
version.setCategory("General");
PropertyDescriptor path = new PropertyDescriptor("Path", "Path");
path.setCategory("General");
PropertyDescriptor log = new PropertyDescriptor("Log", "Log");
log.setCategory("General");
log.setLabelProvider(new LabelProvider() {
@Override
public String getText(Object element) {
if (element instanceof List<?>) {
List<?> logList = (List<?>) element;
StringBuilder out = new StringBuilder();
for (Object logEntry : logList) {
out.append(logEntry + "\n");
}
return out.toString();
}
return "";
}
});
PropertyDescriptor incPlugins = new PropertyDescriptor("IncludedPlugins",
"Included Plugins");
incPlugins.setCategory("Requirements");
PropertyDescriptor incFeatures = new PropertyDescriptor("IncludedFeatures",
"Included Features");
incFeatures.setCategory("Requirements");
PropertyDescriptor reqPlugins = new PropertyDescriptor("RequiredPlugins",
"Required Plugins");
reqPlugins.setCategory("Requirements");
PropertyDescriptor reqFeatures = new PropertyDescriptor("RequiredFeatures",
"Required Features");
reqFeatures.setCategory("Requirements");
PropertyDescriptor resReqPlugins = new PropertyDescriptor("ResolvedRequiredPlugins", "Required Plugins (resolved)");
resReqPlugins.setCategory("Resolution");
PropertyDescriptor resReqFeatures = new PropertyDescriptor("ResolvedRequiredFeatures", "Required Features (resolved)");
resReqFeatures.setCategory("Resolution");
PropertyDescriptor resIncPlugins = new PropertyDescriptor("ResolvedIncludedPlugins", "Included Plugins (resolved)");
resIncPlugins.setCategory("Resolution");
PropertyDescriptor resIncFeatures = new PropertyDescriptor("ResolvedIncludedFeatures", "Included Features (resolved)");
resIncFeatures.setCategory("Resolution");
PropertyDescriptor includedIn = new PropertyDescriptor("IncludedIn",
"Included In");
Collections.addAll(list, name, version, path, log, incPlugins, incFeatures,
reqPlugins, reqFeatures, resReqPlugins, resReqFeatures, resIncPlugins, resIncFeatures,
includedIn);
return list.toArray(new IPropertyDescriptor[list.size()]);
}
示例11: getPropertyDescriptors
import org.eclipse.ui.views.properties.PropertyDescriptor; //导入方法依赖的package包/类
@Override
public IPropertyDescriptor[] getPropertyDescriptors() {
List<IPropertyDescriptor> list = new ArrayList<>();
PropertyDescriptor name = new PropertyDescriptor("SymbolicName", "SymbolicName");
name.setCategory("General");
PropertyDescriptor version = new PropertyDescriptor("Version", "Version");
version.setCategory("General");
PropertyDescriptor path = new PropertyDescriptor("Path", "Path");
path.setCategory("General");
PropertyDescriptor log = new PropertyDescriptor("Log", "Log");
log.setCategory("General");
log.setLabelProvider(new LabelProvider() {
@Override
public String getText(Object element) {
if (element instanceof List<?>) {
List<?> logList = (List<?>) element;
StringBuilder out = new StringBuilder();
for (Object logEntry : logList) {
out.append(logEntry + "\n");
}
return out.toString();
}
return "";
}
});
PropertyDescriptor reqPlugins = new PropertyDescriptor("RequiredPlugins", "Required Plugins");
reqPlugins.setCategory("Requirements");
PropertyDescriptor reqPackages = new PropertyDescriptor("ImportedPackages", "Imported Packages");
reqPackages.setCategory("Requirements");
PropertyDescriptor resPlugins = new PropertyDescriptor("ResolvedRequiredPlugins", "Required Plugins (resolved)");
resPlugins.setCategory("Resolution");
PropertyDescriptor resPackages = new PropertyDescriptor("ResolvedImportedPackages", "Imported Packages (resolved)");
resPackages.setCategory("Resolution");
PropertyDescriptor allDeps = new PropertyDescriptor("AllDependencies", "All Dependencies (resolved)");
allDeps.setCategory("Resolution");
PropertyDescriptor expPackages = new PropertyDescriptor("ExportedPackages", "Exported Packages");
PropertyDescriptor requiredBy = new PropertyDescriptor("RequiredBy", "Required By");
PropertyDescriptor includedIn = new PropertyDescriptor("IncludedIn", "Included In");
Collections.addAll(list, name, version, path, log, reqPlugins, reqPackages,
resPackages, resPlugins, expPackages, requiredBy, includedIn, allDeps);
return list.toArray(new IPropertyDescriptor[list.size()]);
}