org.eclipse.xtext.common.types.ui.notification
Class NameBasedEObjectDescription

java.lang.Object
  extended by org.eclipse.xtext.common.types.ui.notification.NameBasedEObjectDescription
All Implemented Interfaces:
IEObjectDescription

public class NameBasedEObjectDescription
extends java.lang.Object
implements IEObjectDescription

Very simple description which actually wraps a qualified name. This description cannot provide a proxy nor give access to an uri. It will return null when it is queried for an EClass.

Author:
Sebastian Zarnekow - Initial contribution and API

Constructor Summary
protected NameBasedEObjectDescription(QualifiedName name)
           
 
Method Summary
 org.eclipse.emf.ecore.EClass getEClass()
           
 org.eclipse.emf.ecore.EObject getEObjectOrProxy()
           
 org.eclipse.emf.common.util.URI getEObjectURI()
           
 QualifiedName getName()
           
 QualifiedName getQualifiedName()
           
 java.lang.String getUserData(java.lang.String name)
          Access to specific user data.
 java.lang.String[] getUserDataKeys()
           
 java.lang.String toString()
           
 
Methods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, wait
 

Constructor Detail

NameBasedEObjectDescription

protected NameBasedEObjectDescription(QualifiedName name)
Method Detail

getName

public QualifiedName getName()
Specified by:
getName in interface IEObjectDescription
Returns:
the name, this element can be accessed by.

getQualifiedName

public QualifiedName getQualifiedName()
Specified by:
getQualifiedName in interface IEObjectDescription
Returns:
the qualified name of the element.

getEObjectOrProxy

public org.eclipse.emf.ecore.EObject getEObjectOrProxy()
Specified by:
getEObjectOrProxy in interface IEObjectDescription
Returns:
the actual element or a proxy.

getEObjectURI

public org.eclipse.emf.common.util.URI getEObjectURI()
Specified by:
getEObjectURI in interface IEObjectDescription
Returns:
the full URI to the described element

getEClass

public org.eclipse.emf.ecore.EClass getEClass()
Specified by:
getEClass in interface IEObjectDescription
Returns:
the EClass of the described element.

getUserData

public java.lang.String getUserData(java.lang.String name)
Description copied from interface: IEObjectDescription
Access to specific user data.

Specified by:
getUserData in interface IEObjectDescription
Parameters:
name - the user data key. May not be null. Unknown keys yield null.
Returns:
the value. May be null.

getUserDataKeys

public java.lang.String[] getUserDataKeys()
Specified by:
getUserDataKeys in interface IEObjectDescription
Returns:
all available user data keys. Never null.

toString

public java.lang.String toString()
Overrides:
toString in class java.lang.Object