Class EObjectUtil
java.lang.Object
org.eclipse.emf.compare.internal.spec.EObjectUtil
public final class EObjectUtil
extends java.lang.Object
Static utilities to create human readable EObject.toString() methods.
-
Method Summary
Modifier and Type Method Description static java.lang.StringgetLabel(EObject object)Returns a String label for the given EObject given the following rules : if the givenobjectisnull, returns the String"<null>"if not null, return the name of theEClassof the givenobjectand the hex string of the object hashcode.
-
Method Details
-
getLabel
Returns a String label for the given EObject given the following rules :- if the given
objectisnull, returns the String"<null>" - if not null, return the name of the
EClassof the givenobjectand the hex string of the object hashcode. It is followed by the value of theEStructuralFeaturename if the givenobjecthas one or the first EAttribute with an instance class equals to String. (same rule as in the ReflectiveItemProvider)
- Parameters:
object- the object to get the label from.- Returns:
- the label.
- if the given
-