Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
Diffstat (limited to 'extraplugins/diagram-definition/org.eclipse.papyrus.dd/src/org/eclipse/papyrus/dd/dg/impl/ScaleImpl.java')
-rw-r--r--extraplugins/diagram-definition/org.eclipse.papyrus.dd/src/org/eclipse/papyrus/dd/dg/impl/ScaleImpl.java127
1 files changed, 51 insertions, 76 deletions
diff --git a/extraplugins/diagram-definition/org.eclipse.papyrus.dd/src/org/eclipse/papyrus/dd/dg/impl/ScaleImpl.java b/extraplugins/diagram-definition/org.eclipse.papyrus.dd/src/org/eclipse/papyrus/dd/dg/impl/ScaleImpl.java
index 44e4068ef11..fdfb690e5b5 100644
--- a/extraplugins/diagram-definition/org.eclipse.papyrus.dd/src/org/eclipse/papyrus/dd/dg/impl/ScaleImpl.java
+++ b/extraplugins/diagram-definition/org.eclipse.papyrus.dd/src/org/eclipse/papyrus/dd/dg/impl/ScaleImpl.java
@@ -36,20 +36,17 @@ import org.eclipse.papyrus.dd.dg.util.DGValidator;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.dd.dg.impl.ScaleImpl#getFactorX <em>Factor X
- * </em>}</li>
- * <li>{@link org.eclipse.papyrus.dd.dg.impl.ScaleImpl#getFactorY <em>Factor Y
- * </em>}</li>
+ * <li>{@link org.eclipse.papyrus.dd.dg.impl.ScaleImpl#getFactorX <em>Factor X</em>}</li>
+ * <li>{@link org.eclipse.papyrus.dd.dg.impl.ScaleImpl#getFactorY <em>Factor Y</em>}</li>
* </ul>
* </p>
- *
+ *
* @generated
*/
public class ScaleImpl extends TransformImpl implements Scale {
/**
- * The default value of the '{@link #getFactorX() <em>Factor X</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
+ * The default value of the '{@link #getFactorX() <em>Factor X</em>}' attribute.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
* @see #getFactorX()
* @generated
* @ordered
@@ -57,9 +54,8 @@ public class ScaleImpl extends TransformImpl implements Scale {
protected static final double FACTOR_X_EDEFAULT = 0.0;
/**
- * The cached value of the '{@link #getFactorX() <em>Factor X</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
+ * The cached value of the '{@link #getFactorX() <em>Factor X</em>}' attribute.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
* @see #getFactorX()
* @generated
* @ordered
@@ -67,9 +63,8 @@ public class ScaleImpl extends TransformImpl implements Scale {
protected double factorX = FACTOR_X_EDEFAULT;
/**
- * The default value of the '{@link #getFactorY() <em>Factor Y</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
+ * The default value of the '{@link #getFactorY() <em>Factor Y</em>}' attribute.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
* @see #getFactorY()
* @generated
* @ordered
@@ -77,9 +72,8 @@ public class ScaleImpl extends TransformImpl implements Scale {
protected static final double FACTOR_Y_EDEFAULT = 0.0;
/**
- * The cached value of the '{@link #getFactorY() <em>Factor Y</em>}'
- * attribute. <!-- begin-user-doc --> <!-- end-user-doc -->
- *
+ * The cached value of the '{@link #getFactorY() <em>Factor Y</em>}' attribute.
+ * <!-- begin-user-doc --> <!-- end-user-doc -->
* @see #getFactorY()
* @generated
* @ordered
@@ -88,7 +82,6 @@ public class ScaleImpl extends TransformImpl implements Scale {
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
protected ScaleImpl() {
@@ -97,7 +90,6 @@ public class ScaleImpl extends TransformImpl implements Scale {
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
@@ -107,7 +99,6 @@ public class ScaleImpl extends TransformImpl implements Scale {
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
public double getFactorX() {
@@ -116,20 +107,17 @@ public class ScaleImpl extends TransformImpl implements Scale {
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
public void setFactorX(double newFactorX) {
double oldFactorX = factorX;
factorX = newFactorX;
if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- DGPackage.SCALE__FACTOR_X, oldFactorX, factorX));
+ eNotify(new ENotificationImpl(this, Notification.SET, DGPackage.SCALE__FACTOR_X, oldFactorX, factorX));
}
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
public double getFactorY() {
@@ -138,25 +126,20 @@ public class ScaleImpl extends TransformImpl implements Scale {
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
public void setFactorY(double newFactorY) {
double oldFactorY = factorY;
factorY = newFactorY;
if (eNotificationRequired())
- eNotify(new ENotificationImpl(this, Notification.SET,
- DGPackage.SCALE__FACTOR_Y, oldFactorY, factorY));
+ eNotify(new ENotificationImpl(this, Notification.SET, DGPackage.SCALE__FACTOR_Y, oldFactorY, factorY));
}
/**
- * The cached validation expression for the '
- * {@link #nonnegativescale(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map)
- * <em>Nonnegativescale</em>}' invariant operation. <!-- begin-user-doc -->
+ * The cached validation expression for the '{@link #nonnegativescale(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map) <em>Nonnegativescale</em>}' invariant operation.
+ * <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
- * @see #nonnegativescale(org.eclipse.emf.common.util.DiagnosticChain,
- * java.util.Map)
+ * @see #nonnegativescale(org.eclipse.emf.common.util.DiagnosticChain, java.util.Map)
* @generated
* @ordered
*/
@@ -164,95 +147,90 @@ public class ScaleImpl extends TransformImpl implements Scale {
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
public boolean nonnegativescale(DiagnosticChain diagnostics,
Map<Object, Object> context) {
- return DGValidator
- .validate(
- DGPackage.Literals.SCALE,
- this,
- diagnostics,
- context,
- "http://www.eclipse.org/emf/2002/Ecore/OCL",
- DGPackage.Literals.SCALE___NONNEGATIVESCALE__DIAGNOSTICCHAIN_MAP,
- NONNEGATIVESCALE_DIAGNOSTIC_CHAIN_MAP__EEXPRESSION,
- Diagnostic.ERROR, DGValidator.DIAGNOSTIC_SOURCE,
- DGValidator.SCALE__NONNEGATIVESCALE);
+ return
+ DGValidator.validate
+ (DGPackage.Literals.SCALE,
+ this,
+ diagnostics,
+ context,
+ "http://www.eclipse.org/emf/2002/Ecore/OCL",
+ DGPackage.Literals.SCALE___NONNEGATIVESCALE__DIAGNOSTICCHAIN_MAP,
+ NONNEGATIVESCALE_DIAGNOSTIC_CHAIN_MAP__EEXPRESSION,
+ Diagnostic.ERROR,
+ DGValidator.DIAGNOSTIC_SOURCE,
+ DGValidator.SCALE__NONNEGATIVESCALE);
}
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case DGPackage.SCALE__FACTOR_X:
- return getFactorX();
- case DGPackage.SCALE__FACTOR_Y:
- return getFactorY();
+ case DGPackage.SCALE__FACTOR_X:
+ return getFactorX();
+ case DGPackage.SCALE__FACTOR_Y:
+ return getFactorY();
}
return super.eGet(featureID, resolve, coreType);
}
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case DGPackage.SCALE__FACTOR_X:
- setFactorX((Double) newValue);
- return;
- case DGPackage.SCALE__FACTOR_Y:
- setFactorY((Double) newValue);
- return;
+ case DGPackage.SCALE__FACTOR_X:
+ setFactorX((Double)newValue);
+ return;
+ case DGPackage.SCALE__FACTOR_Y:
+ setFactorY((Double)newValue);
+ return;
}
super.eSet(featureID, newValue);
}
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case DGPackage.SCALE__FACTOR_X:
- setFactorX(FACTOR_X_EDEFAULT);
- return;
- case DGPackage.SCALE__FACTOR_Y:
- setFactorY(FACTOR_Y_EDEFAULT);
- return;
+ case DGPackage.SCALE__FACTOR_X:
+ setFactorX(FACTOR_X_EDEFAULT);
+ return;
+ case DGPackage.SCALE__FACTOR_Y:
+ setFactorY(FACTOR_Y_EDEFAULT);
+ return;
}
super.eUnset(featureID);
}
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case DGPackage.SCALE__FACTOR_X:
- return factorX != FACTOR_X_EDEFAULT;
- case DGPackage.SCALE__FACTOR_Y:
- return factorY != FACTOR_Y_EDEFAULT;
+ case DGPackage.SCALE__FACTOR_X:
+ return factorX != FACTOR_X_EDEFAULT;
+ case DGPackage.SCALE__FACTOR_Y:
+ return factorY != FACTOR_Y_EDEFAULT;
}
return super.eIsSet(featureID);
}
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
@@ -260,22 +238,19 @@ public class ScaleImpl extends TransformImpl implements Scale {
public Object eInvoke(int operationID, EList<?> arguments)
throws InvocationTargetException {
switch (operationID) {
- case DGPackage.SCALE___NONNEGATIVESCALE__DIAGNOSTICCHAIN_MAP:
- return nonnegativescale((DiagnosticChain) arguments.get(0),
- (Map<Object, Object>) arguments.get(1));
+ case DGPackage.SCALE___NONNEGATIVESCALE__DIAGNOSTICCHAIN_MAP:
+ return nonnegativescale((DiagnosticChain)arguments.get(0), (Map<Object, Object>)arguments.get(1));
}
return super.eInvoke(operationID, arguments);
}
/**
* <!-- begin-user-doc --> <!-- end-user-doc -->
- *
* @generated
*/
@Override
public String toString() {
- if (eIsProxy())
- return super.toString();
+ if (eIsProxy()) return super.toString();
StringBuffer result = new StringBuffer(super.toString());
result.append(" (factorX: ");

Back to the top