diff options
author | khussey | 2010-09-28 21:19:30 +0000 |
---|---|---|
committer | khussey | 2010-09-28 21:19:30 +0000 |
commit | 969ffee408f7c8392016ad4b1a402d944b42a919 (patch) | |
tree | b998fd34e173eca04e6c04171ea04dae10cc0975 /plugins/org.eclipse.uml2.codegen.ecore | |
parent | c01f51b4891253ad45f50a490d371195b72ed02d (diff) | |
download | org.eclipse.uml2-969ffee408f7c8392016ad4b1a402d944b42a919.tar.gz org.eclipse.uml2-969ffee408f7c8392016ad4b1a402d944b42a919.tar.xz org.eclipse.uml2-969ffee408f7c8392016ad4b1a402d944b42a919.zip |
[323181] Regenerating code with latest templates.v201009281840
Diffstat (limited to 'plugins/org.eclipse.uml2.codegen.ecore')
2 files changed, 59 insertions, 56 deletions
diff --git a/plugins/org.eclipse.uml2.codegen.ecore/src/org/eclipse/uml2/codegen/ecore/genmodel/impl/GenClassImpl.java b/plugins/org.eclipse.uml2.codegen.ecore/src/org/eclipse/uml2/codegen/ecore/genmodel/impl/GenClassImpl.java index 66223c664..b722cc128 100644 --- a/plugins/org.eclipse.uml2.codegen.ecore/src/org/eclipse/uml2/codegen/ecore/genmodel/impl/GenClassImpl.java +++ b/plugins/org.eclipse.uml2.codegen.ecore/src/org/eclipse/uml2/codegen/ecore/genmodel/impl/GenClassImpl.java @@ -9,9 +9,9 @@ * IBM - initial API and implementation * Kenn Hussey (Embarcadero Technologies) - 206636, 204200 * Lutz Wrage - 241411 - * Kenn Hussey - 286329 + * Kenn Hussey - 286329, 323181 * - * $Id: GenClassImpl.java,v 1.47 2010/04/29 21:00:51 khussey Exp $ + * $Id: GenClassImpl.java,v 1.48 2010/09/28 21:19:30 khussey Exp $ */ package org.eclipse.uml2.codegen.ecore.genmodel.impl; @@ -98,8 +98,10 @@ public class GenClassImpl if (genClasses != null) { for (org.eclipse.emf.codegen.ecore.genmodel.GenClass genClass : genClasses) { - result.addAll(collectGenFeatures(null, UML2GenModelUtil - .getDuplicateGenFeatures(genClass), filter)); + result + .addAll(collectGenFeatures(null, + UML2GenModelUtil.getDuplicateGenFeatures(genClass), + filter)); } } @@ -262,8 +264,9 @@ public class GenClassImpl if (genClasses != null) { for (org.eclipse.emf.codegen.ecore.genmodel.GenClass genClass : genClasses) { - result.addAll(collectGenOperations(this, null, UML2GenModelUtil - .getDuplicateGenOperations(genClass), filter)); + result.addAll(collectGenOperations(this, null, + UML2GenModelUtil.getDuplicateGenOperations(genClass), + filter)); } } @@ -568,10 +571,9 @@ public class GenClassImpl } else if (genFeature.isEffectiveContains()) { if (genFeature.isBidirectional()) { GenFeature reverseFeature = genFeature.getReverse(); - sb - .append(getGenModel() - .getImportedName( - "org.eclipse.uml2.common.util.SubsetSupersetEObjectContainmentWithInverseEList")); //$NON-NLS-1$ + sb.append(getGenModel() + .getImportedName( + "org.eclipse.uml2.common.util.SubsetSupersetEObjectContainmentWithInverseEList")); //$NON-NLS-1$ sb.append(unsettable); if (genFeature.isResolveProxies()) { sb.append(".Resolving"); //$NON-NLS-1$ @@ -607,10 +609,9 @@ public class GenClassImpl reverseFeature)); sb.append(")"); //$NON-NLS-1$ } else { - sb - .append(getGenModel() - .getImportedName( - "org.eclipse.uml2.common.util.SubsetSupersetEObjectContainmentEList")); //$NON-NLS-1$ + sb.append(getGenModel() + .getImportedName( + "org.eclipse.uml2.common.util.SubsetSupersetEObjectContainmentEList")); //$NON-NLS-1$ sb.append(unsettable); if (genFeature.isResolveProxies()) { sb.append(".Resolving"); //$NON-NLS-1$ @@ -647,15 +648,13 @@ public class GenClassImpl if (genFeature.isBidirectional()) { GenFeature reverseFeature = genFeature.getReverse(); if (genFeature.isResolveProxies()) { - sb - .append(getGenModel() - .getImportedName( - "org.eclipse.uml2.common.util.SubsetSupersetEObjectWithInverseResolvingEList")); //$NON-NLS-1$ + sb.append(getGenModel() + .getImportedName( + "org.eclipse.uml2.common.util.SubsetSupersetEObjectWithInverseResolvingEList")); //$NON-NLS-1$ } else { - sb - .append(getGenModel() - .getImportedName( - "org.eclipse.uml2.common.util.SubsetSupersetEObjectWithInverseEList")); //$NON-NLS-1$ + sb.append(getGenModel() + .getImportedName( + "org.eclipse.uml2.common.util.SubsetSupersetEObjectWithInverseEList")); //$NON-NLS-1$ } sb.append(unsettable); if (reverseFeature.isListType()) { @@ -693,15 +692,13 @@ public class GenClassImpl sb.append(")"); //$NON-NLS-1$ } else { if (genFeature.isResolveProxies()) { - sb - .append(getGenModel() - .getImportedName( - "org.eclipse.uml2.common.util.SubsetSupersetEObjectResolvingEList")); //$NON-NLS-1$ + sb.append(getGenModel() + .getImportedName( + "org.eclipse.uml2.common.util.SubsetSupersetEObjectResolvingEList")); //$NON-NLS-1$ } else { - sb - .append(getGenModel() - .getImportedName( - "org.eclipse.uml2.common.util.SubsetSupersetEObjectEList")); //$NON-NLS-1$ + sb.append(getGenModel() + .getImportedName( + "org.eclipse.uml2.common.util.SubsetSupersetEObjectEList")); //$NON-NLS-1$ } sb.append(unsettable); if (getEffectiveComplianceLevel().getValue() >= GenJDKLevel.JDK50) { @@ -830,9 +827,12 @@ public class GenClassImpl EParameter ecoreParameter = ecoreOperation.getEParameters() .get(j); - if (!ecoreParameter.getEType().getName().equals( - (duplicateGenOperation.getEcoreOperation() - .getEParameters().get(j)).getEType().getName())) { + if (!ecoreParameter + .getEType() + .getName() + .equals( + (duplicateGenOperation.getEcoreOperation() + .getEParameters().get(j)).getEType().getName())) { continue genOperationsLoop; } @@ -1095,14 +1095,15 @@ public class GenClassImpl public List<GenFeature> getSupersetGenFeatures(GenFeature subsetGenFeature, final boolean includeDerived, final boolean includeListType) { - return collectGenFeatures(null, UML2GenModelUtil - .getSubsettedGenFeatures(subsetGenFeature), new GenFeatureFilter() { + return collectGenFeatures(null, + UML2GenModelUtil.getSubsettedGenFeatures(subsetGenFeature), + new GenFeatureFilter() { - public boolean accept(GenFeature genFeature) { - return (includeDerived || !genFeature.isDerived()) - && (includeListType || !genFeature.isListType()); - } - }); + public boolean accept(GenFeature genFeature) { + return (includeDerived || !genFeature.isDerived()) + && (includeListType || !genFeature.isListType()); + } + }); } public List<GenFeature> getImplementedSupersetGenFeatures() { @@ -1318,8 +1319,8 @@ public class GenClassImpl .getParameterTypes("")).equals(redefinedGenOperation //$NON-NLS-1$ .getName() + redefinedGenOperation.getParameterTypes(""))) { //$NON-NLS-1$ - redefinitionGenOperations.put(duplicateGenOperation - .getName(), duplicateGenOperation); + redefinitionGenOperations.put( + duplicateGenOperation.getName(), duplicateGenOperation); } } } diff --git a/plugins/org.eclipse.uml2.codegen.ecore/src/org/eclipse/uml2/codegen/ecore/genmodel/impl/GenFeatureImpl.java b/plugins/org.eclipse.uml2.codegen.ecore/src/org/eclipse/uml2/codegen/ecore/genmodel/impl/GenFeatureImpl.java index e038b4ffd..3f0c95d20 100644 --- a/plugins/org.eclipse.uml2.codegen.ecore/src/org/eclipse/uml2/codegen/ecore/genmodel/impl/GenFeatureImpl.java +++ b/plugins/org.eclipse.uml2.codegen.ecore/src/org/eclipse/uml2/codegen/ecore/genmodel/impl/GenFeatureImpl.java @@ -1,5 +1,5 @@ /* - * Copyright (c) 2005, 2009 IBM Corporation, Embarcadero Technologies, and others. + * Copyright (c) 2005, 2010 IBM Corporation, Embarcadero Technologies, and others. * 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 @@ -8,9 +8,9 @@ * Contributors: * IBM - initial API and implementation * Kenn Hussey (Embarcadero Technologies) - 208016, 247980 - * Kenn Hussey - 286329 + * Kenn Hussey - 286329, 323181 * - * $Id: GenFeatureImpl.java,v 1.32 2009/11/16 21:11:01 khussey Exp $ + * $Id: GenFeatureImpl.java,v 1.33 2010/09/28 21:19:30 khussey Exp $ */ package org.eclipse.uml2.codegen.ecore.genmodel.impl; @@ -407,8 +407,7 @@ public class GenFeatureImpl .getSubsettedEcoreFeatures(getEcoreFeature())) { if (((EStructuralFeature.Internal) subsettedEcoreFeature) - .isContainment() - && !subsettedEcoreFeature.isDerived()) { + .isContainment() && !subsettedEcoreFeature.isDerived()) { return true; } @@ -651,15 +650,18 @@ public class GenFeatureImpl .next(); if (count++ == index) { - return formattedKeyFeatureName.append( - "'<em><b>" //$NON-NLS-1$ - + format(keyGenFeature.getCapName() - + (keyGenFeature.isListType() - ? Generator - .pluralize(nestedKeyGenFeature - .getCapName()) - : nestedKeyGenFeature.getCapName()), - ' ', null, false, false) + "</b></em>'") //$NON-NLS-1$ + return formattedKeyFeatureName + .append( + "'<em><b>" //$NON-NLS-1$ + + format( + keyGenFeature.getCapName() + + (keyGenFeature.isListType() + ? Generator + .pluralize(nestedKeyGenFeature + .getCapName()) + : nestedKeyGenFeature + .getCapName()), ' ', null, + false, false) + "</b></em>'") //$NON-NLS-1$ .toString(); } } |