All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.eclipse.bpmn2.di.impl.BPMNLabelImpl Maven / Gradle / Ivy

/**
 * 
 * 
 * Copyright (c) 2010 SAP AG.
 * 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:
 *    Reiner Hille-Doering (SAP AG) - initial API and implementation and/or initial documentation
 * 
 * 
 */
package org.eclipse.bpmn2.di.impl;

import com.google.gwt.user.client.rpc.GwtTransient;

import org.eclipse.bpmn2.di.BPMNLabel;
import org.eclipse.bpmn2.di.BPMNLabelStyle;
import org.eclipse.bpmn2.di.BpmnDiPackage;

import org.eclipse.dd.di.impl.LabelImpl;

import org.eclipse.emf.common.notify.Notification;

import org.eclipse.emf.ecore.EClass;
import org.eclipse.emf.ecore.InternalEObject;

import org.eclipse.emf.ecore.impl.ENotificationImpl;

/**
 * 
 * An implementation of the model object 'BPMN Label'.
 * 
 * 

* The following features are implemented: *

*
    *
  • {@link org.eclipse.bpmn2.di.impl.BPMNLabelImpl#getLabelStyle Label Style}
  • *
* * @generated */ public class BPMNLabelImpl extends LabelImpl implements BPMNLabel { /** * The cached value of the '{@link #getLabelStyle() Label Style}' reference. * * * @see #getLabelStyle() * @generated * @ordered */ @GwtTransient protected BPMNLabelStyle labelStyle; /** * * * @generated */ protected BPMNLabelImpl() { super(); } /** * * * @generated */ @Override protected EClass eStaticClass() { return BpmnDiPackage.Literals.BPMN_LABEL; } /** * * * @generated */ @Override public BPMNLabelStyle getLabelStyle() { if (labelStyle != null && labelStyle.eIsProxy()) { InternalEObject oldLabelStyle = (InternalEObject) labelStyle; labelStyle = (BPMNLabelStyle) eResolveProxy(oldLabelStyle); if (labelStyle != oldLabelStyle) { if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.RESOLVE, BpmnDiPackage.BPMN_LABEL__LABEL_STYLE, oldLabelStyle, labelStyle)); } } return labelStyle; } /** * * * @generated */ public BPMNLabelStyle basicGetLabelStyle() { return labelStyle; } /** * * * @generated */ @Override public void setLabelStyle(BPMNLabelStyle newLabelStyle) { BPMNLabelStyle oldLabelStyle = labelStyle; labelStyle = newLabelStyle; if (eNotificationRequired()) eNotify(new ENotificationImpl(this, Notification.SET, BpmnDiPackage.BPMN_LABEL__LABEL_STYLE, oldLabelStyle, labelStyle)); } /** * * * @generated */ @Override public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case BpmnDiPackage.BPMN_LABEL__LABEL_STYLE: if (resolve) return getLabelStyle(); return basicGetLabelStyle(); } return super.eGet(featureID, resolve, coreType); } /** * * * @generated */ @Override public void eSet(int featureID, Object newValue) { switch (featureID) { case BpmnDiPackage.BPMN_LABEL__LABEL_STYLE: setLabelStyle((BPMNLabelStyle) newValue); return; } super.eSet(featureID, newValue); } /** * * * @generated */ @Override public void eUnset(int featureID) { switch (featureID) { case BpmnDiPackage.BPMN_LABEL__LABEL_STYLE: setLabelStyle((BPMNLabelStyle) null); return; } super.eUnset(featureID); } /** * * * @generated */ @Override public boolean eIsSet(int featureID) { switch (featureID) { case BpmnDiPackage.BPMN_LABEL__LABEL_STYLE: return labelStyle != null; } return super.eIsSet(featureID); } } //BPMNLabelImpl




© 2015 - 2025 Weber Informatics LLC | Privacy Policy