/**
   * This returns the label text for the adapted class.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   *
   * @generated NOT
   */
  @Override
  public String getText(Object object) {
    StringBuffer text =
        appendType(
            appendKeywords(new StringBuffer(), object), "_UI_AssociationClass_type"); // $NON-NLS-1$

    AssociationClass associationClass = (AssociationClass) object;

    if (associationClass.isDerived()) {
      appendString(text, "/"); // $NON-NLS-1$
    }

    String label = associationClass.getLabel(shouldTranslate());

    if (!UML2Util.isEmpty(label)) {
      appendString(text, label);
    } else {
      EList<Property> memberEnds = associationClass.getMemberEnds();

      if (!memberEnds.isEmpty()) {
        appendString(text, "A"); // $NON-NLS-1$

        for (Property memberEnd : memberEnds) {
          String memberEndName = memberEnd.getName();

          text.append('_');

          if (!UML2Util.isEmpty(memberEndName)) {
            text.append(memberEndName);
          } else {
            Type type = memberEnd.getType();

            if (type != null) {
              String typeName = type.getName();

              if (!UML2Util.isEmpty(typeName)) {
                memberEndName = Character.toLowerCase(typeName.charAt(0)) + typeName.substring(1);
              }
            }

            if (!UML2Util.isEmpty(memberEndName)) {
              text.append(memberEndName);
            } else {
              text.append('<');
              text.append(getTypeText(memberEnd));
              text.append('>');
            }
          }
        }
      }
    }

    return text.toString();
  }
  /**
   * This returns the label text for the adapted class.
   * <!-- begin-user-doc -->
   * <!-- end-user-doc -->
   *
   * @generated NOT
   */
  @Override
  public String getText(Object object) {
    StringBuffer text =
        appendType(
            appendKeywords(new StringBuffer(), object), "_UI_InstanceValue_type"); // $NON-NLS-1$

    InstanceValue instanceValue = (InstanceValue) object;
    String label = instanceValue.getLabel(shouldTranslate());

    appendString(text, !UML2Util.isEmpty(label) ? label : instanceValue.stringValue());

    return text.toString();
  }
  @Before
  public void createFixture() throws Exception {
    URI profileURI =
        URI.createPlatformPluginURI(
            "org.eclipse.papyrus.uml.modelrepair.tests/resources/profile/myprofile.profile.uml",
            true);
    profile = UML2Util.load(modelSet.getResourceSet(), profileURI, UMLPackage.Literals.PROFILE);
    stereotype = profile.getOwnedStereotype("Stereo");
    class1 = (Class) modelSet.getModel().getOwnedType("Class1");

    fixture =
        houseKeeper.cleanUpLater(
            new StereotypeApplicationRepairSnippet(Functions.constant(profile)),
            "dispose",
            modelSet.getResourceSet());
    fixture.start(modelSet.getResourceSet());
    houseKeeper.setField(
        "zombies", fixture.getZombieStereotypes(modelSet.getModelResource(), modelSet.getModel()));
  }