Package org.eclipse.core.commands.common
Class NamedHandleObject
- java.lang.Object
-
- org.eclipse.core.commands.common.EventManager
-
- org.eclipse.core.commands.common.HandleObject
-
- org.eclipse.core.commands.common.NamedHandleObject
-
- All Implemented Interfaces:
IIdentifiable
public abstract class NamedHandleObject extends HandleObject
A handle object that carries with it a name and a description. This type of handle object is quite common across the commands code base. For example,Command,ContextandScheme.- Since:
- 3.1
-
-
Field Summary
Fields Modifier and Type Field Description protected java.lang.StringdescriptionThe description for this handle.protected java.lang.StringnameThe name of this handle.-
Fields inherited from class org.eclipse.core.commands.common.HandleObject
defined, id, string
-
-
Constructor Summary
Constructors Modifier Constructor Description protectedNamedHandleObject(java.lang.String id)Constructs a new instance ofNamedHandleObject.
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description java.lang.StringgetDescription()Returns the description for this handle.java.lang.StringgetName()Returns the name for this handle.-
Methods inherited from class org.eclipse.core.commands.common.HandleObject
equals, getId, hashCode, isDefined, toString, undefine
-
Methods inherited from class org.eclipse.core.commands.common.EventManager
addListenerObject, clearListeners, getListeners, isListenerAttached, removeListenerObject
-
-
-
-
Method Detail
-
getDescription
public java.lang.String getDescription() throws NotDefinedExceptionReturns the description for this handle.- Returns:
- The description; may be
nullif there is no description. - Throws:
NotDefinedException- If the handle is not currently defined.
-
getName
public java.lang.String getName() throws NotDefinedExceptionReturns the name for this handle.- Returns:
- The name for this handle; never
null. - Throws:
NotDefinedException- If the handle is not currently defined.
-
-