use of org.eclipse.emf.ecore.impl.ENotificationImpl in project openhab1-addons by openhab.
the class MBrickletPiezoSpeakerImpl method setBrickd.
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated
*/
@Override
public void setBrickd(MBrickd newBrickd) {
if (newBrickd != eInternalContainer() || (eContainerFeatureID() != ModelPackage.MBRICKLET_PIEZO_SPEAKER__BRICKD && newBrickd != null)) {
if (EcoreUtil.isAncestor(this, newBrickd))
throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
NotificationChain msgs = null;
if (eInternalContainer() != null)
msgs = eBasicRemoveFromContainer(msgs);
if (newBrickd != null)
msgs = ((InternalEObject) newBrickd).eInverseAdd(this, ModelPackage.MBRICKD__MDEVICES, MBrickd.class, msgs);
msgs = basicSetBrickd(newBrickd, msgs);
if (msgs != null)
msgs.dispatch();
} else if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ModelPackage.MBRICKLET_PIEZO_SPEAKER__BRICKD, newBrickd, newBrickd));
}
use of org.eclipse.emf.ecore.impl.ENotificationImpl in project openhab1-addons by openhab.
the class MBrickletRemoteSwitchImpl method setTinkerforgeDevice.
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated
*/
@Override
public void setTinkerforgeDevice(BrickletRemoteSwitch newTinkerforgeDevice) {
BrickletRemoteSwitch oldTinkerforgeDevice = tinkerforgeDevice;
tinkerforgeDevice = newTinkerforgeDevice;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ModelPackage.MBRICKLET_REMOTE_SWITCH__TINKERFORGE_DEVICE, oldTinkerforgeDevice, tinkerforgeDevice));
}
use of org.eclipse.emf.ecore.impl.ENotificationImpl in project openhab1-addons by openhab.
the class MBrickletRemoteSwitchImpl method setEnabledA.
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated
*/
@Override
public void setEnabledA(AtomicBoolean newEnabledA) {
AtomicBoolean oldEnabledA = enabledA;
enabledA = newEnabledA;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ModelPackage.MBRICKLET_REMOTE_SWITCH__ENABLED_A, oldEnabledA, enabledA));
}
use of org.eclipse.emf.ecore.impl.ENotificationImpl in project openhab1-addons by openhab.
the class MBrickletRemoteSwitchImpl method setTfConfig.
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated
*/
@Override
public void setTfConfig(BrickletRemoteSwitchConfiguration newTfConfig) {
if (newTfConfig != tfConfig) {
NotificationChain msgs = null;
if (tfConfig != null)
msgs = ((InternalEObject) tfConfig).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - ModelPackage.MBRICKLET_REMOTE_SWITCH__TF_CONFIG, null, msgs);
if (newTfConfig != null)
msgs = ((InternalEObject) newTfConfig).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - ModelPackage.MBRICKLET_REMOTE_SWITCH__TF_CONFIG, null, msgs);
msgs = basicSetTfConfig(newTfConfig, msgs);
if (msgs != null)
msgs.dispatch();
} else if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ModelPackage.MBRICKLET_REMOTE_SWITCH__TF_CONFIG, newTfConfig, newTfConfig));
}
use of org.eclipse.emf.ecore.impl.ENotificationImpl in project openhab1-addons by openhab.
the class MBrickletMotionDetectorImpl method setIpConnection.
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
*
* @generated
*/
@Override
public void setIpConnection(IPConnection newIpConnection) {
IPConnection oldIpConnection = ipConnection;
ipConnection = newIpConnection;
if (eNotificationRequired())
eNotify(new ENotificationImpl(this, Notification.SET, ModelPackage.MBRICKLET_MOTION_DETECTOR__IP_CONNECTION, oldIpConnection, ipConnection));
}
Aggregations