Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorTobias Schwarz2013-03-08 03:34:15 -0500
committerTobias Schwarz2013-03-08 03:34:15 -0500
commitd7b4a384b0a241fc473f7e58e12fcc2920b4bc33 (patch)
tree7ac0766dd16e87217561e5857639822c521504f2 /target_explorer/plugins/org.eclipse.tcf.te.runtime.services/src
parent4373f5450b71ddc415c7ebcdb33c3e4033abd298 (diff)
downloadorg.eclipse.tcf-d7b4a384b0a241fc473f7e58e12fcc2920b4bc33.tar.gz
org.eclipse.tcf-d7b4a384b0a241fc473f7e58e12fcc2920b4bc33.tar.xz
org.eclipse.tcf-d7b4a384b0a241fc473f7e58e12fcc2920b4bc33.zip
Target Explorer: add label provider delegate for core
Diffstat (limited to 'target_explorer/plugins/org.eclipse.tcf.te.runtime.services/src')
-rw-r--r--target_explorer/plugins/org.eclipse.tcf.te.runtime.services/src/org/eclipse/tcf/te/runtime/services/interfaces/delegates/ILabelProviderDelegate.java40
1 files changed, 40 insertions, 0 deletions
diff --git a/target_explorer/plugins/org.eclipse.tcf.te.runtime.services/src/org/eclipse/tcf/te/runtime/services/interfaces/delegates/ILabelProviderDelegate.java b/target_explorer/plugins/org.eclipse.tcf.te.runtime.services/src/org/eclipse/tcf/te/runtime/services/interfaces/delegates/ILabelProviderDelegate.java
new file mode 100644
index 000000000..abe514250
--- /dev/null
+++ b/target_explorer/plugins/org.eclipse.tcf.te.runtime.services/src/org/eclipse/tcf/te/runtime/services/interfaces/delegates/ILabelProviderDelegate.java
@@ -0,0 +1,40 @@
+/*******************************************************************************
+ * Copyright (c) 2013 Wind River Systems, Inc. and others. All rights reserved.
+ * This program and the accompanying materials are made available under the terms
+ * of the Eclipse Public License v1.0 which accompanies this distribution, and is
+ * available at http://www.eclipse.org/legal/epl-v10.html
+ *
+ * Contributors:
+ * Wind River Systems - initial API and implementation
+ *******************************************************************************/
+
+package org.eclipse.tcf.te.runtime.services.interfaces.delegates;
+
+import org.eclipse.tcf.te.runtime.services.interfaces.IUIService;
+
+/**
+ * Label provider delegate for {@link IUIService} to enable
+ * label provider access in core.
+ */
+public interface ILabelProviderDelegate {
+
+ /**
+ * Returns the text for the label of the given element.
+ *
+ * @param element the element for which to provide the label text
+ * @return the text string used to label the element, or <code>null</code>
+ * if there is no text label for the given object
+ */
+ public String getText(Object element);
+
+ /**
+ * Returns a text label that is based on the given text label,
+ * but decorated with additional information relating to the state
+ * of the provided element.
+ *
+ * @param text the input text label to decorate
+ * @param element the element whose image is being decorated
+ * @return the decorated text label, or <code>null</code> if no decoration is to be applied
+ */
+ public String decorateText(String text, Object element);
+}

Back to the top