Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCamille Letavernier2014-08-21 11:37:18 +0000
committerCamille Letavernier2014-08-21 11:37:18 +0000
commitea48a20561464c3cbb7895d430583669a9f82fcc (patch)
tree0fdf9eebacbbb301b13bafce3ca4a6952ff6e91c /extraplugins/facade
parentf91b71175fd97557cf378cdcad845a44a6274b16 (diff)
downloadorg.eclipse.papyrus-ea48a20561464c3cbb7895d430583669a9f82fcc.tar.gz
org.eclipse.papyrus-ea48a20561464c3cbb7895d430583669a9f82fcc.tar.xz
org.eclipse.papyrus-ea48a20561464c3cbb7895d430583669a9f82fcc.zip
[Code style] Apply clean-up and formatter on Extra plug-ins
Diffstat (limited to 'extraplugins/facade')
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.codegen/src-templates/org/eclipse/papyrus/facade/codegen/genfacade/GenFacade.java434
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/FacadeCodeGenPlugin.java6
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/Messages.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/handlers/GenerateFacadeHandler.java135
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/EEFGeneratorAdapter.java38
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/FacadeCodegenUtils.java653
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/WrappingListUtils.java215
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/ResourceManager.java79
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/SWTResourceManager.java75
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeDefinitionEditorActivator.java10
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeSpecificEditor.java127
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/Messages.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/EditionUtils.java78
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/ExtensionKindColumnEditingSupport.java118
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/IsPossibleColumnEditingSupport.java80
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassAliasColumnEditingSupport.java28
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassIsAbstractColumnEditingSupport.java30
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassToKeepColumnEditingSupport.java30
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassUseRepresentedColumnEditingSupport.java28
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesAliasColumnEdintingSupport.java28
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMaxColumnEdintingSupport.java52
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMinColumnEdintingSupport.java50
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesToKeepColumnEditingSupport.java38
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/StereotypeIncompatibilityColumnEditingSupport.java98
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/CreatePreliminaryMetamodelListener.java155
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/EcoreGenerator.java351
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/MetamodelUtils.java577
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionContentProvider.java44
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionLabelProvider.java82
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesContentProvider.java14
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesLabelProvider.java62
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelContentProvider.java32
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelLabelProvider.java84
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementContentProvider.java24
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementLabelProvider.java58
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/ProfileUtils.java90
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/PrunerUtils.java106
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/StereotypeUtils.java50
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/UMLModelUtils.java4
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/BaseMetaclassItemProvider.java105
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/CombinationItemProvider.java41
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensionDefinitionItemProvider.java118
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensiondefinitionItemProviderAdapterFactory.java44
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeEditPlugin.java19
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProvider.java37
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProviderAdapterFactory.java32
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualClassifierItemProvider.java20
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualDatatypeItemProvider.java21
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualElementItemProvider.java131
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualEnumItemProvider.java36
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualLiteralItemProvider.java21
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetaclassItemProvider.java150
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetamodelItemProvider.java130
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualOperationItemProvider.java36
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualParameterItemProvider.java21
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualPropertyItemProvider.java21
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualTypedElementItemProvider.java103
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualmetamodelItemProviderAdapterFactory.java74
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacadeMapppingItemProvider.java35
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingEditPlugin.java15
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingItemProviderAdapterFactory.java44
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/MappingItemProvider.java66
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/StereotypedMappingItemProvider.java77
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionActionBarContributor.java99
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionEditor.java846
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionModelWizard.java167
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeActionBarContributor.java99
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditor.java846
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditorPlugin.java23
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeModelWizard.java167
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelActionBarContributor.java99
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelEditor.java846
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelModelWizard.java167
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingActionBarContributor.java99
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditor.java846
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditorPlugin.java23
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingModelWizard.java164
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/CombinationGenerator.java26
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/FacadeUtilsActivator.java6
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/RepresentingElement.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentEList.java88
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentWithInverseEList.java88
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectEList.java84
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectWithInverseEList.java48
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingList.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentEList.java234
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentWithInverseEList.java234
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectEList.java234
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectWithInverseEList.java234
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Facade.java17
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeActivator.java8
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeFactory.java8
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadePackage.java42
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Messages.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/BaseMetaclass.java44
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/Combination.java8
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinition.java48
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinitionKind.java73
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionFactory.java10
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionPackage.java82
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/BaseMetaclassImpl.java221
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/CombinationImpl.java37
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensionDefinitionImpl.java238
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionFactoryImpl.java61
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionPackageImpl.java141
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionAdapterFactory.java60
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceFactoryImpl.java7
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceImpl.java9
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionSwitch.java67
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionXMLProcessor.java9
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/BaseMetaclassValidator.java6
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/CombinationValidator.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/ExtensionDefinitionValidator.java6
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeFactoryImpl.java27
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeImpl.java111
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadePackageImpl.java80
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeAdapterFactory.java40
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceFactoryImpl.java7
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceImpl.java9
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeSwitch.java35
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeXMLProcessor.java9
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/validation/FacadeValidator.java3
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualClassifier.java12
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualDatatype.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualElement.java42
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualEnum.java8
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualLiteral.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetaclass.java46
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetamodel.java48
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualOperation.java8
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualParameter.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualProperty.java12
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualTypedElement.java32
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelFactory.java15
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelPackage.java200
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualClassifierImpl.java83
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualDatatypeImpl.java6
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualElementImpl.java148
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualEnumImpl.java42
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualLiteralImpl.java6
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetaclassImpl.java199
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetamodelImpl.java216
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualOperationImpl.java42
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualParameterImpl.java6
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualPropertyImpl.java83
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualTypedElementImpl.java119
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelFactoryImpl.java62
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelPackageImpl.java221
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelAdapterFactory.java140
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceFactoryImpl.java7
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceImpl.java9
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelSwitch.java255
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelXMLProcessor.java9
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualClassifierValidator.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualDatatypeValidator.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualElementValidator.java5
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualEnumValidator.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualLiteralValidator.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetaclassValidator.java7
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetamodelValidator.java6
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualOperationValidator.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualParameterValidator.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualPropertyValidator.java2
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualTypedElementValidator.java4
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/ExtensionDefinitionKind.java73
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacadeMappping.java8
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingFactory.java10
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingPackage.java66
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/Mapping.java22
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/StereotypedMapping.java18
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacadeMapppingImpl.java42
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingFactoryImpl.java61
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingPackageImpl.java92
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/MappingImpl.java90
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/StereotypedMappingImpl.java73
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingAdapterFactory.java60
-rw-r--r--extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingSwitch.java71
177 files changed, 9042 insertions, 6624 deletions
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src-templates/org/eclipse/papyrus/facade/codegen/genfacade/GenFacade.java b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src-templates/org/eclipse/papyrus/facade/codegen/genfacade/GenFacade.java
index 31b9c62b4d2..dafa77d1c65 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src-templates/org/eclipse/papyrus/facade/codegen/genfacade/GenFacade.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src-templates/org/eclipse/papyrus/facade/codegen/genfacade/GenFacade.java
@@ -4,7 +4,7 @@
* 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:
* Obeo - initial API and implementation
* CEA LIST - Modification to support Facade code generation
@@ -28,28 +28,28 @@ import org.eclipse.emf.ecore.resource.ResourceSet;
/**
* Entry point of the 'GenFacade' generation module.
- *
+ *
* @generated
*/
public class GenFacade extends AbstractAcceleoGenerator {
/**
* The name of the module.
- *
+ *
* @generated
*/
public static final String MODULE_FILE_NAME = "/org/eclipse/papyrus/facade/codegen/genfacade/GenFacade"; //$NON-NLS-1$
/**
* The name of the templates that are to be generated.
- *
+ *
* @generated
*/
public static final String[] TEMPLATE_NAMES = { "GenAllGenClass" }; //$NON-NLS-1$
/**
* The list of properties files from the launch parameters (Launch configuration).
- *
+ *
* @generated
*/
private List<String> propertiesFiles = new ArrayList<String>();
@@ -59,116 +59,115 @@ public class GenFacade extends AbstractAcceleoGenerator {
* this way cannot be used to launch generations before one of {@link #initialize(EObject, File, List)} or {@link #initialize(URI, File, List)} is
* called.
* <p>
- * The main reason for this constructor is to allow clients of this generation to call it from another Java file, as it allows for the retrieval
- * of {@link #getProperties()} and {@link #getGenerationListeners()}.
+ * The main reason for this constructor is to allow clients of this generation to call it from another Java file, as it allows for the retrieval of {@link #getProperties()} and {@link #getGenerationListeners()}.
* </p>
- *
+ *
* @generated
*/
public GenFacade() {
- // Empty implementation
- }
+ // Empty implementation
+ }
/**
* This allows clients to instantiates a generator with all required information.
- *
+ *
* @param modelURI
- * URI where the model on which this generator will be used is located.
+ * URI where the model on which this generator will be used is located.
* @param targetFolder
- * This will be used as the output folder for this generation : it will be the base path
- * against which all file block URLs will be resolved.
+ * This will be used as the output folder for this generation : it will be the base path
+ * against which all file block URLs will be resolved.
* @param arguments
- * If the template which will be called requires more than one argument taken from the model,
- * pass them here.
+ * If the template which will be called requires more than one argument taken from the model,
+ * pass them here.
* @throws IOException
- * This can be thrown in three scenarios : the module cannot be found, it cannot be loaded, or
- * the model cannot be loaded.
+ * This can be thrown in three scenarios : the module cannot be found, it cannot be loaded, or
+ * the model cannot be loaded.
* @generated
*/
public GenFacade(URI modelURI, File targetFolder, List<? extends Object> arguments) throws IOException {
- initialize(modelURI, targetFolder, arguments);
- }
+ initialize(modelURI, targetFolder, arguments);
+ }
/**
* This allows clients to instantiates a generator with all required information.
- *
+ *
* @param model
- * We'll iterate over the content of this element to find Objects matching the first parameter
- * of the template we need to call.
+ * We'll iterate over the content of this element to find Objects matching the first parameter
+ * of the template we need to call.
* @param targetFolder
- * This will be used as the output folder for this generation : it will be the base path
- * against which all file block URLs will be resolved.
+ * This will be used as the output folder for this generation : it will be the base path
+ * against which all file block URLs will be resolved.
* @param arguments
- * If the template which will be called requires more than one argument taken from the model,
- * pass them here.
+ * If the template which will be called requires more than one argument taken from the model,
+ * pass them here.
* @throws IOException
- * This can be thrown in two scenarios : the module cannot be found, or it cannot be loaded.
+ * This can be thrown in two scenarios : the module cannot be found, or it cannot be loaded.
* @generated
*/
public GenFacade(EObject model, File targetFolder, List<? extends Object> arguments) throws IOException {
- initialize(model, targetFolder, arguments);
- }
+ initialize(model, targetFolder, arguments);
+ }
/**
* This can be used to launch the generation from a standalone application.
- *
+ *
* @param args
- * Arguments of the generation.
+ * Arguments of the generation.
* @generated
*/
public static void main(String[] args) {
- try {
- if (args.length < 2) {
- System.out.println("Arguments not valid : {model, folder}.");
- } else {
- URI modelURI = URI.createFileURI(args[0]);
- File folder = new File(args[1]);
-
- List<String> arguments = new ArrayList<String>();
-
- /*
- * If you want to change the content of this method, do NOT forget to change the "@generated"
- * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation
- * of the Acceleo module with the main template that has caused the creation of this class will
- * revert your modifications.
- */
-
- /*
- * Add in this list all the arguments used by the starting point of the generation
- * If your main template is called on an element of your model and a String, you can
- * add in "arguments" this "String" attribute.
- */
-
- GenFacade generator = new GenFacade(modelURI, folder, arguments);
-
- /*
- * Add the properties from the launch arguments.
- * If you want to programmatically add new properties, add them in "propertiesFiles"
- * You can add the absolute path of a properties files, or even a project relative path.
- * If you want to add another "protocol" for your properties files, please override
- * "getPropertiesLoaderService(AcceleoService)" in order to return a new property loader.
- * The behavior of the properties loader service is explained in the Acceleo documentation
- * (Help -> Help Contents).
- */
-
- for (int i = 2; i < args.length; i++) {
- generator.addPropertiesFile(args[i]);
- }
-
- generator.doGenerate(new BasicMonitor());
- }
- } catch (IOException e) {
- e.printStackTrace();
- }
- }
+ try {
+ if (args.length < 2) {
+ System.out.println("Arguments not valid : {model, folder}.");
+ } else {
+ URI modelURI = URI.createFileURI(args[0]);
+ File folder = new File(args[1]);
+
+ List<String> arguments = new ArrayList<String>();
+
+ /*
+ * If you want to change the content of this method, do NOT forget to change the "@generated"
+ * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation
+ * of the Acceleo module with the main template that has caused the creation of this class will
+ * revert your modifications.
+ */
+
+ /*
+ * Add in this list all the arguments used by the starting point of the generation
+ * If your main template is called on an element of your model and a String, you can
+ * add in "arguments" this "String" attribute.
+ */
+
+ GenFacade generator = new GenFacade(modelURI, folder, arguments);
+
+ /*
+ * Add the properties from the launch arguments.
+ * If you want to programmatically add new properties, add them in "propertiesFiles"
+ * You can add the absolute path of a properties files, or even a project relative path.
+ * If you want to add another "protocol" for your properties files, please override
+ * "getPropertiesLoaderService(AcceleoService)" in order to return a new property loader.
+ * The behavior of the properties loader service is explained in the Acceleo documentation
+ * (Help -> Help Contents).
+ */
+
+ for (int i = 2; i < args.length; i++) {
+ generator.addPropertiesFile(args[i]);
+ }
+
+ generator.doGenerate(new BasicMonitor());
+ }
+ } catch (IOException e) {
+ e.printStackTrace();
+ }
+ }
/**
* Launches the generation described by this instance.
- *
+ *
* @param monitor
- * This will be used to display progress information to the user.
+ * This will be used to display progress information to the user.
* @throws IOException
- * This will be thrown if any of the output files cannot be saved to disk.
+ * This will be thrown if any of the output files cannot be saved to disk.
* @generated NOT
*/
@Override
@@ -183,24 +182,24 @@ public class GenFacade extends AbstractAcceleoGenerator {
* note that those instructions may have a significant impact on the performances.
*/
- //org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(model);
+ // org.eclipse.emf.ecore.util.EcoreUtil.resolveAll(model);
/*
* If you want to check for potential errors in your models before the launch of the generation, you
* use the code below.
*/
- //if (model != null && model.eResource() != null) {
- // List<org.eclipse.emf.ecore.resource.Resource.Diagnostic> errors = model.eResource().getErrors();
- // for (org.eclipse.emf.ecore.resource.Resource.Diagnostic diagnostic : errors) {
- // System.err.println(diagnostic.toString());
- // }
- //}
+ // if (model != null && model.eResource() != null) {
+ // List<org.eclipse.emf.ecore.resource.Resource.Diagnostic> errors = model.eResource().getErrors();
+ // for (org.eclipse.emf.ecore.resource.Resource.Diagnostic diagnostic : errors) {
+ // System.err.println(diagnostic.toString());
+ // }
+ // }
- // super.doGenerate(monitor);
+ // super.doGenerate(monitor);
EObject model = getModel();
- if(model instanceof org.eclipse.emf.codegen.ecore.genmodel.GenModel) {
- ((org.eclipse.emf.codegen.ecore.genmodel.GenModel)model).getStaticGenPackages();
+ if (model instanceof org.eclipse.emf.codegen.ecore.genmodel.GenModel) {
+ ((org.eclipse.emf.codegen.ecore.genmodel.GenModel) model).getStaticGenPackages();
}
boolean formerCacheFlag = AcceleoPreferences.isQueryCacheEnabled();
try {
@@ -213,208 +212,205 @@ public class GenFacade extends AbstractAcceleoGenerator {
/**
* If this generator needs to listen to text generation events, listeners can be returned from here.
- *
+ *
* @return List of listeners that are to be notified when text is generated through this launch.
* @generated
*/
@Override
public List<IAcceleoTextGenerationListener> getGenerationListeners() {
- List<IAcceleoTextGenerationListener> listeners = super.getGenerationListeners();
- /*
- * TODO if you need to listen to generation event, add listeners to the list here. If you want to change
- * the content of this method, do NOT forget to change the "@generated" tag in the Javadoc of this method
- * to "@generated NOT". Without this new tag, any compilation of the Acceleo module with the main template
- * that has caused the creation of this class will revert your modifications.
- */
- return listeners;
- }
+ List<IAcceleoTextGenerationListener> listeners = super.getGenerationListeners();
+ /*
+ * TODO if you need to listen to generation event, add listeners to the list here. If you want to change
+ * the content of this method, do NOT forget to change the "@generated" tag in the Javadoc of this method
+ * to "@generated NOT". Without this new tag, any compilation of the Acceleo module with the main template
+ * that has caused the creation of this class will revert your modifications.
+ */
+ return listeners;
+ }
/**
* If you need to change the way files are generated, this is your entry point.
* <p>
- * The default is {@link org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy}; it generates files on the fly. If you only need to
- * preview the results, return a new {@link org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy}. Both of these aren't aware of the
- * running Eclipse and can be used standalone.
+ * The default is {@link org.eclipse.acceleo.engine.generation.strategy.DefaultStrategy}; it generates files on the fly. If you only need to preview the results, return a new {@link org.eclipse.acceleo.engine.generation.strategy.PreviewStrategy}. Both of
+ * these aren't aware of the running Eclipse and can be used standalone.
* </p>
* <p>
- * If you need the file generation to be aware of the workspace (A typical example is when you wanna override files that are under clear case or
- * any other VCS that could forbid the overriding), then return a new
- * {@link org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy}. <b>Note</b>, however, that this <b>cannot</b> be used
- * standalone.
+ * If you need the file generation to be aware of the workspace (A typical example is when you wanna override files that are under clear case or any other VCS that could forbid the overriding), then return a new
+ * {@link org.eclipse.acceleo.engine.generation.strategy.WorkspaceAwareStrategy}. <b>Note</b>, however, that this <b>cannot</b> be used standalone.
* </p>
* <p>
* All three of these default strategies support merging through JMerge.
* </p>
- *
+ *
* @return The generation strategy that is to be used for generations launched through this launcher.
* @generated
*/
@Override
public IAcceleoGenerationStrategy getGenerationStrategy() {
- return super.getGenerationStrategy();
- }
+ return super.getGenerationStrategy();
+ }
/**
* This will be called in order to find and load the module that will be launched through this launcher.
* We expect this name not to contain file extension, and the module to be located beside the launcher.
- *
+ *
* @return The name of the module that is to be launched.
* @generated
*/
@Override
public String getModuleName() {
- return MODULE_FILE_NAME;
- }
+ return MODULE_FILE_NAME;
+ }
/**
* If the module(s) called by this launcher require properties files, return their qualified path from
* here.Take note that the first added properties files will take precedence over subsequent ones if they
* contain conflicting keys.
- *
+ *
* @return The list of properties file we need to add to the generation context.
* @see java.util.ResourceBundle#getBundle(String)
* @generated
*/
@Override
public List<String> getProperties() {
- /*
- * If you want to change the content of this method, do NOT forget to change the "@generated"
- * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation
- * of the Acceleo module with the main template that has caused the creation of this class will
- * revert your modifications.
- */
-
- /*
- * TODO if your generation module requires access to properties files, add their qualified path to the list here.
- *
- * Properties files can be located in an Eclipse plug-in or in the file system (all Acceleo projects are Eclipse
- * plug-in). In order to use properties files located in an Eclipse plugin, you need to add the path of the properties
- * files to the "propertiesFiles" list:
- *
- * final String prefix = "platform:/plugin/";
- * final String pluginName = "org.eclipse.acceleo.module.sample";
- * final String packagePath = "/org/eclipse/acceleo/module/sample/properties/";
- * final String fileName = "default.properties";
- * propertiesFiles.add(prefix + pluginName + packagePath + fileName);
- *
- * With this mechanism, you can load properties files from your plugin or from another plugin.
- *
- * You may want to load properties files from the file system, for that you need to add the absolute path of the file:
- *
- * propertiesFiles.add("C:\Users\MyName\MyFile.properties");
- *
- * If you want to let your users add properties files located in the same folder as the model:
- *
- * if (EMFPlugin.IS_ECLIPSE_RUNNING && model != null && model.eResource() != null) {
- * propertiesFiles.addAll(AcceleoEngineUtils.getPropertiesFilesNearModel(model.eResource()));
- * }
- *
- * To learn more about Properties Files, have a look at the Acceleo documentation (Help -> Help Contents).
- */
- return propertiesFiles;
- }
+ /*
+ * If you want to change the content of this method, do NOT forget to change the "@generated"
+ * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation
+ * of the Acceleo module with the main template that has caused the creation of this class will
+ * revert your modifications.
+ */
+
+ /*
+ * TODO if your generation module requires access to properties files, add their qualified path to the list here.
+ *
+ * Properties files can be located in an Eclipse plug-in or in the file system (all Acceleo projects are Eclipse
+ * plug-in). In order to use properties files located in an Eclipse plugin, you need to add the path of the properties
+ * files to the "propertiesFiles" list:
+ *
+ * final String prefix = "platform:/plugin/";
+ * final String pluginName = "org.eclipse.acceleo.module.sample";
+ * final String packagePath = "/org/eclipse/acceleo/module/sample/properties/";
+ * final String fileName = "default.properties";
+ * propertiesFiles.add(prefix + pluginName + packagePath + fileName);
+ *
+ * With this mechanism, you can load properties files from your plugin or from another plugin.
+ *
+ * You may want to load properties files from the file system, for that you need to add the absolute path of the file:
+ *
+ * propertiesFiles.add("C:\Users\MyName\MyFile.properties");
+ *
+ * If you want to let your users add properties files located in the same folder as the model:
+ *
+ * if (EMFPlugin.IS_ECLIPSE_RUNNING && model != null && model.eResource() != null) {
+ * propertiesFiles.addAll(AcceleoEngineUtils.getPropertiesFilesNearModel(model.eResource()));
+ * }
+ *
+ * To learn more about Properties Files, have a look at the Acceleo documentation (Help -> Help Contents).
+ */
+ return propertiesFiles;
+ }
/**
* Adds a properties file in the list of properties files.
- *
+ *
* @param propertiesFile
- * The properties file to add.
+ * The properties file to add.
* @generated
* @since 3.1
*/
@Override
public void addPropertiesFile(String propertiesFile) {
- this.propertiesFiles.add(propertiesFile);
- }
+ this.propertiesFiles.add(propertiesFile);
+ }
/**
* This will be used to get the list of templates that are to be launched by this launcher.
- *
+ *
* @return The list of templates to call on the module {@link #getModuleName()}.
* @generated
*/
@Override
public String[] getTemplateNames() {
- return TEMPLATE_NAMES;
- }
+ return TEMPLATE_NAMES;
+ }
/**
* This can be used to update the resource set's package registry with all needed EPackages.
- *
+ *
* @param resourceSet
- * The resource set which registry has to be updated.
+ * The resource set which registry has to be updated.
* @generated
*/
@Override
public void registerPackages(ResourceSet resourceSet) {
- super.registerPackages(resourceSet);
- if (!isInWorkspace(org.eclipse.emf.ecore.EcorePackage.class)) {
- resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), org.eclipse.emf.ecore.EcorePackage.eINSTANCE);
- }
- if (!isInWorkspace(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.class)) {
- resourceSet.getPackageRegistry().put(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE.getNsURI(), org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE);
- }
-
- /*
- * If you want to change the content of this method, do NOT forget to change the "@generated"
- * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation
- * of the Acceleo module with the main template that has caused the creation of this class will
- * revert your modifications.
- */
-
- /*
- * If you need additional package registrations, you can register them here. The following line
- * (in comment) is an example of the package registration for UML.
- *
- * You can use the method "isInWorkspace(Class c)" to check if the package that you are about to
- * register is in the workspace.
- *
- * To register a package properly, please follow the following conventions:
- *
- * If the package is located in another plug-in, already installed in Eclipse. The following content should
- * have been generated at the beginning of this method. Do not register the package using this mechanism if
- * the metamodel is located in the workspace.
- *
- * if (!isInWorkspace(UMLPackage.class)) {
- * // The normal package registration if your metamodel is in a plugin.
- * resourceSet.getPackageRegistry().put(UMLPackage.eNS_URI, UMLPackage.eINSTANCE);
- * }
- *
- * If the package is located in another project in your workspace, the plugin containing the package has not
- * been register by EMF and Acceleo should register it automatically. If you want to use the generator in
- * stand alone, the regular registration (seen a couple lines before) is needed.
- *
- * To learn more about Package Registration, have a look at the Acceleo documentation (Help -> Help Contents).
- */
- }
+ super.registerPackages(resourceSet);
+ if (!isInWorkspace(org.eclipse.emf.ecore.EcorePackage.class)) {
+ resourceSet.getPackageRegistry().put(org.eclipse.emf.ecore.EcorePackage.eINSTANCE.getNsURI(), org.eclipse.emf.ecore.EcorePackage.eINSTANCE);
+ }
+ if (!isInWorkspace(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.class)) {
+ resourceSet.getPackageRegistry().put(org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE.getNsURI(), org.eclipse.emf.codegen.ecore.genmodel.GenModelPackage.eINSTANCE);
+ }
+
+ /*
+ * If you want to change the content of this method, do NOT forget to change the "@generated"
+ * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation
+ * of the Acceleo module with the main template that has caused the creation of this class will
+ * revert your modifications.
+ */
+
+ /*
+ * If you need additional package registrations, you can register them here. The following line
+ * (in comment) is an example of the package registration for UML.
+ *
+ * You can use the method "isInWorkspace(Class c)" to check if the package that you are about to
+ * register is in the workspace.
+ *
+ * To register a package properly, please follow the following conventions:
+ *
+ * If the package is located in another plug-in, already installed in Eclipse. The following content should
+ * have been generated at the beginning of this method. Do not register the package using this mechanism if
+ * the metamodel is located in the workspace.
+ *
+ * if (!isInWorkspace(UMLPackage.class)) {
+ * // The normal package registration if your metamodel is in a plugin.
+ * resourceSet.getPackageRegistry().put(UMLPackage.eNS_URI, UMLPackage.eINSTANCE);
+ * }
+ *
+ * If the package is located in another project in your workspace, the plugin containing the package has not
+ * been register by EMF and Acceleo should register it automatically. If you want to use the generator in
+ * stand alone, the regular registration (seen a couple lines before) is needed.
+ *
+ * To learn more about Package Registration, have a look at the Acceleo documentation (Help -> Help Contents).
+ */
+ }
/**
* This can be used to update the resource set's resource factory registry with all needed factories.
- *
+ *
* @param resourceSet
- * The resource set which registry has to be updated.
+ * The resource set which registry has to be updated.
* @generated
*/
@Override
public void registerResourceFactories(ResourceSet resourceSet) {
- super.registerResourceFactories(resourceSet);
- /*
- * If you want to change the content of this method, do NOT forget to change the "@generated"
- * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation
- * of the Acceleo module with the main template that has caused the creation of this class will
- * revert your modifications.
- */
-
- /*
- * TODO If you need additional resource factories registrations, you can register them here. the following line
- * (in comment) is an example of the resource factory registration for UML.
- *
- * If you want to use the generator in stand alone, the resource factory registration will be required.
- *
- * To learn more about the registration of Resource Factories, have a look at the Acceleo documentation (Help -> Help Contents).
- */
-
- // resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE);
- }
+ super.registerResourceFactories(resourceSet);
+ /*
+ * If you want to change the content of this method, do NOT forget to change the "@generated"
+ * tag in the Javadoc of this method to "@generated NOT". Without this new tag, any compilation
+ * of the Acceleo module with the main template that has caused the creation of this class will
+ * revert your modifications.
+ */
+
+ /*
+ * TODO If you need additional resource factories registrations, you can register them here. the following line
+ * (in comment) is an example of the resource factory registration for UML.
+ *
+ * If you want to use the generator in stand alone, the resource factory registration will be required.
+ *
+ * To learn more about the registration of Resource Factories, have a look at the Acceleo documentation (Help -> Help Contents).
+ */
+
+ // resourceSet.getResourceFactoryRegistry().getExtensionToFactoryMap().put(UMLResource.FILE_EXTENSION, UMLResource.Factory.INSTANCE);
+ }
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/FacadeCodeGenPlugin.java b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/FacadeCodeGenPlugin.java
index a7c88816fbd..ade081f1927 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/FacadeCodeGenPlugin.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/FacadeCodeGenPlugin.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -39,6 +39,7 @@ public class FacadeCodeGenPlugin extends AbstractUIPlugin {
*
* @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
*/
+ @Override
public void start(BundleContext context) throws Exception {
super.start(context);
plugin = this;
@@ -49,6 +50,7 @@ public class FacadeCodeGenPlugin extends AbstractUIPlugin {
*
* @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
*/
+ @Override
public void stop(BundleContext context) throws Exception {
plugin = null;
super.stop(context);
@@ -56,7 +58,7 @@ public class FacadeCodeGenPlugin extends AbstractUIPlugin {
/**
* Returns the shared instance
- *
+ *
* @return the shared instance
*/
public static FacadeCodeGenPlugin getDefault() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/Messages.java b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/Messages.java
index 00cafa5e7ec..5f284ad3ffc 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/Messages.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/Messages.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/handlers/GenerateFacadeHandler.java b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/handlers/GenerateFacadeHandler.java
index a32042d416e..a878d1d3139 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/handlers/GenerateFacadeHandler.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/handlers/GenerateFacadeHandler.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -38,8 +38,6 @@ import org.eclipse.emf.codegen.ecore.genmodel.GenModel;
import org.eclipse.emf.codegen.ecore.genmodel.generator.GenBaseGeneratorAdapter;
import org.eclipse.emf.common.util.BasicMonitor;
import org.eclipse.emf.common.util.UniqueEList;
-import org.eclipse.emf.eef.codegen.flow.Step;
-import org.eclipse.emf.eef.codegen.flow.Workflow;
import org.eclipse.jface.viewers.IStructuredSelection;
import org.eclipse.papyrus.facade.codegen.FacadeCodeGenPlugin;
import org.eclipse.papyrus.facade.codegen.Messages;
@@ -62,7 +60,7 @@ public class GenerateFacadeHandler extends AbstractHandler {
/**
* @see org.eclipse.core.commands.AbstractHandler#execute(org.eclipse.core.commands.ExecutionEvent)
- *
+ *
* @param event
* @return
* @throws ExecutionException
@@ -77,17 +75,17 @@ public class GenerateFacadeHandler extends AbstractHandler {
// set selection service
ISelectionService service = window.getSelectionService();
// set structured selection
- IStructuredSelection structured = (IStructuredSelection)service.getSelection();
+ IStructuredSelection structured = (IStructuredSelection) service.getSelection();
- if(structured != null) {
- for(Object selectedElement : structured.toList()) {
- if(selectedElement instanceof GenModel) {
- emfGenModels.add((GenModel)selectedElement);
+ if (structured != null) {
+ for (Object selectedElement : structured.toList()) {
+ if (selectedElement instanceof GenModel) {
+ emfGenModels.add((GenModel) selectedElement);
}
}
}
- if(emfGenModels != null) {
+ if (emfGenModels != null) {
final Workflow flow = initEMFGenFlow(emfGenModels);
flow.prepare();
Job job = new Job(Messages.GenerateCodeAction_0) {
@@ -109,51 +107,52 @@ public class GenerateFacadeHandler extends AbstractHandler {
/**
* Inits the emf gen flow.
- *
+ *
* @param emfGenModels
- * the emf Genmodels to generate the facade for
+ * the emf Genmodels to generate the facade for
* @return the workflow
*/
protected Workflow initEMFGenFlow(List<GenModel> emfGenModels) {
final Workflow flow = new Workflow(Messages.GenerateFacadeAction_0, Display.getCurrent().getActiveShell());
- for(final org.eclipse.emf.codegen.ecore.genmodel.GenModel emfGenModel : emfGenModels) {
+ for (final org.eclipse.emf.codegen.ecore.genmodel.GenModel emfGenModel : emfGenModels) {
String s2 = Messages.GenerateFacadeAction_1 + emfGenModel.eResource().getURI().toString();
flow.addStep(s2, new Step("FACADE MODEL") { //$NON-NLS-1$
- @Override
- public IStatus execute(IProgressMonitor monitor) {
- // create the model project
- IProject modelProject = getProjectFromStringPath(emfGenModel.getModelProjectDirectory());
- if(modelProject == null) {
- return Status.OK_STATUS;
- }
- List<IProject> referencedProjects = new UniqueEList<IProject>();
- if(!workspace.getRoot().exists(modelProject.getFullPath())) {
- if(modelProject.getLocation().toFile().exists()) {
- modelProject.getLocation().toFile().delete();
+ @Override
+ public IStatus execute(IProgressMonitor monitor) {
+ // create the model project
+ IProject modelProject = getProjectFromStringPath(emfGenModel.getModelProjectDirectory());
+ if (modelProject == null) {
+ return Status.OK_STATUS;
+ }
+ List<IProject> referencedProjects = new UniqueEList<IProject>();
+ if (!workspace.getRoot().exists(modelProject.getFullPath())) {
+ if (modelProject.getLocation().toFile().exists()) {
+ modelProject.getLocation().toFile().delete();
+ }
+ modelProject = Generator.createEMFProject(new Path(emfGenModel.getModelDirectory()), modelProject.getLocation(), referencedProjects, new SubProgressMonitor(monitor, IProgressMonitor.UNKNOWN), Generator.EMF_MODEL_PROJECT_STYLE
+ | Generator.EMF_PLUGIN_PROJECT_STYLE);
+ } else if (!modelProject.isAccessible()) {
+ try {
+ modelProject.open(monitor);
+ } catch (CoreException e) {
+ return new Status(IStatus.ERROR, FacadeCodeGenPlugin.PLUGIN_ID, e.getMessage(), e);
+ }
+ }
+ // generate using acceleo
+ List<String> args = new ArrayList<String>();
+ File modelDirectory = modelProject.getLocation().toFile();
+ try {
+ GenFacade generator = new GenFacade(emfGenModel, modelDirectory, args);
+ generator.doGenerate(BasicMonitor.toMonitor(new SubProgressMonitor(monitor, IProgressMonitor.UNKNOWN)));
+ } catch (IOException e) {
+ return new Status(IStatus.ERROR, FacadeCodeGenPlugin.PLUGIN_ID, e.getMessage(), e);
+ }
+ return Status.OK_STATUS;
}
- modelProject = Generator.createEMFProject(new Path(emfGenModel.getModelDirectory()), modelProject.getLocation(), referencedProjects, new SubProgressMonitor(monitor, IProgressMonitor.UNKNOWN), Generator.EMF_MODEL_PROJECT_STYLE | Generator.EMF_PLUGIN_PROJECT_STYLE);
- } else if(!modelProject.isAccessible()) {
- try {
- modelProject.open(monitor);
- } catch (CoreException e) {
- return new Status(IStatus.ERROR, FacadeCodeGenPlugin.PLUGIN_ID, e.getMessage(), e);
- }
- }
- // generate using acceleo
- List<String> args = new ArrayList<String>();
- File modelDirectory = modelProject.getLocation().toFile();
- try {
- GenFacade generator = new GenFacade(emfGenModel, modelDirectory, args);
- generator.doGenerate(BasicMonitor.toMonitor(new SubProgressMonitor(monitor, IProgressMonitor.UNKNOWN)));
- } catch (IOException e) {
- return new Status(IStatus.ERROR, FacadeCodeGenPlugin.PLUGIN_ID, e.getMessage(), e);
- }
- return Status.OK_STATUS;
- }
- });
+ });
- if(emfGenModel.isCodeFormatting()) {
+ if (emfGenModel.isCodeFormatting()) {
refresh(emfGenModel, flow);
String s2prime = Messages.GenerateFacadeAction_5;
@@ -175,34 +174,34 @@ public class GenerateFacadeHandler extends AbstractHandler {
/**
* Refresh.
- *
+ *
* @param emfGenModel
- * the emf GenModel that is used to generate facade code for
+ * the emf GenModel that is used to generate facade code for
* @param flow
- * the flow
+ * the flow
*/
protected void refresh(final org.eclipse.emf.codegen.ecore.genmodel.GenModel emfGenModel, Workflow flow) {
String s3 = Messages.GenerateFacadeAction_6 + emfGenModel.eResource().getURI().toString();
flow.addStep(s3, new Step("REFRESH") { //$NON-NLS-1$
- @Override
- public IStatus execute(IProgressMonitor monitor) {
- // refresh model project
- IProject modelProject = getProjectFromStringPath(emfGenModel.getModelProjectDirectory());
- if(modelProject == null) {
- return Status.OK_STATUS;
- }
- try {
- if(!modelProject.isOpen()) {
- modelProject.open(monitor);
+ @Override
+ public IStatus execute(IProgressMonitor monitor) {
+ // refresh model project
+ IProject modelProject = getProjectFromStringPath(emfGenModel.getModelProjectDirectory());
+ if (modelProject == null) {
+ return Status.OK_STATUS;
+ }
+ try {
+ if (!modelProject.isOpen()) {
+ modelProject.open(monitor);
+ }
+ modelProject.refreshLocal(IResource.DEPTH_INFINITE, monitor);
+ } catch (CoreException e) {
+ return new Status(IStatus.ERROR, FacadeCodeGenPlugin.PLUGIN_ID, e.getMessage(), e);
+ }
+ return Status.OK_STATUS;
}
- modelProject.refreshLocal(IResource.DEPTH_INFINITE, monitor);
- } catch (CoreException e) {
- return new Status(IStatus.ERROR, FacadeCodeGenPlugin.PLUGIN_ID, e.getMessage(), e);
- }
- return Status.OK_STATUS;
- }
- });
+ });
}
@@ -211,14 +210,14 @@ public class GenerateFacadeHandler extends AbstractHandler {
/**
* Extract project.
- *
+ *
* @param stringPath
- * the path to the project encoded as a string
+ * the path to the project encoded as a string
* @return the corresponding project
*/
protected IProject getProjectFromStringPath(String stringPath) {
IPath path = new Path(stringPath);
- if(path.isEmpty()) {
+ if (path.isEmpty()) {
return null;
}
return workspace.getRoot().getProject(path.segment(0));
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/EEFGeneratorAdapter.java b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/EEFGeneratorAdapter.java
index f6ab31310f5..046eb1b24a7 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/EEFGeneratorAdapter.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/EEFGeneratorAdapter.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -43,7 +43,7 @@ public class EEFGeneratorAdapter extends AbstractGeneratorAdapter {
/**
* {@inheritDoc}
- *
+ *
* @see org.eclipse.emf.codegen.ecore.generator.AbstractGeneratorAdapter#canGenerate(java.lang.Object, java.lang.Object)
*/
@Override
@@ -53,31 +53,30 @@ public class EEFGeneratorAdapter extends AbstractGeneratorAdapter {
/**
* {@inheritDoc}
- *
- * @see org.eclipse.emf.codegen.ecore.generator.AbstractGeneratorAdapter#doGenerate(java.lang.Object, java.lang.Object,
- * org.eclipse.emf.common.util.Monitor)
+ *
+ * @see org.eclipse.emf.codegen.ecore.generator.AbstractGeneratorAdapter#doGenerate(java.lang.Object, java.lang.Object, org.eclipse.emf.common.util.Monitor)
*/
@Override
protected Diagnostic doGenerate(Object object, Object projectType, Monitor monitor) throws Exception {
- GenModel genmodel = (GenModel)object;
+ GenModel genmodel = (GenModel) object;
IFolder folder = null;
final IProgressMonitor progressMonitor = BasicMonitor.toIProgressMonitor(monitor);
- if(projectType == GenBaseGeneratorAdapter.MODEL_PROJECT_TYPE) {
+ if (projectType == GenBaseGeneratorAdapter.MODEL_PROJECT_TYPE) {
final Object codeFormatter = createCodeFormatter(null, URI.createPlatformResourceURI(genmodel.getModelDirectory(), true));
folder = ResourcesPlugin.getWorkspace().getRoot().getFolder(new Path(genmodel.getModelDirectory())); // path);
- if(folder != null && folder.isAccessible()) {
+ if (folder != null && folder.isAccessible()) {
folder.accept(new ResourceVisitorFormatter(codeFormatter, progressMonitor));
}
- } else if(projectType == GenBaseGeneratorAdapter.EDIT_PROJECT_TYPE) {
+ } else if (projectType == GenBaseGeneratorAdapter.EDIT_PROJECT_TYPE) {
final Object codeFormatter = createCodeFormatter(null, URI.createPlatformResourceURI(genmodel.getEditDirectory(), true));
folder = ResourcesPlugin.getWorkspace().getRoot().getFolder(new Path(genmodel.getEditDirectory()));
- if(folder != null && folder.isAccessible()) {
+ if (folder != null && folder.isAccessible()) {
folder.accept(new ResourceVisitorFormatter(codeFormatter, progressMonitor));
}
- } else if(projectType == GenBaseGeneratorAdapter.EDITOR_PROJECT_TYPE) {
+ } else if (projectType == GenBaseGeneratorAdapter.EDITOR_PROJECT_TYPE) {
final Object codeFormatter = createCodeFormatter(null, URI.createPlatformResourceURI(genmodel.getEditorDirectory(), true));
folder = ResourcesPlugin.getWorkspace().getRoot().getFolder(new Path(genmodel.getEditorDirectory()));
- if(folder != null && folder.isAccessible()) {
+ if (folder != null && folder.isAccessible()) {
folder.accept(new ResourceVisitorFormatter(codeFormatter, progressMonitor));
}
}
@@ -102,7 +101,7 @@ public class EEFGeneratorAdapter extends AbstractGeneratorAdapter {
*/
protected IPath buildProviderPath(GenModel genmodel, GenPackage genPack) {
String pathStr = genmodel.getEditDirectory();
- if(genPack.getProviderPackageName() != null && !genPack.getProviderPackageName().equals("")) { //$NON-NLS-1$
+ if (genPack.getProviderPackageName() != null && !genPack.getProviderPackageName().equals("")) { //$NON-NLS-1$
pathStr += "/" + genPack.getProviderPackageName().replaceAll("\\.", "/"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
IPath path = new Path(pathStr);
@@ -116,7 +115,7 @@ public class EEFGeneratorAdapter extends AbstractGeneratorAdapter {
*/
protected IPath buildPresentationPath(GenModel genmodel, GenPackage genPack) {
String pathStr = genmodel.getEditorDirectory();
- if(genPack.getPresentationPackageName() != null && !genPack.getPresentationPackageName().equals("")) { //$NON-NLS-1$
+ if (genPack.getPresentationPackageName() != null && !genPack.getPresentationPackageName().equals("")) { //$NON-NLS-1$
pathStr += "/" + genPack.getPresentationPackageName().replaceAll("\\.", "/"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
}
IPath path = new Path(pathStr);
@@ -125,7 +124,7 @@ public class EEFGeneratorAdapter extends AbstractGeneratorAdapter {
/**
* IResourceVisitor responsible to format all java code in a given folder.
- *
+ *
* @author <a href="mailto:goulwen.lefur@obeo.fr">Goulwen Le Fur</a>
*/
private final class ResourceVisitorFormatter implements IResourceVisitor {
@@ -139,12 +138,13 @@ public class EEFGeneratorAdapter extends AbstractGeneratorAdapter {
this.progressMonitor = progressMonitor;
}
+ @Override
public boolean visit(IResource resource) throws CoreException {
try {
- String fileExtension = ((IFile)resource).getFileExtension();
- if(fileExtension != null) {
- if(resource instanceof IFile && fileExtension.equals(JAVA_EXT_FILE)) {
- formatFile((IFile)resource, codeFormatter, progressMonitor);
+ String fileExtension = ((IFile) resource).getFileExtension();
+ if (fileExtension != null) {
+ if (resource instanceof IFile && fileExtension.equals(JAVA_EXT_FILE)) {
+ formatFile((IFile) resource, codeFormatter, progressMonitor);
}
}
return true;
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/FacadeCodegenUtils.java b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/FacadeCodegenUtils.java
index 72be502d4b3..3acacefc448 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/FacadeCodegenUtils.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/FacadeCodegenUtils.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -101,14 +101,14 @@ public class FacadeCodegenUtils {
/**
* Find the mapping model from a genModel. Basically, the mapping model must be in the same folder as the ecoremodel underlying the GenModel and
* named with the same filename but the file extension.
- *
+ *
* @param genModel
- * the GenModel that will be used to try to find the mapping model
+ * the GenModel that will be used to try to find the mapping model
* @return the string
*/
public static String findMappingModel(GenModel genModel) {
- if(!genModel.getForeignModel().isEmpty()) {
+ if (!genModel.getForeignModel().isEmpty()) {
String metamodel = genModel.getForeignModel().get(0);
metamodel = metamodel.replaceAll(".ecore", ".facademapping"); //$NON-NLS-1$ //$NON-NLS-2$
@@ -124,17 +124,17 @@ public class FacadeCodegenUtils {
/**
* Gets the UML element of a mapping.
- *
+ *
* @param mapping
- * the mapping to find the UML element for
+ * the mapping to find the UML element for
* @return the UML element mapped in the mapping
*/
protected static EObject getUMLElement(Mapping mapping) {
- if(mapping instanceof StereotypedMapping) {
- if(((StereotypedMapping)mapping).getKind() == ExtensionDefinitionKind.ASSOCIATION) {
- EList<EObject> appliedStereotypes = ((StereotypedMapping)mapping).getAppliedStereotypes();
- if(appliedStereotypes.size() != 1) {
+ if (mapping instanceof StereotypedMapping) {
+ if (((StereotypedMapping) mapping).getKind() == ExtensionDefinitionKind.ASSOCIATION) {
+ EList<EObject> appliedStereotypes = ((StereotypedMapping) mapping).getAppliedStereotypes();
+ if (appliedStereotypes.size() != 1) {
return null;
} else {
return appliedStereotypes.get(0);
@@ -150,31 +150,31 @@ public class FacadeCodegenUtils {
/**
* Gets the all the mappings based on a GenModel of a facade
- *
+ *
* @param facadeGenModel
- * the GenModel of a facade
+ * the GenModel of a facade
* @return all the mappings corresponding to a facade GenModel
*/
protected static synchronized List<Mapping> getAllMappings(GenModel facadeGenModel) {
- if(!allMappingsCache.containsKey(facadeGenModel)) {
+ if (!allMappingsCache.containsKey(facadeGenModel)) {
List<Mapping> allMappings = new ArrayList<Mapping>();
String mappingModel = findMappingModel(facadeGenModel);
- if(mappingModel != null) {
- if(facadeGenModel.eResource() != null) {
- if(facadeGenModel.eResource().getResourceSet() != null) {
+ if (mappingModel != null) {
+ if (facadeGenModel.eResource() != null) {
+ if (facadeGenModel.eResource().getResourceSet() != null) {
ResourceSet resourceSet = facadeGenModel.eResource().getResourceSet();
Resource res = resourceSet.getResource(URI.createURI(mappingModel, true), true);
- if(res != null) {
- if(!res.getContents().isEmpty()) {
+ if (res != null) {
+ if (!res.getContents().isEmpty()) {
EObject root = res.getContents().get(0);
- if(root instanceof FacadeMappping) {
- FacadeMappping facadeMappping = (FacadeMappping)root;
+ if (root instanceof FacadeMappping) {
+ FacadeMappping facadeMappping = (FacadeMappping) root;
- for(Mapping mapping : facadeMappping.getMappings()) {
+ for (Mapping mapping : facadeMappping.getMappings()) {
allMappings.add(mapping);
}
}
@@ -193,11 +193,11 @@ public class FacadeCodegenUtils {
/**
* Get the stereotype qualifiedNames that are applied on the UML element represented by the facadeMetaElement
- *
+ *
* @param facadeMetaElement
- * the facade metaelement
+ * the facade metaelement
* @param facadeGenModel
- * the facade GenModel
+ * the facade GenModel
* @return the stereotype qualifiedNames
*/
public static String getAllStereotypeQualifiedNames(EObject facadeMetaElement, GenModel facadeGenModel) {
@@ -205,27 +205,27 @@ public class FacadeCodegenUtils {
Set<String> result = new HashSet<String>();
- for(Mapping mapping : getAllMappings(facadeGenModel)) {
- if(EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
- if(mapping instanceof StereotypedMapping) {
+ for (Mapping mapping : getAllMappings(facadeGenModel)) {
+ if (EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
+ if (mapping instanceof StereotypedMapping) {
- for(EObject stereotype : ((StereotypedMapping)mapping).getAppliedStereotypes()) {
- if(stereotype instanceof Stereotype) {
- result.add("\"" + ((Stereotype)stereotype).getQualifiedName() + "\""); //$NON-NLS-1$ //$NON-NLS-2$
+ for (EObject stereotype : ((StereotypedMapping) mapping).getAppliedStereotypes()) {
+ if (stereotype instanceof Stereotype) {
+ result.add("\"" + ((Stereotype) stereotype).getQualifiedName() + "\""); //$NON-NLS-1$ //$NON-NLS-2$
}
}
}
}
}
- if(!result.isEmpty()) {
+ if (!result.isEmpty()) {
StringBuilder sb = new StringBuilder();
- for(String s : result) {
+ for (String s : result) {
sb.append(s).append(',');
}
- sb.deleteCharAt(sb.length() - 1); //delete last comma
+ sb.deleteCharAt(sb.length() - 1); // delete last comma
return sb.toString();
}
@@ -236,11 +236,11 @@ public class FacadeCodegenUtils {
/**
* Get the stereotype qualifiedNames that are applied on the UML element represented by the facadeMetaElement but that are not association kind of
* mapping
- *
+ *
* @param facadeMetaElement
- * the facade metaelement
+ * the facade metaelement
* @param facadeGenModel
- * the facade GenModel
+ * the facade GenModel
* @return the stereotype qualifiedNames
*/
public static String getNonAssociationStereotypeQualifiedNames(EObject facadeMetaElement, GenModel facadeGenModel) {
@@ -248,14 +248,14 @@ public class FacadeCodegenUtils {
Set<String> result = new HashSet<String>();
- for(Mapping mapping : getAllMappings(facadeGenModel)) {
- if(EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
- if(mapping instanceof StereotypedMapping) {
+ for (Mapping mapping : getAllMappings(facadeGenModel)) {
+ if (EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
+ if (mapping instanceof StereotypedMapping) {
- if(((StereotypedMapping)mapping).getKind() != ExtensionDefinitionKind.ASSOCIATION) {
- for(EObject stereotype : ((StereotypedMapping)mapping).getAppliedStereotypes()) {
- if(stereotype instanceof Stereotype) {
- result.add("\"" + ((Stereotype)stereotype).getQualifiedName() + "\""); //$NON-NLS-1$ //$NON-NLS-2$
+ if (((StereotypedMapping) mapping).getKind() != ExtensionDefinitionKind.ASSOCIATION) {
+ for (EObject stereotype : ((StereotypedMapping) mapping).getAppliedStereotypes()) {
+ if (stereotype instanceof Stereotype) {
+ result.add("\"" + ((Stereotype) stereotype).getQualifiedName() + "\""); //$NON-NLS-1$ //$NON-NLS-2$
}
}
}
@@ -263,14 +263,14 @@ public class FacadeCodegenUtils {
}
}
- if(!result.isEmpty()) {
+ if (!result.isEmpty()) {
StringBuilder sb = new StringBuilder();
- for(String s : result) {
+ for (String s : result) {
sb.append(s).append(',');
}
- sb.deleteCharAt(sb.length() - 1); //delete last comma
+ sb.deleteCharAt(sb.length() - 1); // delete last comma
return sb.toString();
}
@@ -280,42 +280,42 @@ public class FacadeCodegenUtils {
/**
* Find UML getAccessor.
- *
+ *
* @param facadeMetaFeature
- * the facade metafeature
+ * the facade metafeature
* @param facadeGenModel
- * the facade GenModel
+ * the facade GenModel
* @return the getAccessor
*/
public static String findUMLGetAccessor(EObject facadeMetaFeature, GenModel facadeGenModel) {
EObject umlMetaElement = findUMLMetaElement(facadeMetaFeature, facadeGenModel);
- if(umlMetaElement != null) {
- if(umlMetaElement instanceof ETypedElement) {
+ if (umlMetaElement != null) {
+ if (umlMetaElement instanceof ETypedElement) {
ResourceSet resourceSet = new ResourceSetImpl();
EObject umlGenModel = resourceSet.getResource(URI.createURI(UML_GEN_MODEL, true), true).getContents().get(0);
- if(umlGenModel != null) {
- if(umlGenModel instanceof org.eclipse.uml2.codegen.ecore.genmodel.GenModel) {
+ if (umlGenModel != null) {
+ if (umlGenModel instanceof org.eclipse.uml2.codegen.ecore.genmodel.GenModel) {
- if(umlMetaElement instanceof EStructuralFeature) {
- return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel)umlGenModel).findGenFeature((EStructuralFeature)umlMetaElement).getGetAccessor();
- } else if(umlMetaElement instanceof EOperation) {
- return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel)umlGenModel).findGenOperation((EOperation)umlMetaElement).getName();
+ if (umlMetaElement instanceof EStructuralFeature) {
+ return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel) umlGenModel).findGenFeature((EStructuralFeature) umlMetaElement).getGetAccessor();
+ } else if (umlMetaElement instanceof EOperation) {
+ return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel) umlGenModel).findGenOperation((EOperation) umlMetaElement).getName();
}
}
}
- } else if(umlMetaElement instanceof Property) {
- if(umlMetaElement.eResource() != null) {
- if(!umlMetaElement.eResource().getContents().isEmpty()) {
+ } else if (umlMetaElement instanceof Property) {
+ if (umlMetaElement.eResource() != null) {
+ if (!umlMetaElement.eResource().getContents().isEmpty()) {
EObject root = umlMetaElement.eResource().getContents().get(0);
- if(root instanceof Profile) {
+ if (root instanceof Profile) {
GenModel profileGen = getGenModel(umlMetaElement);
- EObject umlMetaFeatureDefinition = ((Profile)root).getDefinition((NamedElement)umlMetaElement);
- if(umlMetaFeatureDefinition instanceof EStructuralFeature) {
- return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel)profileGen).findGenFeature((EStructuralFeature)umlMetaFeatureDefinition).getGetAccessor();
+ EObject umlMetaFeatureDefinition = ((Profile) root).getDefinition((NamedElement) umlMetaElement);
+ if (umlMetaFeatureDefinition instanceof EStructuralFeature) {
+ return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel) profileGen).findGenFeature((EStructuralFeature) umlMetaFeatureDefinition).getGetAccessor();
}
}
}
@@ -328,9 +328,9 @@ public class FacadeCodegenUtils {
/**
* Try to get the GenModel from an eObject
- *
+ *
* @param metaElement
- * the metaElement to find the GenMdoel for
+ * the metaElement to find the GenMdoel for
* @return the GenModel
*/
protected static GenModel getGenModel(EObject metaElement) {
@@ -338,22 +338,22 @@ public class FacadeCodegenUtils {
- if(metaElement.eResource() != null) {
- if(!metaElement.eResource().getContents().isEmpty()) {
+ if (metaElement.eResource() != null) {
+ if (!metaElement.eResource().getContents().isEmpty()) {
EObject root = metaElement.eResource().getContents().get(0);
- if(root instanceof Profile) {
- Stereotype ePackageStereotype = ((Profile)root).getAppliedStereotype("Ecore::EPackage"); //$NON-NLS-1$
- if(ePackageStereotype != null) {
- Object nsURI = ((Profile)root).getValue(ePackageStereotype, "nsURI"); //$NON-NLS-1$
- if(nsURI instanceof String) {
+ if (root instanceof Profile) {
+ Stereotype ePackageStereotype = ((Profile) root).getAppliedStereotype("Ecore::EPackage"); //$NON-NLS-1$
+ if (ePackageStereotype != null) {
+ Object nsURI = ((Profile) root).getValue(ePackageStereotype, "nsURI"); //$NON-NLS-1$
+ if (nsURI instanceof String) {
URI genModelURI = nsURIToGenModelsMap.get(nsURI);
String paltformstring = genModelURI.toPlatformString(true);
URI pluginURI = URI.createPlatformPluginURI(paltformstring, true);
- if(pluginURI != null) {
+ if (pluginURI != null) {
ResourceSet resourceSet = new ResourceSetImpl();
EObject genModel = resourceSet.getResource(pluginURI, true).getContents().get(0);
- if(genModel instanceof GenModel) {
- return (GenModel)genModel;
+ if (genModel instanceof GenModel) {
+ return (GenModel) genModel;
}
}
}
@@ -368,27 +368,27 @@ public class FacadeCodegenUtils {
/**
* Find UML accessorName of a facade metaFeature.
- *
+ *
* @param facadeMetaFeature
- * the facade metafeature
+ * the facade metafeature
* @param facadeGenModel
- * the facade GenModel
+ * the facade GenModel
* @return the string
*/
public static String findUMLAccessorName(EObject facadeMetaFeature, GenModel facadeGenModel) {
EObject umlMetaFeature = findUMLMetaElement(facadeMetaFeature, facadeGenModel);
- if(umlMetaFeature instanceof NamedElement) {
+ if (umlMetaFeature instanceof NamedElement) {
- if(umlMetaFeature.eResource() != null) {
- if(!umlMetaFeature.eResource().getContents().isEmpty()) {
+ if (umlMetaFeature.eResource() != null) {
+ if (!umlMetaFeature.eResource().getContents().isEmpty()) {
EObject root = umlMetaFeature.eResource().getContents().get(0);
- if(root instanceof Profile) {
+ if (root instanceof Profile) {
GenModel profileGen = getGenModel(umlMetaFeature);
- EObject umlMetaFeatureDefinition = ((Profile)root).getDefinition((NamedElement)umlMetaFeature);
- if(umlMetaFeatureDefinition instanceof EStructuralFeature) {
- return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel)profileGen).findGenFeature((EStructuralFeature)umlMetaFeatureDefinition).getAccessorName();
+ EObject umlMetaFeatureDefinition = ((Profile) root).getDefinition((NamedElement) umlMetaFeature);
+ if (umlMetaFeatureDefinition instanceof EStructuralFeature) {
+ return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel) profileGen).findGenFeature((EStructuralFeature) umlMetaFeatureDefinition).getAccessorName();
}
}
@@ -396,15 +396,15 @@ public class FacadeCodegenUtils {
}
} else {
- if(umlMetaFeature != null) {
- if(umlMetaFeature instanceof EStructuralFeature) {
+ if (umlMetaFeature != null) {
+ if (umlMetaFeature instanceof EStructuralFeature) {
ResourceSet resourceSet = new ResourceSetImpl();
EObject umlGenModel = resourceSet.getResource(URI.createURI(UML_GEN_MODEL, true), true).getContents().get(0);
- if(umlGenModel != null) {
- if(umlGenModel instanceof org.eclipse.uml2.codegen.ecore.genmodel.GenModel) {
+ if (umlGenModel != null) {
+ if (umlGenModel instanceof org.eclipse.uml2.codegen.ecore.genmodel.GenModel) {
- return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel)umlGenModel).findGenFeature((EStructuralFeature)umlMetaFeature).getAccessorName();
+ return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel) umlGenModel).findGenFeature((EStructuralFeature) umlMetaFeature).getAccessorName();
}
}
}
@@ -416,24 +416,25 @@ public class FacadeCodegenUtils {
/**
* Gets all the metaclass mappings.
- *
+ *
* @param facadeGenModel
- * the facade GenModel
+ * the facade GenModel
* @return all mappings that map a metaclass
*/
public static synchronized List<? extends Mapping> getAllMetaclassMappings(GenModel facadeGenModel) {
- if(!allMetaclassMappingsCache.containsKey(facadeGenModel)) {
+ if (!allMetaclassMappingsCache.containsKey(facadeGenModel)) {
List<Mapping> allMetaclassMappings = new ArrayList<Mapping>();
- for(Mapping mapping : getAllMappings(facadeGenModel)) {
- if(!(mapping instanceof StereotypedMapping)) {
- if(mapping.getSpecificDomainElement() instanceof EClassifier) {
- if(mapping.getUmlElement() != TypesPackage.eINSTANCE.getBoolean() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getString() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getReal() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getInteger() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getUnlimitedNatural()) {
- if(!(mapping.getUmlElement() instanceof Stereotype)) {
- if(mapping.getSpecificDomainElement() instanceof EClass) {
- if(!((EClass)mapping.getSpecificDomainElement()).isAbstract()) {
+ for (Mapping mapping : getAllMappings(facadeGenModel)) {
+ if (!(mapping instanceof StereotypedMapping)) {
+ if (mapping.getSpecificDomainElement() instanceof EClassifier) {
+ if (mapping.getUmlElement() != TypesPackage.eINSTANCE.getBoolean() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getString() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getReal()
+ && mapping.getUmlElement() != TypesPackage.eINSTANCE.getInteger() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getUnlimitedNatural()) {
+ if (!(mapping.getUmlElement() instanceof Stereotype)) {
+ if (mapping.getSpecificDomainElement() instanceof EClass) {
+ if (!((EClass) mapping.getSpecificDomainElement()).isAbstract()) {
allMetaclassMappings.add(mapping);
}
} else {
@@ -443,7 +444,7 @@ public class FacadeCodegenUtils {
}
}
} else {
- if(((StereotypedMapping)mapping).getKind() == ExtensionDefinitionKind.ASSOCIATION) {
+ if (((StereotypedMapping) mapping).getKind() == ExtensionDefinitionKind.ASSOCIATION) {
allMetaclassMappings.add(mapping);
}
}
@@ -468,20 +469,21 @@ public class FacadeCodegenUtils {
/**
* Gets all the enumLiteral mappings.
- *
+ *
* @param facadeGenModel
- * the facade GenModel
+ * the facade GenModel
* @return all mappings that map an enumLiteral
*/
public static synchronized List<? extends Mapping> getAllEnumLiteralMappings(GenModel facadeGenModel) {
- if(!enumLiteralMappingsCache.containsKey(facadeGenModel)) {
+ if (!enumLiteralMappingsCache.containsKey(facadeGenModel)) {
List<Mapping> enumLiteralMappings = new ArrayList<Mapping>();
- synchronized(enumLiteralMappings) {
+ synchronized (enumLiteralMappings) {
- for(Mapping mapping : getAllMappings(facadeGenModel)) {
- if(mapping.getSpecificDomainElement() instanceof EEnumLiteral) {
- if(mapping.getUmlElement() != TypesPackage.eINSTANCE.getBoolean() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getString() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getReal() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getInteger() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getUnlimitedNatural()) {
+ for (Mapping mapping : getAllMappings(facadeGenModel)) {
+ if (mapping.getSpecificDomainElement() instanceof EEnumLiteral) {
+ if (mapping.getUmlElement() != TypesPackage.eINSTANCE.getBoolean() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getString() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getReal()
+ && mapping.getUmlElement() != TypesPackage.eINSTANCE.getInteger() && mapping.getUmlElement() != TypesPackage.eINSTANCE.getUnlimitedNatural()) {
enumLiteralMappings.add(mapping);
}
}
@@ -495,26 +497,26 @@ public class FacadeCodegenUtils {
/**
* Gets all the feature mappings.
- *
+ *
* @param facadeGenModel
- * the facade GenModel
+ * the facade GenModel
* @return all mappings that map a feature
*/
public static synchronized List<? extends Mapping> getAllFeatureMappings(GenModel facadeGenModel) {
- if(!featureMappingsCache.containsKey(facadeGenModel)) {
+ if (!featureMappingsCache.containsKey(facadeGenModel)) {
List<Mapping> featureMappings = new ArrayList<Mapping>();
- for(Mapping mapping : getAllMappings(facadeGenModel)) {
- if(!isExtensionStereotypePropertyFromFacade(mapping.getSpecificDomainElement(), facadeGenModel)) {
- if(mapping.getSpecificDomainElement() instanceof EStructuralFeature) {
+ for (Mapping mapping : getAllMappings(facadeGenModel)) {
+ if (!isExtensionStereotypePropertyFromFacade(mapping.getSpecificDomainElement(), facadeGenModel)) {
+ if (mapping.getSpecificDomainElement() instanceof EStructuralFeature) {
featureMappings.add(mapping);
}
- if(mapping.getSpecificDomainElement() instanceof Property) {
+ if (mapping.getSpecificDomainElement() instanceof Property) {
- if(((Property)mapping.getSpecificDomainElement()).getClass_() instanceof Stereotype) {
+ if (((Property) mapping.getSpecificDomainElement()).getClass_() instanceof Stereotype) {
featureMappings.add(mapping);
}
}
@@ -529,27 +531,27 @@ public class FacadeCodegenUtils {
/**
* Find UML metaElement.
- *
+ *
* @param facadeMetaElement
- * the facade metaElement
+ * the facade metaElement
* @param genModel
- * the GenModel
+ * the GenModel
* @return the UML metaElement
*/
public static EObject findUMLMetaElement(EObject facadeMetaElement, GenModel genModel) {
String mappingModel = findMappingModel(genModel);
- if(mappingModel != null) {
+ if (mappingModel != null) {
- if(genModel.eResource() != null) {
- if(genModel.eResource().getResourceSet() != null) {
+ if (genModel.eResource() != null) {
+ if (genModel.eResource().getResourceSet() != null) {
ResourceSet resourceSet = genModel.eResource().getResourceSet();
EObject root = resourceSet.getResource(URI.createURI(mappingModel, true), true).getContents().get(0);
- if(root != null) {
- if(root instanceof FacadeMappping) {
- FacadeMappping facadeMappping = (FacadeMappping)root;
- for(Mapping mapping : facadeMappping.getMappings()) {
- if(EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
+ if (root != null) {
+ if (root instanceof FacadeMappping) {
+ FacadeMappping facadeMappping = (FacadeMappping) root;
+ for (Mapping mapping : facadeMappping.getMappings()) {
+ if (EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
return getUMLElement(mapping);
@@ -570,27 +572,27 @@ public class FacadeCodegenUtils {
/**
* Gets the FeatureAccessorName of a the UML feature from a mapping.
- *
+ *
* @param mapping
- * the mapping
+ * the mapping
* @param genModel
- * the GenModel
+ * the GenModel
* @return the UML feature from mapping
*/
public static String getUMLFeatureFromMapping(Mapping mapping, GenModel genModel) {
EObject UMLMetaElement = mapping.getUmlElement();
- if(UMLMetaElement instanceof NamedElement) {
+ if (UMLMetaElement instanceof NamedElement) {
- if(UMLMetaElement.eResource() != null) {
- if(!UMLMetaElement.eResource().getContents().isEmpty()) {
+ if (UMLMetaElement.eResource() != null) {
+ if (!UMLMetaElement.eResource().getContents().isEmpty()) {
EObject root = UMLMetaElement.eResource().getContents().get(0);
- if(root instanceof Profile) {
+ if (root instanceof Profile) {
GenModel profileGen = getGenModel(UMLMetaElement);
- EObject umlMetaFeatureDefinition = ((Profile)root).getDefinition((NamedElement)UMLMetaElement);
- if(umlMetaFeatureDefinition instanceof EStructuralFeature) {
- return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel)profileGen).findGenFeature((EStructuralFeature)umlMetaFeatureDefinition).getFeatureAccessorName();
+ EObject umlMetaFeatureDefinition = ((Profile) root).getDefinition((NamedElement) UMLMetaElement);
+ if (umlMetaFeatureDefinition instanceof EStructuralFeature) {
+ return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel) profileGen).findGenFeature((EStructuralFeature) umlMetaFeatureDefinition).getFeatureAccessorName();
}
}
@@ -600,15 +602,15 @@ public class FacadeCodegenUtils {
} else {
- if(UMLMetaElement instanceof EStructuralFeature) {
- if(UMLMetaElement != null) {
+ if (UMLMetaElement instanceof EStructuralFeature) {
+ if (UMLMetaElement != null) {
ResourceSet resourceSet = new ResourceSetImpl();
EObject umlGenModel = resourceSet.getResource(URI.createURI(UML_GEN_MODEL, true), true).getContents().get(0);
- if(umlGenModel != null) {
- if(umlGenModel instanceof org.eclipse.uml2.codegen.ecore.genmodel.GenModel) {
+ if (umlGenModel != null) {
+ if (umlGenModel instanceof org.eclipse.uml2.codegen.ecore.genmodel.GenModel) {
- return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel)umlGenModel).findGenFeature((EStructuralFeature)UMLMetaElement).getFeatureAccessorName();
+ return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel) umlGenModel).findGenFeature((EStructuralFeature) UMLMetaElement).getFeatureAccessorName();
}
}
}
@@ -621,9 +623,9 @@ public class FacadeCodegenUtils {
/**
* Gets the package path from mapping.
- *
+ *
* @param mapping
- * the mapping
+ * the mapping
* @return the package path from mapping
*/
public static String getPackagePathFromMapping(Mapping mapping) {
@@ -634,21 +636,21 @@ public class FacadeCodegenUtils {
/**
* Gets the EPackage path from UML element mapped by a mapping.
- *
+ *
* @param UMLMetaElement
- * the UML metaElement
+ * the UML metaElement
* @return the EPackage path from UML
*/
public static String getPackagePathFromUML(EObject UMLMetaElement) {
EObject root = UMLMetaElement.eResource().getContents().get(0);
- if(root instanceof Profile) {
- Stereotype ePackageStereotype = ((Profile)root).getAppliedStereotype("Ecore::EPackage"); //$NON-NLS-1$
- if(ePackageStereotype != null) {
- Object packageName = ((Profile)root).getValue(ePackageStereotype, "packageName"); //$NON-NLS-1$
- Object basePackage = ((Profile)root).getValue(ePackageStereotype, "basePackage"); //$NON-NLS-1$
- if(packageName instanceof String && basePackage instanceof String) {
- if(UMLMetaElement instanceof NamedElement) {
+ if (root instanceof Profile) {
+ Stereotype ePackageStereotype = ((Profile) root).getAppliedStereotype("Ecore::EPackage"); //$NON-NLS-1$
+ if (ePackageStereotype != null) {
+ Object packageName = ((Profile) root).getValue(ePackageStereotype, "packageName"); //$NON-NLS-1$
+ Object basePackage = ((Profile) root).getValue(ePackageStereotype, "basePackage"); //$NON-NLS-1$
+ if (packageName instanceof String && basePackage instanceof String) {
+ if (UMLMetaElement instanceof NamedElement) {
return basePackage + "." + packageName; //$NON-NLS-1$
}
}
@@ -665,9 +667,9 @@ public class FacadeCodegenUtils {
/**
* Gets the full EPackage path from a mapping.
- *
+ *
* @param mapping
- * the mapping
+ * the mapping
* @return the Epackage path
*/
public static String getUMLPackageName(Mapping mapping) {
@@ -675,12 +677,12 @@ public class FacadeCodegenUtils {
EObject UMLMetaElement = getUMLElement(mapping);
EObject root = UMLMetaElement.eResource().getContents().get(0);
- if(root instanceof Profile) {
- Stereotype ePackageStereotype = ((Profile)root).getAppliedStereotype("Ecore::EPackage"); //$NON-NLS-1$
- if(ePackageStereotype != null) {
- Object packageName = ((Profile)root).getValue(ePackageStereotype, "packageName"); //$NON-NLS-1$
- if(packageName instanceof String) {
- if(UMLMetaElement instanceof NamedElement) {
+ if (root instanceof Profile) {
+ Stereotype ePackageStereotype = ((Profile) root).getAppliedStereotype("Ecore::EPackage"); //$NON-NLS-1$
+ if (ePackageStereotype != null) {
+ Object packageName = ((Profile) root).getValue(ePackageStereotype, "packageName"); //$NON-NLS-1$
+ if (packageName instanceof String) {
+ if (UMLMetaElement instanceof NamedElement) {
return getPackagePathFromMapping(mapping) + "." + packageName + "Package"; //$NON-NLS-1$ //$NON-NLS-2$
}
}
@@ -698,11 +700,11 @@ public class FacadeCodegenUtils {
/**
* Gets the UML accessorName from a mapping.
- *
+ *
* @param mapping
- * the mapping
+ * the mapping
* @param genModel
- * the GenModel
+ * the GenModel
* @return the UML accessorName
*/
public static String getUMLAccessorName(Mapping mapping, GenModel genModel) {
@@ -710,23 +712,23 @@ public class FacadeCodegenUtils {
EObject UMLMetaElement = getUMLElement(mapping);
EObject root = UMLMetaElement.eResource().getContents().get(0);
- if(root instanceof Profile) {
+ if (root instanceof Profile) {
- if(UMLMetaElement instanceof NamedElement) {
- return ((NamedElement)UMLMetaElement).getName();
+ if (UMLMetaElement instanceof NamedElement) {
+ return ((NamedElement) UMLMetaElement).getName();
}
} else {
- if(UMLMetaElement instanceof EClassifier) {
+ if (UMLMetaElement instanceof EClassifier) {
ResourceSet resourceSet = new ResourceSetImpl();
EObject umlGenModel = resourceSet.getResource(URI.createURI(UML_GEN_MODEL, true), true).getContents().get(0);
- if(umlGenModel != null) {
- if(umlGenModel instanceof org.eclipse.uml2.codegen.ecore.genmodel.GenModel) {
+ if (umlGenModel != null) {
+ if (umlGenModel instanceof org.eclipse.uml2.codegen.ecore.genmodel.GenModel) {
- return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel)umlGenModel).findGenClassifier((EClassifier)UMLMetaElement).getClassifierAccessorName();
+ return ((org.eclipse.uml2.codegen.ecore.genmodel.GenModel) umlGenModel).findGenClassifier((EClassifier) UMLMetaElement).getClassifierAccessorName();
}
}
@@ -738,49 +740,49 @@ public class FacadeCodegenUtils {
/**
* Gets the ClassifierAccessorName from a mapping.
- *
+ *
* @param genModel
- * the GenModel
+ * the GenModel
* @param mapping
- * the mapping
+ * the mapping
* @return the ClassifierAccessorName
*/
public static String getClassifierAccessorName(GenModel genModel, Mapping mapping) {
- return genModel.findGenClassifier((EClassifier)mapping.getSpecificDomainElement()).getClassifierAccessorName();
+ return genModel.findGenClassifier((EClassifier) mapping.getSpecificDomainElement()).getClassifierAccessorName();
}
/**
* Gets the FeatureAccessorName from a mapping.
- *
+ *
* @param genModel
- * the GenModel
+ * the GenModel
* @param mapping
- * the mapping
+ * the mapping
* @return the FeatureAccessorName
*/
public static String getFeatureAccessorName(GenModel genModel, Mapping mapping) {
- return genModel.findGenFeature((EStructuralFeature)mapping.getSpecificDomainElement()).getFeatureAccessorName();
+ return genModel.findGenFeature((EStructuralFeature) mapping.getSpecificDomainElement()).getFeatureAccessorName();
}
/**
* Gets the UML meta element mapped to a facadeElement.
- *
+ *
* @param facadeMetaElement
- * the facade meta element
+ * the facade meta element
* @param genModel
- * the GenModel
+ * the GenModel
* @return the UML meta element
*/
public static String getUMLMetaElement(EObject facadeMetaElement, GenModel genModel) {
- for(Mapping mapping : getAllMappings(genModel)) {
- if(EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
+ for (Mapping mapping : getAllMappings(genModel)) {
+ if (EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
EObject UMLMetaElement = getUMLElement(mapping);
- if(UMLMetaElement instanceof ENamedElement) {
- return ((ENamedElement)UMLMetaElement).getName();
- } else if(UMLMetaElement instanceof NamedElement) {
- return ((NamedElement)UMLMetaElement).getName();
+ if (UMLMetaElement instanceof ENamedElement) {
+ return ((ENamedElement) UMLMetaElement).getName();
+ } else if (UMLMetaElement instanceof NamedElement) {
+ return ((NamedElement) UMLMetaElement).getName();
}
}
@@ -792,28 +794,28 @@ public class FacadeCodegenUtils {
/**
* Gets the UML factory.
- *
+ *
* @param facadeMetaElement
- * the facade meta element
+ * the facade meta element
* @param genModel
- * the GenModel
+ * the GenModel
* @return the UML factory
*/
public static String getUMLFactory(EObject facadeMetaElement, GenModel genModel) {
- for(Mapping mapping : getAllMappings(genModel)) {
- if(EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
+ for (Mapping mapping : getAllMappings(genModel)) {
+ if (EcoreUtil.equals(mapping.getSpecificDomainElement(), facadeMetaElement)) {
EObject UMLMetaElement = getUMLElement(mapping);
- if(UMLMetaElement != null) {
+ if (UMLMetaElement != null) {
EObject root = UMLMetaElement.eResource().getContents().get(0);
- if(root instanceof Profile) {
- Stereotype ePackageStereotype = ((Profile)root).getAppliedStereotype("Ecore::EPackage"); //$NON-NLS-1$
- if(ePackageStereotype != null) {
- Object packageName = ((Profile)root).getValue(ePackageStereotype, "packageName"); //$NON-NLS-1$
- if(packageName instanceof String) {
- if(UMLMetaElement instanceof NamedElement) {
+ if (root instanceof Profile) {
+ Stereotype ePackageStereotype = ((Profile) root).getAppliedStereotype("Ecore::EPackage"); //$NON-NLS-1$
+ if (ePackageStereotype != null) {
+ Object packageName = ((Profile) root).getValue(ePackageStereotype, "packageName"); //$NON-NLS-1$
+ if (packageName instanceof String) {
+ if (UMLMetaElement instanceof NamedElement) {
return getPackagePathFromUML(UMLMetaElement) + "." + packageName + "Factory"; //$NON-NLS-1$ //$NON-NLS-2$
}
}
@@ -834,19 +836,19 @@ public class FacadeCodegenUtils {
/**
* Gets the appropriate qualified type name.
- *
+ *
* @param genClassifier
- * a genClassifier
+ * a genClassifier
* @return the qualifiedType name
*/
public static String getAppropriateQualifiedTypeName(GenClassifier genClassifier) {
- if(genClassifier instanceof GenClass) {
+ if (genClassifier instanceof GenClass) {
- return ((GenClass)genClassifier).getQualifiedInterfaceName();
+ return ((GenClass) genClassifier).getQualifiedInterfaceName();
- } else if(genClassifier instanceof GenDataType) {
+ } else if (genClassifier instanceof GenDataType) {
- return ((GenDataType)genClassifier).getQualifiedInstanceClassName();
+ return ((GenDataType) genClassifier).getQualifiedInstanceClassName();
} else {
@@ -856,16 +858,16 @@ public class FacadeCodegenUtils {
/**
* Gets the UML enum element from mapping.
- *
+ *
* @param mapping
- * the mapping
+ * the mapping
* @return the UML enum element from mapping
*/
public static String getUMLEnumElementFromMapping(Mapping mapping) {
- if(mapping.getUmlElement() instanceof EEnumLiteral) {
- return ((EEnumLiteral)mapping.getUmlElement()).getEEnum().getName() + ".get(" + ((EEnumLiteral)mapping.getUmlElement()).getValue() + ")"; //$NON-NLS-1$ //$NON-NLS-2$
- } else if(mapping.getUmlElement() instanceof EnumerationLiteral) {
- return ((EnumerationLiteral)mapping.getUmlElement()).getEnumeration().getName() + ".get(\"" + ((EnumerationLiteral)mapping.getUmlElement()).getName() + "\")"; //$NON-NLS-1$ //$NON-NLS-2$
+ if (mapping.getUmlElement() instanceof EEnumLiteral) {
+ return ((EEnumLiteral) mapping.getUmlElement()).getEEnum().getName() + ".get(" + ((EEnumLiteral) mapping.getUmlElement()).getValue() + ")"; //$NON-NLS-1$ //$NON-NLS-2$
+ } else if (mapping.getUmlElement() instanceof EnumerationLiteral) {
+ return ((EnumerationLiteral) mapping.getUmlElement()).getEnumeration().getName() + ".get(\"" + ((EnumerationLiteral) mapping.getUmlElement()).getName() + "\")"; //$NON-NLS-1$ //$NON-NLS-2$
}
return "FAILED_TO_FIND_MAPPED_UML_ENUM_ELEMENT"; //$NON-NLS-1$
@@ -873,16 +875,16 @@ public class FacadeCodegenUtils {
/**
* Gets the facade enum element from mapping.
- *
+ *
* @param mapping
- * the mapping
+ * the mapping
* @return the facade enum element from the mapping
*/
public static String getFacadeEnumElementFromMapping(Mapping mapping) {
- if(mapping.getUmlElement() instanceof EEnumLiteral) {
- return ((EEnumLiteral)mapping.getUmlElement()).getEEnum().getName() + ".get(" + ((EEnumLiteral)mapping.getUmlElement()).getValue() + ")"; //$NON-NLS-1$ //$NON-NLS-2$
- } else if(mapping.getUmlElement() instanceof EnumerationLiteral) {
- return ((EnumerationLiteral)mapping.getUmlElement()).getEnumeration().getName() + ".get(\"" + ((EnumerationLiteral)mapping.getUmlElement()).getName() + "\")"; //$NON-NLS-1$ //$NON-NLS-2$
+ if (mapping.getUmlElement() instanceof EEnumLiteral) {
+ return ((EEnumLiteral) mapping.getUmlElement()).getEEnum().getName() + ".get(" + ((EEnumLiteral) mapping.getUmlElement()).getValue() + ")"; //$NON-NLS-1$ //$NON-NLS-2$
+ } else if (mapping.getUmlElement() instanceof EnumerationLiteral) {
+ return ((EnumerationLiteral) mapping.getUmlElement()).getEnumeration().getName() + ".get(\"" + ((EnumerationLiteral) mapping.getUmlElement()).getName() + "\")"; //$NON-NLS-1$ //$NON-NLS-2$
}
return "FAILED_TO_FIND_MAPPED_FACADE_ENUM_ELEMENT"; //$NON-NLS-1$
@@ -890,19 +892,19 @@ public class FacadeCodegenUtils {
/**
* Checks if facade element represents a stereotype role for an extension
- *
+ *
* @param facadeElement
- * the facade element
+ * the facade element
* @param genModel
- * the GenModel
+ * the GenModel
* @return true, if facade element represents a stereotype role for an extension
*/
protected static boolean isExtensionStereotypePropertyFromFacade(EObject facadeElement, GenModel genModel) {
EObject umlElement = findUMLMetaElement(facadeElement, genModel);
- if(umlElement instanceof Property) {
- if(((Property)umlElement).getAssociation() instanceof Extension) {
- if(((Property)umlElement).getName().startsWith(Extension.STEREOTYPE_ROLE_PREFIX)) {
+ if (umlElement instanceof Property) {
+ if (((Property) umlElement).getAssociation() instanceof Extension) {
+ if (((Property) umlElement).getName().startsWith(Extension.STEREOTYPE_ROLE_PREFIX)) {
return Boolean.TRUE;
}
@@ -913,9 +915,9 @@ public class FacadeCodegenUtils {
/**
* Checks if is extention stereotype property.
- *
+ *
* @param genFeature
- * the gen feature
+ * the gen feature
* @return true, if is extention stereotype property
*/
public static boolean isExtentionStereotypeProperty(GenFeature genFeature) {
@@ -923,9 +925,9 @@ public class FacadeCodegenUtils {
EObject umlElement = findUMLMetaElement(genFeature.getEcoreFeature(), genFeature.getGenModel());
- if(umlElement instanceof Property) {
- if(((Property)umlElement).getAssociation() instanceof Extension) {
- if(((Property)umlElement).getName().startsWith(Extension.STEREOTYPE_ROLE_PREFIX)) {
+ if (umlElement instanceof Property) {
+ if (((Property) umlElement).getAssociation() instanceof Extension) {
+ if (((Property) umlElement).getName().startsWith(Extension.STEREOTYPE_ROLE_PREFIX)) {
return Boolean.TRUE;
}
@@ -936,16 +938,16 @@ public class FacadeCodegenUtils {
/**
* Checks if is extension property.
- *
+ *
* @param genFeature
- * the gen feature
+ * the gen feature
* @return true, if is extension property
*/
public static boolean isExtensionProperty(GenFeature genFeature) {
EObject umlElement = findUMLMetaElement(genFeature.getEcoreFeature(), genFeature.getGenModel());
- if(umlElement instanceof Property) {
- if(((Property)umlElement).getAssociation() instanceof Extension) {
+ if (umlElement instanceof Property) {
+ if (((Property) umlElement).getAssociation() instanceof Extension) {
return Boolean.TRUE;
}
@@ -955,31 +957,31 @@ public class FacadeCodegenUtils {
/**
* Checks if is stereotype property.
- *
+ *
* @param genFeature
- * the gen feature
+ * the gen feature
* @return true, if is stereotype property
*/
public static boolean isStereotypeProperty(GenFeature genFeature) {
EClass ecoreClass = genFeature.getGenClass().getEcoreClass();
boolean isAppropriateMapping = false;
- for(Mapping mapping : getAllMappings(genFeature.getGenModel())) {
- if(EcoreUtil.equals(ecoreClass, mapping.getSpecificDomainElement())) {
- if(mapping instanceof StereotypedMapping) {
- if(((StereotypedMapping)mapping).getKind() != ExtensionDefinitionKind.ASSOCIATION) {
+ for (Mapping mapping : getAllMappings(genFeature.getGenModel())) {
+ if (EcoreUtil.equals(ecoreClass, mapping.getSpecificDomainElement())) {
+ if (mapping instanceof StereotypedMapping) {
+ if (((StereotypedMapping) mapping).getKind() != ExtensionDefinitionKind.ASSOCIATION) {
isAppropriateMapping = true;
}
}
}
}
- if(isAppropriateMapping) {
+ if (isAppropriateMapping) {
EObject umlElement = findUMLMetaElement(genFeature.getEcoreFeature(), genFeature.getGenModel());
- if(umlElement instanceof Property) {
- if(((Property)umlElement).getClass_() instanceof Stereotype) {
- if(!isExtensionProperty(genFeature)) {
+ if (umlElement instanceof Property) {
+ if (((Property) umlElement).getClass_() instanceof Stereotype) {
+ if (!isExtensionProperty(genFeature)) {
return Boolean.TRUE;
}
}
@@ -990,17 +992,17 @@ public class FacadeCodegenUtils {
/**
* Gets the stereotype qualified name.
- *
+ *
* @param genFeature
- * the gen feature
+ * the gen feature
* @return the stereotype qualified name
*/
public static String getStereotypeQualifiedName(GenFeature genFeature) {
EObject umlElement = findUMLMetaElement(genFeature.getEcoreFeature(), genFeature.getGenModel());
- if(umlElement instanceof Property) {
- if(((Property)umlElement).getClass_() instanceof Stereotype) {
- return ((Property)umlElement).getClass_().getQualifiedName();
+ if (umlElement instanceof Property) {
+ if (((Property) umlElement).getClass_() instanceof Stereotype) {
+ return ((Property) umlElement).getClass_().getQualifiedName();
}
}
return "FAILED_TO_FIND_STEREOTYPE_QUALIFIEDNAME"; //$NON-NLS-1$
@@ -1010,19 +1012,19 @@ public class FacadeCodegenUtils {
/**
* Gets the stereotyped mappings.
- *
+ *
* @param genModel
- * the GenModel
+ * the GenModel
* @return the stereotyped mappings
*/
public static synchronized List<StereotypedMapping> getStereotypedMappings(GenModel genModel) {
- if(!stereotypedMappingsCache.containsKey(genModel)) {
+ if (!stereotypedMappingsCache.containsKey(genModel)) {
List<StereotypedMapping> stereotypedMappings = new ArrayList<StereotypedMapping>();
- for(Mapping mapping : getAllMappings(genModel)) {
- if(mapping instanceof StereotypedMapping) {
- stereotypedMappings.add((StereotypedMapping)mapping);
+ for (Mapping mapping : getAllMappings(genModel)) {
+ if (mapping instanceof StereotypedMapping) {
+ stereotypedMappings.add((StereotypedMapping) mapping);
}
}
@@ -1034,86 +1036,87 @@ public class FacadeCodegenUtils {
/**
* Generate the wrapper for a mapping considering possible application of stereotype combinations
- *
+ *
* @param mapping
- * the mapping
+ * the mapping
* @param genModel
- * the GenModel
+ * the GenModel
* @param genPackage
- * the gen package
+ * the gen package
* @return the corresponding stereotype mapping
*/
public static String getCorrespondingStereotypeMapping(org.eclipse.papyrus.facademapping.Mapping mapping, GenModel genModel, GenPackage genPackage) {
String result = ""; //$NON-NLS-1$
- if(!(mapping instanceof StereotypedMapping)) {
+ if (!(mapping instanceof StereotypedMapping)) {
List<StereotypedMapping> correspondingStereotypeMappings = new ArrayList<StereotypedMapping>();
List<StereotypedMapping> correspondingAssocationStereotypeMappings = new ArrayList<StereotypedMapping>();
- for(Mapping toProcessMapping : getStereotypedMappings(genModel)) {
+ for (Mapping toProcessMapping : getStereotypedMappings(genModel)) {
- if(mapping != toProcessMapping) {
+ if (mapping != toProcessMapping) {
boolean isAbstract = false;
- EList<EObject> stereos = ((StereotypedMapping)toProcessMapping).getAppliedStereotypes();
- for(EObject stereo : stereos) {
- if(stereo instanceof Stereotype) {
- if(((Stereotype)stereo).isAbstract()) {
+ EList<EObject> stereos = ((StereotypedMapping) toProcessMapping).getAppliedStereotypes();
+ for (EObject stereo : stereos) {
+ if (stereo instanceof Stereotype) {
+ if (((Stereotype) stereo).isAbstract()) {
isAbstract = true;
}
}
}
- if(!isAbstract) {
+ if (!isAbstract) {
- if(((StereotypedMapping)toProcessMapping).getKind() == ExtensionDefinitionKind.GENERALIZATION || ((StereotypedMapping)toProcessMapping).getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- if(toProcessMapping.getUmlElement() == mapping.getUmlElement()) {
- correspondingStereotypeMappings.add((StereotypedMapping)toProcessMapping);
+ if (((StereotypedMapping) toProcessMapping).getKind() == ExtensionDefinitionKind.GENERALIZATION || ((StereotypedMapping) toProcessMapping).getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ if (toProcessMapping.getUmlElement() == mapping.getUmlElement()) {
+ correspondingStereotypeMappings.add((StereotypedMapping) toProcessMapping);
}
} else {
- if(mapping.getUmlElement() instanceof EClass) {
+ if (mapping.getUmlElement() instanceof EClass) {
List<EObject> candidates = new ArrayList<EObject>();
- candidates.add((EClass)mapping.getUmlElement());
- candidates.addAll(((EClass)mapping.getUmlElement()).getEAllSuperTypes());
+ candidates.add(mapping.getUmlElement());
+ candidates.addAll(((EClass) mapping.getUmlElement()).getEAllSuperTypes());
- if(candidates.contains(toProcessMapping.getUmlElement()))
- correspondingAssocationStereotypeMappings.add((StereotypedMapping)toProcessMapping);
+ if (candidates.contains(toProcessMapping.getUmlElement())) {
+ correspondingAssocationStereotypeMappings.add((StereotypedMapping) toProcessMapping);
+ }
}
}
}
}
}
- for(StereotypedMapping correspondingStereotypeMapping : correspondingStereotypeMappings) {
- if(correspondingStereotypeMapping.getSpecificDomainElement() instanceof ENamedElement) {
+ for (StereotypedMapping correspondingStereotypeMapping : correspondingStereotypeMappings) {
+ if (correspondingStereotypeMapping.getSpecificDomainElement() instanceof ENamedElement) {
- String name = ((ENamedElement)correspondingStereotypeMapping.getSpecificDomainElement()).getName().toLowerCase();
+ String name = ((ENamedElement) correspondingStereotypeMapping.getSpecificDomainElement()).getName().toLowerCase();
- //Single stereotype
+ // Single stereotype
List<Stereotype> combination = new ArrayList<Stereotype>();
- combination.addAll((Collection<? extends Stereotype>)correspondingStereotypeMapping.getAppliedStereotypes());
+ combination.addAll((Collection<? extends Stereotype>) correspondingStereotypeMapping.getAppliedStereotypes());
result += addWrappingStereotypeMapping(combination, name, genPackage, genModel, correspondingStereotypeMapping);
- //Create combination with association stereo
- if(!correspondingAssocationStereotypeMappings.isEmpty()) {
+ // Create combination with association stereo
+ if (!correspondingAssocationStereotypeMappings.isEmpty()) {
- for(int k = 1; k <= correspondingAssocationStereotypeMappings.size(); k++) {
+ for (int k = 1; k <= correspondingAssocationStereotypeMappings.size(); k++) {
CombinationGenerator combinaisonGenerator = new CombinationGenerator(correspondingAssocationStereotypeMappings.size(), k);
- //Process each combination
- while(combinaisonGenerator.hasMore()) {
+ // Process each combination
+ while (combinaisonGenerator.hasMore()) {
int[] indices = combinaisonGenerator.getNext();
- //Single stereotype first
+ // Single stereotype first
combination = new ArrayList<Stereotype>();
- combination.addAll((Collection<? extends Stereotype>)correspondingStereotypeMapping.getAppliedStereotypes());
- name = ((ENamedElement)correspondingStereotypeMapping.getSpecificDomainElement()).getName().toLowerCase();
+ combination.addAll((Collection<? extends Stereotype>) correspondingStereotypeMapping.getAppliedStereotypes());
+ name = ((ENamedElement) correspondingStereotypeMapping.getSpecificDomainElement()).getName().toLowerCase();
- for(int i = 0; i < indices.length; i++) {
- combination.addAll((Collection<? extends Stereotype>)correspondingAssocationStereotypeMappings.get(indices[i]).getAppliedStereotypes());
+ for (int i = 0; i < indices.length; i++) {
+ combination.addAll((Collection<? extends Stereotype>) correspondingAssocationStereotypeMappings.get(indices[i]).getAppliedStereotypes());
- if(correspondingAssocationStereotypeMappings.get(indices[i]).getSpecificDomainElement() instanceof ENamedElement) {
- name += "_" + ((ENamedElement)correspondingAssocationStereotypeMappings.get(indices[i]).getSpecificDomainElement()).getName().toLowerCase(); //$NON-NLS-1$
+ if (correspondingAssocationStereotypeMappings.get(indices[i]).getSpecificDomainElement() instanceof ENamedElement) {
+ name += "_" + ((ENamedElement) correspondingAssocationStereotypeMappings.get(indices[i]).getSpecificDomainElement()).getName().toLowerCase(); //$NON-NLS-1$
} else {
FacadeCodeGenPlugin.log.warn(Messages.FacadeCodegenUtils_48 + correspondingAssocationStereotypeMappings.get(indices[i]).getSpecificDomainElement());
}
@@ -1137,17 +1140,17 @@ public class FacadeCodegenUtils {
/**
* Generate the actual text for a wrapping of a combination of stereotype application
- *
+ *
* @param combination
- * the combination
+ * the combination
* @param name
- * the name
+ * the name
* @param genPackage
- * the gen package
+ * the gen package
* @param genModel
- * the GenModel
+ * the GenModel
* @param correspondingStereotypeMapping
- * the corresponding stereotype mapping
+ * the corresponding stereotype mapping
* @return the string
*/
protected static String addWrappingStereotypeMapping(List<Stereotype> combination, String name, GenPackage genPackage, GenModel genModel, StereotypedMapping correspondingStereotypeMapping) {
@@ -1162,7 +1165,7 @@ public class FacadeCodegenUtils {
result += "return " + genPackage.getImportedPackageInterfaceName() + ".eINSTANCE.get" + getClassifierAccessorName(genModel, correspondingStereotypeMapping) + "();\n"; //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
result += "}\n"; //$NON-NLS-1$
result += "}\n"; //$NON-NLS-1$
- for(int i = 0; i < combination.size(); i++) {
+ for (int i = 0; i < combination.size(); i++) {
result += "}\n"; //$NON-NLS-1$
}
@@ -1172,20 +1175,20 @@ public class FacadeCodegenUtils {
/**
* Generate the text for the combination of stereotype application
- *
+ *
* @param combination
- * the combination
+ * the combination
* @param name
- * the name
+ * the name
* @return the string
*/
protected static String addStereotypes(List<Stereotype> combination, String name) {
String result = ""; //$NON-NLS-1$
- for(EObject stereotype : combination) {
- if(stereotype instanceof Stereotype) {
- result += "if(((org.eclipse.uml2.uml.Element)umlElement).getApplicableStereotype(\"" + ((Stereotype)stereotype).getQualifiedName() + "\") != null) {\n"; //$NON-NLS-1$ //$NON-NLS-2$
- result += name + "_Stereotypes.add(((org.eclipse.uml2.uml.Element)umlElement).getApplicableStereotype(\"" + ((Stereotype)stereotype).getQualifiedName() + "\"));\n"; //$NON-NLS-1$ //$NON-NLS-2$
+ for (EObject stereotype : combination) {
+ if (stereotype instanceof Stereotype) {
+ result += "if(((org.eclipse.uml2.uml.Element)umlElement).getApplicableStereotype(\"" + ((Stereotype) stereotype).getQualifiedName() + "\") != null) {\n"; //$NON-NLS-1$ //$NON-NLS-2$
+ result += name + "_Stereotypes.add(((org.eclipse.uml2.uml.Element)umlElement).getApplicableStereotype(\"" + ((Stereotype) stereotype).getQualifiedName() + "\"));\n"; //$NON-NLS-1$ //$NON-NLS-2$
}
}
@@ -1195,13 +1198,13 @@ public class FacadeCodegenUtils {
/**
* Checks if is a list of primitive types.
- *
+ *
* @param genFeature
- * the genFeature
+ * the genFeature
* @return true, if is list of primitive types
*/
public static boolean isPrimtiveList(GenTypedElement genTypedElement) {
- if(CodeGenUtil.isJavaDefaultType(genTypedElement.getListItemType())) {
+ if (CodeGenUtil.isJavaDefaultType(genTypedElement.getListItemType())) {
return Boolean.TRUE;
}
@@ -1210,21 +1213,21 @@ public class FacadeCodegenUtils {
/**
* Checks if is primitive type.
- *
+ *
* @param genFeature
- * the genFeature
+ * the genFeature
* @return true, if is primitive type
*/
public static boolean isPrimitive(GenTypedElement genTypedElement) {
- if(isJavaDefaultType(genTypedElement.getType())) {
+ if (isJavaDefaultType(genTypedElement.getType())) {
return Boolean.TRUE;
}
- if(isEcoreDefaultType(genTypedElement.getType())) {
+ if (isEcoreDefaultType(genTypedElement.getType())) {
return Boolean.TRUE;
}
- if(genTypedElement.getType().startsWith("java.util.Map<")) {
+ if (genTypedElement.getType().startsWith("java.util.Map<")) {
return Boolean.TRUE;
}
@@ -1249,7 +1252,7 @@ public class FacadeCodegenUtils {
* Returns the names of the ecore types
*/
public static synchronized Set<String> getEcoreDefaultTypes() {
- if(ecoreDefaultTypes == null) {
+ if (ecoreDefaultTypes == null) {
Set<String> result = new HashSet<String>(100);
result.add("org.eclipse.emf.ecore.EAnnotation");
result.add("org.eclipse.emf.ecore.EAttribute");
@@ -1275,7 +1278,7 @@ public class FacadeCodegenUtils {
result.add("org.eclipse.emf.ecore.EValidator");
result.add("org.eclipse.emf.ecore.InternalEObject");
- //ypes not directly EMF but used by EMF
+ // ypes not directly EMF but used by EMF
result.add("org.eclipse.emf.common.util.DiagnosticChain");
@@ -1288,7 +1291,7 @@ public class FacadeCodegenUtils {
* Returns the names of the primitives and types
*/
public static synchronized Set<String> getJavaDefaultTypes() {
- if(javaDefaultTypes == null) {
+ if (javaDefaultTypes == null) {
Set<String> result = new HashSet<String>(100);
result.add("java.lang.AbstractMethodError");
result.add("java.lang.ArithmeticException");
@@ -1388,25 +1391,25 @@ public class FacadeCodegenUtils {
/**
* Copy the original ecore metamodel in the impl source package
- *
+ *
* @param genPackage
- * the gen package
+ * the gen package
*/
public static void copyEcore(GenPackage genPackage) {
GenModel genModel = genPackage.getGenModel();
EModelElement ecoreModelElement = genPackage.getEcoreModelElement();
- if(ecoreModelElement != null) {
+ if (ecoreModelElement != null) {
URI originalURI = ecoreModelElement.eResource().getURI();
String modelDirectory = genModel.getModelDirectory();
String implPackage = genPackage.getClassPackageName().replaceAll("\\.", "/"); //$NON-NLS-1$ //$NON-NLS-2$
- if(!implPackage.startsWith("/") && !modelDirectory.endsWith("/")) { //$NON-NLS-1$ //$NON-NLS-2$
+ if (!implPackage.startsWith("/") && !modelDirectory.endsWith("/")) { //$NON-NLS-1$ //$NON-NLS-2$
implPackage = "/" + implPackage; //$NON-NLS-1$
}
String filePath = modelDirectory + implPackage;
- if(!filePath.endsWith("/")) { //$NON-NLS-1$
+ if (!filePath.endsWith("/")) { //$NON-NLS-1$
filePath += "/"; //$NON-NLS-1$
}
filePath += originalURI.lastSegment();
@@ -1415,13 +1418,13 @@ public class FacadeCodegenUtils {
try {
- if(originalURI.isPlatformResource()) {
+ if (originalURI.isPlatformResource()) {
String platformString = originalURI.toPlatformString(true);
IResource resource = ResourcesPlugin.getWorkspace().getRoot().findMember(platformString);
- if(resource instanceof IFile) {
+ if (resource instanceof IFile) {
IPath destPath = new Path(dest);
- if(destPath.segmentCount() >= 2) {
+ if (destPath.segmentCount() >= 2) {
IFile destFolder = resource.getProject().getFile(destPath.removeLastSegments(1).removeFirstSegments(1));
IFile destFile = resource.getProject().getFile(destPath.removeFirstSegments(1));
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/WrappingListUtils.java b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/WrappingListUtils.java
index 21372aa2d6c..dbd66a3108c 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/WrappingListUtils.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.codegen/src/org/eclipse/papyrus/facade/codegen/utils/WrappingListUtils.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -36,22 +36,22 @@ public class WrappingListUtils {
/**
* Gets the list of genFeatures that are subsetted by the genFeature.
- *
+ *
* @param genFeature
- * the genFeature
+ * the genFeature
* @return the list of subsetted genFeatures
*/
protected static List<GenFeature> getSubsetReferenceGenFeature(GenFeature genFeature) {
List<GenFeature> result = new ArrayList<GenFeature>();
EStructuralFeature ecoreFeature = genFeature.getEcoreFeature();
- if(ecoreFeature != null) {
+ if (ecoreFeature != null) {
EAnnotation annotation = ecoreFeature.getEAnnotation("subsets"); //$NON-NLS-1$
- if(annotation != null) {
+ if (annotation != null) {
EList<EObject> references = annotation.getReferences();
- for(EObject ref : references) {
+ for (EObject ref : references) {
- if(ref instanceof EReference) {
- GenFeature refGenFeature = genFeature.getGenModel().findGenFeature((EStructuralFeature)ref);
+ if (ref instanceof EReference) {
+ GenFeature refGenFeature = genFeature.getGenModel().findGenFeature((EStructuralFeature) ref);
result.add(refGenFeature);
}
}
@@ -63,97 +63,97 @@ public class WrappingListUtils {
/**
* Gets the wrapping list constructor.
- *
+ *
* @param genClass
- * the gen class
+ * the gen class
* @param genFeature
- * the gen feature
+ * the gen feature
* @param typeArgument
- * the type argument
+ * the type argument
* @return the wrapping list constructor
*/
public static String getWrappingListConstructor(GenClass genClass, GenFeature genFeature, String typeArgument) {
boolean isJava5 = isJDK50(genClass.getGenModel());
- if(genClass instanceof GenClassImpl) {
+ if (genClass instanceof GenClassImpl) {
- GenClassImpl genClassImpl = (GenClassImpl)genClass;
+ GenClassImpl genClassImpl = (GenClassImpl) genClass;
StringBuffer sb = new StringBuffer();
String unsettable = genFeature.isUnsettable() ? ".Unsettable" : ""; //$NON-NLS-1$ //$NON-NLS-2$
String offsetCorrectionField = genClassImpl.hasOffsetCorrection() ? " + " + genClassImpl.getOffsetCorrectionField(null) : ""; //$NON-NLS-1$ //$NON-NLS-2$
- if(genFeature.isMapType()) {
+ if (genFeature.isMapType()) {
sb.append(UNSUPPORTED_LIST_CONSTRUCTOR + "_MapType"); //$NON-NLS-1$
- // GenClass mapGenClass = genFeature.getMapEntryTypeGenClass();
- // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EcoreEMap"));
- // sb.append(unsettable);
- // if(isJava5) {
- // sb.append('<');
- // sb.append(genFeature.getImportedMapKeyType(genClassImpl));
- // sb.append(',');
- // sb.append(genFeature.getImportedMapValueType(genClassImpl));
- // sb.append('>');
- // }
- // sb.append("(");
- // sb.append(mapGenClass.getQualifiedClassifierAccessor());
- // sb.append(", ");
- // sb.append(genFeature.getImportedMapEntryType());
- // sb.append(".class, this, ");
- // sb.append(genClassImpl.getQualifiedFeatureID(genFeature));
- // sb.append(offsetCorrectionField);
- // if(genFeature.isBidirectional() && genClassImpl.getGenModel().getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF27_VALUE) {
- // sb.append(", ");
- // sb.append(genFeature.getReverse().getGenClass().getQualifiedFeatureID(genFeature.getReverse()));
- // }
- // sb.append(")");
- } else if(genFeature.isFeatureMapType()) {
+ // GenClass mapGenClass = genFeature.getMapEntryTypeGenClass();
+ // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EcoreEMap"));
+ // sb.append(unsettable);
+ // if(isJava5) {
+ // sb.append('<');
+ // sb.append(genFeature.getImportedMapKeyType(genClassImpl));
+ // sb.append(',');
+ // sb.append(genFeature.getImportedMapValueType(genClassImpl));
+ // sb.append('>');
+ // }
+ // sb.append("(");
+ // sb.append(mapGenClass.getQualifiedClassifierAccessor());
+ // sb.append(", ");
+ // sb.append(genFeature.getImportedMapEntryType());
+ // sb.append(".class, this, ");
+ // sb.append(genClassImpl.getQualifiedFeatureID(genFeature));
+ // sb.append(offsetCorrectionField);
+ // if(genFeature.isBidirectional() && genClassImpl.getGenModel().getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF27_VALUE) {
+ // sb.append(", ");
+ // sb.append(genFeature.getReverse().getGenClass().getQualifiedFeatureID(genFeature.getReverse()));
+ // }
+ // sb.append(")");
+ } else if (genFeature.isFeatureMapType()) {
sb.append(UNSUPPORTED_LIST_CONSTRUCTOR + "_FeatureMapType"); //$NON-NLS-1$
- // if(genFeature.isWrappedFeatureMapType()) {
- // sb.append(genFeature.getImportedEffectiveFeatureMapWrapperClass());
- // sb.append("(new ");
- // }
- // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.BasicFeatureMap"));
- // sb.append("(this, ");
- // sb.append(genClassImpl.getQualifiedFeatureID(genFeature));
- // sb.append(offsetCorrectionField);
- // sb.append(")");
- // if(genFeature.isWrappedFeatureMapType()) {
- // sb.append(")");
- // }
+ // if(genFeature.isWrappedFeatureMapType()) {
+ // sb.append(genFeature.getImportedEffectiveFeatureMapWrapperClass());
+ // sb.append("(new ");
+ // }
+ // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.BasicFeatureMap"));
+ // sb.append("(this, ");
+ // sb.append(genClassImpl.getQualifiedFeatureID(genFeature));
+ // sb.append(offsetCorrectionField);
+ // sb.append(")");
+ // if(genFeature.isWrappedFeatureMapType()) {
+ // sb.append(")");
+ // }
} else {
EGenericType eGenericType = genFeature.getEcoreFeature().getEGenericType();
- if(genClassImpl.getGenModel().isSuppressNotification()) {
+ if (genClassImpl.getGenModel().isSuppressNotification()) {
sb.append(UNSUPPORTED_LIST_CONSTRUCTOR + "_Generic"); //$NON-NLS-1$
- // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.BasicInternalEList"));
- // if(genClassImpl.getGenModel().getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF28_VALUE) {
- // sb.append(unsettable);
- // }
- // if(isJava5) {
- // sb.append('<');
- // sb.append(genFeature.getListItemType(genClassImpl));
- // sb.append('>');
- // }
- // sb.append("(");
- // sb.append(typeArgument);
- // sb.append(".class)");
- } else if(genFeature.isEffectiveContains()) {
- if(genFeature.isBidirectional()) {
+ // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.BasicInternalEList"));
+ // if(genClassImpl.getGenModel().getRuntimeVersion().getValue() >= GenRuntimeVersion.EMF28_VALUE) {
+ // sb.append(unsettable);
+ // }
+ // if(isJava5) {
+ // sb.append('<');
+ // sb.append(genFeature.getListItemType(genClassImpl));
+ // sb.append('>');
+ // }
+ // sb.append("(");
+ // sb.append(typeArgument);
+ // sb.append(".class)");
+ } else if (genFeature.isEffectiveContains()) {
+ if (genFeature.isBidirectional()) {
GenFeature reverseFeature = genFeature.getReverse();
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.subset.WrappingSubsetEObjectContainmentWithInverseEList")); //$NON-NLS-1$
} else {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingEObjectContainmentWithInverseEList")); //$NON-NLS-1$
}
sb.append(unsettable);
- if(genFeature.isResolveProxies()) {
- // sb.append(".Resolving");
+ if (genFeature.isResolveProxies()) {
+ // sb.append(".Resolving");
sb.append(UNSUPPORTED_LIST_CONSTRUCTOR + "_Resolving"); //$NON-NLS-1$
}
- if(isJava5) {
+ if (isJava5) {
sb.append('<');
sb.append(genFeature.getListItemType(genClassImpl));
sb.append('>');
@@ -165,29 +165,29 @@ public class WrappingListUtils {
sb.append(offsetCorrectionField);
sb.append(", "); //$NON-NLS-1$
sb.append(reverseFeature.getGenClass().getQualifiedFeatureID(reverseFeature));
- if(reverseFeature.getGenClass().hasOffsetCorrection()) {
+ if (reverseFeature.getGenClass().hasOffsetCorrection()) {
sb.append(" + "); //$NON-NLS-1$
sb.append(genClassImpl.getOffsetCorrectionField(genFeature));
}
sb.append(",(java.util.Collection)umlList"); //$NON-NLS-1$
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
- for(GenFeature feature : getSubsetReferenceGenFeature(genFeature)) {
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ for (GenFeature feature : getSubsetReferenceGenFeature(genFeature)) {
sb.append(",(" + genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingList") + ")" + feature.getGetAccessor() + "()"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
}
}
sb.append(")"); //$NON-NLS-1$
} else {
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.subset.WrappingSubsetEObjectContainmentEList")); //$NON-NLS-1$
} else {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingEObjectContainmentEList")); //$NON-NLS-1$
}
sb.append(unsettable);
- if(genFeature.isResolveProxies()) {
- // sb.append(".Resolving");
+ if (genFeature.isResolveProxies()) {
+ // sb.append(".Resolving");
sb.append(UNSUPPORTED_LIST_CONSTRUCTOR + "_Resolving"); //$NON-NLS-1$
}
- if(isJava5) {
+ if (isJava5) {
sb.append('<');
sb.append(genFeature.getListItemType(genClassImpl));
sb.append('>');
@@ -198,39 +198,39 @@ public class WrappingListUtils {
sb.append(genClassImpl.getQualifiedFeatureID(genFeature));
sb.append(offsetCorrectionField);
sb.append(",(java.util.Collection)umlList"); //$NON-NLS-1$
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
- for(GenFeature feature : getSubsetReferenceGenFeature(genFeature)) {
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ for (GenFeature feature : getSubsetReferenceGenFeature(genFeature)) {
sb.append(",(" + genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingList") + ")" + feature.getGetAccessor() + "()"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
}
}
sb.append(")"); //$NON-NLS-1$
}
- } else if(genFeature.isReferenceType()) {
- if(genFeature.isBidirectional()) {
+ } else if (genFeature.isReferenceType()) {
+ if (genFeature.isBidirectional()) {
GenFeature reverseFeature = genFeature.getReverse();
- if(genFeature.isResolveProxies()) {
- // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList"));
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ if (genFeature.isResolveProxies()) {
+ // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EObjectWithInverseResolvingEList"));
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.subset.WrappingSubsetEObjectWithInverseEList")); //$NON-NLS-1$
} else {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingEObjectWithInverseEList")); //$NON-NLS-1$
}
} else {
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.subset.WrappingSubsetEObjectWithInverseEList")); //$NON-NLS-1$
} else {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingEObjectWithInverseEList")); //$NON-NLS-1$
}
}
sb.append(unsettable);
- if(reverseFeature.isListType()) {
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ if (reverseFeature.isListType()) {
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
sb.append(".WrappingSubsetManyInverse"); //$NON-NLS-1$
} else {
sb.append(".WrappingManyInverse"); //$NON-NLS-1$
}
}
- if(isJava5) {
+ if (isJava5) {
sb.append('<');
sb.append(genFeature.getListItemType(genClassImpl));
sb.append('>');
@@ -242,34 +242,34 @@ public class WrappingListUtils {
sb.append(offsetCorrectionField);
sb.append(", "); //$NON-NLS-1$
sb.append(reverseFeature.getGenClass().getQualifiedFeatureID(reverseFeature));
- if(reverseFeature.getGenClass().hasOffsetCorrection()) {
+ if (reverseFeature.getGenClass().hasOffsetCorrection()) {
sb.append(" + "); //$NON-NLS-1$
sb.append(genClassImpl.getOffsetCorrectionField(genFeature));
}
sb.append(",(java.util.Collection)umlList"); //$NON-NLS-1$
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
- for(GenFeature feature : getSubsetReferenceGenFeature(genFeature)) {
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ for (GenFeature feature : getSubsetReferenceGenFeature(genFeature)) {
sb.append(",(" + genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingList") + ")" + feature.getGetAccessor() + "()"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
}
}
sb.append(")"); //$NON-NLS-1$
} else {
- if(genFeature.isResolveProxies()) {
- // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EObjectResolvingEList"));
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ if (genFeature.isResolveProxies()) {
+ // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EObjectResolvingEList"));
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.subset.WrappingSubsetEObjectEList")); //$NON-NLS-1$
} else {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingEObjectEList")); //$NON-NLS-1$
}
} else {
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.subset.WrappingSubsetEObjectEList")); //$NON-NLS-1$
} else {
sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingEObjectEList")); //$NON-NLS-1$
}
}
sb.append(unsettable);
- if(isJava5) {
+ if (isJava5) {
sb.append('<');
sb.append(genFeature.getListItemType(genClassImpl));
sb.append('>');
@@ -280,23 +280,23 @@ public class WrappingListUtils {
sb.append(genClassImpl.getQualifiedFeatureID(genFeature));
sb.append(offsetCorrectionField);
sb.append(",(java.util.Collection)umlList"); //$NON-NLS-1$
- if(!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
- for(GenFeature feature : getSubsetReferenceGenFeature(genFeature)) {
+ if (!getSubsetReferenceGenFeature(genFeature).isEmpty()) {
+ for (GenFeature feature : getSubsetReferenceGenFeature(genFeature)) {
sb.append(",(" + genClassImpl.getGenModel().getImportedName("org.eclipse.papyrus.facade.utils.wrappinglist.WrappingList") + ")" + feature.getGetAccessor() + "()"); //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ //$NON-NLS-4$
}
}
sb.append(")"); //$NON-NLS-1$
}
- } else { //data type
- if(genFeature.isUnique()) {
- // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EDataTypeUniqueEList"));
+ } else { // data type
+ if (genFeature.isUnique()) {
+ // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EDataTypeUniqueEList"));
sb.append(UNSUPPORTED_LIST_CONSTRUCTOR + "_UniqueDatatype"); //$NON-NLS-1$
} else {
- // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EDataTypeEList"));
+ // sb.append(genClassImpl.getGenModel().getImportedName("org.eclipse.emf.ecore.util.EDataTypeEList"));
sb.append(UNSUPPORTED_LIST_CONSTRUCTOR + "_NotUniqueDatatype"); //$NON-NLS-1$
}
sb.append(unsettable);
- if(isJava5) {
+ if (isJava5) {
sb.append('<');
sb.append(genFeature.getListItemType(genClassImpl));
sb.append('>');
@@ -316,22 +316,23 @@ public class WrappingListUtils {
/**
* Checks if the genModel is defined as JDK50 complianceLevel.
- *
+ *
* @param genModel
- * the genModel
+ * the genModel
* @return true, if the genModel is defined as JDK50 complianceLevel.
*/
public static boolean isJDK50(GenModel genModel) {
- if(genModel != null && genModel.getComplianceLevel() != null)
+ if (genModel != null && genModel.getComplianceLevel() != null) {
return genModel.getComplianceLevel().getValue() >= GenJDKLevel.JDK50;
+ }
return false;
}
/**
* Checks if is primitive type.
- *
+ *
* @param eType
- * the eType
+ * the eType
* @return true, if is primitive type
*/
static public boolean isPrimitiveType(EClassifier eType) {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/ResourceManager.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/ResourceManager.java
index 4b94d4e04d4..e157bc93fbb 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/ResourceManager.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/ResourceManager.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -34,30 +34,31 @@ import org.osgi.framework.Bundle;
/**
* Utility class for managing OS resources associated with SWT/JFace controls such as colors, fonts, images,
* etc.
- *
+ *
* !!! IMPORTANT !!! Application code must explicitly invoke the <code>dispose()</code> method to release the
* operating system resources managed by cached objects when those objects and OS resources are no longer
* needed (e.g. on application shutdown)
- *
+ *
* This class may be freely distributed as part of any application or plugin.
* <p>
* Copyright (c) 2003 - 2007, Instantiations, Inc. <br>
* All Rights Reserved
- *
+ *
* @author scheglov_ke
* @author Dan Rubel
*/
public class ResourceManager extends SWTResourceManager {
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
//
// Image
//
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
private static Map<ImageDescriptor, Image> m_descriptorImageMap = new HashMap<ImageDescriptor, Image>();
+
/**
* Returns an {@link ImageDescriptor} stored in the file at the specified path relative to the specified
* class.
- *
+ *
* @param clazz
* the {@link Class} relative to which to find the image descriptor.
* @param path
@@ -67,9 +68,10 @@ public class ResourceManager extends SWTResourceManager {
public static ImageDescriptor getImageDescriptor(Class<?> clazz, String path) {
return ImageDescriptor.createFromFile(clazz, path);
}
+
/**
* Returns an {@link ImageDescriptor} stored in the file at the specified path.
- *
+ *
* @param path
* the path to the image file.
* @return the {@link ImageDescriptor} stored in the file at the specified path.
@@ -81,9 +83,10 @@ public class ResourceManager extends SWTResourceManager {
return null;
}
}
+
/**
* Returns an {@link Image} based on the specified {@link ImageDescriptor}.
- *
+ *
* @param descriptor
* the {@link ImageDescriptor} for the {@link Image}.
* @return the {@link Image} based on the specified {@link ImageDescriptor}.
@@ -99,14 +102,16 @@ public class ResourceManager extends SWTResourceManager {
}
return image;
}
+
/**
* Maps images to decorated images.
*/
@SuppressWarnings("unchecked")
private static Map<Image, Map<Image, Image>>[] m_decoratedImageMap = new Map[LAST_CORNER_KEY];
+
/**
* Returns an {@link Image} composed of a base image decorated by another image.
- *
+ *
* @param baseImage
* the base {@link Image} that should be decorated.
* @param decorator
@@ -116,9 +121,10 @@ public class ResourceManager extends SWTResourceManager {
public static Image decorateImage(Image baseImage, Image decorator) {
return decorateImage(baseImage, decorator, BOTTOM_RIGHT);
}
+
/**
* Returns an {@link Image} composed of a base image decorated by another image.
- *
+ *
* @param baseImage
* the base {@link Image} that should be decorated.
* @param decorator
@@ -161,6 +167,7 @@ public class ResourceManager extends SWTResourceManager {
drawImage(decorator.getImageData(), bib.width - dib.width, bib.height - dib.height);
}
}
+
@Override
protected Point getSize() {
return baseImageSize;
@@ -172,6 +179,7 @@ public class ResourceManager extends SWTResourceManager {
}
return result;
}
+
/**
* Dispose all of the cached images.
*/
@@ -205,34 +213,38 @@ public class ResourceManager extends SWTResourceManager {
m_URLImageMap.clear();
}
}
- ////////////////////////////////////////////////////////////////////////////
+
+ // //////////////////////////////////////////////////////////////////////////
//
// Plugin images support
//
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
/**
* Maps URL to images.
*/
private static Map<String, Image> m_URLImageMap = new HashMap<String, Image>();
+
/**
* Provider for plugin resources, used by WindowBuilder at design time.
*/
public interface PluginResourceProvider {
URL getEntry(String symbolicName, String path);
}
+
/**
* Instance of {@link PluginResourceProvider}, used by WindowBuilder at design time.
*/
private static PluginResourceProvider m_designTimePluginResourceProvider = null;
+
/**
* Returns an {@link Image} based on a plugin and file path.
- *
+ *
* @param plugin
* the plugin {@link Object} containing the image
* @param name
* the path to the image within the plugin
* @return the {@link Image} stored in the file at the specified path
- *
+ *
* @deprecated Use {@link #getPluginImage(String, String)} instead.
*/
@Deprecated
@@ -247,9 +259,10 @@ public class ResourceManager extends SWTResourceManager {
}
return null;
}
+
/**
* Returns an {@link Image} based on a {@link Bundle} and resource entry path.
- *
+ *
* @param symbolicName
* the symbolic name of the {@link Bundle}.
* @param path
@@ -267,6 +280,7 @@ public class ResourceManager extends SWTResourceManager {
}
return null;
}
+
/**
* Returns an {@link Image} based on given {@link URL}.
*/
@@ -293,15 +307,16 @@ public class ResourceManager extends SWTResourceManager {
}
return null;
}
+
/**
* Returns an {@link ImageDescriptor} based on a plugin and file path.
- *
+ *
* @param plugin
* the plugin {@link Object} containing the image.
* @param name
* the path to th eimage within the plugin.
* @return the {@link ImageDescriptor} stored in the file at the specified path.
- *
+ *
* @deprecated Use {@link #getPluginImageDescriptor(String, String)} instead.
*/
@Deprecated
@@ -318,9 +333,10 @@ public class ResourceManager extends SWTResourceManager {
}
return null;
}
+
/**
* Returns an {@link ImageDescriptor} based on a {@link Bundle} and resource entry path.
- *
+ *
* @param symbolicName
* the symbolic name of the {@link Bundle}.
* @param path
@@ -338,6 +354,7 @@ public class ResourceManager extends SWTResourceManager {
}
return null;
}
+
/**
* Returns an {@link URL} based on a {@link Bundle} and resource entry path.
*/
@@ -356,9 +373,10 @@ public class ResourceManager extends SWTResourceManager {
// no such resource
return null;
}
+
/**
* Returns an {@link URL} based on a plugin and file path.
- *
+ *
* @param plugin
* the plugin {@link Object} containing the file path.
* @param name
@@ -376,13 +394,13 @@ public class ResourceManager extends SWTResourceManager {
Object bundle = getBundleMethod.invoke(plugin, new Object[0]);
//
Class<?> PathClass = Class.forName("org.eclipse.core.runtime.Path"); //$NON-NLS-1$
- Constructor<?> pathConstructor = PathClass.getConstructor(new Class[]{String.class});
- Object path = pathConstructor.newInstance(new Object[]{name});
+ Constructor<?> pathConstructor = PathClass.getConstructor(new Class[] { String.class });
+ Object path = pathConstructor.newInstance(new Object[] { name });
//
Class<?> IPathClass = Class.forName("org.eclipse.core.runtime.IPath"); //$NON-NLS-1$
Class<?> PlatformClass = Class.forName("org.eclipse.core.runtime.Platform"); //$NON-NLS-1$
- Method findMethod = PlatformClass.getMethod("find", new Class[]{BundleClass, IPathClass}); //$NON-NLS-1$
- return (URL) findMethod.invoke(null, new Object[]{bundle, path});
+ Method findMethod = PlatformClass.getMethod("find", new Class[] { BundleClass, IPathClass }); //$NON-NLS-1$
+ return (URL) findMethod.invoke(null, new Object[] { bundle, path });
}
} catch (Throwable e) {
// Ignore any exceptions
@@ -393,21 +411,22 @@ public class ResourceManager extends SWTResourceManager {
if (PluginClass.isAssignableFrom(plugin.getClass())) {
//
Class<?> PathClass = Class.forName("org.eclipse.core.runtime.Path"); //$NON-NLS-1$
- Constructor<?> pathConstructor = PathClass.getConstructor(new Class[]{String.class});
- Object path = pathConstructor.newInstance(new Object[]{name});
+ Constructor<?> pathConstructor = PathClass.getConstructor(new Class[] { String.class });
+ Object path = pathConstructor.newInstance(new Object[] { name });
//
Class<?> IPathClass = Class.forName("org.eclipse.core.runtime.IPath"); //$NON-NLS-1$
- Method findMethod = PluginClass.getMethod("find", new Class[]{IPathClass}); //$NON-NLS-1$
- return (URL) findMethod.invoke(plugin, new Object[]{path});
+ Method findMethod = PluginClass.getMethod("find", new Class[] { IPathClass }); //$NON-NLS-1$
+ return (URL) findMethod.invoke(plugin, new Object[] { path });
}
}
return null;
}
- ////////////////////////////////////////////////////////////////////////////
+
+ // //////////////////////////////////////////////////////////////////////////
//
// General
//
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
/**
* Dispose of cached objects and their underlying OS resources. This should only be called when the cached
* objects are no longer needed (e.g. on application shutdown).
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/SWTResourceManager.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/SWTResourceManager.java
index d0bf3bcaa18..94978b58131 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/SWTResourceManager.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/com/swtdesigner/SWTResourceManager.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -34,28 +34,27 @@ import org.eclipse.swt.widgets.Display;
/**
* Utility class for managing OS resources associated with SWT controls such as colors, fonts, images, etc.
* <p>
- * !!! IMPORTANT !!! Application code must explicitly invoke the <code>dispose()</code> method to release the
- * operating system resources managed by cached objects when those objects and OS resources are no longer
- * needed (e.g. on application shutdown)
+ * !!! IMPORTANT !!! Application code must explicitly invoke the <code>dispose()</code> method to release the operating system resources managed by cached objects when those objects and OS resources are no longer needed (e.g. on application shutdown)
* <p>
* This class may be freely distributed as part of any application or plugin.
* <p>
* Copyright (c) 2003 - 2007, Instantiations, Inc. <br>
* All Rights Reserved
- *
+ *
* @author scheglov_ke
* @author Dan Rubel
*/
public class SWTResourceManager {
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
//
// Color
//
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
private static Map<RGB, Color> m_colorMap = new HashMap<RGB, Color>();
+
/**
* Returns the system {@link Color} matching the specific ID.
- *
+ *
* @param systemColorID
* the ID value for the color
* @return the system {@link Color} matching the specific ID
@@ -64,9 +63,10 @@ public class SWTResourceManager {
Display display = Display.getCurrent();
return display.getSystemColor(systemColorID);
}
+
/**
* Returns a {@link Color} given its red, green and blue component values.
- *
+ *
* @param r
* the red component of the color
* @param g
@@ -78,9 +78,10 @@ public class SWTResourceManager {
public static Color getColor(int r, int g, int b) {
return getColor(new RGB(r, g, b));
}
+
/**
* Returns a {@link Color} given its RGB value.
- *
+ *
* @param rgb
* the {@link RGB} value of the color
* @return the {@link Color} matching the RGB value
@@ -94,6 +95,7 @@ public class SWTResourceManager {
}
return color;
}
+
/**
* Dispose of all the cached {@link Color}'s.
*/
@@ -103,18 +105,20 @@ public class SWTResourceManager {
}
m_colorMap.clear();
}
- ////////////////////////////////////////////////////////////////////////////
+
+ // //////////////////////////////////////////////////////////////////////////
//
// Image
//
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
/**
* Maps image paths to images.
*/
private static Map<String, Image> m_imageMap = new HashMap<String, Image>();
+
/**
* Returns an {@link Image} encoded by the specified {@link InputStream}.
- *
+ *
* @param stream
* the {@link InputStream} encoding the image data
* @return the {@link Image} encoded by the specified input stream
@@ -131,9 +135,10 @@ public class SWTResourceManager {
stream.close();
}
}
+
/**
* Returns an {@link Image} stored in the file at the specified path.
- *
+ *
* @param path
* the path to the image file
* @return the {@link Image} stored in the file at the specified path
@@ -151,9 +156,10 @@ public class SWTResourceManager {
}
return image;
}
+
/**
* Returns an {@link Image} stored in the file at the specified path relative to the specified class.
- *
+ *
* @param clazz
* the {@link Class} relative to which to find the image
* @param path
@@ -174,7 +180,9 @@ public class SWTResourceManager {
}
return image;
}
+
private static final int MISSING_IMAGE_SIZE = 10;
+
/**
* @return the small {@link Image} that can be used as placeholder for missing image.
*/
@@ -188,6 +196,7 @@ public class SWTResourceManager {
//
return image;
}
+
/**
* Style constant for placing decorator image in top left corner of base image.
*/
@@ -213,9 +222,10 @@ public class SWTResourceManager {
*/
@SuppressWarnings("unchecked")
private static Map<Image, Map<Image, Image>>[] m_decoratedImageMap = new Map[LAST_CORNER_KEY];
+
/**
* Returns an {@link Image} composed of a base image decorated by another image.
- *
+ *
* @param baseImage
* the base {@link Image} that should be decorated
* @param decorator
@@ -225,9 +235,10 @@ public class SWTResourceManager {
public static Image decorateImage(Image baseImage, Image decorator) {
return decorateImage(baseImage, decorator, BOTTOM_RIGHT);
}
+
/**
* Returns an {@link Image} composed of a base image decorated by another image.
- *
+ *
* @param baseImage
* the base {@link Image} that should be decorated
* @param decorator
@@ -275,6 +286,7 @@ public class SWTResourceManager {
}
return result;
}
+
/**
* Dispose all of the cached {@link Image}'s.
*/
@@ -300,11 +312,12 @@ public class SWTResourceManager {
}
}
}
- ////////////////////////////////////////////////////////////////////////////
+
+ // //////////////////////////////////////////////////////////////////////////
//
// Font
//
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
/**
* Maps font names to fonts.
*/
@@ -313,9 +326,10 @@ public class SWTResourceManager {
* Maps fonts to their bold versions.
*/
private static Map<Font, Font> m_fontToBoldFontMap = new HashMap<Font, Font>();
+
/**
* Returns a {@link Font} based on its name, height and style.
- *
+ *
* @param name
* the name of the font
* @param height
@@ -327,10 +341,11 @@ public class SWTResourceManager {
public static Font getFont(String name, int height, int style) {
return getFont(name, height, style, false, false);
}
+
/**
* Returns a {@link Font} based on its name, height and style. Windows-specific strikeout and underline
* flags are also supported.
- *
+ *
* @param name
* the name of the font
* @param size
@@ -369,9 +384,10 @@ public class SWTResourceManager {
}
return font;
}
+
/**
* Returns a bold version of the given {@link Font}.
- *
+ *
* @param baseFont
* the {@link Font} for which a bold version is desired
* @return the bold version of the given {@link Font}
@@ -386,6 +402,7 @@ public class SWTResourceManager {
}
return font;
}
+
/**
* Dispose all of the cached {@link Font}'s.
*/
@@ -401,18 +418,20 @@ public class SWTResourceManager {
}
m_fontToBoldFontMap.clear();
}
- ////////////////////////////////////////////////////////////////////////////
+
+ // //////////////////////////////////////////////////////////////////////////
//
// Cursor
//
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
/**
* Maps IDs to cursors.
*/
private static Map<Integer, Cursor> m_idToCursorMap = new HashMap<Integer, Cursor>();
+
/**
* Returns the system cursor matching the specific ID.
- *
+ *
* @param id
* int The ID value for the cursor
* @return Cursor The system cursor matching the specific ID
@@ -426,6 +445,7 @@ public class SWTResourceManager {
}
return cursor;
}
+
/**
* Dispose all of the cached cursors.
*/
@@ -435,11 +455,12 @@ public class SWTResourceManager {
}
m_idToCursorMap.clear();
}
- ////////////////////////////////////////////////////////////////////////////
+
+ // //////////////////////////////////////////////////////////////////////////
//
// General
//
- ////////////////////////////////////////////////////////////////////////////
+ // //////////////////////////////////////////////////////////////////////////
/**
* Dispose of cached objects and their underlying OS resources. This should only be called when the cached
* objects are no longer needed (e.g. on application shutdown).
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeDefinitionEditorActivator.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeDefinitionEditorActivator.java
index 116954f3596..75f023f06bb 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeDefinitionEditorActivator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeDefinitionEditorActivator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -42,6 +42,7 @@ public class FacadeDefinitionEditorActivator extends AbstractUIPlugin {
*
* @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
*/
+ @Override
public void start(BundleContext context) throws Exception {
super.start(context);
plugin = this;
@@ -53,6 +54,7 @@ public class FacadeDefinitionEditorActivator extends AbstractUIPlugin {
*
* @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
*/
+ @Override
public void stop(BundleContext context) throws Exception {
plugin = null;
super.stop(context);
@@ -60,7 +62,7 @@ public class FacadeDefinitionEditorActivator extends AbstractUIPlugin {
/**
* Returns the shared instance
- *
+ *
* @return the shared instance
*/
public static FacadeDefinitionEditorActivator getDefault() {
@@ -69,9 +71,9 @@ public class FacadeDefinitionEditorActivator extends AbstractUIPlugin {
/**
* Returns an image descriptor for the image file at the given plug-in relative path
- *
+ *
* @param path
- * the path
+ * the path
* @return the image descriptor
*/
public static ImageDescriptor getImageDescriptor(String path) {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeSpecificEditor.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeSpecificEditor.java
index c839948ea50..e5b7b116313 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeSpecificEditor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/FacadeSpecificEditor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -175,8 +175,9 @@ public class FacadeSpecificEditor extends FacadeEditor {
/**
* @see org.eclipse.papyrus.facade.presentation.FacadeEditor#createModel()
- *
+ *
*/
+ @Override
public void createModel() {
URI resourceURI = EditUIUtil.getURI(getEditorInput());
@@ -191,20 +192,20 @@ public class FacadeSpecificEditor extends FacadeEditor {
}
Diagnostic diagnostic = analyzeResourceProblems(facadeModelResource, exception);
- if(diagnostic.getSeverity() != Diagnostic.OK) {
+ if (diagnostic.getSeverity() != Diagnostic.OK) {
resourceToDiagnosticMap.put(facadeModelResource, analyzeResourceProblems(facadeModelResource, exception));
}
editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter);
- if(facadeModelResource.getContents().size() > 0) {
+ if (facadeModelResource.getContents().size() > 0) {
// Get the root
- facade = (Facade)facadeModelResource.getContents().get(0);
+ facade = (Facade) facadeModelResource.getContents().get(0);
- if(!facade.getExtensionDefinitions().isEmpty()) {
+ if (!facade.getExtensionDefinitions().isEmpty()) {
// Shouldn't be required but just in case
ProfileUtils.clearSiblings();
- for(ExtensionDefinition stereotypeDefinition : facade.getExtensionDefinitions()) {
+ for (ExtensionDefinition stereotypeDefinition : facade.getExtensionDefinitions()) {
ProfileUtils.initSiblings(stereotypeDefinition.getStereotype());
}
}
@@ -213,7 +214,7 @@ public class FacadeSpecificEditor extends FacadeEditor {
/**
* Getter for the extensionDefintionTreeViewer widget
- *
+ *
* @return the extensionDefintionTreeViewer widget
*/
public static TreeViewer getExtensionDefintionTreeViewer() {
@@ -222,7 +223,7 @@ public class FacadeSpecificEditor extends FacadeEditor {
/**
* Getter for the metamodelTreeViewer widget
- *
+ *
* @return the metamodelTreeViewer widget
*/
public static TreeViewer getMetamodelTreeViewer() {
@@ -257,43 +258,43 @@ public class FacadeSpecificEditor extends FacadeEditor {
}
public Object[] getElements(Object inputElement) {
- if(inputElement instanceof List) {
- return ((List<?>)inputElement).toArray();
+ if (inputElement instanceof List) {
+ return ((List<?>) inputElement).toArray();
}
return Collections.emptyList().toArray();
}
}, new ExtensionLabelProvider(), Messages.FacadeSpecificEditor_1);
dlg.setTitle(Messages.FacadeSpecificEditor_2);
dlg.open();
- if(dlg.getResult() != null) {
+ if (dlg.getResult() != null) {
- for(Object selectedElement : dlg.getResult()) {
- if(selectedElement instanceof RegisteredProfile) {
- EObject model = UMLModelUtils.loadModel(((RegisteredProfile)selectedElement).uri, profileResourceSet);
- if(model instanceof Profile) {
+ for (Object selectedElement : dlg.getResult()) {
+ if (selectedElement instanceof RegisteredProfile) {
+ EObject model = UMLModelUtils.loadModel(((RegisteredProfile) selectedElement).uri, profileResourceSet);
+ if (model instanceof Profile) {
TreeIterator<EObject> it = model.eAllContents();
boolean failed = false;
- while(it.hasNext() && !failed) {
- EObject eObject = (EObject)it.next();
- if(eObject instanceof PrimitiveType) {
- Stereotype stereotype = ((PrimitiveType)eObject).getAppliedStereotype("Ecore::EDataType"); //$NON-NLS-1$
- if(stereotype != null) {
- Object value = ((PrimitiveType)eObject).getValue(stereotype, "instanceClassName"); //$NON-NLS-1$
- if(!(value instanceof String)) {
+ while (it.hasNext() && !failed) {
+ EObject eObject = it.next();
+ if (eObject instanceof PrimitiveType) {
+ Stereotype stereotype = ((PrimitiveType) eObject).getAppliedStereotype("Ecore::EDataType"); //$NON-NLS-1$
+ if (stereotype != null) {
+ Object value = ((PrimitiveType) eObject).getValue(stereotype, "instanceClassName"); //$NON-NLS-1$
+ if (!(value instanceof String)) {
failed = true;
- MessageDialog.openError(getContainer().getShell(), Messages.FacadeSpecificEditor_5, Messages.FacadeSpecificEditor_6 + ((PrimitiveType)eObject).getName() + Messages.FacadeSpecificEditor_7);
+ MessageDialog.openError(getContainer().getShell(), Messages.FacadeSpecificEditor_5, Messages.FacadeSpecificEditor_6 + ((PrimitiveType) eObject).getName() + Messages.FacadeSpecificEditor_7);
}
}
}
- if(eObject instanceof Extension) {
- if(((Extension)eObject).isRequired()) {
+ if (eObject instanceof Extension) {
+ if (((Extension) eObject).isRequired()) {
failed = true;
MessageDialog.openError(getContainer().getShell(), Messages.FacadeSpecificEditor_8, Messages.FacadeSpecificEditor_9);
}
}
}
- if(!failed) {
- profileModels.add((Profile)model);
+ if (!failed) {
+ profileModels.add((Profile) model);
}
} else {
MessageDialog.openError(getContainer().getShell(), Messages.FacadeSpecificEditor_10, Messages.FacadeSpecificEditor_11);
@@ -305,17 +306,18 @@ public class FacadeSpecificEditor extends FacadeEditor {
/**
* @see org.eclipse.swt.events.MouseAdapter#mouseUp(org.eclipse.swt.events.MouseEvent)
- *
+ *
* @param e
*/
+ @Override
public void mouseUp(MouseEvent e) {
profileModels.clear();
openProfile();
- if(!profileModels.isEmpty()) {
+ if (!profileModels.isEmpty()) {
clearModel();
ProfileUtils.clearSiblings();
@@ -351,26 +353,26 @@ public class FacadeSpecificEditor extends FacadeEditor {
// Find all extensions be it in the profile or in another profile
Set<Extension> extensions = new HashSet<Extension>();
- for(Profile profile : profileModels) {
+ for (Profile profile : profileModels) {
TreeIterator<EObject> iterator = profile.eAllContents();
- while(iterator.hasNext()) {
- EObject eObject = (EObject)iterator.next();
- if(eObject instanceof Stereotype) {
+ while (iterator.hasNext()) {
+ EObject eObject = iterator.next();
+ if (eObject instanceof Stereotype) {
- extensions.addAll(ProfileUtils.findExtensions((Stereotype)eObject));
+ extensions.addAll(ProfileUtils.findExtensions((Stereotype) eObject));
}
}
}
- for(Extension extension : extensions) {
+ for (Extension extension : extensions) {
List<Stereotype> stereotypes = ProfileUtils.findAllSubsInProfile(extension.getStereotype());
stereotypes.add(extension.getStereotype());
- for(Stereotype stereotype : stereotypes) {
+ for (Stereotype stereotype : stereotypes) {
ExtensionDefinition extensionDefinition = ExtensiondefinitionFactory.eINSTANCE.createExtensionDefinition();
extensionDefinition.setExtension(extension);
extensionDefinition.setKind(ExtensionDefinitionKind.ASSOCIATION);
@@ -382,7 +384,7 @@ public class FacadeSpecificEditor extends FacadeEditor {
ProfileUtils.initSiblings(stereotype);
List<EClass> baseMetaclasses = StereotypeUtils.getAllExtendableMetaclasses(extension, false);
- for(EClass eClass : baseMetaclasses) {
+ for (EClass eClass : baseMetaclasses) {
BaseMetaclass baseMetaclass = ExtensiondefinitionFactory.eINSTANCE.createBaseMetaclass();
baseMetaclass.setBase(eClass);
@@ -413,14 +415,15 @@ public class FacadeSpecificEditor extends FacadeEditor {
/**
* @see org.eclipse.papyrus.facade.presentation.FacadeEditor#createPages()
- *
+ *
*/
+ @Override
public void createPages() {
// Creates the model from the editor input
createModel();
// Only creates the other pages if there is something that can be edited
- if(!getEditingDomain().getResourceSet().getResources().isEmpty()) {
+ if (!getEditingDomain().getResourceSet().getResources().isEmpty()) {
Composite composite = new Composite(getContainer(), SWT.NONE);
composite.setLayout(new GridLayout(1, true));
@@ -450,8 +453,9 @@ public class FacadeSpecificEditor extends FacadeEditor {
tabFolder.addSelectionListener(new SelectionAdapter() {
+ @Override
public void widgetSelected(org.eclipse.swt.events.SelectionEvent event) {
- if(tabFolder.getSelectionIndex() <= 1) {
+ if (tabFolder.getSelectionIndex() <= 1) {
extensionDefintionTreeViewer.refresh();
metamodelTreeViewer.refresh();
}
@@ -468,8 +472,9 @@ public class FacadeSpecificEditor extends FacadeEditor {
boolean guard = false;
+ @Override
public void controlResized(ControlEvent event) {
- if(!guard) {
+ if (!guard) {
guard = true;
hideTabs();
guard = false;
@@ -487,11 +492,11 @@ public class FacadeSpecificEditor extends FacadeEditor {
/**
* Creates the tab corresponding to the generation of the actual ECore metamodel
- *
+ *
* @param tabFolder
- * the tab folder
+ * the tab folder
* @param generateMetamodelTabItem
- * the generate metamodel tab item
+ * the generate metamodel tab item
*/
protected void createGenerateEcore(Composite tabFolder, TabItem generateMetamodelTabItem) {
GridData layoutData = new GridData(SWT.FILL, SWT.FILL, true, false);
@@ -503,8 +508,8 @@ public class FacadeSpecificEditor extends FacadeEditor {
metamodelNameLabel.setText(Messages.FacadeSpecificEditor_21);
metamodelName = new Text(composite, SWT.BORDER);
metamodelName.setLayoutData(layoutData);
- if(facade.getVirtualmetamodel() != null) {
- if(facade.getVirtualmetamodel().getName() != null) {
+ if (facade.getVirtualmetamodel() != null) {
+ if (facade.getVirtualmetamodel().getName() != null) {
metamodelName.setText(facade.getVirtualmetamodel().getName());
} else {
metamodelName.setText(""); //$NON-NLS-1$
@@ -522,8 +527,8 @@ public class FacadeSpecificEditor extends FacadeEditor {
nsPrefixLabel.setText(Messages.FacadeSpecificEditor_23);
nsPrefix = new Text(composite, SWT.BORDER);
nsPrefix.setLayoutData(layoutData);
- if(facade.getVirtualmetamodel() != null) {
- if(facade.getVirtualmetamodel().getNsPrefix() != null) {
+ if (facade.getVirtualmetamodel() != null) {
+ if (facade.getVirtualmetamodel().getNsPrefix() != null) {
nsPrefix.setText(facade.getVirtualmetamodel().getNsPrefix());
} else {
nsPrefix.setText(""); //$NON-NLS-1$
@@ -542,8 +547,8 @@ public class FacadeSpecificEditor extends FacadeEditor {
nsURILabel.setText(Messages.FacadeSpecificEditor_25);
nsURI = new Text(composite, SWT.BORDER);
nsURI.setLayoutData(layoutData);
- if(facade.getVirtualmetamodel() != null) {
- if(facade.getVirtualmetamodel().getNsURI() != null) {
+ if (facade.getVirtualmetamodel() != null) {
+ if (facade.getVirtualmetamodel().getNsURI() != null) {
nsURI.setText(facade.getVirtualmetamodel().getNsURI());
} else {
nsURI.setText(""); //$NON-NLS-1$
@@ -567,11 +572,11 @@ public class FacadeSpecificEditor extends FacadeEditor {
/**
* Creates the tab used to define the wanted facade metamodel.
- *
+ *
* @param tabFolder
- * the tab folder
+ * the tab folder
* @param designMetamodelTabItem
- * the design metamodel tab item
+ * the design metamodel tab item
*/
protected void createDesignMetamodel(Composite tabFolder, TabItem designMetamodelTabItem) {
@@ -631,8 +636,8 @@ public class FacadeSpecificEditor extends FacadeEditor {
metamodelTreeViewer.addSelectionChangedListener(new ISelectionChangedListener() {
public void selectionChanged(SelectionChangedEvent event) {
- if(event.getSelection() instanceof IStructuredSelection) {
- Object first = ((IStructuredSelection)event.getSelection()).getFirstElement();
+ if (event.getSelection() instanceof IStructuredSelection) {
+ Object first = ((IStructuredSelection) event.getSelection()).getFirstElement();
propertiesTreeViewer.setInput(first);
propertiesTreeViewer.refresh();
}
@@ -683,11 +688,11 @@ public class FacadeSpecificEditor extends FacadeEditor {
/**
* Creates the tab used to clarify extensions identified in the UML profiles
- *
+ *
* @param tabFolder
- * the tab folder
+ * the tab folder
* @param clarifyExtensionsTabItem
- * the clarify extensions tab item
+ * the clarify extensions tab item
*/
protected void createClarifyExtension(Composite tabFolder, TabItem clarifyExtensionsTabItem) {
GridData layoutData = new GridData(SWT.FILL, SWT.FILL, true, true);
@@ -727,8 +732,8 @@ public class FacadeSpecificEditor extends FacadeEditor {
extensionDefintionTreeViewer.addSelectionChangedListener(new ISelectionChangedListener() {
public void selectionChanged(SelectionChangedEvent event) {
- if(event.getSelection() instanceof IStructuredSelection) {
- Object first = ((IStructuredSelection)event.getSelection()).getFirstElement();
+ if (event.getSelection() instanceof IStructuredSelection) {
+ Object first = ((IStructuredSelection) event.getSelection()).getFirstElement();
incompatibilitiesTableViewer.setInput(first);
incompatibilitiesTableViewer.refresh();
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/Messages.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/Messages.java
index 5547489cab5..ff982c2ef9c 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/Messages.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/Messages.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/EditionUtils.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/EditionUtils.java
index c25fc8a125a..133b2033ad7 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/EditionUtils.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/EditionUtils.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -31,17 +31,17 @@ public class EditionUtils {
/**
* Check is a combination of stereotypes appears in a list (independently from the order of the combination)
- *
+ *
* @param list
- * the list to search in
+ * the list to search in
* @param combinaison
- * the combination to find
+ * the combination to find
* @return
*/
public static boolean containsCombination(List<Combination> list, Combination combinaison) {
- for(Combination item : list) {
- if(item.getMembers().size() == combinaison.getMembers().size()) {
- if(item.getMembers().containsAll(combinaison.getMembers())) {
+ for (Combination item : list) {
+ if (item.getMembers().size() == combinaison.getMembers().size()) {
+ if (item.getMembers().containsAll(combinaison.getMembers())) {
return true;
}
}
@@ -53,17 +53,17 @@ public class EditionUtils {
/**
* Find a combination of stereotypes appears in a list of combination (independently from the order of the combination)
- *
+ *
* @param list
- * the list to search in
+ * the list to search in
* @param combinaison
- * the combination to find
+ * the combination to find
* @return
*/
public static Combination getCombinationThatMatch(List<Combination> list, Combination combinaison) {
- for(Combination item : list) {
- if(item.getMembers().size() == combinaison.getMembers().size()) {
- if(item.getMembers().containsAll(combinaison.getMembers())) {
+ for (Combination item : list) {
+ if (item.getMembers().size() == combinaison.getMembers().size()) {
+ if (item.getMembers().containsAll(combinaison.getMembers())) {
return item;
}
}
@@ -75,30 +75,30 @@ public class EditionUtils {
/**
* Generate the stereotype combinations for the facade
- *
+ *
* @param facade
- * the facade to generate the combinations for
+ * the facade to generate the combinations for
* @param editingDomain
*/
public static void initAllStereotypeCombinations(Facade facade, AdapterFactoryEditingDomain editingDomain) {
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- for(BaseMetaclass baseMeta : extensionDefinition.getBaseMetaclasses()) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ for (BaseMetaclass baseMeta : extensionDefinition.getBaseMetaclasses()) {
List<Combination> possibleCombinations = ProfileUtils.getPossibleCombinations(baseMeta);
List<Combination> toAdd = new ArrayList<Combination>();
- for(Combination combinaison : possibleCombinations) {
+ for (Combination combinaison : possibleCombinations) {
- if(!containsCombination(baseMeta.getIncompatibleStereotypes(), combinaison)) {
- if(!containsCombination(baseMeta.getCompatibleStereotypes(), combinaison)) {
+ if (!containsCombination(baseMeta.getIncompatibleStereotypes(), combinaison)) {
+ if (!containsCombination(baseMeta.getCompatibleStereotypes(), combinaison)) {
toAdd.add(combinaison);
}
}
}
- for(Combination combination : toAdd) {
+ for (Combination combination : toAdd) {
AddCommand addIncompatibilitiesCommand = new AddCommand(editingDomain, baseMeta, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_IncompatibleStereotypes(), combination);
editingDomain.getCommandStack().execute(addIncompatibilitiesCommand);
@@ -109,35 +109,35 @@ public class EditionUtils {
/**
* Remove the stereotype combinations from the facade
- *
+ *
* @param facade
* @param editingDomain
*/
public static void clearAllStereotypeCombinations(Facade facade, AdapterFactoryEditingDomain editingDomain) {
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- for(BaseMetaclass baseMeta : extensionDefinition.getBaseMetaclasses()) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ for (BaseMetaclass baseMeta : extensionDefinition.getBaseMetaclasses()) {
List<Combination> possibleCombinations = ProfileUtils.getPossibleCombinations(baseMeta);
List<Combination> incompatibilitiesToRemove = new ArrayList<Combination>();
- for(Combination incompatibleBase : baseMeta.getIncompatibleStereotypes()) {
- if(!containsCombination(possibleCombinations, incompatibleBase)) {
+ for (Combination incompatibleBase : baseMeta.getIncompatibleStereotypes()) {
+ if (!containsCombination(possibleCombinations, incompatibleBase)) {
incompatibilitiesToRemove.add(incompatibleBase);
}
}
- RemoveCommand removeIncompatibilityCommand = new RemoveCommand(editingDomain, baseMeta, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_IncompatibleStereotypes(), incompatibilitiesToRemove); //$NON-NLS-1$
+ RemoveCommand removeIncompatibilityCommand = new RemoveCommand(editingDomain, baseMeta, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_IncompatibleStereotypes(), incompatibilitiesToRemove);
editingDomain.getCommandStack().execute(removeIncompatibilityCommand);
List<Combination> compatibilitiesToRemove = new ArrayList<Combination>();
- for(Combination compatibleBase : baseMeta.getCompatibleStereotypes()) {
- if(!containsCombination(possibleCombinations, compatibleBase)) {
+ for (Combination compatibleBase : baseMeta.getCompatibleStereotypes()) {
+ if (!containsCombination(possibleCombinations, compatibleBase)) {
compatibilitiesToRemove.add(compatibleBase);
}
}
- RemoveCommand removeCompatibilityCommand = new RemoveCommand(editingDomain, baseMeta, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_CompatibleStereotypes(), compatibilitiesToRemove); //$NON-NLS-1$
+ RemoveCommand removeCompatibilityCommand = new RemoveCommand(editingDomain, baseMeta, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_CompatibleStereotypes(), compatibilitiesToRemove);
editingDomain.getCommandStack().execute(removeCompatibilityCommand);
}
@@ -146,7 +146,7 @@ public class EditionUtils {
/**
* Check whether the baseMetaclass has a combination that is required
- *
+ *
* @param baseMeta
* @return
*/
@@ -157,10 +157,10 @@ public class EditionUtils {
combinaisonsToCheck.addAll(baseMeta.getCompatibleStereotypes());
combinaisonsToCheck.addAll(baseMeta.getIncompatibleStereotypes());
- for(Combination combination : combinaisonsToCheck) {
- for(BaseMetaclass metaclass : combination.getMembers()) {
- if(metaclass.getExtensionDefinition().getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- if(metaclass.getExtensionDefinition().getExtension().isRequired()) {
+ for (Combination combination : combinaisonsToCheck) {
+ for (BaseMetaclass metaclass : combination.getMembers()) {
+ if (metaclass.getExtensionDefinition().getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ if (metaclass.getExtensionDefinition().getExtension().isRequired()) {
return true;
}
}
@@ -172,15 +172,15 @@ public class EditionUtils {
/**
* Initialize the isPossible of all the extension definitions of a Facade
- *
+ *
* @param facade
* @param editingDomain
*/
public static void initIsPossible(Facade facade, AdapterFactoryEditingDomain editingDomain) {
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- for(BaseMetaclass baseMeta : extensionDefinition.getBaseMetaclasses()) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ for (BaseMetaclass baseMeta : extensionDefinition.getBaseMetaclasses()) {
// If it has a combination that contains a required
- if(hasARequiredCombination(baseMeta)) {
+ if (hasARequiredCombination(baseMeta)) {
baseMeta.setPossible(false);
} else {
baseMeta.setPossible(true);
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/ExtensionKindColumnEditingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/ExtensionKindColumnEditingSupport.java
index 32eee41119c..ebdfa527661 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/ExtensionKindColumnEditingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/ExtensionKindColumnEditingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -53,64 +53,64 @@ public class ExtensionKindColumnEditingSupport extends EditingSupport {
/**
* Change the interpretation to give to an extension to ExtensionDefinitionKind.ASSOCIATION
- *
+ *
* @param element
*/
protected void transformIntoAssociation(ExtensionDefinition element) {
- SetCommand command = new SetCommand(editingDomain, element, ExtensiondefinitionPackage.eINSTANCE.getExtensionDefinition_Kind(), ExtensionDefinitionKind.ASSOCIATION); //$NON-NLS-1$
+ SetCommand command = new SetCommand(editingDomain, element, ExtensiondefinitionPackage.eINSTANCE.getExtensionDefinition_Kind(), ExtensionDefinitionKind.ASSOCIATION);
editingDomain.getCommandStack().execute(command);
}
/**
* Change the interpretation to give to an extension to ExtensionDefinitionKind.GENERALIZATION
- *
+ *
* @param element
*/
protected void transformIntoGeneralization(ExtensionDefinition element) {
- SetCommand command = new SetCommand(editingDomain, element, ExtensiondefinitionPackage.eINSTANCE.getExtensionDefinition_Kind(), ExtensionDefinitionKind.GENERALIZATION); //$NON-NLS-1$
+ SetCommand command = new SetCommand(editingDomain, element, ExtensiondefinitionPackage.eINSTANCE.getExtensionDefinition_Kind(), ExtensionDefinitionKind.GENERALIZATION);
editingDomain.getCommandStack().execute(command);
}
/**
* Change the interpretation to give to an extension to ExtensionDefinitionKind.MULTI_GENERALIZATION
- *
+ *
* @param element
*/
protected void transformIntoMultiGeneralization(ExtensionDefinition element) {
- SetCommand command = new SetCommand(editingDomain, element, ExtensiondefinitionPackage.eINSTANCE.getExtensionDefinition_Kind(), ExtensionDefinitionKind.MULTI_GENERALIZATION); //$NON-NLS-1$
+ SetCommand command = new SetCommand(editingDomain, element, ExtensiondefinitionPackage.eINSTANCE.getExtensionDefinition_Kind(), ExtensionDefinitionKind.MULTI_GENERALIZATION);
editingDomain.getCommandStack().execute(command);
}
/**
* Change the interpretation to give to an extension to ExtensionDefinitionKind.FUSION
- *
+ *
* @param element
*/
protected void transformIntoFusion(ExtensionDefinition element) {
- SetCommand command = new SetCommand(editingDomain, element, ExtensiondefinitionPackage.eINSTANCE.getExtensionDefinition_Kind(), ExtensionDefinitionKind.FUSION); //$NON-NLS-1$
+ SetCommand command = new SetCommand(editingDomain, element, ExtensiondefinitionPackage.eINSTANCE.getExtensionDefinition_Kind(), ExtensionDefinitionKind.FUSION);
editingDomain.getCommandStack().execute(command);
}
/**
* Check if the stereotype involved in the extensionDefinition is also used to type the property of a stereotype elsewhere
- *
+ *
* @param extensionDefinition
* @return
*/
protected boolean stereotypeUsedElsewhere(ExtensionDefinition extensionDefinition) {
EList<ExtensionDefinition> allExtensionDefintion = extensionDefinition.getFacade().getExtensionDefinitions();
- for(ExtensionDefinition otherExtensionDefinition : allExtensionDefintion) {
- if(otherExtensionDefinition != extensionDefinition) {
- for(Property property : otherExtensionDefinition.getStereotype().getAttributes()) {
- if(property.getType() == extensionDefinition.getStereotype()) {
+ for (ExtensionDefinition otherExtensionDefinition : allExtensionDefintion) {
+ if (otherExtensionDefinition != extensionDefinition) {
+ for (Property property : otherExtensionDefinition.getStereotype().getAttributes()) {
+ if (property.getType() == extensionDefinition.getStereotype()) {
return true;
}
}
@@ -122,16 +122,16 @@ public class ExtensionKindColumnEditingSupport extends EditingSupport {
/**
* Check if the stereotype involved in the extensionDefinition is also involved in another extensionDefinition
- *
+ *
* @param extensionDefinition
* @return
*/
protected boolean hasOtherExtension(ExtensionDefinition extensionDefinition) {
EList<ExtensionDefinition> allExtensionDefintion = extensionDefinition.getFacade().getExtensionDefinitions();
- for(ExtensionDefinition otherExtensionDefinition : allExtensionDefintion) {
- if(otherExtensionDefinition != extensionDefinition) {
- if(extensionDefinition.getStereotype() == otherExtensionDefinition.getStereotype()) {
+ for (ExtensionDefinition otherExtensionDefinition : allExtensionDefintion) {
+ if (otherExtensionDefinition != extensionDefinition) {
+ if (extensionDefinition.getStereotype() == otherExtensionDefinition.getStereotype()) {
return true;
}
}
@@ -142,15 +142,15 @@ public class ExtensionKindColumnEditingSupport extends EditingSupport {
/**
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(final Object element, final Object value) {
- final ExtensionDefinitionKind newValue = ExtensionDefinitionKind.get((Integer)value);
+ final ExtensionDefinitionKind newValue = ExtensionDefinitionKind.get((Integer) value);
- if(element instanceof ExtensionDefinition) {
+ if (element instanceof ExtensionDefinition) {
ProgressMonitorDialog dialog = new ProgressMonitorDialog(Display.getCurrent().getActiveShell());
try {
@@ -159,43 +159,43 @@ public class ExtensionKindColumnEditingSupport extends EditingSupport {
public void run(IProgressMonitor monitor) {
monitor.beginTask(Messages.ExtensionKindColumnEditingSupport_0, IProgressMonitor.UNKNOWN);
- Facade facade = ((ExtensionDefinition)element).getFacade();
+ Facade facade = ((ExtensionDefinition) element).getFacade();
- if(newValue == ExtensionDefinitionKind.ASSOCIATION) {
+ if (newValue == ExtensionDefinitionKind.ASSOCIATION) {
- transformIntoAssociation((ExtensionDefinition)element);
+ transformIntoAssociation((ExtensionDefinition) element);
// All children and generals must be set to Association as well
- HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((ExtensionDefinition)element).getStereotype());
+ HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((ExtensionDefinition) element).getStereotype());
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getExtension() == ((ExtensionDefinition)element).getExtension()) {
- if(siblings.contains(extensionDefinition.getStereotype())) {
+ if (extensionDefinition.getExtension() == ((ExtensionDefinition) element).getExtension()) {
+ if (siblings.contains(extensionDefinition.getStereotype())) {
transformIntoAssociation(extensionDefinition);
}
}
}
- } else if(newValue == ExtensionDefinitionKind.GENERALIZATION) {
+ } else if (newValue == ExtensionDefinitionKind.GENERALIZATION) {
- if(((ExtensionDefinition)element).getExtension().getMetaclass().isAbstract()) {
+ if (((ExtensionDefinition) element).getExtension().getMetaclass().isAbstract()) {
MessageDialog.openInformation(Display.getCurrent().getActiveShell(), Messages.ExtensionKindColumnEditingSupport_1, Messages.ExtensionKindColumnEditingSupport_2);
} else {
- if(((ExtensionDefinition)element).getExtension().isRequired()) {
+ if (((ExtensionDefinition) element).getExtension().isRequired()) {
MessageDialog.openInformation(Display.getCurrent().getActiveShell(), Messages.ExtensionKindColumnEditingSupport_3, Messages.ExtensionKindColumnEditingSupport_4);
} else {
- transformIntoGeneralization((ExtensionDefinition)element);
+ transformIntoGeneralization((ExtensionDefinition) element);
// All children and generals must be set to generalization as well
- HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((ExtensionDefinition)element).getStereotype());
+ HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((ExtensionDefinition) element).getStereotype());
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getExtension() == ((ExtensionDefinition)element).getExtension()) {
- if(siblings.contains(extensionDefinition.getStereotype())) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ if (extensionDefinition.getExtension() == ((ExtensionDefinition) element).getExtension()) {
+ if (siblings.contains(extensionDefinition.getStereotype())) {
transformIntoGeneralization(extensionDefinition);
}
}
@@ -203,36 +203,36 @@ public class ExtensionKindColumnEditingSupport extends EditingSupport {
}
}
- } else if(newValue == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ } else if (newValue == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- if(hasOtherExtension((ExtensionDefinition)element) && stereotypeUsedElsewhere((ExtensionDefinition)element)) {
+ if (hasOtherExtension((ExtensionDefinition) element) && stereotypeUsedElsewhere((ExtensionDefinition) element)) {
MessageDialog.openInformation(Display.getCurrent().getActiveShell(), Messages.ExtensionKindColumnEditingSupport_5, Messages.ExtensionKindColumnEditingSupport_6);
} else {
- transformIntoMultiGeneralization((ExtensionDefinition)element);
+ transformIntoMultiGeneralization((ExtensionDefinition) element);
// All children and generals must be set to generalization as well
- HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((ExtensionDefinition)element).getStereotype());
+ HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((ExtensionDefinition) element).getStereotype());
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getExtension() == ((ExtensionDefinition)element).getExtension()) {
- if(siblings.contains(extensionDefinition.getStereotype())) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ if (extensionDefinition.getExtension() == ((ExtensionDefinition) element).getExtension()) {
+ if (siblings.contains(extensionDefinition.getStereotype())) {
transformIntoMultiGeneralization(extensionDefinition);
}
}
}
}
- } else if(newValue == ExtensionDefinitionKind.FUSION) {
- if(hasOtherExtension((ExtensionDefinition)element) && stereotypeUsedElsewhere((ExtensionDefinition)element)) {
+ } else if (newValue == ExtensionDefinitionKind.FUSION) {
+ if (hasOtherExtension((ExtensionDefinition) element) && stereotypeUsedElsewhere((ExtensionDefinition) element)) {
MessageDialog.openInformation(Display.getCurrent().getActiveShell(), Messages.ExtensionKindColumnEditingSupport_7, Messages.ExtensionKindColumnEditingSupport_8);
} else {
- transformIntoFusion((ExtensionDefinition)element);
+ transformIntoFusion((ExtensionDefinition) element);
// All children and generals must be set to generalization as well
- HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((ExtensionDefinition)element).getStereotype());
+ HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((ExtensionDefinition) element).getStereotype());
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getExtension() == ((ExtensionDefinition)element).getExtension()) {
- if(siblings.contains(extensionDefinition.getStereotype())) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ if (extensionDefinition.getExtension() == ((ExtensionDefinition) element).getExtension()) {
+ if (siblings.contains(extensionDefinition.getStereotype())) {
transformIntoFusion(extensionDefinition);
}
}
@@ -263,16 +263,16 @@ public class ExtensionKindColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof ExtensionDefinition) {
- int value = ((ExtensionDefinition)element).getKind().getValue();
+ if (element instanceof ExtensionDefinition) {
+ int value = ((ExtensionDefinition) element).getKind().getValue();
return value;
}
@@ -280,16 +280,16 @@ public class ExtensionKindColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected CellEditor getCellEditor(Object element) {
- if(element instanceof ExtensionDefinition) {
+ if (element instanceof ExtensionDefinition) {
String[] itemsArray = { ExtensionDefinitionKind.ASSOCIATION.getName(), ExtensionDefinitionKind.GENERALIZATION.getName(), ExtensionDefinitionKind.MULTI_GENERALIZATION.getName() };
@@ -302,9 +302,9 @@ public class ExtensionKindColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/IsPossibleColumnEditingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/IsPossibleColumnEditingSupport.java
index 4cfe72a3dba..e77922f6e9b 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/IsPossibleColumnEditingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/IsPossibleColumnEditingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -50,7 +50,7 @@ public class IsPossibleColumnEditingSupport extends EditingSupport {
/**
* Change IsPossible in the model to impossible
- *
+ *
* @param element
*/
protected void transformPossibleIntoImpossible(BaseMetaclass element) {
@@ -61,7 +61,7 @@ public class IsPossibleColumnEditingSupport extends EditingSupport {
/**
* Change IsPossible in the model to possible
- *
+ *
* @param element
*/
protected void transformImpossibleIntoPossible(BaseMetaclass element) {
@@ -73,23 +73,24 @@ public class IsPossibleColumnEditingSupport extends EditingSupport {
/**
* Change IsPossible in the model to impossible and propagate to children and generals
- *
+ *
* @param element
*/
protected void transformAllPossibleIntoImpossible(BaseMetaclass element) {
- Facade facade = ((BaseMetaclass)element).getExtensionDefinition().getFacade();
- transformPossibleIntoImpossible((BaseMetaclass)element);
+ Facade facade = element.getExtensionDefinition().getFacade();
+ transformPossibleIntoImpossible(element);
// All children and generals must be set to Impossible as well
- HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((BaseMetaclass)element).getExtensionDefinition().getStereotype());
+ HashSet<Stereotype> siblings = ProfileUtils.getSiblings(element.getExtensionDefinition().getStereotype());
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getExtension() == ((BaseMetaclass)element).getExtensionDefinition().getExtension()) {
- if(siblings.contains(extensionDefinition.getStereotype())) {
- for(BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses())
- if(baseMetaclass.getBase() == ((BaseMetaclass)element).getBase()) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ if (extensionDefinition.getExtension() == element.getExtensionDefinition().getExtension()) {
+ if (siblings.contains(extensionDefinition.getStereotype())) {
+ for (BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
+ if (baseMetaclass.getBase() == element.getBase()) {
transformPossibleIntoImpossible(baseMetaclass);
}
+ }
}
}
}
@@ -97,40 +98,41 @@ public class IsPossibleColumnEditingSupport extends EditingSupport {
/**
* Change IsPossible in the model to possible and propagate to children and generals
- *
+ *
* @param element
*/
protected void transformAllImpossibleIntoPossible(BaseMetaclass element) {
- Facade facade = ((BaseMetaclass)element).getExtensionDefinition().getFacade();
- transformImpossibleIntoPossible((BaseMetaclass)element);
+ Facade facade = element.getExtensionDefinition().getFacade();
+ transformImpossibleIntoPossible(element);
// All children and generals must be set to Possible as well
- HashSet<Stereotype> siblings = ProfileUtils.getSiblings(((BaseMetaclass)element).getExtensionDefinition().getStereotype());
+ HashSet<Stereotype> siblings = ProfileUtils.getSiblings(element.getExtensionDefinition().getStereotype());
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getExtension() == ((BaseMetaclass)element).getExtensionDefinition().getExtension()) {
- if(siblings.contains(extensionDefinition.getStereotype())) {
- for(BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses())
- if(baseMetaclass.getBase() == ((BaseMetaclass)element).getBase()) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ if (extensionDefinition.getExtension() == element.getExtensionDefinition().getExtension()) {
+ if (siblings.contains(extensionDefinition.getStereotype())) {
+ for (BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
+ if (baseMetaclass.getBase() == element.getBase()) {
transformImpossibleIntoPossible(baseMetaclass);
}
+ }
}
}
}
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(final Object element, final Object value) {
- if(element instanceof BaseMetaclass) {
+ if (element instanceof BaseMetaclass) {
- if(EditionUtils.hasARequiredCombination((BaseMetaclass)element)) {
+ if (EditionUtils.hasARequiredCombination((BaseMetaclass) element)) {
MessageDialog.openInformation(Display.getCurrent().getActiveShell(), Messages.IsPossibleColumnEditingSupport_0, Messages.IsPossibleColumnEditingSupport_1);
} else {
@@ -142,14 +144,14 @@ public class IsPossibleColumnEditingSupport extends EditingSupport {
public void run(IProgressMonitor monitor) {
monitor.beginTask(Messages.IsPossibleColumnEditingSupport_2, IProgressMonitor.UNKNOWN);
- if((Boolean)value == true) {
- transformAllImpossibleIntoPossible((BaseMetaclass)element);
+ if ((Boolean) value == true) {
+ transformAllImpossibleIntoPossible((BaseMetaclass) element);
} else {
- transformAllPossibleIntoImpossible((BaseMetaclass)element);
+ transformAllPossibleIntoImpossible((BaseMetaclass) element);
}
- Facade facade = ((BaseMetaclass)element).getExtensionDefinition().getFacade();
+ Facade facade = ((BaseMetaclass) element).getExtensionDefinition().getFacade();
// Clear incompatibilities that don't exist anymore
EditionUtils.clearAllStereotypeCombinations(facade, editingDomain);
@@ -172,16 +174,16 @@ public class IsPossibleColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected CellEditor getCellEditor(Object element) {
- if(element instanceof BaseMetaclass) {
- if(!((BaseMetaclass)element).getExtensionDefinition().getExtension().isRequired()) {
+ if (element instanceof BaseMetaclass) {
+ if (!((BaseMetaclass) element).getExtensionDefinition().getExtension().isRequired()) {
return new CheckboxCellEditor(parent);
}
}
@@ -189,9 +191,9 @@ public class IsPossibleColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -201,16 +203,16 @@ public class IsPossibleColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof BaseMetaclass) {
- return Boolean.valueOf(((BaseMetaclass)element).isPossible());
+ if (element instanceof BaseMetaclass) {
+ return Boolean.valueOf(((BaseMetaclass) element).isPossible());
}
return null;
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassAliasColumnEditingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassAliasColumnEditingSupport.java
index e18fbdeaeaa..4dde7a1ca54 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassAliasColumnEditingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassAliasColumnEditingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -36,44 +36,44 @@ public class MetaclassAliasColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(Object element, Object value) {
- if(element instanceof VirtualElement) {
- SetCommand command = new SetCommand(editingDomain, (VirtualElement)element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_AliasName(), (String)value); //$NON-NLS-1$
+ if (element instanceof VirtualElement) {
+ SetCommand command = new SetCommand(editingDomain, (VirtualElement) element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_AliasName(), (String) value);
editingDomain.getCommandStack().execute(command);
getViewer().refresh();
}
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof VirtualElement) {
- if(((VirtualElement)element).getAliasName() == null) {
+ if (element instanceof VirtualElement) {
+ if (((VirtualElement) element).getAliasName() == null) {
return ""; //$NON-NLS-1$
} else {
- return ((VirtualElement)element).getAliasName();
+ return ((VirtualElement) element).getAliasName();
}
}
return null;
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -83,9 +83,9 @@ public class MetaclassAliasColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassIsAbstractColumnEditingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassIsAbstractColumnEditingSupport.java
index 8531c561cce..1b04f4ac7dd 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassIsAbstractColumnEditingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassIsAbstractColumnEditingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -37,17 +37,17 @@ public class MetaclassIsAbstractColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected CellEditor getCellEditor(Object element) {
- if(element instanceof VirtualMetaclass) {
+ if (element instanceof VirtualMetaclass) {
- if(MetamodelUtils.canBeAbstract((VirtualMetaclass)element)) {
+ if (MetamodelUtils.canBeAbstract((VirtualMetaclass) element)) {
return new CheckboxCellEditor(parent);
}
}
@@ -56,9 +56,9 @@ public class MetaclassIsAbstractColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -68,32 +68,32 @@ public class MetaclassIsAbstractColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof VirtualMetaclass) {
- return Boolean.valueOf(((VirtualMetaclass)element).isAbstract());
+ if (element instanceof VirtualMetaclass) {
+ return Boolean.valueOf(((VirtualMetaclass) element).isAbstract());
}
return null;
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(Object element, Object value) {
- if(element instanceof VirtualMetaclass) {
+ if (element instanceof VirtualMetaclass) {
- SetCommand command = new SetCommand(editingDomain, (VirtualMetaclass)element, VirtualmetamodelPackage.eINSTANCE.getVirtualMetaclass_Abstract(), (Boolean)value); //$NON-NLS-1$
+ SetCommand command = new SetCommand(editingDomain, (VirtualMetaclass) element, VirtualmetamodelPackage.eINSTANCE.getVirtualMetaclass_Abstract(), (Boolean) value);
editingDomain.getCommandStack().execute(command);
getViewer().refresh();
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassToKeepColumnEditingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassToKeepColumnEditingSupport.java
index c17545dc1c5..a8650e00470 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassToKeepColumnEditingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassToKeepColumnEditingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -42,25 +42,25 @@ public class MetaclassToKeepColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(Object element, Object value) {
- if(element instanceof VirtualElement) {
+ if (element instanceof VirtualElement) {
VirtualMetamodel metamodel = facade.getVirtualmetamodel();
- if((Boolean)value == false) {
- if(PrunerUtils.classifierUnkeep((VirtualElement)element, metamodel, editingDomain)) {
+ if ((Boolean) value == false) {
+ if (PrunerUtils.classifierUnkeep((VirtualElement) element, metamodel, editingDomain)) {
getViewer().refresh();
}
} else {
- SetCommand command = new SetCommand(editingDomain, (VirtualElement)element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_Kept(), (Boolean)value); //$NON-NLS-1$
+ SetCommand command = new SetCommand(editingDomain, (VirtualElement) element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_Kept(), (Boolean) value);
editingDomain.getCommandStack().execute(command);
getViewer().refresh();
}
@@ -69,24 +69,24 @@ public class MetaclassToKeepColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof VirtualElement) {
- return Boolean.valueOf(((VirtualElement)element).isKept());
+ if (element instanceof VirtualElement) {
+ return Boolean.valueOf(((VirtualElement) element).isKept());
}
return null;
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -98,9 +98,9 @@ public class MetaclassToKeepColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassUseRepresentedColumnEditingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassUseRepresentedColumnEditingSupport.java
index 73686c74159..47848246cd8 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassUseRepresentedColumnEditingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/MetaclassUseRepresentedColumnEditingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -37,15 +37,15 @@ public class MetaclassUseRepresentedColumnEditingSupport extends EditingSupport
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected CellEditor getCellEditor(Object element) {
- if(element instanceof VirtualElement) {
+ if (element instanceof VirtualElement) {
return new CheckboxCellEditor(parent);
}
@@ -53,9 +53,9 @@ public class MetaclassUseRepresentedColumnEditingSupport extends EditingSupport
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -65,32 +65,32 @@ public class MetaclassUseRepresentedColumnEditingSupport extends EditingSupport
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof VirtualElement) {
- return Boolean.valueOf(((VirtualElement)element).isUseRepresented());
+ if (element instanceof VirtualElement) {
+ return Boolean.valueOf(((VirtualElement) element).isUseRepresented());
}
return null;
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(Object element, Object value) {
- if(element instanceof VirtualMetaclass) {
+ if (element instanceof VirtualMetaclass) {
- SetCommand command = new SetCommand(editingDomain, (VirtualMetaclass)element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_UseRepresented(), (Boolean)value); //$NON-NLS-1$
+ SetCommand command = new SetCommand(editingDomain, (VirtualMetaclass) element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_UseRepresented(), (Boolean) value);
editingDomain.getCommandStack().execute(command);
getViewer().refresh();
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesAliasColumnEdintingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesAliasColumnEdintingSupport.java
index 868c785dfca..b3fdc0b8d74 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesAliasColumnEdintingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesAliasColumnEdintingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -36,44 +36,44 @@ public class PropertiesAliasColumnEdintingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(Object element, Object value) {
- if(element instanceof VirtualElement) {
- SetCommand command = new SetCommand(editingDomain, (VirtualElement)element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_AliasName(), (String)value); //$NON-NLS-1$
+ if (element instanceof VirtualElement) {
+ SetCommand command = new SetCommand(editingDomain, (VirtualElement) element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_AliasName(), (String) value);
editingDomain.getCommandStack().execute(command);
getViewer().refresh();
}
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof VirtualElement) {
- if(((VirtualElement)element).getAliasName() == null) {
+ if (element instanceof VirtualElement) {
+ if (((VirtualElement) element).getAliasName() == null) {
return ""; //$NON-NLS-1$
} else {
- return ((VirtualElement)element).getAliasName();
+ return ((VirtualElement) element).getAliasName();
}
}
return null;
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -85,9 +85,9 @@ public class PropertiesAliasColumnEdintingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMaxColumnEdintingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMaxColumnEdintingSupport.java
index 79cfb5b0b7f..bb0bb73d19f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMaxColumnEdintingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMaxColumnEdintingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -42,35 +42,35 @@ public class PropertiesMaxColumnEdintingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(Object element, Object value) {
- if(element instanceof VirtualTypedElement) {
+ if (element instanceof VirtualTypedElement) {
try {
- if(((VirtualTypedElement)element).getRepresentedElement() instanceof MultiplicityElement || ((VirtualTypedElement)element).getRepresentedElement() instanceof ETypedElement) {
+ if (((VirtualTypedElement) element).getRepresentedElement() instanceof MultiplicityElement || ((VirtualTypedElement) element).getRepresentedElement() instanceof ETypedElement) {
boolean isOk = false;
- int intValue = Integer.valueOf((String)value);
+ int intValue = Integer.valueOf((String) value);
- if(intValue >= -1) {
+ if (intValue >= -1) {
int upperReference = 0;
- if(((VirtualTypedElement)element).getRepresentedElement() instanceof MultiplicityElement) {
- upperReference = ((MultiplicityElement)((VirtualTypedElement)element).getRepresentedElement()).getUpper();
+ if (((VirtualTypedElement) element).getRepresentedElement() instanceof MultiplicityElement) {
+ upperReference = ((MultiplicityElement) ((VirtualTypedElement) element).getRepresentedElement()).getUpper();
- } else if(((VirtualTypedElement)element).getRepresentedElement() instanceof ETypedElement) {
- upperReference = ((ETypedElement)((VirtualTypedElement)element).getRepresentedElement()).getUpperBound();
+ } else if (((VirtualTypedElement) element).getRepresentedElement() instanceof ETypedElement) {
+ upperReference = ((ETypedElement) ((VirtualTypedElement) element).getRepresentedElement()).getUpperBound();
}
- if(upperReference != -1) {
- if(intValue != -1) {
- if(intValue <= upperReference) {
+ if (upperReference != -1) {
+ if (intValue != -1) {
+ if (intValue <= upperReference) {
isOk = true;
}
}
@@ -79,8 +79,8 @@ public class PropertiesMaxColumnEdintingSupport extends EditingSupport {
isOk = true;
}
- if(isOk) {
- SetCommand command = new SetCommand(editingDomain, (VirtualTypedElement)element, VirtualmetamodelPackage.eINSTANCE.getVirtualTypedElement_Upper(), intValue); //$NON-NLS-1$
+ if (isOk) {
+ SetCommand command = new SetCommand(editingDomain, (VirtualTypedElement) element, VirtualmetamodelPackage.eINSTANCE.getVirtualTypedElement_Upper(), intValue);
editingDomain.getCommandStack().execute(command);
getViewer().refresh();
} else {
@@ -98,32 +98,32 @@ public class PropertiesMaxColumnEdintingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof VirtualTypedElement) {
+ if (element instanceof VirtualTypedElement) {
- return ((VirtualTypedElement)element).getUpper() + ""; //$NON-NLS-1$
+ return ((VirtualTypedElement) element).getUpper() + ""; //$NON-NLS-1$
}
return null;
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected CellEditor getCellEditor(Object element) {
- if(element instanceof VirtualTypedElement) {
+ if (element instanceof VirtualTypedElement) {
return new TextCellEditor(parent);
}
@@ -131,15 +131,15 @@ public class PropertiesMaxColumnEdintingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected boolean canEdit(Object element) {
- if(element instanceof VirtualProperty) {
+ if (element instanceof VirtualProperty) {
return true;
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMinColumnEdintingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMinColumnEdintingSupport.java
index 8f62674c1f0..d901b677d3b 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMinColumnEdintingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesMinColumnEdintingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -42,40 +42,40 @@ public class PropertiesMinColumnEdintingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(Object element, Object value) {
- if(element instanceof VirtualTypedElement) {
+ if (element instanceof VirtualTypedElement) {
try {
- if(((VirtualTypedElement)element).getRepresentedElement() instanceof MultiplicityElement || ((VirtualTypedElement)element).getRepresentedElement() instanceof ETypedElement) {
+ if (((VirtualTypedElement) element).getRepresentedElement() instanceof MultiplicityElement || ((VirtualTypedElement) element).getRepresentedElement() instanceof ETypedElement) {
boolean isOk = false;
- int intValue = Integer.valueOf((String)value);
+ int intValue = Integer.valueOf((String) value);
- if(intValue >= -1) {
+ if (intValue >= -1) {
int lowerReference = 0;
- if(((VirtualTypedElement)element).getRepresentedElement() instanceof MultiplicityElement) {
- lowerReference = ((MultiplicityElement)((VirtualTypedElement)element).getRepresentedElement()).getLower();
+ if (((VirtualTypedElement) element).getRepresentedElement() instanceof MultiplicityElement) {
+ lowerReference = ((MultiplicityElement) ((VirtualTypedElement) element).getRepresentedElement()).getLower();
- } else if(((VirtualTypedElement)element).getRepresentedElement() instanceof ETypedElement) {
- lowerReference = ((ETypedElement)((VirtualTypedElement)element).getRepresentedElement()).getLowerBound();
+ } else if (((VirtualTypedElement) element).getRepresentedElement() instanceof ETypedElement) {
+ lowerReference = ((ETypedElement) ((VirtualTypedElement) element).getRepresentedElement()).getLowerBound();
}
- if(lowerReference != -1) {
- if(intValue >= lowerReference) {
+ if (lowerReference != -1) {
+ if (intValue >= lowerReference) {
isOk = true;
}
}
- if(isOk) {
- SetCommand command = new SetCommand(editingDomain, (VirtualTypedElement)element, VirtualmetamodelPackage.eINSTANCE.getVirtualTypedElement_Lower(), intValue); //$NON-NLS-1$
+ if (isOk) {
+ SetCommand command = new SetCommand(editingDomain, (VirtualTypedElement) element, VirtualmetamodelPackage.eINSTANCE.getVirtualTypedElement_Lower(), intValue);
editingDomain.getCommandStack().execute(command);
getViewer().refresh();
} else {
@@ -93,32 +93,32 @@ public class PropertiesMinColumnEdintingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof VirtualTypedElement) {
+ if (element instanceof VirtualTypedElement) {
- return ((VirtualTypedElement)element).getLower() + ""; //$NON-NLS-1$
+ return ((VirtualTypedElement) element).getLower() + ""; //$NON-NLS-1$
}
return null;
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected CellEditor getCellEditor(Object element) {
- if(element instanceof VirtualTypedElement) {
+ if (element instanceof VirtualTypedElement) {
return new TextCellEditor(parent);
}
@@ -126,15 +126,15 @@ public class PropertiesMinColumnEdintingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected boolean canEdit(Object element) {
- if(element instanceof VirtualProperty) {
+ if (element instanceof VirtualProperty) {
return true;
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesToKeepColumnEditingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesToKeepColumnEditingSupport.java
index 536b683afb3..9ad46add07e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesToKeepColumnEditingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/PropertiesToKeepColumnEditingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -42,24 +42,24 @@ public class PropertiesToKeepColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(Object element, Object value) {
- if(element instanceof VirtualElement) {
+ if (element instanceof VirtualElement) {
boolean canBeUnkept = true;
- if(element instanceof VirtualProperty) {
- if(((VirtualElement)element).getRepresentedElement() instanceof EStructuralFeature) {
- if(((EStructuralFeature)((VirtualElement)element).getRepresentedElement()).getLowerBound() > 0) {
+ if (element instanceof VirtualProperty) {
+ if (((VirtualElement) element).getRepresentedElement() instanceof EStructuralFeature) {
+ if (((EStructuralFeature) ((VirtualElement) element).getRepresentedElement()).getLowerBound() > 0) {
canBeUnkept = false;
MessageDialog.openWarning(Display.getCurrent().getActiveShell(), Messages.PropertiesToKeepColumnEditingSupport_0, Messages.PropertiesToKeepColumnEditingSupport_1);
}
- } else if(((VirtualElement)element).getRepresentedElement() instanceof Property) {
- if(((Property)((VirtualElement)element).getRepresentedElement()).getLower() > 0) {
+ } else if (((VirtualElement) element).getRepresentedElement() instanceof Property) {
+ if (((Property) ((VirtualElement) element).getRepresentedElement()).getLower() > 0) {
canBeUnkept = false;
MessageDialog.openWarning(Display.getCurrent().getActiveShell(), Messages.PropertiesToKeepColumnEditingSupport_2, Messages.PropertiesToKeepColumnEditingSupport_3);
}
@@ -67,8 +67,8 @@ public class PropertiesToKeepColumnEditingSupport extends EditingSupport {
}
- if(canBeUnkept) {
- SetCommand command = new SetCommand(editingDomain, (VirtualElement)element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_Kept(), (Boolean)value); //$NON-NLS-1$
+ if (canBeUnkept) {
+ SetCommand command = new SetCommand(editingDomain, (VirtualElement) element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_Kept(), (Boolean) value);
editingDomain.getCommandStack().execute(command);
getViewer().refresh();
}
@@ -76,24 +76,24 @@ public class PropertiesToKeepColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof VirtualElement) {
- return Boolean.valueOf(((VirtualElement)element).isKept());
+ if (element instanceof VirtualElement) {
+ return Boolean.valueOf(((VirtualElement) element).isKept());
}
return null;
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -103,9 +103,9 @@ public class PropertiesToKeepColumnEditingSupport extends EditingSupport {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/StereotypeIncompatibilityColumnEditingSupport.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/StereotypeIncompatibilityColumnEditingSupport.java
index 30a0e5c20e7..850da2dfa0b 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/StereotypeIncompatibilityColumnEditingSupport.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/editingSupport/StereotypeIncompatibilityColumnEditingSupport.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -51,20 +51,20 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
/**
* Change a compatibility between stereotype application to incompatible in the model
- *
+ *
* @param baseMetaclass
* @param combinaison
*/
protected void transformCompatibleIntoIncompatible(BaseMetaclass baseMetaclass, Combination combinaison) {
- AddCommand command = new AddCommand(editingDomain, baseMetaclass, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_IncompatibleStereotypes(), combinaison); //$NON-NLS-1$
+ AddCommand command = new AddCommand(editingDomain, baseMetaclass, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_IncompatibleStereotypes(), combinaison);
editingDomain.getCommandStack().execute(command);
- RemoveCommand removeCommand = new RemoveCommand(editingDomain, baseMetaclass, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_CompatibleStereotypes(), combinaison); //$NON-NLS-1$
+ RemoveCommand removeCommand = new RemoveCommand(editingDomain, baseMetaclass, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_CompatibleStereotypes(), combinaison);
editingDomain.getCommandStack().execute(removeCommand);
}
/**
* Change a compatibility between stereotype application to incompatible in the model
- *
+ *
* @param baseMetaclass
* @param combinaison
*/
@@ -75,20 +75,20 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
/**
* Change a compatibility between stereotype application to compatible in the model
- *
+ *
* @param baseMetaclass
* @param combinaison
*/
protected void transformImcompatibleIntoCompatible(BaseMetaclass baseMetaclass, Combination combinaison) {
- RemoveCommand removeCommand = new RemoveCommand(editingDomain, baseMetaclass, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_IncompatibleStereotypes(), combinaison); //$NON-NLS-1$
+ RemoveCommand removeCommand = new RemoveCommand(editingDomain, baseMetaclass, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_IncompatibleStereotypes(), combinaison);
editingDomain.getCommandStack().execute(removeCommand);
- AddCommand addCommand = new AddCommand(editingDomain, baseMetaclass, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_CompatibleStereotypes(), combinaison); //$NON-NLS-1$
+ AddCommand addCommand = new AddCommand(editingDomain, baseMetaclass, ExtensiondefinitionPackage.eINSTANCE.getBaseMetaclass_CompatibleStereotypes(), combinaison);
editingDomain.getCommandStack().execute(addCommand);
}
/**
* Change a compatibility between stereotype application to compatible in the model
- *
+ *
* @param baseMetaclass
* @param combinaison
*/
@@ -99,23 +99,23 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
/**
* Used to propagate compatibilities and incompatibilities among stereotype applications
- *
+ *
* @param combination
* @param iAmNotARequired
*/
protected void proceedTheOtherWayCompatibleIntoIncompatible(Combination combination, boolean iAmNotARequired) {
- for(BaseMetaclass meta : ((Combination)combination).getMembers()) {
+ for (BaseMetaclass meta : combination.getMembers()) {
// Build fake Combination that contain all the basemetaclass of the combinaison except the basemetaclass we are processing
Combination fakeCombination = ExtensiondefinitionFactory.eINSTANCE.createCombination();
- for(BaseMetaclass metaFake : ((Combination)combination).getMembers()) {
- if(meta != metaFake) {
+ for (BaseMetaclass metaFake : combination.getMembers()) {
+ if (meta != metaFake) {
fakeCombination.getMembers().add(metaFake);
}
}
// fake Combination + the general basemetaclass that own this combinaison
- if(iAmNotARequired) {
- BaseMetaclass containerBaseMetaClass = (BaseMetaclass)((Combination)combination).eContainer();
+ if (iAmNotARequired) {
+ BaseMetaclass containerBaseMetaClass = (BaseMetaclass) combination.eContainer();
BaseMetaclass general = containerBaseMetaClass;
fakeCombination.getMembers().add(general);
}
@@ -123,7 +123,7 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
// if (!EditionUtils.containsOnlyRequired(fakeCombination)) {
// We go through the compatible combinaison of this basemeta and try to find the fake
Combination combinaison = EditionUtils.getCombinationThatMatch(meta.getCompatibleStereotypes(), fakeCombination);
- if(combinaison != null) {
+ if (combinaison != null) {
transformAllCompatibleIntoIncompatible(meta, combinaison);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.StereotypeIncompatibilityColumnEditingSupport_0);
@@ -134,23 +134,23 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
/**
* Used to propagate compatibilities and incompatibilities among stereotype applications
- *
+ *
* @param combination
* @param iAmNotARequired
*/
protected void proceedTheOtherWayImcompatibleIntoCompatible(Combination combination, boolean iAmNotARequired) {
- for(BaseMetaclass meta : ((Combination)combination).getMembers()) {
+ for (BaseMetaclass meta : combination.getMembers()) {
// Build fake Combination that contain all the basemetaclass of the combinaison except the basemetaclass we are processing
Combination fakeCombination = ExtensiondefinitionFactory.eINSTANCE.createCombination();
- for(BaseMetaclass metaFake : ((Combination)combination).getMembers()) {
- if(meta != metaFake) {
+ for (BaseMetaclass metaFake : combination.getMembers()) {
+ if (meta != metaFake) {
fakeCombination.getMembers().add(metaFake);
}
}
// fake Combination + the basemetaclass that own this combinaison
- if(iAmNotARequired) {
- BaseMetaclass containerBaseMetaClass = (BaseMetaclass)((Combination)combination).eContainer();
- // BaseMetaclass general = findCorrespondingGeneral(containerBaseMetaClass);
+ if (iAmNotARequired) {
+ BaseMetaclass containerBaseMetaClass = (BaseMetaclass) combination.eContainer();
+ // BaseMetaclass general = findCorrespondingGeneral(containerBaseMetaClass);
BaseMetaclass general = containerBaseMetaClass;
fakeCombination.getMembers().add(general);
}
@@ -158,7 +158,7 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
// if (!EditionUtils.containsOnlyRequired(fakeCombination)) {
// We go through the incompatible combinaison of this basemeta and try to find the fake
Combination combinaison = EditionUtils.getCombinationThatMatch(meta.getIncompatibleStereotypes(), fakeCombination);
- if(combinaison != null) {
+ if (combinaison != null) {
transformAllImcompatibleIntoCompatible(meta, combinaison);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.StereotypeIncompatibilityColumnEditingSupport_1);
@@ -170,7 +170,7 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
/**
* Set a combination of stereotype application to incompatible
- *
+ *
* @param baseMetaclass
* @param combination
* @param bothWays
@@ -182,26 +182,26 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
/**
* Set a combination of stereotype application to compatible
- *
+ *
* @param baseMetaclass
* @param combination
* @param bothWays
*/
protected void makeItCompatible(BaseMetaclass baseMetaclass, Combination combination, boolean bothWays) {
- transformAllImcompatibleIntoCompatible(baseMetaclass, (Combination)combination);
+ transformAllImcompatibleIntoCompatible(baseMetaclass, combination);
proceedTheOtherWayImcompatibleIntoCompatible(combination, true);
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#setValue(java.lang.Object, java.lang.Object)
- *
+ *
* @param element
* @param value
*/
@Override
protected void setValue(final Object element, final Object value) {
- if(element instanceof Combination) {
+ if (element instanceof Combination) {
ProgressMonitorDialog dialog = new ProgressMonitorDialog(Display.getCurrent().getActiveShell());
try {
@@ -211,17 +211,17 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
monitor.beginTask(Messages.StereotypeIncompatibilityColumnEditingSupport_2, IProgressMonitor.UNKNOWN);
ISelection selection = FacadeSpecificEditor.getExtensionDefintionTreeViewer().getSelection();
- if(selection instanceof IStructuredSelection) {
- Object first = ((IStructuredSelection)selection).getFirstElement();
+ if (selection instanceof IStructuredSelection) {
+ Object first = ((IStructuredSelection) selection).getFirstElement();
- if(first instanceof BaseMetaclass) {
- BaseMetaclass baseMetaclass = (BaseMetaclass)first;
+ if (first instanceof BaseMetaclass) {
+ BaseMetaclass baseMetaclass = (BaseMetaclass) first;
- if((Boolean)value == false) {
- makeItImcompatible(baseMetaclass, (Combination)element, true);
+ if ((Boolean) value == false) {
+ makeItImcompatible(baseMetaclass, (Combination) element, true);
} else {
// Make it compatible
- makeItCompatible(baseMetaclass, (Combination)element, true);
+ makeItCompatible(baseMetaclass, (Combination) element, true);
}
@@ -243,22 +243,22 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getValue(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@Override
protected Object getValue(Object element) {
- if(element instanceof Combination) {
+ if (element instanceof Combination) {
ISelection selection = FacadeSpecificEditor.getExtensionDefintionTreeViewer().getSelection();
- if(selection instanceof IStructuredSelection) {
- Object first = ((IStructuredSelection)selection).getFirstElement();
+ if (selection instanceof IStructuredSelection) {
+ Object first = ((IStructuredSelection) selection).getFirstElement();
- if(first instanceof BaseMetaclass) {
- EList<Combination> incompatibleStereotypes = ((BaseMetaclass)first).getIncompatibleStereotypes();
- if(incompatibleStereotypes.contains(element)) {
+ if (first instanceof BaseMetaclass) {
+ EList<Combination> incompatibleStereotypes = ((BaseMetaclass) first).getIncompatibleStereotypes();
+ if (incompatibleStereotypes.contains(element)) {
return Boolean.valueOf(false);
} else {
return Boolean.valueOf(true);
@@ -271,9 +271,9 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#getCellEditor(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -283,9 +283,9 @@ public class StereotypeIncompatibilityColumnEditingSupport extends EditingSuppor
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.EditingSupport#canEdit(java.lang.Object)
- *
+ *
* @param element
* @return
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/CreatePreliminaryMetamodelListener.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/CreatePreliminaryMetamodelListener.java
index 4e8a2cb7b0c..07b5b8793df 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/CreatePreliminaryMetamodelListener.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/CreatePreliminaryMetamodelListener.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -57,20 +57,20 @@ public class CreatePreliminaryMetamodelListener extends MouseAdapter {
/**
* Interpret the extension as a Generalization and therefore generate the metaclass accordingly
- *
+ *
* @param extensionDefinition
*/
protected void initGeneralization(ExtensionDefinition extensionDefinition) {
BaseMetaclass baseMetaclass = MetamodelUtils.findActualBaseMetaclass(extensionDefinition);
- if(baseMetaclass != null) {
+ if (baseMetaclass != null) {
ArrayList<BaseMetaclass> stereotypes = new ArrayList<BaseMetaclass>();
stereotypes.add(baseMetaclass);
MetamodelUtils.addMetaclass(StereotypeUtils.findBase(extensionDefinition), stereotypes, extensionDefinition.getStereotype().getName(), facade, editingDomain);
- if(MetamodelUtils.hasSiblings(extensionDefinition)) {
- //Create a Stereotype interface
+ if (MetamodelUtils.hasSiblings(extensionDefinition)) {
+ // Create a Stereotype interface
MetamodelUtils.addStereotypeInterface(baseMetaclass.getExtensionDefinition().getStereotype(), baseMetaclass.getExtensionDefinition().getStereotype().getName() + "_applied", facade, editingDomain);
}
@@ -81,29 +81,29 @@ public class CreatePreliminaryMetamodelListener extends MouseAdapter {
/**
* Interpret the extension as an Association and therefore generate the metaclass accordingly
- *
+ *
* @param extensionDefinition
*/
protected void initAssociation(ExtensionDefinition extensionDefinition) {
BaseMetaclass baseMetaclass = MetamodelUtils.findActualBaseMetaclass(extensionDefinition);
- if(baseMetaclass != null) {
+ if (baseMetaclass != null) {
ArrayList<BaseMetaclass> stereotypes = new ArrayList<BaseMetaclass>();
stereotypes.add(baseMetaclass);
- String name = ((EClass)baseMetaclass.getBase()).getName() + "_" + baseMetaclass.getExtensionDefinition().getStereotype().getName();
+ String name = ((EClass) baseMetaclass.getBase()).getName() + "_" + baseMetaclass.getExtensionDefinition().getStereotype().getName();
MetamodelUtils.addMetaclass(baseMetaclass.getBase(), stereotypes, name, facade, editingDomain);
- //Create property in the virtualmetaclass that represents the base metaclass to facilitate navigation
- if(MetamodelUtils.isActualExtensionDefinition(extensionDefinition)) {
- //Find the base metaclass
- VirtualMetaclass virtualMetaclass = MetamodelUtils.findMetaclassWithNoRealStereoThatMatch((EClass)baseMetaclass.getBase(), facade);
- //Add the property
+ // Create property in the virtualmetaclass that represents the base metaclass to facilitate navigation
+ if (MetamodelUtils.isActualExtensionDefinition(extensionDefinition)) {
+ // Find the base metaclass
+ VirtualMetaclass virtualMetaclass = MetamodelUtils.findMetaclassWithNoRealStereoThatMatch(baseMetaclass.getBase(), facade);
+ // Add the property
MetamodelUtils.addProperty(virtualMetaclass, extensionDefinition.getExtension().getMemberEnds().get(0), extensionDefinition.getExtension().getMemberEnds().get(0).getType(), name, facade, editingDomain);
}
- if(MetamodelUtils.hasSiblings(extensionDefinition)) {
- //Create a Stereotype interface
+ if (MetamodelUtils.hasSiblings(extensionDefinition)) {
+ // Create a Stereotype interface
MetamodelUtils.addStereotypeInterface(baseMetaclass.getExtensionDefinition().getStereotype(), baseMetaclass.getExtensionDefinition().getStereotype().getName() + "_applied", facade, editingDomain);
}
}
@@ -111,53 +111,53 @@ public class CreatePreliminaryMetamodelListener extends MouseAdapter {
/**
* Interpret the extension as a MultiGeneralization and therefore generate the metaclass accordingly
- *
+ *
* @param extensionDefinition
*/
protected void initMultiGeneralization(ExtensionDefinition extensionDefinition) {
// Prepare possible METACLASS combinations
HashMap<EClass, ArrayList<Combination>> possibleMetaclasses = new HashMap<EClass, ArrayList<Combination>>();
- for(BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
+ for (BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
ArrayList<Combination> possibleCombinations = new ArrayList<Combination>();
- if(possibleMetaclasses.containsKey(baseMetaclass.getBase())) {
+ if (possibleMetaclasses.containsKey(baseMetaclass.getBase())) {
possibleCombinations = possibleMetaclasses.get(baseMetaclass.getBase());
}
// If I am possible I am a combination
- if(baseMetaclass.isPossible()) {
+ if (baseMetaclass.isPossible()) {
Combination combination = ExtensiondefinitionFactory.eINSTANCE.createCombination();
combination.getMembers().add(baseMetaclass);
- if(!EditionUtils.containsCombination(possibleCombinations, combination)) {
+ if (!EditionUtils.containsCombination(possibleCombinations, combination)) {
possibleCombinations.add(combination);
}
}
// I take the compatible combination
- for(Combination possibleCombination : baseMetaclass.getCompatibleStereotypes()) {
+ for (Combination possibleCombination : baseMetaclass.getCompatibleStereotypes()) {
Combination combination = ExtensiondefinitionFactory.eINSTANCE.createCombination();
combination.getMembers().add(baseMetaclass);
combination.getMembers().addAll(possibleCombination.getMembers());
- if(!EditionUtils.containsCombination(possibleCombinations, combination)) {
+ if (!EditionUtils.containsCombination(possibleCombinations, combination)) {
possibleCombinations.add(combination);
}
}
- possibleMetaclasses.put((EClass)baseMetaclass.getBase(), possibleCombinations);
+ possibleMetaclasses.put((EClass) baseMetaclass.getBase(), possibleCombinations);
}
// Generate the possible METACLASS combinations
- for(EClass representedElement : possibleMetaclasses.keySet()) {
- for(Combination combination : possibleMetaclasses.get(representedElement)) {
+ for (EClass representedElement : possibleMetaclasses.keySet()) {
+ for (Combination combination : possibleMetaclasses.get(representedElement)) {
MetamodelUtils.addMetaclass(representedElement, combination.getMembers(), createName(representedElement, combination), facade, editingDomain);
- //Each stereotype that is used in a MultiGeneralization must be declared as a Stereotype interface
- for(BaseMetaclass baseMetaclass : combination.getMembers()) {
+ // Each stereotype that is used in a MultiGeneralization must be declared as a Stereotype interface
+ for (BaseMetaclass baseMetaclass : combination.getMembers()) {
Stereotype stereotype = baseMetaclass.getExtensionDefinition().getStereotype();
MetamodelUtils.addStereotypeInterface(stereotype, stereotype.getName() + "_applied", facade, editingDomain);
}
@@ -168,24 +168,24 @@ public class CreatePreliminaryMetamodelListener extends MouseAdapter {
/**
* Interpret the extension as a Fusion and therefore generate the metaclass accordingly
- *
+ *
* @param extensionDefinition
*/
protected void initFusion(ExtensionDefinition extensionDefinition) {
- if(extensionDefinition.getStereotype().getGenerals().isEmpty()) {
- //Find virtualmetaclass that will be fusion with
+ if (extensionDefinition.getStereotype().getGenerals().isEmpty()) {
+ // Find virtualmetaclass that will be fusion with
VirtualMetaclass toFusionWith = MetamodelUtils.findMetaclassWithNoRealStereoThatMatch(StereotypeUtils.findBase(extensionDefinition), facade);
BaseMetaclass baseMetaclass = MetamodelUtils.findActualBaseMetaclass(extensionDefinition);
- if(baseMetaclass != null) {
- //Add the stereotype to fusion to the virtualmetaclasse that represent the base metaclass of the stereotype
- if(!toFusionWith.getAppliedStereotypes().contains(baseMetaclass)) {
+ if (baseMetaclass != null) {
+ // Add the stereotype to fusion to the virtualmetaclasse that represent the base metaclass of the stereotype
+ if (!toFusionWith.getAppliedStereotypes().contains(baseMetaclass)) {
toFusionWith.getAppliedStereotypes().add(baseMetaclass);
}
}
} else {
- //For the stereotype that inherit from the stereotype to fusion with the base metaclss, create corresponding virtualmetaclasses
+ // For the stereotype that inherit from the stereotype to fusion with the base metaclss, create corresponding virtualmetaclasses
BaseMetaclass baseMetaclass = MetamodelUtils.findActualBaseMetaclass(extensionDefinition);
ArrayList<BaseMetaclass> stereotypes = new ArrayList<BaseMetaclass>();
stereotypes.add(baseMetaclass);
@@ -199,23 +199,23 @@ public class CreatePreliminaryMetamodelListener extends MouseAdapter {
protected void initMetamodel() {
// Generate for the UML metamodel
- for(EClassifier classifier : umlMetamodel.getEClassifiers()) {
+ for (EClassifier classifier : umlMetamodel.getEClassifiers()) {
MetamodelUtils.createForType(classifier, facade, editingDomain);
}
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getKind() == ExtensionDefinitionKind.GENERALIZATION) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ if (extensionDefinition.getKind() == ExtensionDefinitionKind.GENERALIZATION) {
initGeneralization(extensionDefinition);
- } else if(extensionDefinition.getKind() == ExtensionDefinitionKind.FUSION) {
+ } else if (extensionDefinition.getKind() == ExtensionDefinitionKind.FUSION) {
initFusion(extensionDefinition);
- } else if(extensionDefinition.getKind() == ExtensionDefinitionKind.ASSOCIATION) {
+ } else if (extensionDefinition.getKind() == ExtensionDefinitionKind.ASSOCIATION) {
initAssociation(extensionDefinition);
- } else if(extensionDefinition.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ } else if (extensionDefinition.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
initMultiGeneralization(extensionDefinition);
}
}
- // initStereotypeInterfaces();
+ // initStereotypeInterfaces();
initAbstractMetaclasses(MetamodelUtils.getOnlyVirtualMetaclasses(facade.getVirtualmetamodel().getVirtualClassifiers()));
@@ -230,35 +230,35 @@ public class CreatePreliminaryMetamodelListener extends MouseAdapter {
MetamodelUtils.postProcessUseRepresented(facade, editingDomain);
}
- // private void initStereotypeInterfaces() {
- // for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- // if(classifier instanceof VirtualMetaclass) {
- // if(!MetamodelUtils.onlyOneKind(((VirtualMetaclass)classifier).getAppliedStereotypes())) {
- // List<Stereotype> stereotypes = MetamodelUtils.getStereotypesFromBaseMetaclass(((VirtualMetaclass)classifier).getAppliedStereotypes());
- // if(stereotypes.size() == 1) {
- //
- // } else {
- // org.eclipse.papyrus.facadeSpecificEditor.Activator.log.info("initStereotypeInterfaces: Error with number of different applied stereotypes");
- // }
- // }
- // }
- // }
- // }
+ // private void initStereotypeInterfaces() {
+ // for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ // if(classifier instanceof VirtualMetaclass) {
+ // if(!MetamodelUtils.onlyOneKind(((VirtualMetaclass)classifier).getAppliedStereotypes())) {
+ // List<Stereotype> stereotypes = MetamodelUtils.getStereotypesFromBaseMetaclass(((VirtualMetaclass)classifier).getAppliedStereotypes());
+ // if(stereotypes.size() == 1) {
+ //
+ // } else {
+ // org.eclipse.papyrus.facadeSpecificEditor.Activator.log.info("initStereotypeInterfaces: Error with number of different applied stereotypes");
+ // }
+ // }
+ // }
+ // }
+ // }
/**
* Set the isAbstract value each virtualMetaclass
- *
+ *
* @param list
*/
protected void initAbstractMetaclasses(List<VirtualMetaclass> list) {
- for(VirtualMetaclass metaclass : list) {
+ for (VirtualMetaclass metaclass : list) {
metaclass.setAbstract(MetamodelUtils.mustBeAbstract(metaclass));
}
}
/**
* Generate a name that is meaningful using a combination of applied stereotypes
- *
+ *
* @param representedElement
* @param combination
* @return
@@ -267,7 +267,7 @@ public class CreatePreliminaryMetamodelListener extends MouseAdapter {
protected String createName(EClass representedElement, Combination combination) {
String name = representedElement.getName();
- for(BaseMetaclass baseMetaclass : combination.getMembers()) {
+ for (BaseMetaclass baseMetaclass : combination.getMembers()) {
name += "_" + baseMetaclass.getExtensionDefinition().getStereotype().getName();
}
@@ -276,27 +276,28 @@ public class CreatePreliminaryMetamodelListener extends MouseAdapter {
/**
* Check whether two or more required stereotypes are defined as MULTI_GENERALIZATION on a unique base metaclass
- *
+ *
* @return
*/
protected boolean isFeasible() {
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- if(extensionDefinition.getExtension().isRequired()) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ if (extensionDefinition.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ if (extensionDefinition.getExtension().isRequired()) {
// Is there another that is required with common basemetaclasses
- for(ExtensionDefinition extensionDefinition2 : facade.getExtensionDefinitions()) {
- if(!ProfileUtils.getSiblings(extensionDefinition.getStereotype()).contains(extensionDefinition2.getStereotype())) {
- if(extensionDefinition2.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- if(extensionDefinition2.getExtension().isRequired()) {
- if(extensionDefinition != extensionDefinition2) {
+ for (ExtensionDefinition extensionDefinition2 : facade.getExtensionDefinitions()) {
+ if (!ProfileUtils.getSiblings(extensionDefinition.getStereotype()).contains(extensionDefinition2.getStereotype())) {
+ if (extensionDefinition2.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ if (extensionDefinition2.getExtension().isRequired()) {
+ if (extensionDefinition != extensionDefinition2) {
List<EClass> baseMetaclasses = StereotypeUtils.getAllExtendableMetaclasses(extensionDefinition.getExtension(), true);
List<EClass> baseMetaclasses2 = StereotypeUtils.getAllExtendableMetaclasses(extensionDefinition2.getExtension(), true);
- for(EClass eClass : baseMetaclasses) {
- if(baseMetaclasses2.contains(eClass)) {
- MessageDialog.openError(Display.getCurrent().getActiveShell(), "Cannot generate metamodel", "Two or more required stereotypes are defined as MULTI_GENERALIZATION on " + eClass.getName() + ". \nYou must define only one as MultiGeneralization.");
+ for (EClass eClass : baseMetaclasses) {
+ if (baseMetaclasses2.contains(eClass)) {
+ MessageDialog.openError(Display.getCurrent().getActiveShell(), "Cannot generate metamodel", "Two or more required stereotypes are defined as MULTI_GENERALIZATION on " + eClass.getName()
+ + ". \nYou must define only one as MultiGeneralization.");
return false;
}
}
@@ -313,25 +314,25 @@ public class CreatePreliminaryMetamodelListener extends MouseAdapter {
}
/**
- *
+ *
* @see org.eclipse.swt.events.MouseAdapter#mouseUp(org.eclipse.swt.events.MouseEvent)
- *
+ *
* @param e
*/
@Override
public void mouseUp(MouseEvent e) {
- if(isFeasible()) {
+ if (isFeasible()) {
boolean proceed = false;
- if(facade.getVirtualmetamodel().eContents().isEmpty()) {
+ if (facade.getVirtualmetamodel().eContents().isEmpty()) {
proceed = true;
} else {
- if(MessageDialog.openConfirm(Display.getCurrent().getActiveShell(), "Confirmation", "We are going to erase the preliminary metamodel")) {
+ if (MessageDialog.openConfirm(Display.getCurrent().getActiveShell(), "Confirmation", "We are going to erase the preliminary metamodel")) {
proceed = true;
}
}
- if(proceed) {
+ if (proceed) {
// Command to execute for development only
RemoveCommand commandMetaclasses = new RemoveCommand(editingDomain, facade.getVirtualmetamodel(), VirtualmetamodelPackage.eINSTANCE.getVirtualMetamodel_VirtualClassifiers(), facade.getVirtualmetamodel().getVirtualClassifiers());
editingDomain.getCommandStack().execute(commandMetaclasses);
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/EcoreGenerator.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/EcoreGenerator.java
index eb129a57f8c..34ffc8f8feb 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/EcoreGenerator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/EcoreGenerator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -128,7 +128,7 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Helper method to create the Ecore file for the actual metamodel for the facade
- *
+ *
* @return
* the root of the ecore metamodel
*/
@@ -154,7 +154,7 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Helper method to create the mapping file between UML + profile and the facade metamodel
- *
+ *
* @return
* the root of the mapping model
*/
@@ -191,31 +191,31 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Store a mapping in the mapping model
- *
+ *
* @param element
* @param representingElement
* @param facadeMappingModel
*/
protected void setRepresenting(VirtualElement element, EObject representingElement, FacadeMappping facadeMappingModel) {
- if(element instanceof VirtualMetaclass) {
- if(!((VirtualMetaclass)element).getAppliedStereotypes().isEmpty()) {
+ if (element instanceof VirtualMetaclass) {
+ if (!((VirtualMetaclass) element).getAppliedStereotypes().isEmpty()) {
StereotypedMapping mappingToEdit = FacademappingFactory.eINSTANCE.createStereotypedMapping();
List<Stereotype> stereotypes = new ArrayList<Stereotype>();
- for(BaseMetaclass baseMetaclass : ((VirtualMetaclass)element).getAppliedStereotypes()) {
+ for (BaseMetaclass baseMetaclass : ((VirtualMetaclass) element).getAppliedStereotypes()) {
stereotypes.add(baseMetaclass.getExtensionDefinition().getStereotype());
}
- if(MetamodelUtils.onlyOneKind(((VirtualMetaclass)element).getAppliedStereotypes(), ExtensionDefinitionKind.ASSOCIATION)) {
+ if (MetamodelUtils.onlyOneKind(((VirtualMetaclass) element).getAppliedStereotypes(), ExtensionDefinitionKind.ASSOCIATION)) {
mappingToEdit.setKind(org.eclipse.papyrus.facademapping.ExtensionDefinitionKind.ASSOCIATION);
- } else if(MetamodelUtils.onlyOneKind(((VirtualMetaclass)element).getAppliedStereotypes(), ExtensionDefinitionKind.GENERALIZATION)) {
+ } else if (MetamodelUtils.onlyOneKind(((VirtualMetaclass) element).getAppliedStereotypes(), ExtensionDefinitionKind.GENERALIZATION)) {
mappingToEdit.setKind(org.eclipse.papyrus.facademapping.ExtensionDefinitionKind.GENERALIZATION);
- } else if(MetamodelUtils.onlyOneKind(((VirtualMetaclass)element).getAppliedStereotypes(), ExtensionDefinitionKind.MULTI_GENERALIZATION)) {
+ } else if (MetamodelUtils.onlyOneKind(((VirtualMetaclass) element).getAppliedStereotypes(), ExtensionDefinitionKind.MULTI_GENERALIZATION)) {
mappingToEdit.setKind(org.eclipse.papyrus.facademapping.ExtensionDefinitionKind.MULTI_GENERALIZATION);
- } else if(MetamodelUtils.onlyOneKind(((VirtualMetaclass)element).getAppliedStereotypes(), ExtensionDefinitionKind.FUSION)) {
+ } else if (MetamodelUtils.onlyOneKind(((VirtualMetaclass) element).getAppliedStereotypes(), ExtensionDefinitionKind.FUSION)) {
mappingToEdit.setKind(org.eclipse.papyrus.facademapping.ExtensionDefinitionKind.FUSION);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_3 + element.getRepresentedElement());
@@ -223,7 +223,7 @@ public class EcoreGenerator extends MouseAdapter {
mappingToEdit.setUmlElement(element.getRepresentedElement());
mappingToEdit.setSpecificDomainElement(representingElement);
- ((StereotypedMapping)mappingToEdit).getAppliedStereotypes().addAll(stereotypes);
+ mappingToEdit.getAppliedStereotypes().addAll(stereotypes);
facadeMappingModel.getMappings().add(mappingToEdit);
@@ -240,23 +240,23 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Create an EEnum from an VirtualEnum in the facade metamodel
- *
+ *
* @param virtualEnum
* @param ecoreRoot
* @param facadeMappping
*/
protected void createEnum(VirtualEnum virtualEnum, EPackage ecoreRoot, FacadeMappping facadeMappping) {
- if(virtualEnum.getRepresentedElement() instanceof EEnum) {
+ if (virtualEnum.getRepresentedElement() instanceof EEnum) {
EEnum enumeration = EcoreFactory.eINSTANCE.createEEnum();
enumeration.setName(virtualEnum.getAliasName());
- for(VirtualLiteral literal : virtualEnum.getLiterals()) {
- if(literal.getRepresentedElement() instanceof EEnumLiteral) {
+ for (VirtualLiteral literal : virtualEnum.getLiterals()) {
+ if (literal.getRepresentedElement() instanceof EEnumLiteral) {
EEnumLiteral enumLiteral = EcoreFactory.eINSTANCE.createEEnumLiteral();
enumLiteral.setName(literal.getAliasName());
- enumLiteral.setValue(((EEnumLiteral)literal.getRepresentedElement()).getValue());
+ enumLiteral.setValue(((EEnumLiteral) literal.getRepresentedElement()).getValue());
enumeration.getELiterals().add(enumLiteral);
setRepresenting(literal, enumLiteral, facadeMappping);
processedLiteral.put(literal, enumLiteral);
@@ -269,13 +269,13 @@ public class EcoreGenerator extends MouseAdapter {
setRepresenting(virtualEnum, enumeration, facadeMappping);
processedClassifier.put(virtualEnum, enumeration);
- } else if(virtualEnum.getRepresentedElement() instanceof Enumeration) {
+ } else if (virtualEnum.getRepresentedElement() instanceof Enumeration) {
EEnum enumeration = EcoreFactory.eINSTANCE.createEEnum();
enumeration.setName(virtualEnum.getAliasName());
int i = 0;
- for(VirtualLiteral literal : virtualEnum.getLiterals()) {
- if(literal.getRepresentedElement() instanceof EnumerationLiteral) {
+ for (VirtualLiteral literal : virtualEnum.getLiterals()) {
+ if (literal.getRepresentedElement() instanceof EnumerationLiteral) {
EEnumLiteral enumLiteral = EcoreFactory.eINSTANCE.createEEnumLiteral();
enumLiteral.setName(literal.getAliasName());
@@ -299,30 +299,30 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Create an EDatatype from an VirtualDatatype in the facade metamodel
- *
+ *
* @param datatype
* @param ecoreRoot
* @param facadeMappping
*/
protected void createDatatype(VirtualDatatype datatype, EPackage ecoreRoot, FacadeMappping facadeMappping) {
- if(datatype.getRepresentedElement() instanceof EDataType) {
+ if (datatype.getRepresentedElement() instanceof EDataType) {
EDataType eDataType = EcoreFactory.eINSTANCE.createEDataType();
eDataType.setName(datatype.getAliasName());
- eDataType.setInstanceTypeName(((EDataType)datatype.getRepresentedElement()).getInstanceTypeName());
+ eDataType.setInstanceTypeName(((EDataType) datatype.getRepresentedElement()).getInstanceTypeName());
ecoreRoot.getEClassifiers().add(eDataType);
setRepresenting(datatype, eDataType, facadeMappping);
processedClassifier.put(datatype, eDataType);
}
- if(datatype.getRepresentedElement() instanceof PrimitiveType) {
+ if (datatype.getRepresentedElement() instanceof PrimitiveType) {
EDataType eDataType = EcoreFactory.eINSTANCE.createEDataType();
eDataType.setName(datatype.getAliasName());
- Stereotype stereotype = ((PrimitiveType)datatype.getRepresentedElement()).getAppliedStereotype("Ecore::EDataType"); //$NON-NLS-1$
- if(stereotype != null) {
- Object value = ((PrimitiveType)datatype.getRepresentedElement()).getValue(stereotype, "instanceClassName"); //$NON-NLS-1$
- if(value instanceof String) {
- eDataType.setInstanceTypeName((String)value);
+ Stereotype stereotype = ((PrimitiveType) datatype.getRepresentedElement()).getAppliedStereotype("Ecore::EDataType"); //$NON-NLS-1$
+ if (stereotype != null) {
+ Object value = ((PrimitiveType) datatype.getRepresentedElement()).getValue(stereotype, "instanceClassName"); //$NON-NLS-1$
+ if (value instanceof String) {
+ eDataType.setInstanceTypeName((String) value);
}
}
@@ -336,14 +336,14 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Create an EClass from an VirtualMetaclass in the facade metamodel
- *
+ *
* @param metaclass
* @param ecoreRoot
* @param facadeMappping
*/
protected void createMetaclass(VirtualMetaclass metaclass, EPackage ecoreRoot, FacadeMappping facadeMappping) {
- if(!processedClassifier.containsKey(metaclass)) {
+ if (!processedClassifier.containsKey(metaclass)) {
EClass eClass = EcoreFactory.eINSTANCE.createEClass();
eClass.setName(metaclass.getAliasName());
eClass.setAbstract(metaclass.isAbstract());
@@ -357,7 +357,7 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Add a boolean attribute to a representingElement in the facade metamodel
- *
+ *
* @param virtualProperty
* @param representingElement
* @param facadeMappping
@@ -376,7 +376,7 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Add a String attribute to a representingElement in the facade metamodel
- *
+ *
* @param virtualProperty
* @param representingElement
* @param facadeMappping
@@ -395,7 +395,7 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Add an integer attribute to a representingElement in the facade metamodel
- *
+ *
* @param virtualProperty
* @param representingElement
* @param facadeMappping
@@ -414,7 +414,7 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Add an unlimitedNatural attribute to a representingElement in the facade metamodel
- *
+ *
* @param virtualProperty
* @param representingElement
* @param facadeMappping
@@ -425,7 +425,7 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Add a real attribute to a representingElement in the facade metamodel
- *
+ *
* @param virtualProperty
* @param representingElement
* @param facadeMappping
@@ -444,47 +444,47 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Generate a eAttribute of eReference in the facade metamodel to represent a virtualProperty
- *
+ *
* @param virtualProperty
* @param representingElement
* @param facadeMappping
*/
protected void processPropertyFeature(VirtualProperty virtualProperty, EClass representingElement, FacadeMappping facadeMappping) {
- if(!processedPropertyFeature.containsKey(virtualProperty)) {
- Property property = (Property)virtualProperty.getRepresentedElement();
+ if (!processedPropertyFeature.containsKey(virtualProperty)) {
+ Property property = (Property) virtualProperty.getRepresentedElement();
- EObject eType = StereotypeUtils.findEClass((Classifier)((Property)property).getType());
+ EObject eType = StereotypeUtils.findEClass((Classifier) property.getType());
- if(eType == TypesPackage.eINSTANCE.getBoolean()) {
+ if (eType == TypesPackage.eINSTANCE.getBoolean()) {
createBooleanAttribute(virtualProperty, representingElement, facadeMappping);
- } else if(eType == TypesPackage.eINSTANCE.getString()) {
+ } else if (eType == TypesPackage.eINSTANCE.getString()) {
createStringAttribute(virtualProperty, representingElement, facadeMappping);
- } else if(eType == TypesPackage.eINSTANCE.getInteger()) {
+ } else if (eType == TypesPackage.eINSTANCE.getInteger()) {
createIntegerAttribute(virtualProperty, representingElement, facadeMappping);
- } else if(eType == TypesPackage.eINSTANCE.getUnlimitedNatural()) {
+ } else if (eType == TypesPackage.eINSTANCE.getUnlimitedNatural()) {
createUnlimitedNaturalAttribute(virtualProperty, representingElement, facadeMappping);
- } else if(eType == TypesPackage.eINSTANCE.getReal()) {
+ } else if (eType == TypesPackage.eINSTANCE.getReal()) {
createRealAttribute(virtualProperty, representingElement, facadeMappping);
} else {
EClassifier representingType = null;
- if(eType != null) {
- if(eType instanceof EClassifier) {
+ if (eType != null) {
+ if (eType instanceof EClassifier) {
VirtualClassifier typeVirtualMetaclass = MetamodelUtils.findClassifierThatMatch(eType, facade);
representingType = processedClassifier.get(typeVirtualMetaclass);
}
- } else if(property instanceof ExtensionEnd) {
- Property otherEnd = ((ExtensionEnd)property).getOtherEnd();
- VirtualClassifier typeVirtualMetaclass = MetamodelUtils.findMetaclassThatMatch(StereotypeUtils.findEClass((Classifier)otherEnd.getType()), (Stereotype)property.getType(), facade);
+ } else if (property instanceof ExtensionEnd) {
+ Property otherEnd = ((ExtensionEnd) property).getOtherEnd();
+ VirtualClassifier typeVirtualMetaclass = MetamodelUtils.findMetaclassThatMatch(StereotypeUtils.findEClass((Classifier) otherEnd.getType()), (Stereotype) property.getType(), facade);
representingType = processedClassifier.get(typeVirtualMetaclass);
} else {
VirtualClassifier typeVirtualMetaclass = MetamodelUtils.findClassifierThatMatch(property.getType(), facade);
representingType = processedClassifier.get(typeVirtualMetaclass);
}
- if(representingType != null) {
+ if (representingType != null) {
EStructuralFeature attrib;
- if(representingType instanceof EDataType) {
+ if (representingType instanceof EDataType) {
attrib = EcoreFactory.eINSTANCE.createEAttribute();
} else {
attrib = EcoreFactory.eINSTANCE.createEReference();
@@ -494,25 +494,25 @@ public class EcoreGenerator extends MouseAdapter {
attrib.setLowerBound(virtualProperty.getLower());
attrib.setUpperBound(virtualProperty.getUpper());
- if(attrib instanceof EReference) {
- if(virtualProperty.getRepresentedElement() instanceof Property) {
- if(((Property)virtualProperty.getRepresentedElement()).getClass_() instanceof Stereotype) {
- if(!(((Property)virtualProperty.getRepresentedElement()).getType() instanceof Stereotype) && !(((Property)virtualProperty.getRepresentedElement()).getAssociation() instanceof Extension)) {
- if(((Property)virtualProperty.getRepresentedElement()).getType().eClass().getEPackage() != UMLPackage.eINSTANCE) {
- ((EReference)attrib).setContainment(true);
+ if (attrib instanceof EReference) {
+ if (virtualProperty.getRepresentedElement() instanceof Property) {
+ if (((Property) virtualProperty.getRepresentedElement()).getClass_() instanceof Stereotype) {
+ if (!(((Property) virtualProperty.getRepresentedElement()).getType() instanceof Stereotype) && !(((Property) virtualProperty.getRepresentedElement()).getAssociation() instanceof Extension)) {
+ if (((Property) virtualProperty.getRepresentedElement()).getType().eClass().getEPackage() != UMLPackage.eINSTANCE) {
+ ((EReference) attrib).setContainment(true);
}
}
}
- if(virtualProperty.getRepresentedElement() instanceof ExtensionEnd) {
- ((EReference)attrib).setContainment(true);
+ if (virtualProperty.getRepresentedElement() instanceof ExtensionEnd) {
+ ((EReference) attrib).setContainment(true);
}
}
}
- if(property.getAssociation() != null) {
- if(property.getAssociation().getOwnedEnds().size() == 1) {
- if(property.getAssociation().getMemberEnds().size() == 2) {
+ if (property.getAssociation() != null) {
+ if (property.getAssociation().getOwnedEnds().size() == 1) {
+ if (property.getAssociation().getMemberEnds().size() == 2) {
// Do nothing
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_10 + property.getAssociation());
@@ -526,7 +526,7 @@ public class EcoreGenerator extends MouseAdapter {
representingElement.getEStructuralFeatures().add(attrib);
setRepresenting(virtualProperty, attrib, facadeMappping);
- // updateRepresenting(property, attrib, facadeMappping);
+ // updateRepresenting(property, attrib, facadeMappping);
processedPropertyFeature.put(virtualProperty, attrib);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_12 + property);
@@ -541,25 +541,25 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Create the generalization relationships of a representingElement of a virtualMetaclass
- *
+ *
* @param metaclass
* @param root
* @param facadeMappping
*/
protected void createGeneralisations(VirtualMetaclass metaclass, EPackage root, FacadeMappping facadeMappping) {
- if(!generalizationProcessed.contains(metaclass)) {
+ if (!generalizationProcessed.contains(metaclass)) {
EObject representingElement = processedClassifier.get(metaclass);
- if(representingElement != null) {
+ if (representingElement != null) {
generalizationProcessed.add(metaclass);
// Add generalization
- for(VirtualMetaclass father : metaclass.getParents()) {
+ for (VirtualMetaclass father : metaclass.getParents()) {
EObject elementReprensentingFather = processedClassifier.get(father);
- if(representingElement instanceof EClass) {
- if(elementReprensentingFather instanceof EClass) {
- ((EClass)representingElement).getESuperTypes().add((EClass)elementReprensentingFather);
+ if (representingElement instanceof EClass) {
+ if (elementReprensentingFather instanceof EClass) {
+ ((EClass) representingElement).getESuperTypes().add((EClass) elementReprensentingFather);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_14 + elementReprensentingFather);
}
@@ -577,56 +577,56 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Generate the properties in the facade metamodel from virtualmetaclass
- *
+ *
* @param metaclass
* @param root
* @param facadeMappping
*/
protected void createProperties(VirtualMetaclass metaclass, EPackage root, FacadeMappping facadeMappping) {
- if(!propertiesProcessed.contains(metaclass)) {
+ if (!propertiesProcessed.contains(metaclass)) {
EObject representingElement = processedClassifier.get(metaclass);
- if(representingElement != null) {
+ if (representingElement != null) {
propertiesProcessed.add(metaclass);
// Create features
- if(representingElement instanceof EClass) {
- for(VirtualProperty property : metaclass.getProperties()) {
- if(property.isKept()) {
+ if (representingElement instanceof EClass) {
+ for (VirtualProperty property : metaclass.getProperties()) {
+ if (property.isKept()) {
- if(property.getRepresentedElement() instanceof EAttribute) {
- VirtualClassifier typeVirtualMetaclass = MetamodelUtils.findClassifierThatMatch(((EAttribute)property.getRepresentedElement()).getEType(), facade);
+ if (property.getRepresentedElement() instanceof EAttribute) {
+ VirtualClassifier typeVirtualMetaclass = MetamodelUtils.findClassifierThatMatch(((EAttribute) property.getRepresentedElement()).getEType(), facade);
EClassifier representingType = processedClassifier.get(typeVirtualMetaclass);
- if(representingType != null) {
- EAttribute attrib = (EAttribute)EcoreUtil.copy(property.getRepresentedElement());
+ if (representingType != null) {
+ EAttribute attrib = (EAttribute) EcoreUtil.copy(property.getRepresentedElement());
attrib.setName(property.getAliasName());
attrib.setEType(representingType);
- ((EClass)representingElement).getEStructuralFeatures().add(attrib);
+ ((EClass) representingElement).getEStructuralFeatures().add(attrib);
setRepresenting(property, attrib, facadeMappping);
processedProperty.put(property, attrib);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_18 + property);
}
- } else if(property.getRepresentedElement() instanceof EReference) {
- VirtualClassifier typeVirtualMetaclass = MetamodelUtils.findClassifierThatMatch(((EReference)property.getRepresentedElement()).getEType(), facade);
+ } else if (property.getRepresentedElement() instanceof EReference) {
+ VirtualClassifier typeVirtualMetaclass = MetamodelUtils.findClassifierThatMatch(((EReference) property.getRepresentedElement()).getEType(), facade);
EClassifier representingType = processedClassifier.get(typeVirtualMetaclass);
- if(representingType != null) {
- EReference attrib = (EReference)EcoreUtil.copy(property.getRepresentedElement());
+ if (representingType != null) {
+ EReference attrib = (EReference) EcoreUtil.copy(property.getRepresentedElement());
attrib.setName(property.getAliasName());
attrib.setEType(representingType);
- ((EClass)representingElement).getEStructuralFeatures().add(attrib);
+ ((EClass) representingElement).getEStructuralFeatures().add(attrib);
setRepresenting(property, attrib, facadeMappping);
processedProperty.put(property, attrib);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_19 + property);
}
- } else if(property.getRepresentedElement() instanceof Property) {
- processPropertyFeature(property, (EClass)representingElement, facadeMappping);
+ } else if (property.getRepresentedElement() instanceof Property) {
+ processPropertyFeature(property, (EClass) representingElement, facadeMappping);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_20 + property.getRepresentedElement());
}
@@ -646,29 +646,29 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Generate the operations in the facade metamodel from virtualmetaclass
- *
+ *
* @param metaclass
* @param root
* @param facadeMappping
*/
protected void createOperations(VirtualMetaclass metaclass, EPackage root, FacadeMappping facadeMappping) {
- for(VirtualOperation virtualOperation : metaclass.getOperations()) {
- if(virtualOperation.isKept()) {
+ for (VirtualOperation virtualOperation : metaclass.getOperations()) {
+ if (virtualOperation.isKept()) {
EClassifier representing = processedClassifier.get(metaclass);
- if(representing instanceof EClass) {
- if(virtualOperation.getRepresentedElement() instanceof EOperation) {
- EOperation eOperation = (EOperation)EcoreUtil.copy(virtualOperation.getRepresentedElement());
+ if (representing instanceof EClass) {
+ if (virtualOperation.getRepresentedElement() instanceof EOperation) {
+ EOperation eOperation = (EOperation) EcoreUtil.copy(virtualOperation.getRepresentedElement());
eOperation.getEParameters().clear();
eOperation.setName(virtualOperation.getAliasName());
- ((EClass)representing).getEOperations().add(eOperation);
+ ((EClass) representing).getEOperations().add(eOperation);
setRepresenting(virtualOperation, eOperation, facadeMappping);
- if(eOperation.getEType() != null) {
- if(eOperation.getEType().getEPackage() == UMLPackage.eINSTANCE || eOperation.getEType().getEPackage() == TypesPackage.eINSTANCE) {
+ if (eOperation.getEType() != null) {
+ if (eOperation.getEType().getEPackage() == UMLPackage.eINSTANCE || eOperation.getEType().getEPackage() == TypesPackage.eINSTANCE) {
VirtualClassifier virtualClassifier = MetamodelUtils.findClassifierThatMatch(eOperation.getEType(), facade);
- if(virtualClassifier != null) {
+ if (virtualClassifier != null) {
eOperation.setEType(processedClassifier.get(virtualClassifier));
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_24 + eOperation.getEType());
@@ -676,17 +676,17 @@ public class EcoreGenerator extends MouseAdapter {
}
}
- for(VirtualParameter virtualParameter : virtualOperation.getParameters()) {
- EParameter eParameter = (EParameter)EcoreUtil.copy(virtualParameter.getRepresentedElement());
+ for (VirtualParameter virtualParameter : virtualOperation.getParameters()) {
+ EParameter eParameter = (EParameter) EcoreUtil.copy(virtualParameter.getRepresentedElement());
eParameter.setName(virtualParameter.getAliasName());
eParameter.setLowerBound(virtualParameter.getLower());
eParameter.setUpperBound(virtualParameter.getUpper());
setRepresenting(virtualParameter, eParameter, facadeMappping);
- if(eParameter.getEType() != null) {
- if(eParameter.getEType().getEPackage() == UMLPackage.eINSTANCE || eParameter.getEType().getEPackage() == TypesPackage.eINSTANCE) {
+ if (eParameter.getEType() != null) {
+ if (eParameter.getEType().getEPackage() == UMLPackage.eINSTANCE || eParameter.getEType().getEPackage() == TypesPackage.eINSTANCE) {
VirtualClassifier virtualClassifier = MetamodelUtils.findClassifierThatMatch(eParameter.getEType(), facade);
- if(virtualClassifier != null) {
+ if (virtualClassifier != null) {
eParameter.setEType(processedClassifier.get(virtualClassifier));
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_25 + eOperation.getEType());
@@ -696,8 +696,8 @@ public class EcoreGenerator extends MouseAdapter {
eOperation.getEParameters().add(eParameter);
}
- EList<EAnnotation> annotation = ((EModelElement)virtualOperation.getRepresentedElement()).getEAnnotations();
- for(EAnnotation eAnnotation : annotation) {
+ EList<EAnnotation> annotation = ((EModelElement) virtualOperation.getRepresentedElement()).getEAnnotations();
+ for (EAnnotation eAnnotation : annotation) {
eOperation.getEAnnotations().add(EcoreUtil.copy(eAnnotation));
}
}
@@ -708,35 +708,35 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Find the representing eReference that is the eOpposite of a eReference
- *
+ *
* @param reference
* @return
*/
protected EReference findEOpposite(EReference reference) {
- VirtualMetaclass oppositeTypeVirtualMetaclass = MetamodelUtils.findMetaclassWithNoRealStereoThatMatch((EClassifier)reference.eContainer(), facade);
+ VirtualMetaclass oppositeTypeVirtualMetaclass = MetamodelUtils.findMetaclassWithNoRealStereoThatMatch(reference.eContainer(), facade);
VirtualProperty oppositeVirtualProperty = null;
- if(oppositeTypeVirtualMetaclass != null) {
- for(VirtualProperty virtualProperty : oppositeTypeVirtualMetaclass.getProperties()) {
+ if (oppositeTypeVirtualMetaclass != null) {
+ for (VirtualProperty virtualProperty : oppositeTypeVirtualMetaclass.getProperties()) {
EObject virtualPropertyRepresentedElement = virtualProperty.getRepresentedElement();
- if(virtualPropertyRepresentedElement instanceof ENamedElement) {
- if(((ENamedElement)virtualPropertyRepresentedElement).getName().equals(reference.getName())) {
+ if (virtualPropertyRepresentedElement instanceof ENamedElement) {
+ if (((ENamedElement) virtualPropertyRepresentedElement).getName().equals(reference.getName())) {
oppositeVirtualProperty = virtualProperty;
break;
}
- } else if(virtualPropertyRepresentedElement instanceof ExtensionEnd) {
+ } else if (virtualPropertyRepresentedElement instanceof ExtensionEnd) {
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_26 + virtualPropertyRepresentedElement);
}
}
- if(oppositeVirtualProperty != null) {
- if(processedProperty.containsKey(oppositeVirtualProperty)) {
- if(processedProperty.get(oppositeVirtualProperty) instanceof EReference) {
- return (EReference)processedProperty.get(oppositeVirtualProperty);
+ if (oppositeVirtualProperty != null) {
+ if (processedProperty.containsKey(oppositeVirtualProperty)) {
+ if (processedProperty.get(oppositeVirtualProperty) instanceof EReference) {
+ return (EReference) processedProperty.get(oppositeVirtualProperty);
}
}
}
@@ -747,14 +747,14 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Find the facade element that represents a umlElement
- *
+ *
* @param umlElement
* @param facadeMappping
* @return
*/
protected EObject findRepresenting(EObject umlElement, FacadeMappping facadeMappping) {
- for(Mapping mapping : facadeMappping.getMappings()) {
- if(mapping.getUmlElement() == umlElement) {
+ for (Mapping mapping : facadeMappping.getMappings()) {
+ if (mapping.getUmlElement() == umlElement) {
return mapping.getSpecificDomainElement();
}
}
@@ -763,35 +763,35 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Update the eOpposite among eReferences in the facade metamodel
- *
+ *
* @param root
* @param facadeMappping
*/
protected void processEOpposites(EPackage root, FacadeMappping facadeMappping) {
TreeIterator<EObject> it = root.eAllContents();
- while(it.hasNext()) {
- EObject eObject = (EObject)it.next();
- if(eObject instanceof EReference) {
- EReference reference = (EReference)eObject;
+ while (it.hasNext()) {
+ EObject eObject = it.next();
+ if (eObject instanceof EReference) {
+ EReference reference = (EReference) eObject;
EReference eOpposite = reference.getEOpposite();
- if(eOpposite != null) {
+ if (eOpposite != null) {
EReference representingEOpposite = findEOpposite(eOpposite);
- if(representingEOpposite == null) {
+ if (representingEOpposite == null) {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_27 + eOpposite);
}
reference.setEOpposite(representingEOpposite);
} else {
- for(Mapping mapping : facadeMappping.getMappings()) {
- if(mapping.getSpecificDomainElement() == eObject) {
+ for (Mapping mapping : facadeMappping.getMappings()) {
+ if (mapping.getSpecificDomainElement() == eObject) {
EObject umlElement = mapping.getUmlElement();
- if(umlElement instanceof Property) {
- Property otherEnd = ((Property)umlElement).getOtherEnd();
- if(otherEnd != null) {
+ if (umlElement instanceof Property) {
+ Property otherEnd = ((Property) umlElement).getOtherEnd();
+ if (otherEnd != null) {
EObject otherEndRepresenting = findRepresenting(otherEnd, facadeMappping);
- if(otherEndRepresenting instanceof EReference) {
- reference.setEOpposite((EReference)otherEndRepresenting);
+ if (otherEndRepresenting instanceof EReference) {
+ reference.setEOpposite((EReference) otherEndRepresenting);
}
}
@@ -805,28 +805,28 @@ public class EcoreGenerator extends MouseAdapter {
/**
* Copy significant EAnnotations from represented element to representing elements in the facade metamodel
- *
+ *
* @param root
*/
protected void processEAnnotations(EPackage root) {
TreeIterator<EObject> it = root.eAllContents();
- while(it.hasNext()) {
- EObject eObject = (EObject)it.next();
+ while (it.hasNext()) {
+ EObject eObject = it.next();
- if(eObject instanceof EAnnotation) {
- String source = ((EAnnotation)eObject).getSource();
- if(source.equals("subsets") || source.equals("redefines")) { //$NON-NLS-1$ //$NON-NLS-2$
+ if (eObject instanceof EAnnotation) {
+ String source = ((EAnnotation) eObject).getSource();
+ if (source.equals("subsets") || source.equals("redefines")) { //$NON-NLS-1$ //$NON-NLS-2$
ArrayList<EObject> newList = new ArrayList<EObject>();
- for(EObject reference : ((EAnnotation)eObject).getReferences()) {
+ for (EObject reference : ((EAnnotation) eObject).getReferences()) {
VirtualProperty correspondingVirtualProperty = MetamodelUtils.findProperty(reference, facade);
- if(correspondingVirtualProperty != null) {
+ if (correspondingVirtualProperty != null) {
EObject representing = processedProperty.get(correspondingVirtualProperty);
- if(representing != null) {
+ if (representing != null) {
newList.add(representing);
} else {
representing = processedPropertyFeature.get(correspondingVirtualProperty);
- if(representing != null) {
+ if (representing != null) {
newList.add(representing);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_30 + correspondingVirtualProperty);
@@ -837,22 +837,22 @@ public class EcoreGenerator extends MouseAdapter {
}
}
- ((EAnnotation)eObject).getReferences().clear();
- ((EAnnotation)eObject).getReferences().addAll(newList);
+ ((EAnnotation) eObject).getReferences().clear();
+ ((EAnnotation) eObject).getReferences().addAll(newList);
}
}
}
}
/**
- *
+ *
* @see org.eclipse.swt.events.MouseAdapter#mouseUp(org.eclipse.swt.events.MouseEvent)
- *
+ *
* @param event
*/
@Override
public void mouseUp(MouseEvent event) {
- if(!facade.getVirtualmetamodel().getName().equals("") && !facade.getVirtualmetamodel().getNsPrefix().equals("") && !facade.getVirtualmetamodel().getNsURI().equals("")) { //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
+ if (!facade.getVirtualmetamodel().getName().equals("") && !facade.getVirtualmetamodel().getNsPrefix().equals("") && !facade.getVirtualmetamodel().getNsURI().equals("")) { //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$
ProgressMonitorDialog dialog = new ProgressMonitorDialog(Display.getCurrent().getActiveShell());
try {
@@ -872,21 +872,21 @@ public class EcoreGenerator extends MouseAdapter {
EObject ecoreModel = createEcoreFile();
EObject facadeMapppingModel = createMappingFile();
- if(ecoreModel instanceof EPackage) {
- EPackage root = (EPackage)ecoreModel;
- if(facadeMapppingModel instanceof FacadeMappping) {
- FacadeMappping facadeMappping = (FacadeMappping)facadeMapppingModel;
+ if (ecoreModel instanceof EPackage) {
+ EPackage root = (EPackage) ecoreModel;
+ if (facadeMapppingModel instanceof FacadeMappping) {
+ FacadeMappping facadeMappping = (FacadeMappping) facadeMapppingModel;
// Create metaclasses first
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier.isKept()) {
- if(!classifier.isUseRepresented()) {
- if(classifier instanceof VirtualMetaclass) {
- createMetaclass((VirtualMetaclass)classifier, root, facadeMappping);
- } else if(classifier instanceof VirtualEnum) {
- createEnum((VirtualEnum)classifier, root, facadeMappping);
- } else if(classifier instanceof VirtualDatatype) {
- createDatatype((VirtualDatatype)classifier, root, facadeMappping);
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ if (classifier.isKept()) {
+ if (!classifier.isUseRepresented()) {
+ if (classifier instanceof VirtualMetaclass) {
+ createMetaclass((VirtualMetaclass) classifier, root, facadeMappping);
+ } else if (classifier instanceof VirtualEnum) {
+ createEnum((VirtualEnum) classifier, root, facadeMappping);
+ } else if (classifier instanceof VirtualDatatype) {
+ createDatatype((VirtualDatatype) classifier, root, facadeMappping);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_36 + classifier);
}
@@ -895,7 +895,7 @@ public class EcoreGenerator extends MouseAdapter {
}
// Hierarchy and features among metaclasses
- for(VirtualMetaclass metaclass : MetamodelUtils.getOnlyVirtualMetaclasses(processedClassifier.keySet())) {
+ for (VirtualMetaclass metaclass : MetamodelUtils.getOnlyVirtualMetaclasses(processedClassifier.keySet())) {
createGeneralisations(metaclass, root, facadeMappping);
createProperties(metaclass, root, facadeMappping);
createOperations(metaclass, root, facadeMappping);
@@ -904,16 +904,16 @@ public class EcoreGenerator extends MouseAdapter {
// Process eOpposites
processEOpposites(root, facadeMappping);
- //Clean eAnnotations
+ // Clean eAnnotations
processEAnnotations(root);
Diagnostic diagnostic = Diagnostician.INSTANCE.validate(root);
- for(Diagnostic child : diagnostic.getChildren()) {
- if(child.getCode() == EcoreValidator.DISJOINT_FEATURE_AND_OPERATION_SIGNATURES) {
- for(Object dataElement : child.getData()) {
- if(dataElement instanceof EOperation) {
- EcoreUtil.setSuppressedVisibility((EOperation)dataElement, true);
+ for (Diagnostic child : diagnostic.getChildren()) {
+ if (child.getCode() == EcoreValidator.DISJOINT_FEATURE_AND_OPERATION_SIGNATURES) {
+ for (Object dataElement : child.getData()) {
+ if (dataElement instanceof EOperation) {
+ EcoreUtil.setSuppressedVisibility((EOperation) dataElement, true);
}
}
}
@@ -923,10 +923,10 @@ public class EcoreGenerator extends MouseAdapter {
// Sanity check
TreeIterator<EObject> it = facade.eAllContents();
- while(it.hasNext()) {
- EObject eObject = (EObject)it.next();
- if(eObject instanceof VirtualElement) {
- if(((VirtualElement)eObject).getRepresentedElement() == null) {
+ while (it.hasNext()) {
+ EObject eObject = it.next();
+ if (eObject instanceof VirtualElement) {
+ if (((VirtualElement) eObject).getRepresentedElement() == null) {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.EcoreGenerator_37 + eObject);
}
}
@@ -935,11 +935,12 @@ public class EcoreGenerator extends MouseAdapter {
// Save
save();
- if(diagnostic.getSeverity() == Diagnostic.OK) {
+ if (diagnostic.getSeverity() == Diagnostic.OK) {
MessageDialog.openInformation(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), Messages.EcoreGenerator_40, Messages.EcoreGenerator_41);
} else {
- DiagnosticDialog dialog = new DiagnosticDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), Messages.EcoreGenerator_42, Messages.EcoreGenerator_43, diagnostic, Diagnostic.OK | Diagnostic.INFO | Diagnostic.WARNING | Diagnostic.ERROR);
+ DiagnosticDialog dialog = new DiagnosticDialog(PlatformUI.getWorkbench().getActiveWorkbenchWindow().getShell(), Messages.EcoreGenerator_42, Messages.EcoreGenerator_43, diagnostic, Diagnostic.OK | Diagnostic.INFO
+ | Diagnostic.WARNING | Diagnostic.ERROR);
dialog.open();
}
monitor.done();
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/MetamodelUtils.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/MetamodelUtils.java
index a9c86c09035..f12efad71fc 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/MetamodelUtils.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/metamodel/MetamodelUtils.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -67,15 +67,15 @@ public class MetamodelUtils {
/**
* Check whether the list contains only {@link BaseMetaclass} that represent required extensions
- *
+ *
* @param list
* @return true if the list contains only required extensions
*/
public static boolean containsOnlyRequiredBaseMetaclass(List<BaseMetaclass> list) {
- if(!list.isEmpty()) {
- for(BaseMetaclass baseMetaclass : list) {
- if(baseMetaclass.getExtensionDefinition().getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION || baseMetaclass.getExtensionDefinition().getKind() == ExtensionDefinitionKind.GENERALIZATION) {
- if(!baseMetaclass.getExtensionDefinition().getExtension().isRequired()) {
+ if (!list.isEmpty()) {
+ for (BaseMetaclass baseMetaclass : list) {
+ if (baseMetaclass.getExtensionDefinition().getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION || baseMetaclass.getExtensionDefinition().getKind() == ExtensionDefinitionKind.GENERALIZATION) {
+ if (!baseMetaclass.getExtensionDefinition().getExtension().isRequired()) {
return false;
}
}
@@ -88,13 +88,13 @@ public class MetamodelUtils {
/**
* Check whether the list contains a {@link BaseMetaclass} that represent an abstract stereotype
- *
+ *
* @param list
* @return true if the list contains a {@link BaseMetaclass} that represent an abstract stereotype
*/
public static boolean containsAbstractStereotype(EList<BaseMetaclass> list) {
- for(BaseMetaclass baseMetaclass : list) {
- if(baseMetaclass.getExtensionDefinition().getStereotype().isAbstract()) {
+ for (BaseMetaclass baseMetaclass : list) {
+ if (baseMetaclass.getExtensionDefinition().getStereotype().isAbstract()) {
return true;
}
}
@@ -103,17 +103,17 @@ public class MetamodelUtils {
/**
* Extract only {@link VirtualMetaclass} from a list of {@link VirtualClassifier}
- *
+ *
* @param list
- * a list containing {@link VirtualClassifier}
+ * a list containing {@link VirtualClassifier}
* @return
* a list containing only {@link VirtualMetaclass}
*/
public static List<VirtualMetaclass> getOnlyVirtualMetaclasses(Collection<VirtualClassifier> list) {
List<VirtualMetaclass> result = new ArrayList<VirtualMetaclass>();
- for(VirtualClassifier classifier : list) {
- if(classifier instanceof VirtualMetaclass) {
- result.add((VirtualMetaclass)classifier);
+ for (VirtualClassifier classifier : list) {
+ if (classifier instanceof VirtualMetaclass) {
+ result.add((VirtualMetaclass) classifier);
}
}
return result;
@@ -122,15 +122,15 @@ public class MetamodelUtils {
/**
* Check whether the list contains only {@link BaseMetaclass} that represent abstract stereotype
- *
+ *
* @param list
* @return
* true if the list contains only {@link BaseMetaclass} that represent abstract stereotype
*/
public static boolean containsOnlyAbstractStereotype(EList<BaseMetaclass> list) {
- if(!list.isEmpty()) {
- for(BaseMetaclass baseMetaclass : list) {
- if(!baseMetaclass.getExtensionDefinition().getStereotype().isAbstract()) {
+ if (!list.isEmpty()) {
+ for (BaseMetaclass baseMetaclass : list) {
+ if (!baseMetaclass.getExtensionDefinition().getStereotype().isAbstract()) {
return false;
}
}
@@ -142,21 +142,21 @@ public class MetamodelUtils {
/**
* Find a {@link VirtualClassifier} that represents the element in the facade
- *
+ *
* @param element
- * the element that must be represented by the {@link VirtualClassifier}
+ * the element that must be represented by the {@link VirtualClassifier}
* @param facade
* @return a {@link VirtualClassifier} that represents the element or null
*/
public static VirtualClassifier findClassifierThatMatch(EObject element, Facade facade) {
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier.getRepresentedElement() == element) {
- if(classifier instanceof VirtualMetaclass) {
+ if (classifier.getRepresentedElement() == element) {
+ if (classifier instanceof VirtualMetaclass) {
- if(((VirtualMetaclass)classifier).getAppliedStereotypes().isEmpty() || onlyOneKind(((VirtualMetaclass)classifier).getAppliedStereotypes(), ExtensionDefinitionKind.FUSION)) {
- return ((VirtualMetaclass)classifier);
+ if (((VirtualMetaclass) classifier).getAppliedStereotypes().isEmpty() || onlyOneKind(((VirtualMetaclass) classifier).getAppliedStereotypes(), ExtensionDefinitionKind.FUSION)) {
+ return (classifier);
}
} else {
@@ -165,13 +165,13 @@ public class MetamodelUtils {
}
}
- //Try to find as an association
- if(element instanceof Stereotype) {
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier instanceof VirtualMetaclass) {
- if(((VirtualMetaclass)classifier).getAppliedStereotypes().size() == 1) {
- if(onlyOneKind(((VirtualMetaclass)classifier).getAppliedStereotypes(), ExtensionDefinitionKind.ASSOCIATION)) {
- if(((VirtualMetaclass)classifier).getAppliedStereotypes().get(0).getExtensionDefinition().getStereotype() == element) {
+ // Try to find as an association
+ if (element instanceof Stereotype) {
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ if (classifier instanceof VirtualMetaclass) {
+ if (((VirtualMetaclass) classifier).getAppliedStereotypes().size() == 1) {
+ if (onlyOneKind(((VirtualMetaclass) classifier).getAppliedStereotypes(), ExtensionDefinitionKind.ASSOCIATION)) {
+ if (((VirtualMetaclass) classifier).getAppliedStereotypes().get(0).getExtensionDefinition().getStereotype() == element) {
return classifier;
}
}
@@ -180,9 +180,9 @@ public class MetamodelUtils {
}
}
- if(element instanceof Classifier) {
- EClassifier foundEClass = StereotypeUtils.findEClass((Classifier)element);
- if(foundEClass != null) {
+ if (element instanceof Classifier) {
+ EClassifier foundEClass = StereotypeUtils.findEClass((Classifier) element);
+ if (foundEClass != null) {
return findClassifierThatMatch(foundEClass, facade);
}
}
@@ -192,19 +192,19 @@ public class MetamodelUtils {
/**
* Find a {@link VirtualClassifier} that represents the element in the facade but that doesn't have a stereotype applied
- *
+ *
* @param element
* @param facade
* @return
*/
public static VirtualMetaclass findMetaclassWithNoRealStereoThatMatch(EObject element, Facade facade) {
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier instanceof VirtualMetaclass) {
- if(((VirtualMetaclass)classifier).getRepresentedElement() == element) {
- if(((VirtualMetaclass)classifier).getAppliedStereotypes().isEmpty() || onlyOneKind(((VirtualMetaclass)classifier).getAppliedStereotypes(), ExtensionDefinitionKind.FUSION)) {
+ if (classifier instanceof VirtualMetaclass) {
+ if (((VirtualMetaclass) classifier).getRepresentedElement() == element) {
+ if (((VirtualMetaclass) classifier).getAppliedStereotypes().isEmpty() || onlyOneKind(((VirtualMetaclass) classifier).getAppliedStereotypes(), ExtensionDefinitionKind.FUSION)) {
- return ((VirtualMetaclass)classifier);
+ return ((VirtualMetaclass) classifier);
}
}
}
@@ -214,32 +214,33 @@ public class MetamodelUtils {
/**
* Find a {@link VirtualProperty} that represents the feature in the facade
- *
+ *
* @param feature
* @param facade
* @return
*/
public static VirtualProperty findProperty(EObject feature, Facade facade) {
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier instanceof VirtualMetaclass)
- for(VirtualProperty property : ((VirtualMetaclass)classifier).getProperties()) {
- if(property.getRepresentedElement() == feature) {
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ if (classifier instanceof VirtualMetaclass) {
+ for (VirtualProperty property : ((VirtualMetaclass) classifier).getProperties()) {
+ if (property.getRepresentedElement() == feature) {
return property;
}
}
+ }
}
return null;
}
/**
* Find the BaseMetaclass that represents the actual base metaclass among the BaseMetaclasses of an ExtensionDefinition
- *
+ *
* @param extensionDefinition
* @return
*/
public static BaseMetaclass findActualBaseMetaclass(ExtensionDefinition extensionDefinition) {
- for(BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
- if(baseMetaclass.getBase() == StereotypeUtils.findBase(extensionDefinition)) {
+ for (BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
+ if (baseMetaclass.getBase() == StereotypeUtils.findBase(extensionDefinition)) {
return baseMetaclass;
}
@@ -250,21 +251,21 @@ public class MetamodelUtils {
/**
* Find a {@link VirtualMetaclass} that represents the element in the facade
- *
+ *
* @param element
* @param stereo
* @param facade
* @return
*/
public static VirtualMetaclass findMetaclassThatMatch(EObject element, Stereotype stereo, Facade facade) {
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier.getRepresentedElement() == element) {
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ if (classifier.getRepresentedElement() == element) {
- if(classifier instanceof VirtualMetaclass) {
- if(((VirtualMetaclass)classifier).getAppliedStereotypes().size() == 1) {
+ if (classifier instanceof VirtualMetaclass) {
+ if (((VirtualMetaclass) classifier).getAppliedStereotypes().size() == 1) {
- if(((VirtualMetaclass)classifier).getAppliedStereotypes().get(0).getExtensionDefinition().getStereotype() == stereo) {
- return ((VirtualMetaclass)classifier);
+ if (((VirtualMetaclass) classifier).getAppliedStereotypes().get(0).getExtensionDefinition().getStereotype() == stereo) {
+ return ((VirtualMetaclass) classifier);
}
}
@@ -278,13 +279,13 @@ public class MetamodelUtils {
/**
* Check whether the stereotype represented by the {@link ExtensionDefinition} is a the same as the stereotype related to the extension
* represented by this {@link ExtensionDefinition}
- *
+ *
* @param extensionDefinition
* @return
*/
public static boolean isActualExtensionDefinition(ExtensionDefinition extensionDefinition) {
- if(extensionDefinition.getExtension().getStereotype() == extensionDefinition.getStereotype()) {
+ if (extensionDefinition.getExtension().getStereotype() == extensionDefinition.getStereotype()) {
return true;
}
@@ -294,14 +295,14 @@ public class MetamodelUtils {
/**
* Check whether the list of {@link BaseMetaclass} contains only {@link BaseMetaclass} that are of the same {@link ExtensionDefinitionKind}
- *
+ *
* @param list
* @param kind
* @return
*/
public static boolean onlyOneKind(List<BaseMetaclass> list, ExtensionDefinitionKind kind) {
- for(BaseMetaclass baseMetaclass : list) {
- if(baseMetaclass.getExtensionDefinition().getKind() != kind) {
+ for (BaseMetaclass baseMetaclass : list) {
+ if (baseMetaclass.getExtensionDefinition().getKind() != kind) {
return false;
}
}
@@ -310,16 +311,16 @@ public class MetamodelUtils {
/**
* Check whether the stereotype represented by an {@link ExtensionDefinition} is also represented by another {@link ExtensionDefinition}
- *
+ *
* @param extensionDefinition
* @return
*/
public static boolean hasSiblings(ExtensionDefinition extensionDefinition) {
Facade facade = extensionDefinition.getFacade();
- for(ExtensionDefinition otherExtensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition != otherExtensionDefinition) {
- if(extensionDefinition.getStereotype() == otherExtensionDefinition.getStereotype()) {
+ for (ExtensionDefinition otherExtensionDefinition : facade.getExtensionDefinitions()) {
+ if (extensionDefinition != otherExtensionDefinition) {
+ if (extensionDefinition.getStereotype() == otherExtensionDefinition.getStereotype()) {
return true;
}
@@ -333,17 +334,17 @@ public class MetamodelUtils {
BaseMetaclass requiredBaseMetaclass = null;
// Find the required one
- for(BaseMetaclass baseMetaclass : metaclassInput.getAppliedStereotypes()) {
- if(baseMetaclass.getExtensionDefinition().getExtension().isRequired()) {
+ for (BaseMetaclass baseMetaclass : metaclassInput.getAppliedStereotypes()) {
+ if (baseMetaclass.getExtensionDefinition().getExtension().isRequired()) {
requiredBaseMetaclass = baseMetaclass;
break;
}
}
- if(requiredBaseMetaclass != null) {
- output.add(findMetaclassThatMatch((EClass)requiredBaseMetaclass.getBase(), requiredBaseMetaclass.getExtensionDefinition().getStereotype(), facade));
+ if (requiredBaseMetaclass != null) {
+ output.add(findMetaclassThatMatch(requiredBaseMetaclass.getBase(), requiredBaseMetaclass.getExtensionDefinition().getStereotype(), facade));
} else {
- output.add(findMetaclassWithNoRealStereoThatMatch((EClass)metaclassInput.getRepresentedElement(), facade));
+ output.add(findMetaclassWithNoRealStereoThatMatch(metaclassInput.getRepresentedElement(), facade));
}
return output;
@@ -352,7 +353,7 @@ public class MetamodelUtils {
/**
* Get all {@link VirtualMetaclass} (i.e. recursively) that are generals of a {@link VirtualMetaclass}
- *
+ *
* @param metaclass
* @return
*/
@@ -362,7 +363,7 @@ public class MetamodelUtils {
List<VirtualMetaclass> output = new ArrayList<VirtualMetaclass>();
toProcess.addAll(getFathers(metaclass));
- while(!toProcess.isEmpty()) {
+ while (!toProcess.isEmpty()) {
VirtualMetaclass father = toProcess.remove(0);
output.add(father);
toProcess.addAll(getFathers(father));
@@ -374,33 +375,33 @@ public class MetamodelUtils {
/**
* Get {@link VirtualMetaclass} that are generals of a {@link VirtualMetaclass}
- *
+ *
* @param metaclass
* @return
*/
public static List<VirtualMetaclass> getFathers(VirtualMetaclass metaclass) {
List<VirtualMetaclass> output = new ArrayList<VirtualMetaclass>();
- Facade facade = ((VirtualMetaclass)metaclass).getMetamodel().getFacade();
+ Facade facade = metaclass.getMetamodel().getFacade();
- if(metaclass.getAppliedStereotypes().isEmpty() || onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.FUSION)) {
- if(metaclass.getRepresentedElement() instanceof EClass) {
- EList<EClass> supers = ((EClass)metaclass.getRepresentedElement()).getESuperTypes();
- for(EClass eClass : supers) {
+ if (metaclass.getAppliedStereotypes().isEmpty() || onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.FUSION)) {
+ if (metaclass.getRepresentedElement() instanceof EClass) {
+ EList<EClass> supers = ((EClass) metaclass.getRepresentedElement()).getESuperTypes();
+ for (EClass eClass : supers) {
VirtualMetaclass meta = findMetaclassWithNoRealStereoThatMatch(eClass, facade);
- if(meta != null) {
+ if (meta != null) {
output.add(meta);
}
}
}
- } else if(onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.MULTI_GENERALIZATION)) {
- if(MetamodelUtils.containsOnlyRequiredBaseMetaclass(metaclass.getAppliedStereotypes())) {
- if(metaclass.getAppliedStereotypes().get(0).getExtensionDefinition().getStereotype().getGenerals().isEmpty()) {
- output.add(findMetaclassWithNoRealStereoThatMatch((EClass)metaclass.getAppliedStereotypes().get(0).getBase(), facade));
+ } else if (onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.MULTI_GENERALIZATION)) {
+ if (MetamodelUtils.containsOnlyRequiredBaseMetaclass(metaclass.getAppliedStereotypes())) {
+ if (metaclass.getAppliedStereotypes().get(0).getExtensionDefinition().getStereotype().getGenerals().isEmpty()) {
+ output.add(findMetaclassWithNoRealStereoThatMatch(metaclass.getAppliedStereotypes().get(0).getBase(), facade));
} else {
EList<Classifier> supersStereo = metaclass.getAppliedStereotypes().get(0).getExtensionDefinition().getStereotype().getGenerals();
- for(Classifier superStereo : supersStereo) {
- output.add(findMetaclassThatMatch(metaclass.getRepresentedElement(), (Stereotype)superStereo, facade));
+ for (Classifier superStereo : supersStereo) {
+ output.add(findMetaclassThatMatch(metaclass.getRepresentedElement(), (Stereotype) superStereo, facade));
}
}
} else {
@@ -408,40 +409,40 @@ public class MetamodelUtils {
output.addAll(findThoseToSpecialize(metaclass, facade));
}
- //Add the StereotypeInterface to generals
- for(BaseMetaclass stereotype : metaclass.getAppliedStereotypes()) {
+ // Add the StereotypeInterface to generals
+ for (BaseMetaclass stereotype : metaclass.getAppliedStereotypes()) {
output.add(findStereotypeInterface(stereotype));
}
- } else if(onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.ASSOCIATION)) {
- for(BaseMetaclass baseMetaclass : metaclass.getAppliedStereotypes()) {
+ } else if (onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.ASSOCIATION)) {
+ for (BaseMetaclass baseMetaclass : metaclass.getAppliedStereotypes()) {
EList<Classifier> supersStereo = baseMetaclass.getExtensionDefinition().getStereotype().getGenerals();
- for(Classifier superStereo : supersStereo) {
- output.add(findMetaclassThatMatch(metaclass.getRepresentedElement(), (Stereotype)superStereo, facade));
+ for (Classifier superStereo : supersStereo) {
+ output.add(findMetaclassThatMatch(metaclass.getRepresentedElement(), (Stereotype) superStereo, facade));
}
}
- if(hasSiblings(metaclass.getAppliedStereotypes().get(0).getExtensionDefinition())) {
- //Add the StereotypeInterface to generals
- for(BaseMetaclass stereotype : metaclass.getAppliedStereotypes()) {
+ if (hasSiblings(metaclass.getAppliedStereotypes().get(0).getExtensionDefinition())) {
+ // Add the StereotypeInterface to generals
+ for (BaseMetaclass stereotype : metaclass.getAppliedStereotypes()) {
output.add(findStereotypeInterface(stereotype));
}
}
- } else if(onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.GENERALIZATION)) {
- for(BaseMetaclass baseMetaclass : metaclass.getAppliedStereotypes()) {
+ } else if (onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.GENERALIZATION)) {
+ for (BaseMetaclass baseMetaclass : metaclass.getAppliedStereotypes()) {
EList<Classifier> supersStereo = baseMetaclass.getExtensionDefinition().getStereotype().getGenerals();
- if(!supersStereo.isEmpty()) {
- for(Classifier superStereo : supersStereo) {
- output.add(findMetaclassThatMatch(metaclass.getRepresentedElement(), (Stereotype)superStereo, facade));
+ if (!supersStereo.isEmpty()) {
+ for (Classifier superStereo : supersStereo) {
+ output.add(findMetaclassThatMatch(metaclass.getRepresentedElement(), (Stereotype) superStereo, facade));
}
} else {
output.add(findMetaclassWithNoRealStereoThatMatch(StereotypeUtils.findBase(metaclass.getAppliedStereotypes().get(0).getExtensionDefinition()), facade));
}
}
- if(hasSiblings(metaclass.getAppliedStereotypes().get(0).getExtensionDefinition())) {
- //Add the StereotypeInterface to generals
- for(BaseMetaclass stereotype : metaclass.getAppliedStereotypes()) {
+ if (hasSiblings(metaclass.getAppliedStereotypes().get(0).getExtensionDefinition())) {
+ // Add the StereotypeInterface to generals
+ for (BaseMetaclass stereotype : metaclass.getAppliedStereotypes()) {
output.add(findStereotypeInterface(stereotype));
}
}
@@ -455,9 +456,9 @@ public class MetamodelUtils {
public static VirtualMetaclass findStereotypeInterface(BaseMetaclass stereotype) {
List<VirtualMetaclass> allVirtualMetaclasses = getOnlyVirtualMetaclasses(stereotype.getExtensionDefinition().getFacade().getVirtualmetamodel().getVirtualClassifiers());
- for(VirtualMetaclass virtualMetaclass : allVirtualMetaclasses) {
- if(virtualMetaclass.isStereotypeInterface()) {
- if(virtualMetaclass.getRepresentedElement() == stereotype.getExtensionDefinition().getStereotype()) {
+ for (VirtualMetaclass virtualMetaclass : allVirtualMetaclasses) {
+ if (virtualMetaclass.isStereotypeInterface()) {
+ if (virtualMetaclass.getRepresentedElement() == stereotype.getExtensionDefinition().getStereotype()) {
return virtualMetaclass;
}
}
@@ -467,19 +468,20 @@ public class MetamodelUtils {
/**
* Get {@link VirtualMetaclass} that are children (through generalization relationship) of a {@link VirtualMetaclass}
- *
+ *
* @param parent
* @return
*/
public static List<VirtualMetaclass> getChildren(VirtualMetaclass parent) {
List<VirtualMetaclass> children = new ArrayList<VirtualMetaclass>();
- for(VirtualClassifier classifier : parent.getMetamodel().getVirtualClassifiers()) {
+ for (VirtualClassifier classifier : parent.getMetamodel().getVirtualClassifiers()) {
- if(classifier instanceof VirtualMetaclass)
- if(MetamodelUtils.getFathers((VirtualMetaclass)classifier).contains(parent)) {
- children.add((VirtualMetaclass)classifier);
+ if (classifier instanceof VirtualMetaclass) {
+ if (MetamodelUtils.getFathers((VirtualMetaclass) classifier).contains(parent)) {
+ children.add((VirtualMetaclass) classifier);
}
+ }
}
return children;
@@ -487,7 +489,7 @@ public class MetamodelUtils {
/**
* Get all {@link VirtualMetaclass} (i.e. recursively) that are children (through generalization relationship) of a {@link VirtualMetaclass}
- *
+ *
* @param parent
* @return
*/
@@ -496,7 +498,7 @@ public class MetamodelUtils {
List<VirtualMetaclass> output = new ArrayList<VirtualMetaclass>();
toProcess.addAll(getChildren(parent));
- while(!toProcess.isEmpty()) {
+ while (!toProcess.isEmpty()) {
VirtualMetaclass child = toProcess.remove(0);
output.add(child);
toProcess.addAll(getChildren(child));
@@ -506,24 +508,24 @@ public class MetamodelUtils {
}
public static boolean mustBeAbstract(VirtualMetaclass metaclass) {
- if(metaclass.isStereotypeInterface()) {
+ if (metaclass.isStereotypeInterface()) {
return true;
}
- if(metaclass.getAppliedStereotypes().isEmpty()) {
- if(metaclass.getRepresentedElement() instanceof EClass) {
- if(((EClass)metaclass.getRepresentedElement()).isAbstract()) {
+ if (metaclass.getAppliedStereotypes().isEmpty()) {
+ if (metaclass.getRepresentedElement() instanceof EClass) {
+ if (((EClass) metaclass.getRepresentedElement()).isAbstract()) {
return true;
} else {
List<VirtualMetaclass> children = getChildren(metaclass);
- if(containsOnlyRequired(children)) {
+ if (containsOnlyRequired(children)) {
return true;
}
}
}
} else {
- if(containsOnlyAbstractStereotype(metaclass.getAppliedStereotypes())) {
+ if (containsOnlyAbstractStereotype(metaclass.getAppliedStereotypes())) {
return true;
}
}
@@ -533,9 +535,9 @@ public class MetamodelUtils {
}
private static boolean containsOnlyRequired(List<VirtualMetaclass> children) {
- if(!children.isEmpty()) {
- for(VirtualMetaclass metaclass : children) {
- if(!containsOnlyRequiredBaseMetaclass(metaclass.getAppliedStereotypes())) {
+ if (!children.isEmpty()) {
+ for (VirtualMetaclass metaclass : children) {
+ if (!containsOnlyRequiredBaseMetaclass(metaclass.getAppliedStereotypes())) {
return false;
}
}
@@ -547,10 +549,10 @@ public class MetamodelUtils {
public static boolean canBeAbstract(VirtualMetaclass metaclass) {
- if(!mustBeAbstract(metaclass)) {
- for(VirtualMetaclass child : getAllChildren(metaclass)) {
- if(child.isKept()) {
- if(!child.isAbstract()) {
+ if (!mustBeAbstract(metaclass)) {
+ for (VirtualMetaclass child : getAllChildren(metaclass)) {
+ if (child.isKept()) {
+ if (!child.isAbstract()) {
return true;
}
}
@@ -561,11 +563,11 @@ public class MetamodelUtils {
}
public static boolean isStereotypableByMetaclassKind(EClass classifier, Facade facade) {
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- for(BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
- if(baseMetaclass.isPossible() == true) {
- if(baseMetaclass.getBase() == classifier) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ if (extensionDefinition.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ for (BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
+ if (baseMetaclass.isPossible() == true) {
+ if (baseMetaclass.getBase() == classifier) {
return true;
}
}
@@ -577,8 +579,8 @@ public class MetamodelUtils {
public static List<Stereotype> getStereotypesFromBaseMetaclass(List<BaseMetaclass> list) {
List<Stereotype> result = new ArrayList<Stereotype>();
- for(BaseMetaclass baseMetaclass : list) {
- if(!result.contains(baseMetaclass.getExtensionDefinition().getStereotype())) {
+ for (BaseMetaclass baseMetaclass : list) {
+ if (!result.contains(baseMetaclass.getExtensionDefinition().getStereotype())) {
result.add(baseMetaclass.getExtensionDefinition().getStereotype());
}
}
@@ -589,18 +591,18 @@ public class MetamodelUtils {
VirtualClassifier output = null;
- //Verify that the virtualmetaclass doesn't exist already
+ // Verify that the virtualmetaclass doesn't exist already
boolean found = false;
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier.getRepresentedElement() == representedElement) {
- if(stereotypes != null) {
- List<Stereotype> classifierStereotypes = getStereotypesFromBaseMetaclass(((VirtualMetaclass)classifier).getAppliedStereotypes());
+ if (classifier.getRepresentedElement() == representedElement) {
+ if (stereotypes != null) {
+ List<Stereotype> classifierStereotypes = getStereotypesFromBaseMetaclass(((VirtualMetaclass) classifier).getAppliedStereotypes());
List<Stereotype> stereotypesToAdd = getStereotypesFromBaseMetaclass(stereotypes);
- if(classifierStereotypes.size() == stereotypesToAdd.size()) {
+ if (classifierStereotypes.size() == stereotypesToAdd.size()) {
- if(classifierStereotypes.containsAll(stereotypesToAdd)) {
- output = ((VirtualMetaclass)classifier);
+ if (classifierStereotypes.containsAll(stereotypesToAdd)) {
+ output = (classifier);
found = true;
break;
}
@@ -614,8 +616,8 @@ public class MetamodelUtils {
}
}
- if(!found) {
- if(representedElement instanceof PrimitiveType) {
+ if (!found) {
+ if (representedElement instanceof PrimitiveType) {
VirtualDatatype datatype = VirtualmetamodelFactory.eINSTANCE.createVirtualDatatype();
datatype.setKept(true);
datatype.setRepresentedElement(representedElement);
@@ -630,7 +632,7 @@ public class MetamodelUtils {
metaclass.setRepresentedElement(representedElement);
metaclass.setAbstract(false);
metaclass.setStereotypeInterface(false);
- if(stereotypes != null) {
+ if (stereotypes != null) {
metaclass.getAppliedStereotypes().addAll(stereotypes);
}
metaclass.setAliasName(alias);
@@ -650,16 +652,17 @@ public class MetamodelUtils {
VirtualEnum output = null;
boolean found = false;
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier instanceof VirtualEnum)
- if(classifier.getRepresentedElement() == representedElement) {
- output = (VirtualEnum)classifier;
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ if (classifier instanceof VirtualEnum) {
+ if (classifier.getRepresentedElement() == representedElement) {
+ output = (VirtualEnum) classifier;
found = true;
break;
}
+ }
}
- if(!found) {
+ if (!found) {
VirtualEnum enumeration = VirtualmetamodelFactory.eINSTANCE.createVirtualEnum();
enumeration.setKept(true);
@@ -668,14 +671,14 @@ public class MetamodelUtils {
AddCommand command = new AddCommand(editingDomain, facade.getVirtualmetamodel(), VirtualmetamodelPackage.eINSTANCE.getVirtualMetamodel_VirtualClassifiers(), enumeration);
editingDomain.getCommandStack().execute(command);
- if(enumeration.getRepresentedElement() instanceof EEnum) {
- EList<EEnumLiteral> literals = ((EEnum)enumeration.getRepresentedElement()).getELiterals();
- for(EEnumLiteral literal : literals) {
+ if (enumeration.getRepresentedElement() instanceof EEnum) {
+ EList<EEnumLiteral> literals = ((EEnum) enumeration.getRepresentedElement()).getELiterals();
+ for (EEnumLiteral literal : literals) {
MetamodelUtils.addLiteral(enumeration, literal, literal.getName(), facade, editingDomain);
}
- } else if(enumeration.getRepresentedElement() instanceof Enumeration) {
- EList<EnumerationLiteral> literals = ((Enumeration)enumeration.getRepresentedElement()).getOwnedLiterals();
- for(EnumerationLiteral literal : literals) {
+ } else if (enumeration.getRepresentedElement() instanceof Enumeration) {
+ EList<EnumerationLiteral> literals = ((Enumeration) enumeration.getRepresentedElement()).getOwnedLiterals();
+ for (EnumerationLiteral literal : literals) {
MetamodelUtils.addLiteral(enumeration, literal, literal.getName(), facade, editingDomain);
}
} else {
@@ -692,15 +695,15 @@ public class MetamodelUtils {
VirtualOperation output = null;
boolean found = false;
- for(VirtualOperation operation : metaclass.getOperations()) {
- if(operation.getRepresentedElement() == operationElement) {
+ for (VirtualOperation operation : metaclass.getOperations()) {
+ if (operation.getRepresentedElement() == operationElement) {
output = operation;
found = true;
break;
}
}
- if(!found) {
+ if (!found) {
VirtualOperation operation = VirtualmetamodelFactory.eINSTANCE.createVirtualOperation();
operation.setKept(true);
operation.setRepresentedElement(operationElement);
@@ -712,14 +715,14 @@ public class MetamodelUtils {
AddCommand command = new AddCommand(editingDomain, metaclass, VirtualmetamodelPackage.eINSTANCE.getVirtualMetaclass_Operations(), operation);
editingDomain.getCommandStack().execute(command);
- if(operation.getRepresentedElement() instanceof EOperation) {
- EList<EParameter> parameters = ((EOperation)operation.getRepresentedElement()).getEParameters();
- for(EParameter param : parameters) {
+ if (operation.getRepresentedElement() instanceof EOperation) {
+ EList<EParameter> parameters = ((EOperation) operation.getRepresentedElement()).getEParameters();
+ for (EParameter param : parameters) {
MetamodelUtils.addParameter(operation, param, param.getName(), facade, editingDomain);
}
- } else if(operation.getRepresentedElement() instanceof Operation) {
- EList<Parameter> parameters = ((Operation)operation.getRepresentedElement()).getOwnedParameters();
- for(Parameter param : parameters) {
+ } else if (operation.getRepresentedElement() instanceof Operation) {
+ EList<Parameter> parameters = ((Operation) operation.getRepresentedElement()).getOwnedParameters();
+ for (Parameter param : parameters) {
MetamodelUtils.addParameter(operation, param, param.getName(), facade, editingDomain);
}
} else {
@@ -737,16 +740,17 @@ public class MetamodelUtils {
VirtualDatatype output = null;
boolean found = false;
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier instanceof VirtualDatatype)
- if(classifier.getRepresentedElement() == representedElement) {
- output = (VirtualDatatype)classifier;
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ if (classifier instanceof VirtualDatatype) {
+ if (classifier.getRepresentedElement() == representedElement) {
+ output = (VirtualDatatype) classifier;
found = true;
break;
}
+ }
}
- if(!found) {
+ if (!found) {
VirtualDatatype datatype = VirtualmetamodelFactory.eINSTANCE.createVirtualDatatype();
datatype.setKept(true);
@@ -767,18 +771,19 @@ public class MetamodelUtils {
VirtualMetaclass output = null;
boolean found = false;
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier instanceof VirtualMetaclass)
- if(((VirtualMetaclass)classifier).isStereotypeInterface()) {
- if(classifier.getRepresentedElement() == representedElement) {
- output = (VirtualMetaclass)classifier;
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ if (classifier instanceof VirtualMetaclass) {
+ if (((VirtualMetaclass) classifier).isStereotypeInterface()) {
+ if (classifier.getRepresentedElement() == representedElement) {
+ output = (VirtualMetaclass) classifier;
found = true;
break;
}
}
+ }
}
- if(!found) {
+ if (!found) {
VirtualMetaclass metaclass = VirtualmetamodelFactory.eINSTANCE.createVirtualMetaclass();
metaclass.setKept(true);
metaclass.setRepresentedElement(representedElement);
@@ -797,23 +802,23 @@ public class MetamodelUtils {
}
public static VirtualClassifier createForType(EObject classifier, Facade facade, AdapterFactoryEditingDomain editingDomain) {
- if(classifier instanceof EClass) {
- VirtualClassifier metaclass = MetamodelUtils.addMetaclass(classifier, null, ((EClass)classifier).getName(), facade, editingDomain);
+ if (classifier instanceof EClass) {
+ VirtualClassifier metaclass = MetamodelUtils.addMetaclass(classifier, null, ((EClass) classifier).getName(), facade, editingDomain);
return metaclass;
- } else if(classifier instanceof EDataType) {
- if(classifier instanceof EEnum) {
- VirtualEnum enumeration = MetamodelUtils.addEnum(classifier, ((EEnum)classifier).getName(), facade, editingDomain);
+ } else if (classifier instanceof EDataType) {
+ if (classifier instanceof EEnum) {
+ VirtualEnum enumeration = MetamodelUtils.addEnum(classifier, ((EEnum) classifier).getName(), facade, editingDomain);
return enumeration;
} else {
- VirtualDatatype datatype = MetamodelUtils.addDatatype(classifier, ((EDataType)classifier).getName(), facade, editingDomain);
+ VirtualDatatype datatype = MetamodelUtils.addDatatype(classifier, ((EDataType) classifier).getName(), facade, editingDomain);
return datatype;
}
- } else if(classifier instanceof DataType) {
- VirtualClassifier dataype = MetamodelUtils.addMetaclass(classifier, null, ((DataType)classifier).getName(), facade, editingDomain);
+ } else if (classifier instanceof DataType) {
+ VirtualClassifier dataype = MetamodelUtils.addMetaclass(classifier, null, ((DataType) classifier).getName(), facade, editingDomain);
return dataype;
- } else if(classifier instanceof PrimitiveType) {
- // VirtualClassifier dataype = MetamodelUtils.addMetaclass(classifier, null, ((PrimitiveType)classifier).getName(), facade, editingDomain);
- // return dataype;
+ } else if (classifier instanceof PrimitiveType) {
+ // VirtualClassifier dataype = MetamodelUtils.addMetaclass(classifier, null, ((PrimitiveType)classifier).getName(), facade, editingDomain);
+ // return dataype;
}
return null;
}
@@ -822,13 +827,13 @@ public class MetamodelUtils {
int lower = 0;
int upper = 0;
- if(element instanceof ETypedElement) {
- lower = ((ETypedElement)element).getLowerBound();
- upper = ((ETypedElement)element).getUpperBound();
- } else if(element instanceof MultiplicityElement) {
+ if (element instanceof ETypedElement) {
+ lower = ((ETypedElement) element).getLowerBound();
+ upper = ((ETypedElement) element).getUpperBound();
+ } else if (element instanceof MultiplicityElement) {
- lower = ((MultiplicityElement)element).getLower();
- upper = ((MultiplicityElement)element).getUpper();
+ lower = ((MultiplicityElement) element).getLower();
+ upper = ((MultiplicityElement) element).getUpper();
}
virtualElement.setLower(lower);
@@ -836,54 +841,54 @@ public class MetamodelUtils {
}
public static void processTypedElement(EObject typedElement, Facade facade, AdapterFactoryEditingDomain editingDomain) {
- if(typedElement instanceof ETypedElement) {
+ if (typedElement instanceof ETypedElement) {
- EClassifier eType = ((ETypedElement)typedElement).getEType();
+ EClassifier eType = ((ETypedElement) typedElement).getEType();
- if(!containtsType(eType, facade)) {
+ if (!containtsType(eType, facade)) {
VirtualClassifier newType = createForType(eType, facade, editingDomain);
- if(newType instanceof VirtualMetaclass) {
- createProperties((VirtualMetaclass)newType, facade, editingDomain);
+ if (newType instanceof VirtualMetaclass) {
+ createProperties((VirtualMetaclass) newType, facade, editingDomain);
}
}
- } else if(typedElement instanceof TypedElement) {
+ } else if (typedElement instanceof TypedElement) {
- if(!(((TypedElement)typedElement).getType() instanceof Stereotype)) {
- if(((TypedElement)typedElement).getType() instanceof Enumeration) {
- EObject eType = ((TypedElement)typedElement).getType();
- String name = ((TypedElement)typedElement).getType().getName();
- if(!containtsType(eType, facade)) {
+ if (!(((TypedElement) typedElement).getType() instanceof Stereotype)) {
+ if (((TypedElement) typedElement).getType() instanceof Enumeration) {
+ EObject eType = ((TypedElement) typedElement).getType();
+ String name = ((TypedElement) typedElement).getType().getName();
+ if (!containtsType(eType, facade)) {
MetamodelUtils.addEnum(eType, name, facade, editingDomain);
}
- } else if(((TypedElement)typedElement).getType() instanceof DataType) {
- if(((TypedElement)typedElement).getType() instanceof PrimitiveType) {
- //Check if it is a UML primitivetype
- EObject eType = StereotypeUtils.findEClass((Classifier)((TypedElement)typedElement).getType());
- if(eType != null) {
- if(!containtsType(eType, facade)) {
- VirtualClassifier virtualClassifier = createForType((EClassifier)eType, facade, editingDomain);
- if(virtualClassifier instanceof VirtualMetaclass) {
- createProperties((VirtualMetaclass)virtualClassifier, facade, editingDomain);
+ } else if (((TypedElement) typedElement).getType() instanceof DataType) {
+ if (((TypedElement) typedElement).getType() instanceof PrimitiveType) {
+ // Check if it is a UML primitivetype
+ EObject eType = StereotypeUtils.findEClass((Classifier) ((TypedElement) typedElement).getType());
+ if (eType != null) {
+ if (!containtsType(eType, facade)) {
+ VirtualClassifier virtualClassifier = createForType(eType, facade, editingDomain);
+ if (virtualClassifier instanceof VirtualMetaclass) {
+ createProperties((VirtualMetaclass) virtualClassifier, facade, editingDomain);
}
}
} else {
- createForType(((TypedElement)typedElement).getType(), facade, editingDomain);
+ createForType(((TypedElement) typedElement).getType(), facade, editingDomain);
}
} else {
- VirtualClassifier virtualClassifier = createForType(((TypedElement)typedElement).getType(), facade, editingDomain);
- if(virtualClassifier instanceof VirtualMetaclass) {
- createProperties((VirtualMetaclass)virtualClassifier, facade, editingDomain);
+ VirtualClassifier virtualClassifier = createForType(((TypedElement) typedElement).getType(), facade, editingDomain);
+ if (virtualClassifier instanceof VirtualMetaclass) {
+ createProperties((VirtualMetaclass) virtualClassifier, facade, editingDomain);
}
}
- } else if(((TypedElement)typedElement).getType() instanceof org.eclipse.uml2.uml.Class) {
- EClassifier eClass = StereotypeUtils.findEClass((Classifier)((TypedElement)typedElement).getType());
- if(eClass == null) {
+ } else if (((TypedElement) typedElement).getType() instanceof org.eclipse.uml2.uml.Class) {
+ EClassifier eClass = StereotypeUtils.findEClass((Classifier) ((TypedElement) typedElement).getType());
+ if (eClass == null) {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.MetamodelUtils_5);
}
} else {
- org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.MetamodelUtils_6 + ((TypedElement)typedElement).getType());
+ org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.MetamodelUtils_6 + ((TypedElement) typedElement).getType());
}
}
@@ -895,13 +900,13 @@ public class MetamodelUtils {
public static void addProperty(VirtualMetaclass metaclass, EObject propertyElement, EObject type, String alias, Facade facade, AdapterFactoryEditingDomain editingDomain) {
boolean found = false;
- for(VirtualProperty property : metaclass.getProperties()) {
- if(property.getRepresentedElement() == propertyElement) {
+ for (VirtualProperty property : metaclass.getProperties()) {
+ if (property.getRepresentedElement() == propertyElement) {
found = true;
}
}
- if(!found) {
+ if (!found) {
processTypedElement(propertyElement, facade, editingDomain);
@@ -949,33 +954,33 @@ public class MetamodelUtils {
public static void createStereotypeProperties(VirtualMetaclass metaclass, Facade facade, AdapterFactoryEditingDomain editingDomain) {
// Add stereotype properties only if it is not already added to a father
- for(BaseMetaclass appliedStereotype : metaclass.getAppliedStereotypes()) {
+ for (BaseMetaclass appliedStereotype : metaclass.getAppliedStereotypes()) {
List<VirtualMetaclass> allFathers = MetamodelUtils.getAllFathers(metaclass);
boolean alreadyApplied = false;
- for(VirtualMetaclass virtualMetaclass : allFathers) {
- if(virtualMetaclass.getAppliedStereotypes().contains(appliedStereotype)) {
+ for (VirtualMetaclass virtualMetaclass : allFathers) {
+ if (virtualMetaclass.getAppliedStereotypes().contains(appliedStereotype)) {
alreadyApplied = true;
}
}
- if(!alreadyApplied) {
+ if (!alreadyApplied) {
- if(!hasSiblings(appliedStereotype.getExtensionDefinition())) {
+ if (!hasSiblings(appliedStereotype.getExtensionDefinition())) {
EList<Property> stereotypeProperties = appliedStereotype.getExtensionDefinition().getStereotype().getAttributes();
- for(Property property : stereotypeProperties) {
+ for (Property property : stereotypeProperties) {
- if(appliedStereotype.getExtensionDefinition().getKind() == ExtensionDefinitionKind.ASSOCIATION) {
- if(!property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
+ if (appliedStereotype.getExtensionDefinition().getKind() == ExtensionDefinitionKind.ASSOCIATION) {
+ if (!property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
MetamodelUtils.addProperty(metaclass, property, property.getType(), property.getName(), facade, editingDomain);
} else {
- if(appliedStereotype.getExtensionDefinition().getExtension().getMemberEnds().contains(property)) {
+ if (appliedStereotype.getExtensionDefinition().getExtension().getMemberEnds().contains(property)) {
MetamodelUtils.addProperty(metaclass, property, property.getType(), property.getName(), facade, editingDomain);
}
}
} else {
- if(!property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
+ if (!property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
MetamodelUtils.addProperty(metaclass, property, property.getType(), property.getName(), facade, editingDomain);
}
}
@@ -983,11 +988,11 @@ public class MetamodelUtils {
} else {
EList<Property> stereotypeProperties = appliedStereotype.getExtensionDefinition().getStereotype().getAttributes();
- for(Property property : stereotypeProperties) {
+ for (Property property : stereotypeProperties) {
- if(appliedStereotype.getExtensionDefinition().getKind() == ExtensionDefinitionKind.ASSOCIATION) {
- if(property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
- if(appliedStereotype.getExtensionDefinition().getExtension().getMemberEnds().contains(property)) {
+ if (appliedStereotype.getExtensionDefinition().getKind() == ExtensionDefinitionKind.ASSOCIATION) {
+ if (property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
+ if (appliedStereotype.getExtensionDefinition().getExtension().getMemberEnds().contains(property)) {
MetamodelUtils.addProperty(metaclass, property, property.getType(), property.getName(), facade, editingDomain);
}
}
@@ -1001,25 +1006,25 @@ public class MetamodelUtils {
}
public static void createProperties(VirtualMetaclass metaclass, Facade facade, AdapterFactoryEditingDomain editingDomain) {
- if(metaclass.isStereotypeInterface()) {
- EList<Property> stereotypeProperties = ((Stereotype)metaclass.getRepresentedElement()).getAttributes();
- for(Property property : stereotypeProperties) {
- if(!property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
+ if (metaclass.isStereotypeInterface()) {
+ EList<Property> stereotypeProperties = ((Stereotype) metaclass.getRepresentedElement()).getAttributes();
+ for (Property property : stereotypeProperties) {
+ if (!property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
MetamodelUtils.addProperty(metaclass, property, property.getType(), property.getName(), facade, editingDomain);
}
}
} else {
- if(!onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.MULTI_GENERALIZATION) || metaclass.getAppliedStereotypes().isEmpty()) {
- if(metaclass.getRepresentedElement() instanceof EClass) {
- if(onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.FUSION) || metaclass.getAppliedStereotypes().isEmpty()) {
- EList<EStructuralFeature> properties = ((EClass)metaclass.getRepresentedElement()).getEStructuralFeatures();
- for(EStructuralFeature eStructuralFeature : properties) {
+ if (!onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.MULTI_GENERALIZATION) || metaclass.getAppliedStereotypes().isEmpty()) {
+ if (metaclass.getRepresentedElement() instanceof EClass) {
+ if (onlyOneKind(metaclass.getAppliedStereotypes(), ExtensionDefinitionKind.FUSION) || metaclass.getAppliedStereotypes().isEmpty()) {
+ EList<EStructuralFeature> properties = ((EClass) metaclass.getRepresentedElement()).getEStructuralFeatures();
+ for (EStructuralFeature eStructuralFeature : properties) {
MetamodelUtils.addProperty(metaclass, eStructuralFeature, eStructuralFeature.getEType(), eStructuralFeature.getName(), facade, editingDomain);
}
}
- } else if(metaclass.getRepresentedElement() instanceof DataType) {
- EList<Property> properties = ((DataType)metaclass.getRepresentedElement()).getAttributes();
- for(Property property : properties) {
+ } else if (metaclass.getRepresentedElement() instanceof DataType) {
+ EList<Property> properties = ((DataType) metaclass.getRepresentedElement()).getAttributes();
+ for (Property property : properties) {
MetamodelUtils.addProperty(metaclass, property, property.getType(), property.getName(), facade, editingDomain);
}
} else {
@@ -1032,16 +1037,16 @@ public class MetamodelUtils {
}
public static void createPropertiesForAll(Facade facade, AdapterFactoryEditingDomain editingDomain) {
- //Only VirtualMetaclasses can have properties
- for(VirtualMetaclass metaclass : getOnlyVirtualMetaclasses(facade.getVirtualmetamodel().getVirtualClassifiers())) {
+ // Only VirtualMetaclasses can have properties
+ for (VirtualMetaclass metaclass : getOnlyVirtualMetaclasses(facade.getVirtualmetamodel().getVirtualClassifiers())) {
createProperties(metaclass, facade, editingDomain);
}
}
protected static boolean containtsType(EObject type, Facade facade) {
- for(VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier.isKept()) {
- if(classifier.getRepresentedElement() == type) {
+ for (VirtualClassifier classifier : facade.getVirtualmetamodel().getVirtualClassifiers()) {
+ if (classifier.isKept()) {
+ if (classifier.getRepresentedElement() == type) {
return true;
}
}
@@ -1053,12 +1058,12 @@ public class MetamodelUtils {
public static List<VirtualClassifier> getElements(Facade inputElement) {
List<VirtualClassifier> elements = new ArrayList<VirtualClassifier>();
- if(inputElement.getVirtualmetamodel() != null) {
- for(VirtualClassifier classifier : inputElement.getVirtualmetamodel().getVirtualClassifiers()) {
+ if (inputElement.getVirtualmetamodel() != null) {
+ for (VirtualClassifier classifier : inputElement.getVirtualmetamodel().getVirtualClassifiers()) {
- if(classifier instanceof VirtualMetaclass) {
- if(MetamodelUtils.getFathers((VirtualMetaclass)classifier).isEmpty()) {
- elements.add((VirtualMetaclass)classifier);
+ if (classifier instanceof VirtualMetaclass) {
+ if (MetamodelUtils.getFathers((VirtualMetaclass) classifier).isEmpty()) {
+ elements.add(classifier);
}
} else {
elements.add(classifier);
@@ -1070,12 +1075,12 @@ public class MetamodelUtils {
}
public static void createGeneralizations(Facade facade, AdapterFactoryEditingDomain editingDomain) {
- for(VirtualMetaclass metaclass : MetamodelUtils.getOnlyVirtualMetaclasses(facade.getVirtualmetamodel().getVirtualClassifiers())) {
+ for (VirtualMetaclass metaclass : MetamodelUtils.getOnlyVirtualMetaclasses(facade.getVirtualmetamodel().getVirtualClassifiers())) {
List<VirtualMetaclass> fathers = getFathers(metaclass);
List<VirtualMetaclass> fathersToAdd = new ArrayList<VirtualMetaclass>();
- for(VirtualMetaclass father : fathers) {
- if(!metaclass.getParents().contains(father)) {
+ for (VirtualMetaclass father : fathers) {
+ if (!metaclass.getParents().contains(father)) {
fathersToAdd.add(father);
}
}
@@ -1086,17 +1091,17 @@ public class MetamodelUtils {
}
public static void createOperationsForAll(Facade facade, AdapterFactoryEditingDomain editingDomain) {
- //Only VirtualMetaclasses can have operations
- for(VirtualMetaclass metaclass : getOnlyVirtualMetaclasses(facade.getVirtualmetamodel().getVirtualClassifiers())) {
+ // Only VirtualMetaclasses can have operations
+ for (VirtualMetaclass metaclass : getOnlyVirtualMetaclasses(facade.getVirtualmetamodel().getVirtualClassifiers())) {
createOperations(metaclass, facade, editingDomain);
}
}
private static void createOperations(VirtualMetaclass metaclass, Facade facade, AdapterFactoryEditingDomain editingDomain) {
- if(metaclass.getRepresentedElement() instanceof EClass) {
- if(metaclass.getAppliedStereotypes().isEmpty()) {
- EList<EOperation> operations = ((EClass)metaclass.getRepresentedElement()).getEOperations();
- for(EOperation eOperation : operations) {
+ if (metaclass.getRepresentedElement() instanceof EClass) {
+ if (metaclass.getAppliedStereotypes().isEmpty()) {
+ EList<EOperation> operations = ((EClass) metaclass.getRepresentedElement()).getEOperations();
+ for (EOperation eOperation : operations) {
addOperation(metaclass, eOperation, eOperation.getName(), facade, editingDomain);
}
}
@@ -1105,24 +1110,24 @@ public class MetamodelUtils {
public static void postProcessTypedElements(Facade facade, AdapterFactoryEditingDomain editingDomain) {
TreeIterator<EObject> it = facade.eAllContents();
- while(it.hasNext()) {
- EObject eObject = (EObject)it.next();
+ while (it.hasNext()) {
+ EObject eObject = it.next();
- if(eObject instanceof VirtualTypedElement) {
- VirtualTypedElement virtualTypedElement = (VirtualTypedElement)eObject;
+ if (eObject instanceof VirtualTypedElement) {
+ VirtualTypedElement virtualTypedElement = (VirtualTypedElement) eObject;
VirtualClassifier representingType = null;
- if(virtualTypedElement.getRepresentedElement() instanceof TypedElement) {
- representingType = MetamodelUtils.findClassifierThatMatch(((TypedElement)virtualTypedElement.getRepresentedElement()).getType(), facade);
- if(representingType != null) {
+ if (virtualTypedElement.getRepresentedElement() instanceof TypedElement) {
+ representingType = MetamodelUtils.findClassifierThatMatch(((TypedElement) virtualTypedElement.getRepresentedElement()).getType(), facade);
+ if (representingType != null) {
virtualTypedElement.setType(representingType);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.MetamodelUtils_11 + virtualTypedElement);
}
} else {
- if(virtualTypedElement.getRepresentedElement() instanceof ETypedElement) {
- if(((ETypedElement)virtualTypedElement.getRepresentedElement()).getEType() != null) {
- representingType = MetamodelUtils.findClassifierThatMatch(((ETypedElement)virtualTypedElement.getRepresentedElement()).getEType(), facade);
- if(representingType != null) {
+ if (virtualTypedElement.getRepresentedElement() instanceof ETypedElement) {
+ if (((ETypedElement) virtualTypedElement.getRepresentedElement()).getEType() != null) {
+ representingType = MetamodelUtils.findClassifierThatMatch(((ETypedElement) virtualTypedElement.getRepresentedElement()).getEType(), facade);
+ if (representingType != null) {
virtualTypedElement.setType(representingType);
} else {
org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info(Messages.MetamodelUtils_12 + virtualTypedElement);
@@ -1139,17 +1144,17 @@ public class MetamodelUtils {
public static void postProcessUseRepresented(Facade facade, AdapterFactoryEditingDomain editingDomain) {
TreeIterator<EObject> it = facade.eAllContents();
- while(it.hasNext()) {
- EObject virtualElement = (EObject)it.next();
+ while (it.hasNext()) {
+ EObject virtualElement = it.next();
- if(virtualElement instanceof VirtualElement) {
- EObject represented = ((VirtualElement)virtualElement).getRepresentedElement();
+ if (virtualElement instanceof VirtualElement) {
+ EObject represented = ((VirtualElement) virtualElement).getRepresentedElement();
TreeIterator<EObject> ecoreIt = EcorePackage.eINSTANCE.eAllContents();
- while(ecoreIt.hasNext()) {
- EObject ecoreEObject = (EObject)ecoreIt.next();
- if(ecoreEObject == represented) {
- ((VirtualElement)virtualElement).setUseRepresented(true);
+ while (ecoreIt.hasNext()) {
+ EObject ecoreEObject = ecoreIt.next();
+ if (ecoreEObject == represented) {
+ ((VirtualElement) virtualElement).setUseRepresented(true);
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionContentProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionContentProvider.java
index caa7dbeee3e..e7bfeb705e2 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionContentProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionContentProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -29,18 +29,18 @@ import org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind;
public class ExtensionDefintionContentProvider implements ITreeContentProvider {
/**
- *
+ *
* @see org.eclipse.jface.viewers.IContentProvider#dispose()
- *
+ *
*/
public void dispose() {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object)
- *
+ *
* @param viewer
* @param oldInput
* @param newInput
@@ -50,18 +50,18 @@ public class ExtensionDefintionContentProvider implements ITreeContentProvider {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.ITreeContentProvider#getElements(java.lang.Object)
- *
+ *
* @param inputElement
* @return
*/
public Object[] getElements(Object inputElement) {
HashSet<ExtensionDefinition> output = new HashSet<ExtensionDefinition>();
- if(inputElement instanceof Facade) {
- EList<ExtensionDefinition> extensionsDefinitions = ((Facade)inputElement).getExtensionDefinitions();
- for(ExtensionDefinition extensionDefinition : extensionsDefinitions) {
+ if (inputElement instanceof Facade) {
+ EList<ExtensionDefinition> extensionsDefinitions = ((Facade) inputElement).getExtensionDefinitions();
+ for (ExtensionDefinition extensionDefinition : extensionsDefinitions) {
output.add(extensionDefinition);
}
}
@@ -70,21 +70,21 @@ public class ExtensionDefintionContentProvider implements ITreeContentProvider {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.ITreeContentProvider#getChildren(java.lang.Object)
- *
+ *
* @param parentElement
* @return
*/
public Object[] getChildren(Object parentElement) {
List<BaseMetaclass> output = new ArrayList<BaseMetaclass>();
- if(parentElement instanceof ExtensionDefinition) {
+ if (parentElement instanceof ExtensionDefinition) {
- ExtensionDefinition parent = (ExtensionDefinition)parentElement;
+ ExtensionDefinition parent = (ExtensionDefinition) parentElement;
- if(parent.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- for(BaseMetaclass baseMetaclass : parent.getBaseMetaclasses()) {
- if(!((EClass)baseMetaclass.getBase()).isAbstract()) {
+ if (parent.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ for (BaseMetaclass baseMetaclass : parent.getBaseMetaclasses()) {
+ if (!((EClass) baseMetaclass.getBase()).isAbstract()) {
output.add(baseMetaclass);
}
}
@@ -94,9 +94,9 @@ public class ExtensionDefintionContentProvider implements ITreeContentProvider {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.ITreeContentProvider#getParent(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -105,14 +105,14 @@ public class ExtensionDefintionContentProvider implements ITreeContentProvider {
}
/**
- *
+ *
* @see org.eclipse.jface.viewers.ITreeContentProvider#hasChildren(java.lang.Object)
- *
+ *
* @param element
* @return
*/
public boolean hasChildren(Object element) {
- if(getChildren(element).length != 0) {
+ if (getChildren(element).length != 0) {
return true;
} else {
return false;
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionLabelProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionLabelProvider.java
index 3508440f858..57414d19d33 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionLabelProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/ExtensionDefintionLabelProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -34,7 +34,7 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#addListener(org.eclipse.jface.viewers.ILabelProviderListener)
- *
+ *
* @param listener
*/
@@ -44,7 +44,7 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#dispose()
- *
+ *
*/
public void dispose() {
@@ -53,7 +53,7 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#isLabelProperty(java.lang.Object, java.lang.String)
- *
+ *
* @param element
* @param property
* @return
@@ -65,7 +65,7 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#removeListener(org.eclipse.jface.viewers.ILabelProviderListener)
- *
+ *
* @param listener
*/
@@ -75,41 +75,41 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
/**
* @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnImage(java.lang.Object, int)
- *
+ *
* @param element
* @param columnIndex
* @return
*/
public Image getColumnImage(Object element, int columnIndex) {
- switch(columnIndex) {
+ switch (columnIndex) {
case 0:
break;
case 1:
- if(element instanceof ExtensionDefinition) {
- if(((ExtensionDefinition)element).getKind() == ExtensionDefinitionKind.ASSOCIATION) {
- if(((ExtensionDefinition)element).getExtension().isRequired()) {
+ if (element instanceof ExtensionDefinition) {
+ if (((ExtensionDefinition) element).getKind() == ExtensionDefinitionKind.ASSOCIATION) {
+ if (((ExtensionDefinition) element).getExtension().isRequired()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/associationRequired.png"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/association.png"); //$NON-NLS-1$
}
- } else if(((ExtensionDefinition)element).getKind() == ExtensionDefinitionKind.GENERALIZATION) {
- if(((ExtensionDefinition)element).getExtension().isRequired()) {
+ } else if (((ExtensionDefinition) element).getKind() == ExtensionDefinitionKind.GENERALIZATION) {
+ if (((ExtensionDefinition) element).getExtension().isRequired()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/generalizationRequired.png"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/generalization.png"); //$NON-NLS-1$
}
- } else if(((ExtensionDefinition)element).getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- if(((ExtensionDefinition)element).getExtension().isRequired()) {
+ } else if (((ExtensionDefinition) element).getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ if (((ExtensionDefinition) element).getExtension().isRequired()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/multigeneralizationRequired.png"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/multigeneralization.png"); //$NON-NLS-1$
}
- } else if(((ExtensionDefinition)element).getKind() == ExtensionDefinitionKind.FUSION) {
- if(((ExtensionDefinition)element).getExtension().isRequired()) {
+ } else if (((ExtensionDefinition) element).getKind() == ExtensionDefinitionKind.FUSION) {
+ if (((ExtensionDefinition) element).getExtension().isRequired()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/fusionRequired.png"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/fusion.png"); //$NON-NLS-1$
@@ -120,9 +120,9 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
}
break;
case 2:
- if(element instanceof BaseMetaclass) {
- if(!((BaseMetaclass)element).getExtensionDefinition().getExtension().isRequired()) {
- if(((BaseMetaclass)element).isPossible()) {
+ if (element instanceof BaseMetaclass) {
+ if (!((BaseMetaclass) element).getExtensionDefinition().getExtension().isRequired()) {
+ if (((BaseMetaclass) element).isPossible()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/checked.gif"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/unchecked.gif"); //$NON-NLS-1$
@@ -141,48 +141,48 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
/**
* @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnText(java.lang.Object, int)
- *
+ *
* @param element
* @param columnIndex
* @return
*/
public String getColumnText(Object element, int columnIndex) {
- switch(columnIndex) {
+ switch (columnIndex) {
case 0:
- if(element instanceof ExtensionDefinition) {
+ if (element instanceof ExtensionDefinition) {
- String name = ((ExtensionDefinition)element).getStereotype().getQualifiedName();
- if(!((ExtensionDefinition)element).getStereotype().getGenerals().isEmpty()) {
+ String name = ((ExtensionDefinition) element).getStereotype().getQualifiedName();
+ if (!((ExtensionDefinition) element).getStereotype().getGenerals().isEmpty()) {
name += " [-> "; //$NON-NLS-1$
- name += ((ExtensionDefinition)element).getStereotype().getGenerals().get(0).getQualifiedName();
- if(((ExtensionDefinition)element).getStereotype().getGenerals().size() > 1) {
- for(int i = 1; i < ((ExtensionDefinition)element).getStereotype().getGenerals().size(); i++) {
- name += ", " + ((ExtensionDefinition)element).getStereotype().getGenerals().get(i).getQualifiedName(); //$NON-NLS-1$
+ name += ((ExtensionDefinition) element).getStereotype().getGenerals().get(0).getQualifiedName();
+ if (((ExtensionDefinition) element).getStereotype().getGenerals().size() > 1) {
+ for (int i = 1; i < ((ExtensionDefinition) element).getStereotype().getGenerals().size(); i++) {
+ name += ", " + ((ExtensionDefinition) element).getStereotype().getGenerals().get(i).getQualifiedName(); //$NON-NLS-1$
}
}
name += "]"; //$NON-NLS-1$
}
name += Messages.ExtensionDefintionLabelProvider_13;
- if(((ExtensionDefinition)element).getKind() != ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- if(StereotypeUtils.findBase((ExtensionDefinition)element) != null) {
- name += " " + StereotypeUtils.findBase((ExtensionDefinition)element).getName(); //$NON-NLS-1$
+ if (((ExtensionDefinition) element).getKind() != ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ if (StereotypeUtils.findBase((ExtensionDefinition) element) != null) {
+ name += " " + StereotypeUtils.findBase((ExtensionDefinition) element).getName(); //$NON-NLS-1$
}
}
return name;
- } else if(element instanceof BaseMetaclass) {
- if(((BaseMetaclass)element).getBase() instanceof EClass) {
+ } else if (element instanceof BaseMetaclass) {
+ if (((BaseMetaclass) element).getBase() instanceof EClass) {
- String name = ((EClass)((BaseMetaclass)element).getBase()).getName();
+ String name = ((EClass) ((BaseMetaclass) element).getBase()).getName();
return name;
}
}
break;
case 1:
- if(element instanceof ExtensionDefinition) {
- return ((ExtensionDefinition)element).getKind().getName();
+ if (element instanceof ExtensionDefinition) {
+ return ((ExtensionDefinition) element).getKind().getName();
}
break;
case 2:
@@ -198,7 +198,7 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
/**
* @see org.eclipse.jface.viewers.ILabelProvider#getImage(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -209,7 +209,7 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
/**
* @see org.eclipse.jface.viewers.ILabelProvider#getText(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -220,14 +220,14 @@ public class ExtensionDefintionLabelProvider implements ITableLabelProvider, ILa
/**
* @see org.eclipse.jface.viewers.IFontProvider#getFont(java.lang.Object)
- *
+ *
* @param element
* @return
*/
public Font getFont(Object element) {
- if(element instanceof ExtensionDefinition) {
- if(((ExtensionDefinition)element).getStereotype().isAbstract()) {
+ if (element instanceof ExtensionDefinition) {
+ if (((ExtensionDefinition) element).getStereotype().isAbstract()) {
return JFaceResources.getFontRegistry().getItalic(JFaceResources.DEFAULT_FONT);
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesContentProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesContentProvider.java
index 0fc542ab5c5..96ec83aff4c 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesContentProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesContentProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -24,7 +24,7 @@ public class IncompatibilitiesContentProvider implements IStructuredContentProvi
/**
* @see org.eclipse.jface.viewers.IContentProvider#dispose()
- *
+ *
*/
public void dispose() {
@@ -33,7 +33,7 @@ public class IncompatibilitiesContentProvider implements IStructuredContentProvi
/**
* @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object)
- *
+ *
* @param viewer
* @param oldInput
* @param newInput
@@ -45,7 +45,7 @@ public class IncompatibilitiesContentProvider implements IStructuredContentProvi
/**
* @see org.eclipse.jface.viewers.IStructuredContentProvider#getElements(java.lang.Object)
- *
+ *
* @param inputElement
* @return
*/
@@ -53,9 +53,9 @@ public class IncompatibilitiesContentProvider implements IStructuredContentProvi
public Object[] getElements(Object inputElement) {
HashSet<Combination> output = new HashSet<Combination>();
- if(inputElement instanceof BaseMetaclass) {
- output.addAll(((BaseMetaclass)inputElement).getIncompatibleStereotypes());
- output.addAll(((BaseMetaclass)inputElement).getCompatibleStereotypes());
+ if (inputElement instanceof BaseMetaclass) {
+ output.addAll(((BaseMetaclass) inputElement).getIncompatibleStereotypes());
+ output.addAll(((BaseMetaclass) inputElement).getCompatibleStereotypes());
}
return output.toArray();
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesLabelProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesLabelProvider.java
index 165e0b6d717..b5a45ec43a4 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesLabelProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/IncompatibilitiesLabelProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -41,7 +41,7 @@ public class IncompatibilitiesLabelProvider implements ITableLabelProvider, IFon
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#addListener(org.eclipse.jface.viewers.ILabelProviderListener)
- *
+ *
* @param listener
*/
@@ -51,7 +51,7 @@ public class IncompatibilitiesLabelProvider implements ITableLabelProvider, IFon
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#dispose()
- *
+ *
*/
public void dispose() {
@@ -60,7 +60,7 @@ public class IncompatibilitiesLabelProvider implements ITableLabelProvider, IFon
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#isLabelProperty(java.lang.Object, java.lang.String)
- *
+ *
* @param element
* @param property
* @return
@@ -72,7 +72,7 @@ public class IncompatibilitiesLabelProvider implements ITableLabelProvider, IFon
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#removeListener(org.eclipse.jface.viewers.ILabelProviderListener)
- *
+ *
* @param listener
*/
@@ -82,28 +82,28 @@ public class IncompatibilitiesLabelProvider implements ITableLabelProvider, IFon
/**
* @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnImage(java.lang.Object, int)
- *
+ *
* @param element
* @param columnIndex
* @return
*/
public Image getColumnImage(Object element, int columnIndex) {
- switch(columnIndex) {
+ switch (columnIndex) {
case 0:
- if(element instanceof Combination) {
+ if (element instanceof Combination) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/combinaison.png"); //$NON-NLS-1$
}
break;
case 1:
- if(element instanceof Combination) {
+ if (element instanceof Combination) {
ISelection selection = FacadeSpecificEditor.getExtensionDefintionTreeViewer().getSelection();
- if(selection instanceof IStructuredSelection) {
- Object first = ((IStructuredSelection)selection).getFirstElement();
+ if (selection instanceof IStructuredSelection) {
+ Object first = ((IStructuredSelection) selection).getFirstElement();
- if(first instanceof BaseMetaclass) {
- EList<Combination> incompatibleStereotypes = ((BaseMetaclass)first).getIncompatibleStereotypes();
- if(incompatibleStereotypes.contains(element)) {
+ if (first instanceof BaseMetaclass) {
+ EList<Combination> incompatibleStereotypes = ((BaseMetaclass) first).getIncompatibleStereotypes();
+ if (incompatibleStereotypes.contains(element)) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/unchecked.gif"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/checked.gif"); //$NON-NLS-1$
@@ -123,31 +123,31 @@ public class IncompatibilitiesLabelProvider implements ITableLabelProvider, IFon
/**
* Produce sibling list.
- *
+ *
* @param stereotype
- * the stereotype
+ * the stereotype
* @return the string
*/
protected String produceSiblingList(Stereotype stereotype) {
String output = ""; //$NON-NLS-1$
HashSet<Stereotype> siblings = ProfileUtils.getSiblings(stereotype);
List<Classifier> siblingsList = new ArrayList<Classifier>(siblings);
- if(siblingsList.size() > 1) {
+ if (siblingsList.size() > 1) {
output += "["; //$NON-NLS-1$
}
- if(!siblingsList.isEmpty()) {
+ if (!siblingsList.isEmpty()) {
output += siblingsList.get(0).getQualifiedName();
- if(siblingsList.size() > 1) {
- for(int i = 1; i < siblingsList.size(); i++) {
+ if (siblingsList.size() > 1) {
+ for (int i = 1; i < siblingsList.size(); i++) {
output += ", "; //$NON-NLS-1$
output += siblingsList.get(i).getQualifiedName();
}
}
}
- if(siblings.size() > 1) {
+ if (siblings.size() > 1) {
output += "]"; //$NON-NLS-1$
}
return output;
@@ -155,23 +155,23 @@ public class IncompatibilitiesLabelProvider implements ITableLabelProvider, IFon
/**
* @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnText(java.lang.Object, int)
- *
+ *
* @param element
* @param columnIndex
* @return
*/
public String getColumnText(Object element, int columnIndex) {
- switch(columnIndex) {
+ switch (columnIndex) {
case 0:
String name = ""; //$NON-NLS-1$
- if(element instanceof Combination) {
+ if (element instanceof Combination) {
- Combination combination = (Combination)element;
- if(!combination.getMembers().isEmpty()) {
+ Combination combination = (Combination) element;
+ if (!combination.getMembers().isEmpty()) {
name += combination.getMembers().get(0).getExtensionDefinition().getStereotype().getName();
- if(((Combination)element).getMembers().size() > 1) {
- for(int i = 1; i < combination.getMembers().size(); i++) {
+ if (((Combination) element).getMembers().size() > 1) {
+ for (int i = 1; i < combination.getMembers().size(); i++) {
name += ", "; //$NON-NLS-1$
name += combination.getMembers().get(i).getExtensionDefinition().getStereotype().getName();
}
@@ -195,14 +195,14 @@ public class IncompatibilitiesLabelProvider implements ITableLabelProvider, IFon
/**
* @see org.eclipse.jface.viewers.IFontProvider#getFont(java.lang.Object)
- *
+ *
* @param element
* @return
*/
public Font getFont(Object element) {
- if(element instanceof ExtensionDefinition) {
- if(((ExtensionDefinition)element).getStereotype().isAbstract()) {
+ if (element instanceof ExtensionDefinition) {
+ if (((ExtensionDefinition) element).getStereotype().isAbstract()) {
return JFaceResources.getFontRegistry().getItalic(JFaceResources.DEFAULT_FONT);
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelContentProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelContentProvider.java
index c1f8cde5ed8..a399708ade7 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelContentProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelContentProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -29,7 +29,7 @@ public class MetamodelContentProvider implements ITreeContentProvider {
/**
* @see org.eclipse.jface.viewers.IContentProvider#dispose()
- *
+ *
*/
public void dispose() {
@@ -38,7 +38,7 @@ public class MetamodelContentProvider implements ITreeContentProvider {
/**
* @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object)
- *
+ *
* @param viewer
* @param oldInput
* @param newInput
@@ -50,7 +50,7 @@ public class MetamodelContentProvider implements ITreeContentProvider {
/**
* @see org.eclipse.jface.viewers.ITreeContentProvider#getElements(java.lang.Object)
- *
+ *
* @param inputElement
* @return
*/
@@ -58,8 +58,8 @@ public class MetamodelContentProvider implements ITreeContentProvider {
public Object[] getElements(Object inputElement) {
List<VirtualElement> elements = new ArrayList<VirtualElement>();
- if(inputElement instanceof Facade) {
- elements.addAll(MetamodelUtils.getElements((Facade)inputElement));
+ if (inputElement instanceof Facade) {
+ elements.addAll(MetamodelUtils.getElements((Facade) inputElement));
}
return elements.toArray();
@@ -67,7 +67,7 @@ public class MetamodelContentProvider implements ITreeContentProvider {
/**
* @see org.eclipse.jface.viewers.ITreeContentProvider#getChildren(java.lang.Object)
- *
+ *
* @param parentElement
* @return
*/
@@ -75,21 +75,23 @@ public class MetamodelContentProvider implements ITreeContentProvider {
public Object[] getChildren(Object parentElement) {
List<VirtualMetaclass> children = new ArrayList<VirtualMetaclass>();
- if(parentElement instanceof VirtualMetaclass)
- for(VirtualClassifier classifier : ((VirtualMetaclass)parentElement).getMetamodel().getVirtualClassifiers()) {
+ if (parentElement instanceof VirtualMetaclass) {
+ for (VirtualClassifier classifier : ((VirtualMetaclass) parentElement).getMetamodel().getVirtualClassifiers()) {
- if(classifier instanceof VirtualMetaclass)
- if(((VirtualMetaclass)classifier).getParents().contains(parentElement)) {
- children.add((VirtualMetaclass)classifier);
+ if (classifier instanceof VirtualMetaclass) {
+ if (((VirtualMetaclass) classifier).getParents().contains(parentElement)) {
+ children.add((VirtualMetaclass) classifier);
}
+ }
}
+ }
return children.toArray();
}
/**
* @see org.eclipse.jface.viewers.ITreeContentProvider#getParent(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -100,13 +102,13 @@ public class MetamodelContentProvider implements ITreeContentProvider {
/**
* @see org.eclipse.jface.viewers.ITreeContentProvider#hasChildren(java.lang.Object)
- *
+ *
* @param element
* @return
*/
public boolean hasChildren(Object element) {
- if(getChildren(element).length == 0) {
+ if (getChildren(element).length == 0) {
return false;
} else {
return true;
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelLabelProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelLabelProvider.java
index 2de7bdc30a3..09aa06fa47e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelLabelProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/MetamodelLabelProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -44,7 +44,7 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#addListener(org.eclipse.jface.viewers.ILabelProviderListener)
- *
+ *
* @param listener
*/
@@ -54,7 +54,7 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#dispose()
- *
+ *
*/
public void dispose() {
@@ -63,7 +63,7 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#isLabelProperty(java.lang.Object, java.lang.String)
- *
+ *
* @param element
* @param property
* @return
@@ -75,7 +75,7 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#removeListener(org.eclipse.jface.viewers.ILabelProviderListener)
- *
+ *
* @param listener
*/
@@ -85,31 +85,31 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnImage(java.lang.Object, int)
- *
+ *
* @param element
* @param columnIndex
* @return
*/
public Image getColumnImage(Object element, int columnIndex) {
- switch(columnIndex) {
+ switch (columnIndex) {
case 0:
- if(element instanceof VirtualMetaclass) {
- if(((VirtualMetaclass)element).isStereotypeInterface()) {
+ if (element instanceof VirtualMetaclass) {
+ if (((VirtualMetaclass) element).isStereotypeInterface()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/virtualmetamodel/StereotypeInterface.gif"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/virtualmetamodel/VirtualMetaclass.gif"); //$NON-NLS-1$
}
- } else if(element instanceof VirtualDatatype) {
+ } else if (element instanceof VirtualDatatype) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/virtualmetamodel/VirtualDatatype.gif"); //$NON-NLS-1$
- } else if(element instanceof VirtualEnum) {
+ } else if (element instanceof VirtualEnum) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/virtualmetamodel/VirtualEnum.gif"); //$NON-NLS-1$
}
break;
case 1:
- if(element instanceof VirtualElement) {
- if(((VirtualElement)element).isKept()) {
+ if (element instanceof VirtualElement) {
+ if (((VirtualElement) element).isKept()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/checked.gif"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/unchecked.gif"); //$NON-NLS-1$
@@ -121,9 +121,9 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
break;
case 3:
- if(element instanceof VirtualMetaclass) {
- if(MetamodelUtils.canBeAbstract((VirtualMetaclass)element)) {
- if(((VirtualMetaclass)element).isAbstract()) {
+ if (element instanceof VirtualMetaclass) {
+ if (MetamodelUtils.canBeAbstract((VirtualMetaclass) element)) {
+ if (((VirtualMetaclass) element).isAbstract()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/checked.gif"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/unchecked.gif"); //$NON-NLS-1$
@@ -133,9 +133,9 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
break;
case 4:
- if(element instanceof VirtualElement) {
+ if (element instanceof VirtualElement) {
- if(((VirtualElement)element).isUseRepresented()) {
+ if (((VirtualElement) element).isUseRepresented()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/checked.gif"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/unchecked.gif"); //$NON-NLS-1$
@@ -152,32 +152,32 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnText(java.lang.Object, int)
- *
+ *
* @param element
* @param columnIndex
* @return
*/
public String getColumnText(Object element, int columnIndex) {
- switch(columnIndex) {
+ switch (columnIndex) {
case 0:
String result = Messages.MetamodelLabelProvider_8;
- if(element instanceof VirtualElement) {
- if(((VirtualElement)element).getRepresentedElement() instanceof ENamedElement) {
- result = ((ENamedElement)((VirtualElement)element).getRepresentedElement()).getName();
- } else if(((VirtualElement)element).getRepresentedElement() instanceof NamedElement) {
- result = ((NamedElement)((VirtualElement)element).getRepresentedElement()).getName();
+ if (element instanceof VirtualElement) {
+ if (((VirtualElement) element).getRepresentedElement() instanceof ENamedElement) {
+ result = ((ENamedElement) ((VirtualElement) element).getRepresentedElement()).getName();
+ } else if (((VirtualElement) element).getRepresentedElement() instanceof NamedElement) {
+ result = ((NamedElement) ((VirtualElement) element).getRepresentedElement()).getName();
}
- if(element instanceof VirtualMetaclass) {
- if(!((VirtualMetaclass)element).getAppliedStereotypes().isEmpty()) {
+ if (element instanceof VirtualMetaclass) {
+ if (!((VirtualMetaclass) element).getAppliedStereotypes().isEmpty()) {
result += " ("; //$NON-NLS-1$
- result += ((VirtualMetaclass)element).getAppliedStereotypes().get(0).getExtensionDefinition().getStereotype().getName();
+ result += ((VirtualMetaclass) element).getAppliedStereotypes().get(0).getExtensionDefinition().getStereotype().getName();
- if(((VirtualMetaclass)element).getAppliedStereotypes().size() > 1) {
- for(int i = 1; i < ((VirtualMetaclass)element).getAppliedStereotypes().size(); i++) {
+ if (((VirtualMetaclass) element).getAppliedStereotypes().size() > 1) {
+ for (int i = 1; i < ((VirtualMetaclass) element).getAppliedStereotypes().size(); i++) {
result += ", "; //$NON-NLS-1$
- result += ((VirtualMetaclass)element).getAppliedStereotypes().get(i).getExtensionDefinition().getStereotype().getName();
+ result += ((VirtualMetaclass) element).getAppliedStereotypes().get(i).getExtensionDefinition().getStereotype().getName();
}
}
@@ -192,8 +192,8 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
break;
case 2:
- if(element instanceof VirtualElement) {
- return ((VirtualElement)element).getAliasName();
+ if (element instanceof VirtualElement) {
+ return ((VirtualElement) element).getAliasName();
}
break;
@@ -209,7 +209,7 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.ILabelProvider#getImage(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -220,7 +220,7 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.ILabelProvider#getText(java.lang.Object)
- *
+ *
* @param element
* @return
*/
@@ -232,15 +232,15 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.IFontProvider#getFont(java.lang.Object)
- *
+ *
* @param element
* @return
*/
public Font getFont(Object element) {
- if(element instanceof VirtualMetaclass) {
+ if (element instanceof VirtualMetaclass) {
- if(((VirtualMetaclass)element).isAbstract()) {
+ if (((VirtualMetaclass) element).isAbstract()) {
return JFaceResources.getFontRegistry().getItalic(JFaceResources.DEFAULT_FONT);
}
}
@@ -250,14 +250,14 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.IColorProvider#getForeground(java.lang.Object)
- *
+ *
* @param element
* @return
*/
public Color getForeground(Object element) {
- if(element instanceof VirtualElement) {
- if(!((VirtualElement)element).isKept()) {
+ if (element instanceof VirtualElement) {
+ if (!((VirtualElement) element).isKept()) {
return Display.getDefault().getSystemColor(SWT.COLOR_GRAY);
}
}
@@ -266,7 +266,7 @@ public class MetamodelLabelProvider implements ITableLabelProvider, ILabelProvid
/**
* @see org.eclipse.jface.viewers.IColorProvider#getBackground(java.lang.Object)
- *
+ *
* @param element
* @return
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementContentProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementContentProvider.java
index 420a28fdec3..77c97746bd2 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementContentProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementContentProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,7 +27,7 @@ public class TypedElementContentProvider implements ITreeContentProvider {
/**
* @see org.eclipse.jface.viewers.IContentProvider#dispose()
- *
+ *
*/
public void dispose() {
@@ -36,7 +36,7 @@ public class TypedElementContentProvider implements ITreeContentProvider {
/**
* @see org.eclipse.jface.viewers.IContentProvider#inputChanged(org.eclipse.jface.viewers.Viewer, java.lang.Object, java.lang.Object)
- *
+ *
* @param viewer
* @param oldInput
* @param newInput
@@ -48,19 +48,19 @@ public class TypedElementContentProvider implements ITreeContentProvider {
/**
* @see org.eclipse.jface.viewers.IStructuredContentProvider#getElements(java.lang.Object)
- *
+ *
* @param inputElement
* @return
*/
public Object[] getElements(Object inputElement) {
ArrayList<VirtualElement> output = new ArrayList<VirtualElement>();
- if(inputElement instanceof VirtualMetaclass) {
- output.addAll(((VirtualMetaclass)inputElement).getProperties());
- output.addAll(((VirtualMetaclass)inputElement).getOperations());
+ if (inputElement instanceof VirtualMetaclass) {
+ output.addAll(((VirtualMetaclass) inputElement).getProperties());
+ output.addAll(((VirtualMetaclass) inputElement).getOperations());
}
- if(inputElement instanceof VirtualEnum) {
- output.addAll(((VirtualEnum)inputElement).getLiterals());
+ if (inputElement instanceof VirtualEnum) {
+ output.addAll(((VirtualEnum) inputElement).getLiterals());
}
return output.toArray();
@@ -68,8 +68,8 @@ public class TypedElementContentProvider implements ITreeContentProvider {
public Object[] getChildren(Object parentElement) {
List<Object> result = new ArrayList<Object>();
- if(parentElement instanceof VirtualOperation) {
- result.addAll(((VirtualOperation)parentElement).getParameters());
+ if (parentElement instanceof VirtualOperation) {
+ result.addAll(((VirtualOperation) parentElement).getParameters());
}
return result.toArray();
@@ -80,7 +80,7 @@ public class TypedElementContentProvider implements ITreeContentProvider {
}
public boolean hasChildren(Object element) {
- if(getChildren(element).length == 0) {
+ if (getChildren(element).length == 0) {
return false;
} else {
return true;
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementLabelProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementLabelProvider.java
index 355c9e70f4f..c59af3f5f54 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementLabelProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/providers/TypedElementLabelProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -32,7 +32,7 @@ public class TypedElementLabelProvider implements ITableLabelProvider {
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#addListener(org.eclipse.jface.viewers.ILabelProviderListener)
- *
+ *
* @param listener
*/
@@ -42,7 +42,7 @@ public class TypedElementLabelProvider implements ITableLabelProvider {
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#dispose()
- *
+ *
*/
public void dispose() {
@@ -50,7 +50,7 @@ public class TypedElementLabelProvider implements ITableLabelProvider {
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#isLabelProperty(java.lang.Object, java.lang.String)
- *
+ *
* @param element
* @param property
* @return
@@ -62,7 +62,7 @@ public class TypedElementLabelProvider implements ITableLabelProvider {
/**
* @see org.eclipse.jface.viewers.IBaseLabelProvider#removeListener(org.eclipse.jface.viewers.ILabelProviderListener)
- *
+ *
* @param listener
*/
@@ -72,32 +72,32 @@ public class TypedElementLabelProvider implements ITableLabelProvider {
/**
* @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnImage(java.lang.Object, int)
- *
+ *
* @param element
* @param columnIndex
* @return
*/
public Image getColumnImage(Object element, int columnIndex) {
- switch(columnIndex) {
+ switch (columnIndex) {
case 0:
- if(element instanceof VirtualProperty) {
+ if (element instanceof VirtualProperty) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/virtualmetamodel/VirtualReference.gif"); //$NON-NLS-1$
- } else if(element instanceof VirtualOperation) {
+ } else if (element instanceof VirtualOperation) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/virtualmetamodel/VirtualOperation.gif"); //$NON-NLS-1$
- } else if(element instanceof VirtualLiteral) {
+ } else if (element instanceof VirtualLiteral) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/virtualmetamodel/VirtualLiteral.gif"); //$NON-NLS-1$
- } else if(element instanceof VirtualParameter) {
+ } else if (element instanceof VirtualParameter) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/virtualmetamodel/VirtualParameter.gif"); //$NON-NLS-1$
}
break;
case 1:
- if(element instanceof VirtualElement) {
- if(((VirtualElement)element).isKept()) {
+ if (element instanceof VirtualElement) {
+ if (((VirtualElement) element).isKept()) {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/checked.gif"); //$NON-NLS-1$
} else {
return ResourceManager.getPluginImage(FacadeDefinitionEditorActivator.getDefault(), "icons/unchecked.gif"); //$NON-NLS-1$
@@ -122,27 +122,27 @@ public class TypedElementLabelProvider implements ITableLabelProvider {
/**
* @see org.eclipse.jface.viewers.ITableLabelProvider#getColumnText(java.lang.Object, int)
- *
+ *
* @param element
* @param columnIndex
* @return
*/
public String getColumnText(Object element, int columnIndex) {
- switch(columnIndex) {
+ switch (columnIndex) {
case 0:
- if(element instanceof VirtualElement) {
+ if (element instanceof VirtualElement) {
String name = ""; //$NON-NLS-1$
- if(((VirtualElement)element).getRepresentedElement() instanceof ENamedElement) {
- name += ((ENamedElement)((VirtualElement)element).getRepresentedElement()).getName();
- } else if(((VirtualElement)element).getRepresentedElement() instanceof NamedElement) {
- name += ((NamedElement)((VirtualElement)element).getRepresentedElement()).getName();
+ if (((VirtualElement) element).getRepresentedElement() instanceof ENamedElement) {
+ name += ((ENamedElement) ((VirtualElement) element).getRepresentedElement()).getName();
+ } else if (((VirtualElement) element).getRepresentedElement() instanceof NamedElement) {
+ name += ((NamedElement) ((VirtualElement) element).getRepresentedElement()).getName();
}
- if(element instanceof VirtualTypedElement) {
- if(((VirtualTypedElement)element).getType() != null) {
- name += " (" + ((VirtualTypedElement)element).getType().getAliasName() + ")"; //$NON-NLS-1$ //$NON-NLS-2$
+ if (element instanceof VirtualTypedElement) {
+ if (((VirtualTypedElement) element).getType() != null) {
+ name += " (" + ((VirtualTypedElement) element).getType().getAliasName() + ")"; //$NON-NLS-1$ //$NON-NLS-2$
}
}
@@ -153,18 +153,18 @@ public class TypedElementLabelProvider implements ITableLabelProvider {
break;
case 2:
- if(element instanceof VirtualElement) {
- return ((VirtualElement)element).getAliasName();
+ if (element instanceof VirtualElement) {
+ return ((VirtualElement) element).getAliasName();
}
break;
case 3:
- if(element instanceof VirtualTypedElement) {
- return ((VirtualTypedElement)element).getLower() + ""; //$NON-NLS-1$
+ if (element instanceof VirtualTypedElement) {
+ return ((VirtualTypedElement) element).getLower() + ""; //$NON-NLS-1$
}
break;
case 4:
- if(element instanceof VirtualTypedElement) {
- return ((VirtualTypedElement)element).getUpper() + ""; //$NON-NLS-1$
+ if (element instanceof VirtualTypedElement) {
+ return ((VirtualTypedElement) element).getUpper() + ""; //$NON-NLS-1$
}
break;
default:
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/ProfileUtils.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/ProfileUtils.java
index 62740845eee..1f57f6747cb 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/ProfileUtils.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/ProfileUtils.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -47,12 +47,12 @@ public class ProfileUtils {
EcoreUtil.resolveAll(element);
EList<Resource> resources = element.eResource().getResourceSet().getResources();
- for(Resource resource : resources) {
+ for (Resource resource : resources) {
TreeIterator<EObject> it = resource.getAllContents();
- while(it.hasNext()) {
- EObject eObject = (EObject)it.next();
- if(eObject instanceof Classifier) {
- output.add((Classifier)eObject);
+ while (it.hasNext()) {
+ EObject eObject = it.next();
+ if (eObject instanceof Classifier) {
+ output.add((Classifier) eObject);
}
}
}
@@ -68,12 +68,12 @@ public class ProfileUtils {
EcoreUtil.resolveAll(profile);
EList<Resource> resources = profile.eResource().getResourceSet().getResources();
- for(Resource resource : resources) {
+ for (Resource resource : resources) {
TreeIterator<EObject> it = resource.getAllContents();
- while(it.hasNext()) {
- EObject eObject = (EObject)it.next();
- if(eObject instanceof Extension) {
- output.add((Extension)eObject);
+ while (it.hasNext()) {
+ EObject eObject = it.next();
+ if (eObject instanceof Extension) {
+ output.add((Extension) eObject);
}
}
}
@@ -84,10 +84,10 @@ public class ProfileUtils {
public static List<Extension> findExtensions(Stereotype stereotype) {
List<Extension> extensions = new ArrayList<Extension>();
- for(Property property : stereotype.getAllAttributes()) {
- if(property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
- if(property.getAssociation() instanceof Extension) {
- extensions.add((Extension)property.getAssociation());
+ for (Property property : stereotype.getAllAttributes()) {
+ if (property.getName().startsWith(Extension.METACLASS_ROLE_PREFIX)) {
+ if (property.getAssociation() instanceof Extension) {
+ extensions.add((Extension) property.getAssociation());
}
}
}
@@ -100,10 +100,10 @@ public class ProfileUtils {
List<Stereotype> output = new ArrayList<Stereotype>();
HashSet<Classifier> classifiers = getAllClassifiers(classifier);
- for(Classifier classifierCandidate : classifiers) {
- if(classifierCandidate.getGenerals().contains(classifier)) {
- if(classifierCandidate instanceof Stereotype) {
- output.add((Stereotype)classifierCandidate);
+ for (Classifier classifierCandidate : classifiers) {
+ if (classifierCandidate.getGenerals().contains(classifier)) {
+ if (classifierCandidate instanceof Stereotype) {
+ output.add((Stereotype) classifierCandidate);
}
}
@@ -132,12 +132,12 @@ public class ProfileUtils {
EList<Classifier> stereotypeGenerals = stereotype.getGenerals();
- if(!stereotypeGenerals.isEmpty()) {
- for(Classifier classifier : stereotypeGenerals) {
- if(classifier instanceof Stereotype) {
- stereotypeRelatives.addAll(findAllSubsInProfile((Stereotype)classifier));
+ if (!stereotypeGenerals.isEmpty()) {
+ for (Classifier classifier : stereotypeGenerals) {
+ if (classifier instanceof Stereotype) {
+ stereotypeRelatives.addAll(findAllSubsInProfile((Stereotype) classifier));
- stereotypeRelatives.add((Stereotype)classifier);
+ stereotypeRelatives.add((Stereotype) classifier);
}
}
} else {
@@ -154,7 +154,7 @@ public class ProfileUtils {
HashSet<Stereotype> stereotypeBRelatives = getSiblings(stereotypeB);
// They must not be relatives
- if(!stereotypeARelatives.contains(stereotypeB) && !stereotypeBRelatives.contains(stereotypeA)) {
+ if (!stereotypeARelatives.contains(stereotypeB) && !stereotypeBRelatives.contains(stereotypeA)) {
return true;
}
@@ -166,33 +166,33 @@ public class ProfileUtils {
int[] indices;
List<Combination> allCombination = new ArrayList<Combination>();
- for(int k = 1; k <= possibleStereotypes.size(); k++) {
+ for (int k = 1; k <= possibleStereotypes.size(); k++) {
CombinationGenerator combinaisonGenerator = new CombinationGenerator(elements.size(), k);
- while(combinaisonGenerator.hasMore()) {
+ while (combinaisonGenerator.hasMore()) {
// ArrayList<Stereotype> combination = new ArrayList<Stereotype>();
indices = combinaisonGenerator.getNext();
Combination combinaison = ExtensiondefinitionFactory.eINSTANCE.createCombination();
- for(int i = 0; i < indices.length; i++) {
+ for (int i = 0; i < indices.length; i++) {
// combination.add();
combinaison.getMembers().add(elements.get(indices[i]));
}
- //Check that combination doesn't contain siblings
+ // Check that combination doesn't contain siblings
boolean containsSiblings = false;
- for(BaseMetaclass baseA : combinaison.getMembers()) {
- for(BaseMetaclass baseB : combinaison.getMembers()) {
- if(baseA != baseB) {
- if(!areNotRelatives(baseA.getExtensionDefinition().getStereotype(), baseB.getExtensionDefinition().getStereotype())) {
+ for (BaseMetaclass baseA : combinaison.getMembers()) {
+ for (BaseMetaclass baseB : combinaison.getMembers()) {
+ if (baseA != baseB) {
+ if (!areNotRelatives(baseA.getExtensionDefinition().getStereotype(), baseB.getExtensionDefinition().getStereotype())) {
containsSiblings = true;
}
}
}
}
- if(!containsSiblings) {
+ if (!containsSiblings) {
allCombination.add(combinaison);
}
}
@@ -205,24 +205,24 @@ public class ProfileUtils {
List<BaseMetaclass> requiredCompatibleStereotypes = new ArrayList<BaseMetaclass>();
List<BaseMetaclass> optionalCompatibleStereotypes = new ArrayList<BaseMetaclass>();
- if(inputElement.getExtensionDefinition().getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ if (inputElement.getExtensionDefinition().getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
Facade facade = inputElement.getExtensionDefinition().getFacade();
- for(ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
+ for (ExtensionDefinition extensionDefinition : facade.getExtensionDefinitions()) {
- if(extensionDefinition.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
- for(BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
- if(baseMetaclass.getBase() == inputElement.getBase()) {
+ if (extensionDefinition.getKind() == ExtensionDefinitionKind.MULTI_GENERALIZATION) {
+ for (BaseMetaclass baseMetaclass : extensionDefinition.getBaseMetaclasses()) {
+ if (baseMetaclass.getBase() == inputElement.getBase()) {
- if(baseMetaclass != inputElement) {
+ if (baseMetaclass != inputElement) {
Stereotype inputElementStereo = inputElement.getExtensionDefinition().getStereotype();
Stereotype baseMetaClassStereo = baseMetaclass.getExtensionDefinition().getStereotype();
- if(ProfileUtils.areNotRelatives(inputElementStereo, baseMetaClassStereo)) {
+ if (ProfileUtils.areNotRelatives(inputElementStereo, baseMetaClassStereo)) {
- if(!baseMetaclass.getExtensionDefinition().getStereotype().isAbstract()) {
+ if (!baseMetaclass.getExtensionDefinition().getStereotype().isAbstract()) {
- if(baseMetaclass.getExtensionDefinition().getExtension().isRequired()) {
+ if (baseMetaclass.getExtensionDefinition().getExtension().isRequired()) {
requiredCompatibleStereotypes.add(baseMetaclass);
} else {
optionalCompatibleStereotypes.add(baseMetaclass);
@@ -238,8 +238,8 @@ public class ProfileUtils {
}
List<Combination> possibleCombination = generatePossibleCombination(optionalCompatibleStereotypes);
- if(!requiredCompatibleStereotypes.isEmpty()) {
- for(Combination combination : possibleCombination) {
+ if (!requiredCompatibleStereotypes.isEmpty()) {
+ for (Combination combination : possibleCombination) {
combination.getMembers().addAll(requiredCompatibleStereotypes);
}
Combination combinationRequired = ExtensiondefinitionFactory.eINSTANCE.createCombination();
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/PrunerUtils.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/PrunerUtils.java
index 2b3cb6489a4..4476fbe43e6 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/PrunerUtils.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/PrunerUtils.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -32,78 +32,78 @@ import org.eclipse.swt.widgets.Display;
public class PrunerUtils {
- // protected static VirtualElement findVirtualElement(EObject element, VirtualMetamodel metamodel) {
- // TreeIterator<EObject> it = metamodel.eAllContents();
+ // protected static VirtualElement findVirtualElement(EObject element, VirtualMetamodel metamodel) {
+ // TreeIterator<EObject> it = metamodel.eAllContents();
//
- // while(it.hasNext()) {
- // EObject eObject = (EObject)it.next();
- // if(eObject instanceof VirtualElement) {
- // if(((VirtualElement)eObject).getRepresentedElement() == element) {
- // return (VirtualElement)eObject;
- // }
- // }
- // }
- // return null;
- // }
-
- // protected static boolean isUsed(VirtualClassifier classifier, VirtualMetamodel metamodel) {
+ // while(it.hasNext()) {
+ // EObject eObject = (EObject)it.next();
+ // if(eObject instanceof VirtualElement) {
+ // if(((VirtualElement)eObject).getRepresentedElement() == element) {
+ // return (VirtualElement)eObject;
+ // }
+ // }
+ // }
+ // return null;
+ // }
+
+ // protected static boolean isUsed(VirtualClassifier classifier, VirtualMetamodel metamodel) {
//
- // TreeIterator<EObject> it = metamodel.eAllContents();
+ // TreeIterator<EObject> it = metamodel.eAllContents();
//
- // while(it.hasNext()) {
- // EObject element = (EObject)it.next();
- // if(element != classifier) {
- // //VirtualMetclass of type of the property must be not kept
- // if(element instanceof VirtualProperty) {
- // if(((VirtualProperty)element).isKept()) {
+ // while(it.hasNext()) {
+ // EObject element = (EObject)it.next();
+ // if(element != classifier) {
+ // //VirtualMetclass of type of the property must be not kept
+ // if(element instanceof VirtualProperty) {
+ // if(((VirtualProperty)element).isKept()) {
//
- // if(((VirtualProperty)element).getRepresentedElement() instanceof Property) {
- // Type typeOfTheProperty = ((Property)((VirtualProperty)element).getRepresentedElement()).getType();
+ // if(((VirtualProperty)element).getRepresentedElement() instanceof Property) {
+ // Type typeOfTheProperty = ((Property)((VirtualProperty)element).getRepresentedElement()).getType();
//
- // if(findVirtualElement(typeOfTheProperty, metamodel).isKept()) {
+ // if(findVirtualElement(typeOfTheProperty, metamodel).isKept()) {
//
- // }
+ // }
//
- // } else if(((VirtualProperty)element).getRepresentedElement() instanceof EStructuralFeature) {
- // EClassifier typeOfTheProperty = ((EStructuralFeature)((VirtualProperty)element).getRepresentedElement()).getEType();
- // } else {
- // org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info("The kind of the property is unknown: " + element);
- // }
- // }
+ // } else if(((VirtualProperty)element).getRepresentedElement() instanceof EStructuralFeature) {
+ // EClassifier typeOfTheProperty = ((EStructuralFeature)((VirtualProperty)element).getRepresentedElement()).getEType();
+ // } else {
+ // org.eclipse.papyrus.facadeSpecificEditor.FacadeDefinitionEditorActivator.log.info("The kind of the property is unknown: " + element);
+ // }
+ // }
//
- // }
+ // }
//
- // }
+ // }
//
- // }
+ // }
//
- // return true;
- // }
+ // return true;
+ // }
public static boolean classifierUnkeep(VirtualElement element, VirtualMetamodel metamodel, EditingDomain editingDomain) {
List<EObject> typedElementToUnkeep = new ArrayList<EObject>();
- if(element instanceof VirtualClassifier) {
- List<VirtualMetaclass> children = MetamodelUtils.getChildren((VirtualMetaclass)element);
+ if (element instanceof VirtualClassifier) {
+ List<VirtualMetaclass> children = MetamodelUtils.getChildren((VirtualMetaclass) element);
- for(VirtualMetaclass child : children) {
- if(classifierUnkeep(child, metamodel, editingDomain) == false) {
+ for (VirtualMetaclass child : children) {
+ if (classifierUnkeep(child, metamodel, editingDomain) == false) {
return false;
}
}
TreeIterator<EObject> it = metamodel.eAllContents();
- while(it.hasNext()) {
- EObject metamodelElement = (EObject)it.next();
- if(metamodelElement != element) {
- //VirtualMetclass of type of the property must be not kept
- if(metamodelElement instanceof VirtualTypedElement) {
- if(((VirtualTypedElement)metamodelElement).isKept()) {
+ while (it.hasNext()) {
+ EObject metamodelElement = it.next();
+ if (metamodelElement != element) {
+ // VirtualMetclass of type of the property must be not kept
+ if (metamodelElement instanceof VirtualTypedElement) {
+ if (((VirtualTypedElement) metamodelElement).isKept()) {
- if(((VirtualTypedElement)metamodelElement).getType() == element) {
- if(((VirtualTypedElement)metamodelElement).getLower() > 0) {
- MessageDialog.openWarning(Display.getCurrent().getActiveShell(), "Cannot unkeep this element", "This element cannot be unkept because it is used by : " + ((VirtualTypedElement)metamodelElement).getAliasName());
+ if (((VirtualTypedElement) metamodelElement).getType() == element) {
+ if (((VirtualTypedElement) metamodelElement).getLower() > 0) {
+ MessageDialog.openWarning(Display.getCurrent().getActiveShell(), "Cannot unkeep this element", "This element cannot be unkept because it is used by : " + ((VirtualTypedElement) metamodelElement).getAliasName());
return false;
}
@@ -115,12 +115,12 @@ public class PrunerUtils {
}
}
- for(EObject eObject : typedElementToUnkeep) {
- SetCommand command = new SetCommand(editingDomain, (VirtualElement)eObject, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_Kept(), false); //$NON-NLS-1$
+ for (EObject eObject : typedElementToUnkeep) {
+ SetCommand command = new SetCommand(editingDomain, eObject, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_Kept(), false);
editingDomain.getCommandStack().execute(command);
}
- SetCommand command = new SetCommand(editingDomain, (VirtualElement)element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_Kept(), false); //$NON-NLS-1$
+ SetCommand command = new SetCommand(editingDomain, element, VirtualmetamodelPackage.eINSTANCE.getVirtualElement_Kept(), false);
editingDomain.getCommandStack().execute(command);
return true;
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/StereotypeUtils.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/StereotypeUtils.java
index 1cd18b61436..3d52a294303 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/StereotypeUtils.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/StereotypeUtils.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -41,7 +41,7 @@ public class StereotypeUtils {
/**
* Compute all the ecore UML metaclasses on which the stereotype can be applied
- *
+ *
* @param stereotype
* @param concreteClassesOnly
* @return
@@ -49,10 +49,10 @@ public class StereotypeUtils {
public static List<EClass> getAllExtendableMetaclasses(Stereotype stereotype, boolean concreteClassesOnly) {
EList<Class> extendedMetaclasses = stereotype.getAllExtendedMetaclasses();
Set<EClass> allMetaclasses = new LinkedHashSet<EClass>();
- for(Class extendedMetaclass : extendedMetaclasses) {
+ for (Class extendedMetaclass : extendedMetaclasses) {
EClassifier UMLEClass = findEClass(extendedMetaclass);
- if(UMLEClass instanceof EClass) {
- allMetaclasses.addAll(getSubclassesOf((EClass)UMLEClass, concreteClassesOnly));
+ if (UMLEClass instanceof EClass) {
+ allMetaclasses.addAll(getSubclassesOf((EClass) UMLEClass, concreteClassesOnly));
}
}
@@ -61,14 +61,14 @@ public class StereotypeUtils {
/**
* Get the ecore UML metaclass corresponding to an {@link ExtensionDefinition}
- *
+ *
* @param extension
* @return
*/
public static EClassifier findBase(ExtensionDefinition extension) {
- for(Property member : extension.getExtension().getMemberEnds()) {
- if(!(member instanceof ExtensionEnd)) {
- return findEClass((Classifier)member.getType());
+ for (Property member : extension.getExtension().getMemberEnds()) {
+ if (!(member instanceof ExtensionEnd)) {
+ return findEClass((Classifier) member.getType());
}
}
return null;
@@ -76,7 +76,7 @@ public class StereotypeUtils {
/**
* Compute all the ecore UML metaclasses on which the extension applies
- *
+ *
* @param extension
* @param concreteClassesOnly
* @return
@@ -86,8 +86,8 @@ public class StereotypeUtils {
Set<EClass> allMetaclasses = new LinkedHashSet<EClass>();
EClassifier UMLEClass = findEClass(extendedMetaclass);
- if(UMLEClass instanceof EClass) {
- allMetaclasses.addAll(getSubclassesOf((EClass)UMLEClass, concreteClassesOnly));
+ if (UMLEClass instanceof EClass) {
+ allMetaclasses.addAll(getSubclassesOf((EClass) UMLEClass, concreteClassesOnly));
}
return new LinkedList<EClass>(allMetaclasses);
@@ -95,7 +95,7 @@ public class StereotypeUtils {
/**
* Get all the ecore subclasses of a UML metaclass
- *
+ *
* @param UMLEClass
* @param concreteClassesOnly
* @return
@@ -103,19 +103,19 @@ public class StereotypeUtils {
protected static Collection<? extends EClass> getSubclassesOf(EClass UMLEClass, boolean concreteClassesOnly) {
Set<EClass> subs = new LinkedHashSet<EClass>();
- if(UMLEClass != null) {
- if((concreteClassesOnly && !UMLEClass.isAbstract()) || !concreteClassesOnly) {
+ if (UMLEClass != null) {
+ if ((concreteClassesOnly && !UMLEClass.isAbstract()) || !concreteClassesOnly) {
subs.add(UMLEClass);
}
- for(EClassifier classifier : umlMetamodel.getEClassifiers()) {
- if(classifier instanceof EClass) {
- EClass clazz = (EClass)classifier;
+ for (EClassifier classifier : umlMetamodel.getEClassifiers()) {
+ if (classifier instanceof EClass) {
+ EClass clazz = (EClass) classifier;
- if((concreteClassesOnly && !clazz.isAbstract()) || !concreteClassesOnly) {
+ if ((concreteClassesOnly && !clazz.isAbstract()) || !concreteClassesOnly) {
EList<EClass> supers = clazz.getEAllSuperTypes();
- if(supers.contains(UMLEClass)) {
+ if (supers.contains(UMLEClass)) {
subs.add(clazz);
}
}
@@ -127,19 +127,19 @@ public class StereotypeUtils {
/**
* Get the eClass in the UML metamodel from a UML classifier
- *
+ *
* @param type
* @return
*/
public static EClassifier findEClass(Classifier type) {
- for(EClassifier classifier : umlMetamodel.getEClassifiers()) {
- if(classifier.getName().equals(type.getName())) {
+ for (EClassifier classifier : umlMetamodel.getEClassifiers()) {
+ if (classifier.getName().equals(type.getName())) {
return classifier;
}
}
- for(EClassifier classifier : typesPackage.getEClassifiers()) {
- if(classifier.getName().equals(type.getName())) {
+ for (EClassifier classifier : typesPackage.getEClassifiers()) {
+ if (classifier.getName().equals(type.getName())) {
return classifier;
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/UMLModelUtils.java b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/UMLModelUtils.java
index 85ff139ff8c..39640150bc1 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/UMLModelUtils.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.definition.editor/src/org/eclipse/papyrus/facadeSpecificEditor/utils/UMLModelUtils.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -22,7 +22,7 @@ public class UMLModelUtils {
/**
* Load a given uri as an EMF model and return the root
- *
+ *
* @param file
* @param resourceSet
* @return
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/BaseMetaclassItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/BaseMetaclassItemProvider.java
index fb93864be4f..88d77852b95 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/BaseMetaclassItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/BaseMetaclassItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -45,11 +45,12 @@ import org.eclipse.papyrus.facade.provider.FacadeEditPlugin;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class BaseMetaclassItemProvider
- extends ItemProviderAdapter
- implements
+ extends ItemProviderAdapter
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -59,6 +60,7 @@ public class BaseMetaclassItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public BaseMetaclassItemProvider(AdapterFactory adapterFactory) {
@@ -69,6 +71,7 @@ public class BaseMetaclassItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -86,52 +89,54 @@ public class BaseMetaclassItemProvider
* This adds a property descriptor for the Base feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addBasePropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_BaseMetaclass_base_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_BaseMetaclass_base_feature", "_UI_BaseMetaclass_type"),
- ExtensiondefinitionPackage.Literals.BASE_METACLASS__BASE,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_BaseMetaclass_base_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_BaseMetaclass_base_feature", "_UI_BaseMetaclass_type"),
+ ExtensiondefinitionPackage.Literals.BASE_METACLASS__BASE,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Possible feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addPossiblePropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_BaseMetaclass_possible_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_BaseMetaclass_possible_feature", "_UI_BaseMetaclass_type"),
- ExtensiondefinitionPackage.Literals.BASE_METACLASS__POSSIBLE,
- true,
- false,
- false,
- ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_BaseMetaclass_possible_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_BaseMetaclass_possible_feature", "_UI_BaseMetaclass_type"),
+ ExtensiondefinitionPackage.Literals.BASE_METACLASS__POSSIBLE,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
+ null,
+ null));
}
/**
- * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
* {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -147,6 +152,7 @@ public class BaseMetaclassItemProvider
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -161,6 +167,7 @@ public class BaseMetaclassItemProvider
* This returns BaseMetaclass.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -172,20 +179,22 @@ public class BaseMetaclassItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- BaseMetaclass baseMetaclass = (BaseMetaclass)object;
+ BaseMetaclass baseMetaclass = (BaseMetaclass) object;
return getString("_UI_BaseMetaclass_type") + " " + baseMetaclass.isPossible();
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -193,13 +202,13 @@ public class BaseMetaclassItemProvider
updateChildren(notification);
switch (notification.getFeatureID(BaseMetaclass.class)) {
- case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
- return;
- case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
- case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
+ case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -209,6 +218,7 @@ public class BaseMetaclassItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -216,20 +226,21 @@ public class BaseMetaclassItemProvider
super.collectNewChildDescriptors(newChildDescriptors, object);
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(ExtensiondefinitionPackage.Literals.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES,
- ExtensiondefinitionFactory.eINSTANCE.createCombination()));
+ ExtensiondefinitionFactory.eINSTANCE.createCombination()));
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(ExtensiondefinitionPackage.Literals.BASE_METACLASS__COMPATIBLE_STEREOTYPES,
- ExtensiondefinitionFactory.eINSTANCE.createCombination()));
+ ExtensiondefinitionFactory.eINSTANCE.createCombination()));
}
/**
* This returns the label text for {@link org.eclipse.emf.edit.command.CreateChildCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -238,13 +249,12 @@ public class BaseMetaclassItemProvider
Object childObject = child;
boolean qualify =
- childFeature == ExtensiondefinitionPackage.Literals.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES ||
- childFeature == ExtensiondefinitionPackage.Literals.BASE_METACLASS__COMPATIBLE_STEREOTYPES;
+ childFeature == ExtensiondefinitionPackage.Literals.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES ||
+ childFeature == ExtensiondefinitionPackage.Literals.BASE_METACLASS__COMPATIBLE_STEREOTYPES;
if (qualify) {
- return getString
- ("_UI_CreateChild_text2",
- new Object[] { getTypeText(childObject), getFeatureText(childFeature), getTypeText(owner) });
+ return getString("_UI_CreateChild_text2",
+ new Object[] { getTypeText(childObject), getFeatureText(childFeature), getTypeText(owner) });
}
return super.getCreateChildText(owner, feature, child, selection);
}
@@ -253,6 +263,7 @@ public class BaseMetaclassItemProvider
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/CombinationItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/CombinationItemProvider.java
index 5544591d6f3..f03241bb4da 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/CombinationItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/CombinationItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -39,11 +39,12 @@ import org.eclipse.papyrus.facade.provider.FacadeEditPlugin;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.extensiondefinition.Combination} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class CombinationItemProvider
- extends ItemProviderAdapter
- implements
+ extends ItemProviderAdapter
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -53,6 +54,7 @@ public class CombinationItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public CombinationItemProvider(AdapterFactory adapterFactory) {
@@ -63,6 +65,7 @@ public class CombinationItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -79,28 +82,30 @@ public class CombinationItemProvider
* This adds a property descriptor for the Members feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addMembersPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_Combination_members_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_Combination_members_feature", "_UI_Combination_type"),
- ExtensiondefinitionPackage.Literals.COMBINATION__MEMBERS,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Combination_members_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_Combination_members_feature", "_UI_Combination_type"),
+ ExtensiondefinitionPackage.Literals.COMBINATION__MEMBERS,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This returns Combination.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -112,19 +117,21 @@ public class CombinationItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
return getString("_UI_Combination_type");
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -138,6 +145,7 @@ public class CombinationItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -149,6 +157,7 @@ public class CombinationItemProvider
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensionDefinitionItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensionDefinitionItemProvider.java
index 1f3e872d9d8..f3875466206 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensionDefinitionItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensionDefinitionItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -46,11 +46,12 @@ import org.eclipse.papyrus.facade.provider.FacadeEditPlugin;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensionDefinitionItemProvider
- extends ItemProviderAdapter
- implements
+ extends ItemProviderAdapter
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -60,6 +61,7 @@ public class ExtensionDefinitionItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensionDefinitionItemProvider(AdapterFactory adapterFactory) {
@@ -70,6 +72,7 @@ public class ExtensionDefinitionItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -88,74 +91,77 @@ public class ExtensionDefinitionItemProvider
* This adds a property descriptor for the Extension feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addExtensionPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_ExtensionDefinition_extension_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_ExtensionDefinition_extension_feature", "_UI_ExtensionDefinition_type"),
- ExtensiondefinitionPackage.Literals.EXTENSION_DEFINITION__EXTENSION,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_ExtensionDefinition_extension_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_ExtensionDefinition_extension_feature", "_UI_ExtensionDefinition_type"),
+ ExtensiondefinitionPackage.Literals.EXTENSION_DEFINITION__EXTENSION,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Stereotype feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addStereotypePropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_ExtensionDefinition_stereotype_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_ExtensionDefinition_stereotype_feature", "_UI_ExtensionDefinition_type"),
- ExtensiondefinitionPackage.Literals.EXTENSION_DEFINITION__STEREOTYPE,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_ExtensionDefinition_stereotype_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_ExtensionDefinition_stereotype_feature", "_UI_ExtensionDefinition_type"),
+ ExtensiondefinitionPackage.Literals.EXTENSION_DEFINITION__STEREOTYPE,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Kind feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addKindPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_ExtensionDefinition_kind_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_ExtensionDefinition_kind_feature", "_UI_ExtensionDefinition_type"),
- ExtensiondefinitionPackage.Literals.EXTENSION_DEFINITION__KIND,
- true,
- false,
- false,
- ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_ExtensionDefinition_kind_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_ExtensionDefinition_kind_feature", "_UI_ExtensionDefinition_type"),
+ ExtensiondefinitionPackage.Literals.EXTENSION_DEFINITION__KIND,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
- * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
* {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -170,6 +176,7 @@ public class ExtensionDefinitionItemProvider
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -184,6 +191,7 @@ public class ExtensionDefinitionItemProvider
* This returns ExtensionDefinition.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -195,23 +203,25 @@ public class ExtensionDefinitionItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- ExtensionDefinitionKind labelValue = ((ExtensionDefinition)object).getKind();
+ ExtensionDefinitionKind labelValue = ((ExtensionDefinition) object).getKind();
String label = labelValue == null ? null : labelValue.toString();
return label == null || label.length() == 0 ?
- getString("_UI_ExtensionDefinition_type") :
- getString("_UI_ExtensionDefinition_type") + " " + label;
+ getString("_UI_ExtensionDefinition_type") :
+ getString("_UI_ExtensionDefinition_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -219,12 +229,12 @@ public class ExtensionDefinitionItemProvider
updateChildren(notification);
switch (notification.getFeatureID(ExtensionDefinition.class)) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
- return;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -234,6 +244,7 @@ public class ExtensionDefinitionItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -241,15 +252,16 @@ public class ExtensionDefinitionItemProvider
super.collectNewChildDescriptors(newChildDescriptors, object);
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(ExtensiondefinitionPackage.Literals.EXTENSION_DEFINITION__BASE_METACLASSES,
- ExtensiondefinitionFactory.eINSTANCE.createBaseMetaclass()));
+ ExtensiondefinitionFactory.eINSTANCE.createBaseMetaclass()));
}
/**
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensiondefinitionItemProviderAdapterFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensiondefinitionItemProviderAdapterFactory.java
index eb41300826d..81b673c1690 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensiondefinitionItemProviderAdapterFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/extensiondefinition/provider/ExtensiondefinitionItemProviderAdapterFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -41,6 +41,7 @@ import org.eclipse.papyrus.facade.extensiondefinition.util.ExtensiondefinitionAd
* Note that most of the adapters are shared among multiple instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensiondefinitionItemProviderAdapterFactory extends ExtensiondefinitionAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable {
@@ -48,6 +49,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This keeps track of the root adapter factory that delegates to this adapter factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ComposedAdapterFactory parentAdapterFactory;
@@ -56,6 +58,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IChangeNotifier changeNotifier = new ChangeNotifier();
@@ -64,6 +67,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Object> supportedTypes = new ArrayList<Object>();
@@ -72,6 +76,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This constructs an instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionItemProviderAdapterFactory() {
@@ -86,6 +91,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ExtensionDefinitionItemProvider extensionDefinitionItemProvider;
@@ -94,6 +100,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This creates an adapter for a {@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -109,6 +116,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected BaseMetaclassItemProvider baseMetaclassItemProvider;
@@ -117,6 +125,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This creates an adapter for a {@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -132,6 +141,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.extensiondefinition.Combination} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected CombinationItemProvider combinationItemProvider;
@@ -140,6 +150,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This creates an adapter for a {@link org.eclipse.papyrus.facade.extensiondefinition.Combination}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -155,8 +166,10 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This returns the root adapter factory that contains this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ComposeableAdapterFactory getRootAdapterFactory() {
return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory();
}
@@ -165,8 +178,10 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This sets the composed adapter factory that contains this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) {
this.parentAdapterFactory = parentAdapterFactory;
}
@@ -174,6 +189,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -185,6 +201,7 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This implementation substitutes the factory itself as the key for the adapter.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -195,13 +212,14 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object adapt(Object object, Object type) {
if (isFactoryForType(type)) {
Object adapter = super.adapt(object, type);
- if (!(type instanceof Class<?>) || (((Class<?>)type).isInstance(adapter))) {
+ if (!(type instanceof Class<?>) || (((Class<?>) type).isInstance(adapter))) {
return adapter;
}
}
@@ -213,8 +231,10 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This adds a listener.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void addListener(INotifyChangedListener notifyChangedListener) {
changeNotifier.addListener(notifyChangedListener);
}
@@ -223,8 +243,10 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This removes a listener.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void removeListener(INotifyChangedListener notifyChangedListener) {
changeNotifier.removeListener(notifyChangedListener);
}
@@ -233,8 +255,10 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
* This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void fireNotifyChanged(Notification notification) {
changeNotifier.fireNotifyChanged(notification);
@@ -244,15 +268,23 @@ public class ExtensiondefinitionItemProviderAdapterFactory extends Extensiondefi
}
/**
- * This disposes all of the item providers created by this factory.
+ * This disposes all of the item providers created by this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void dispose() {
- if (extensionDefinitionItemProvider != null) extensionDefinitionItemProvider.dispose();
- if (baseMetaclassItemProvider != null) baseMetaclassItemProvider.dispose();
- if (combinationItemProvider != null) combinationItemProvider.dispose();
+ if (extensionDefinitionItemProvider != null) {
+ extensionDefinitionItemProvider.dispose();
+ }
+ if (baseMetaclassItemProvider != null) {
+ baseMetaclassItemProvider.dispose();
+ }
+ if (combinationItemProvider != null) {
+ combinationItemProvider.dispose();
+ }
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeEditPlugin.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeEditPlugin.java
index 8876e5d1ac8..39ed21086d6 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeEditPlugin.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeEditPlugin.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,6 +25,7 @@ import org.eclipse.uml2.uml.edit.UMLEditPlugin;
* This is the central singleton for the Facade edit plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public final class FacadeEditPlugin extends EMFPlugin {
@@ -32,6 +33,7 @@ public final class FacadeEditPlugin extends EMFPlugin {
* Keep track of the singleton.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final FacadeEditPlugin INSTANCE = new FacadeEditPlugin();
@@ -40,6 +42,7 @@ public final class FacadeEditPlugin extends EMFPlugin {
* Keep track of the singleton.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static Implementation plugin;
@@ -48,20 +51,21 @@ public final class FacadeEditPlugin extends EMFPlugin {
* Create the instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeEditPlugin() {
- super
- (new ResourceLocator [] {
- EcoreEditPlugin.INSTANCE,
- UMLEditPlugin.INSTANCE,
- });
+ super(new ResourceLocator[] {
+ EcoreEditPlugin.INSTANCE,
+ UMLEditPlugin.INSTANCE,
+ });
}
/**
* Returns the singleton instance of the Eclipse plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the singleton instance.
* @generated
*/
@@ -74,6 +78,7 @@ public final class FacadeEditPlugin extends EMFPlugin {
* Returns the singleton instance of the Eclipse plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the singleton instance.
* @generated
*/
@@ -85,6 +90,7 @@ public final class FacadeEditPlugin extends EMFPlugin {
* The actual implementation of the Eclipse <b>Plugin</b>.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static class Implementation extends EclipsePlugin {
@@ -92,6 +98,7 @@ public final class FacadeEditPlugin extends EMFPlugin {
* Creates an instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Implementation() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProvider.java
index 9323355dbbf..cb373439ffb 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -44,11 +44,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelFactory;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.Facade} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeItemProvider
- extends ItemProviderAdapter
- implements
+ extends ItemProviderAdapter
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -58,6 +59,7 @@ public class FacadeItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeItemProvider(AdapterFactory adapterFactory) {
@@ -68,6 +70,7 @@ public class FacadeItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -80,11 +83,11 @@ public class FacadeItemProvider
}
/**
- * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
* {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -100,6 +103,7 @@ public class FacadeItemProvider
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -114,6 +118,7 @@ public class FacadeItemProvider
* This returns Facade.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -125,19 +130,21 @@ public class FacadeItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
return getString("_UI_Facade_type");
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -145,10 +152,10 @@ public class FacadeItemProvider
updateChildren(notification);
switch (notification.getFeatureID(Facade.class)) {
- case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
- case FacadePackage.FACADE__VIRTUALMETAMODEL:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
+ case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
+ case FacadePackage.FACADE__VIRTUALMETAMODEL:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -158,6 +165,7 @@ public class FacadeItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -165,20 +173,21 @@ public class FacadeItemProvider
super.collectNewChildDescriptors(newChildDescriptors, object);
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(FacadePackage.Literals.FACADE__EXTENSION_DEFINITIONS,
- ExtensiondefinitionFactory.eINSTANCE.createExtensionDefinition()));
+ ExtensiondefinitionFactory.eINSTANCE.createExtensionDefinition()));
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(FacadePackage.Literals.FACADE__VIRTUALMETAMODEL,
- VirtualmetamodelFactory.eINSTANCE.createVirtualMetamodel()));
+ VirtualmetamodelFactory.eINSTANCE.createVirtualMetamodel()));
}
/**
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProviderAdapterFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProviderAdapterFactory.java
index 7333c458b91..e46dc8e296d 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProviderAdapterFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/provider/FacadeItemProviderAdapterFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -41,6 +41,7 @@ import org.eclipse.papyrus.facade.util.FacadeAdapterFactory;
* Note that most of the adapters are shared among multiple instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable {
@@ -48,6 +49,7 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This keeps track of the root adapter factory that delegates to this adapter factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ComposedAdapterFactory parentAdapterFactory;
@@ -56,6 +58,7 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IChangeNotifier changeNotifier = new ChangeNotifier();
@@ -64,6 +67,7 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Object> supportedTypes = new ArrayList<Object>();
@@ -72,6 +76,7 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This constructs an instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeItemProviderAdapterFactory() {
@@ -86,6 +91,7 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.Facade} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacadeItemProvider facadeItemProvider;
@@ -94,6 +100,7 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This creates an adapter for a {@link org.eclipse.papyrus.facade.Facade}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -109,8 +116,10 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This returns the root adapter factory that contains this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ComposeableAdapterFactory getRootAdapterFactory() {
return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory();
}
@@ -119,8 +128,10 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This sets the composed adapter factory that contains this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) {
this.parentAdapterFactory = parentAdapterFactory;
}
@@ -128,6 +139,7 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -139,6 +151,7 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This implementation substitutes the factory itself as the key for the adapter.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -149,13 +162,14 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object adapt(Object object, Object type) {
if (isFactoryForType(type)) {
Object adapter = super.adapt(object, type);
- if (!(type instanceof Class<?>) || (((Class<?>)type).isInstance(adapter))) {
+ if (!(type instanceof Class<?>) || (((Class<?>) type).isInstance(adapter))) {
return adapter;
}
}
@@ -167,8 +181,10 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This adds a listener.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void addListener(INotifyChangedListener notifyChangedListener) {
changeNotifier.addListener(notifyChangedListener);
}
@@ -177,8 +193,10 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This removes a listener.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void removeListener(INotifyChangedListener notifyChangedListener) {
changeNotifier.removeListener(notifyChangedListener);
}
@@ -187,8 +205,10 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
* This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void fireNotifyChanged(Notification notification) {
changeNotifier.fireNotifyChanged(notification);
@@ -198,13 +218,17 @@ public class FacadeItemProviderAdapterFactory extends FacadeAdapterFactory imple
}
/**
- * This disposes all of the item providers created by this factory.
+ * This disposes all of the item providers created by this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void dispose() {
- if (facadeItemProvider != null) facadeItemProvider.dispose();
+ if (facadeItemProvider != null) {
+ facadeItemProvider.dispose();
+ }
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualClassifierItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualClassifierItemProvider.java
index 9a6d888592c..6728029d817 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualClassifierItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualClassifierItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -33,11 +33,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualClassifierItemProvider
- extends VirtualElementItemProvider
- implements
+ extends VirtualElementItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -47,6 +48,7 @@ public class VirtualClassifierItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualClassifierItemProvider(AdapterFactory adapterFactory) {
@@ -57,6 +59,7 @@ public class VirtualClassifierItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -72,22 +75,24 @@ public class VirtualClassifierItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualClassifier)object).getAliasName();
+ String label = ((VirtualClassifier) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualClassifier_type") :
- getString("_UI_VirtualClassifier_type") + " " + label;
+ getString("_UI_VirtualClassifier_type") :
+ getString("_UI_VirtualClassifier_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -101,6 +106,7 @@ public class VirtualClassifierItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualDatatypeItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualDatatypeItemProvider.java
index 104c4b1ec6f..68adf5931d3 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualDatatypeItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualDatatypeItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -33,11 +33,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualDatatype;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualDatatype} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualDatatypeItemProvider
- extends VirtualClassifierItemProvider
- implements
+ extends VirtualClassifierItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -47,6 +48,7 @@ public class VirtualDatatypeItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualDatatypeItemProvider(AdapterFactory adapterFactory) {
@@ -57,6 +59,7 @@ public class VirtualDatatypeItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -72,6 +75,7 @@ public class VirtualDatatypeItemProvider
* This returns VirtualDatatype.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -83,22 +87,24 @@ public class VirtualDatatypeItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualDatatype)object).getAliasName();
+ String label = ((VirtualDatatype) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualDatatype_type") :
- getString("_UI_VirtualDatatype_type") + " " + label;
+ getString("_UI_VirtualDatatype_type") :
+ getString("_UI_VirtualDatatype_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -112,6 +118,7 @@ public class VirtualDatatypeItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualElementItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualElementItemProvider.java
index c0b72509770..8889eeee2be 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualElementItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualElementItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -42,11 +42,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualElementItemProvider
- extends ItemProviderAdapter
- implements
+ extends ItemProviderAdapter
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -56,6 +57,7 @@ public class VirtualElementItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualElementItemProvider(AdapterFactory adapterFactory) {
@@ -66,6 +68,7 @@ public class VirtualElementItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -85,110 +88,116 @@ public class VirtualElementItemProvider
* This adds a property descriptor for the Alias Name feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addAliasNamePropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualElement_aliasName_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualElement_aliasName_feature", "_UI_VirtualElement_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_ELEMENT__ALIAS_NAME,
- true,
- false,
- false,
- ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualElement_aliasName_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualElement_aliasName_feature", "_UI_VirtualElement_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_ELEMENT__ALIAS_NAME,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Kept feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addKeptPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualElement_kept_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualElement_kept_feature", "_UI_VirtualElement_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_ELEMENT__KEPT,
- true,
- false,
- false,
- ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualElement_kept_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualElement_kept_feature", "_UI_VirtualElement_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_ELEMENT__KEPT,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Represented Element feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addRepresentedElementPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualElement_representedElement_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualElement_representedElement_feature", "_UI_VirtualElement_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualElement_representedElement_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualElement_representedElement_feature", "_UI_VirtualElement_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Use Represented feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addUseRepresentedPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualElement_useRepresented_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualElement_useRepresented_feature", "_UI_VirtualElement_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_ELEMENT__USE_REPRESENTED,
- true,
- false,
- false,
- ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualElement_useRepresented_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualElement_useRepresented_feature", "_UI_VirtualElement_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_ELEMENT__USE_REPRESENTED,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualElement)object).getAliasName();
+ String label = ((VirtualElement) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualElement_type") :
- getString("_UI_VirtualElement_type") + " " + label;
+ getString("_UI_VirtualElement_type") :
+ getString("_UI_VirtualElement_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -196,11 +205,11 @@ public class VirtualElementItemProvider
updateChildren(notification);
switch (notification.getFeatureID(VirtualElement.class)) {
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
- return;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
}
super.notifyChanged(notification);
}
@@ -210,6 +219,7 @@ public class VirtualElementItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -221,6 +231,7 @@ public class VirtualElementItemProvider
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualEnumItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualEnumItemProvider.java
index 01aa785cee0..e8187daed49 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualEnumItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualEnumItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -38,11 +38,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualEnumItemProvider
- extends VirtualClassifierItemProvider
- implements
+ extends VirtualClassifierItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -52,6 +53,7 @@ public class VirtualEnumItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualEnumItemProvider(AdapterFactory adapterFactory) {
@@ -62,6 +64,7 @@ public class VirtualEnumItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -74,11 +77,11 @@ public class VirtualEnumItemProvider
}
/**
- * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
* {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -93,6 +96,7 @@ public class VirtualEnumItemProvider
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -107,6 +111,7 @@ public class VirtualEnumItemProvider
* This returns VirtualEnum.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -118,22 +123,24 @@ public class VirtualEnumItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualEnum)object).getAliasName();
+ String label = ((VirtualEnum) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualEnum_type") :
- getString("_UI_VirtualEnum_type") + " " + label;
+ getString("_UI_VirtualEnum_type") :
+ getString("_UI_VirtualEnum_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -141,9 +148,9 @@ public class VirtualEnumItemProvider
updateChildren(notification);
switch (notification.getFeatureID(VirtualEnum.class)) {
- case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
+ case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -153,6 +160,7 @@ public class VirtualEnumItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -160,9 +168,9 @@ public class VirtualEnumItemProvider
super.collectNewChildDescriptors(newChildDescriptors, object);
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(VirtualmetamodelPackage.Literals.VIRTUAL_ENUM__LITERALS,
- VirtualmetamodelFactory.eINSTANCE.createVirtualLiteral()));
+ VirtualmetamodelFactory.eINSTANCE.createVirtualLiteral()));
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualLiteralItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualLiteralItemProvider.java
index 7c9c9815c11..60f53e61dcb 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualLiteralItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualLiteralItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -33,11 +33,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualLiteral;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualLiteral} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualLiteralItemProvider
- extends VirtualElementItemProvider
- implements
+ extends VirtualElementItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -47,6 +48,7 @@ public class VirtualLiteralItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualLiteralItemProvider(AdapterFactory adapterFactory) {
@@ -57,6 +59,7 @@ public class VirtualLiteralItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -72,6 +75,7 @@ public class VirtualLiteralItemProvider
* This returns VirtualLiteral.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -83,22 +87,24 @@ public class VirtualLiteralItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualLiteral)object).getAliasName();
+ String label = ((VirtualLiteral) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualLiteral_type") :
- getString("_UI_VirtualLiteral_type") + " " + label;
+ getString("_UI_VirtualLiteral_type") :
+ getString("_UI_VirtualLiteral_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -112,6 +118,7 @@ public class VirtualLiteralItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetaclassItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetaclassItemProvider.java
index 5b5ff556299..128778ea134 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetaclassItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetaclassItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -40,11 +40,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualMetaclassItemProvider
- extends VirtualClassifierItemProvider
- implements
+ extends VirtualClassifierItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -54,6 +55,7 @@ public class VirtualMetaclassItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualMetaclassItemProvider(AdapterFactory adapterFactory) {
@@ -64,6 +66,7 @@ public class VirtualMetaclassItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -83,96 +86,100 @@ public class VirtualMetaclassItemProvider
* This adds a property descriptor for the Abstract feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addAbstractPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualMetaclass_abstract_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetaclass_abstract_feature", "_UI_VirtualMetaclass_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__ABSTRACT,
- true,
- false,
- false,
- ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualMetaclass_abstract_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetaclass_abstract_feature", "_UI_VirtualMetaclass_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__ABSTRACT,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Applied Stereotypes feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addAppliedStereotypesPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualMetaclass_appliedStereotypes_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetaclass_appliedStereotypes_feature", "_UI_VirtualMetaclass_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__APPLIED_STEREOTYPES,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualMetaclass_appliedStereotypes_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetaclass_appliedStereotypes_feature", "_UI_VirtualMetaclass_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__APPLIED_STEREOTYPES,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Parents feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addParentsPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualMetaclass_parents_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetaclass_parents_feature", "_UI_VirtualMetaclass_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__PARENTS,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualMetaclass_parents_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetaclass_parents_feature", "_UI_VirtualMetaclass_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__PARENTS,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Stereotype Interface feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addStereotypeInterfacePropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualMetaclass_stereotypeInterface_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetaclass_stereotypeInterface_feature", "_UI_VirtualMetaclass_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE,
- true,
- false,
- false,
- ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualMetaclass_stereotypeInterface_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetaclass_stereotypeInterface_feature", "_UI_VirtualMetaclass_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.BOOLEAN_VALUE_IMAGE,
+ null,
+ null));
}
/**
- * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
* {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -188,6 +195,7 @@ public class VirtualMetaclassItemProvider
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -202,6 +210,7 @@ public class VirtualMetaclassItemProvider
* This returns VirtualMetaclass.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -213,22 +222,24 @@ public class VirtualMetaclassItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualMetaclass)object).getAliasName();
+ String label = ((VirtualMetaclass) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualMetaclass_type") :
- getString("_UI_VirtualMetaclass_type") + " " + label;
+ getString("_UI_VirtualMetaclass_type") :
+ getString("_UI_VirtualMetaclass_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -236,14 +247,14 @@ public class VirtualMetaclassItemProvider
updateChildren(notification);
switch (notification.getFeatureID(VirtualMetaclass.class)) {
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -253,6 +264,7 @@ public class VirtualMetaclassItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -260,14 +272,14 @@ public class VirtualMetaclassItemProvider
super.collectNewChildDescriptors(newChildDescriptors, object);
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__OPERATIONS,
- VirtualmetamodelFactory.eINSTANCE.createVirtualOperation()));
+ VirtualmetamodelFactory.eINSTANCE.createVirtualOperation()));
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(VirtualmetamodelPackage.Literals.VIRTUAL_METACLASS__PROPERTIES,
- VirtualmetamodelFactory.eINSTANCE.createVirtualProperty()));
+ VirtualmetamodelFactory.eINSTANCE.createVirtualProperty()));
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetamodelItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetamodelItemProvider.java
index ba7051fa7b2..95ee2ec9b98 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetamodelItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualMetamodelItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -45,11 +45,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualMetamodelItemProvider
- extends ItemProviderAdapter
- implements
+ extends ItemProviderAdapter
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -59,6 +60,7 @@ public class VirtualMetamodelItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualMetamodelItemProvider(AdapterFactory adapterFactory) {
@@ -69,6 +71,7 @@ public class VirtualMetamodelItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -87,74 +90,77 @@ public class VirtualMetamodelItemProvider
* This adds a property descriptor for the Name feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addNamePropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualMetamodel_name_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetamodel_name_feature", "_UI_VirtualMetamodel_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_METAMODEL__NAME,
- true,
- false,
- false,
- ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualMetamodel_name_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetamodel_name_feature", "_UI_VirtualMetamodel_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_METAMODEL__NAME,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Ns Prefix feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addNsPrefixPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualMetamodel_nsPrefix_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetamodel_nsPrefix_feature", "_UI_VirtualMetamodel_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_METAMODEL__NS_PREFIX,
- true,
- false,
- false,
- ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualMetamodel_nsPrefix_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetamodel_nsPrefix_feature", "_UI_VirtualMetamodel_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_METAMODEL__NS_PREFIX,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Ns URI feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addNsURIPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualMetamodel_nsURI_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetamodel_nsURI_feature", "_UI_VirtualMetamodel_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_METAMODEL__NS_URI,
- true,
- false,
- false,
- ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualMetamodel_nsURI_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualMetamodel_nsURI_feature", "_UI_VirtualMetamodel_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_METAMODEL__NS_URI,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
- * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
* {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -169,6 +175,7 @@ public class VirtualMetamodelItemProvider
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -183,6 +190,7 @@ public class VirtualMetamodelItemProvider
* This returns VirtualMetamodel.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -194,22 +202,24 @@ public class VirtualMetamodelItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualMetamodel)object).getName();
+ String label = ((VirtualMetamodel) object).getName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualMetamodel_type") :
- getString("_UI_VirtualMetamodel_type") + " " + label;
+ getString("_UI_VirtualMetamodel_type") :
+ getString("_UI_VirtualMetamodel_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -217,14 +227,14 @@ public class VirtualMetamodelItemProvider
updateChildren(notification);
switch (notification.getFeatureID(VirtualMetamodel.class)) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
- return;
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -234,6 +244,7 @@ public class VirtualMetamodelItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -241,25 +252,26 @@ public class VirtualMetamodelItemProvider
super.collectNewChildDescriptors(newChildDescriptors, object);
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(VirtualmetamodelPackage.Literals.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS,
- VirtualmetamodelFactory.eINSTANCE.createVirtualMetaclass()));
+ VirtualmetamodelFactory.eINSTANCE.createVirtualMetaclass()));
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(VirtualmetamodelPackage.Literals.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS,
- VirtualmetamodelFactory.eINSTANCE.createVirtualDatatype()));
+ VirtualmetamodelFactory.eINSTANCE.createVirtualDatatype()));
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(VirtualmetamodelPackage.Literals.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS,
- VirtualmetamodelFactory.eINSTANCE.createVirtualEnum()));
+ VirtualmetamodelFactory.eINSTANCE.createVirtualEnum()));
}
/**
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualOperationItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualOperationItemProvider.java
index a7367b9c2f9..867ed4451c3 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualOperationItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualOperationItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -38,11 +38,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualOperationItemProvider
- extends VirtualTypedElementItemProvider
- implements
+ extends VirtualTypedElementItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -52,6 +53,7 @@ public class VirtualOperationItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualOperationItemProvider(AdapterFactory adapterFactory) {
@@ -62,6 +64,7 @@ public class VirtualOperationItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -74,11 +77,11 @@ public class VirtualOperationItemProvider
}
/**
- * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
* {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -93,6 +96,7 @@ public class VirtualOperationItemProvider
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -107,6 +111,7 @@ public class VirtualOperationItemProvider
* This returns VirtualOperation.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -118,22 +123,24 @@ public class VirtualOperationItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualOperation)object).getAliasName();
+ String label = ((VirtualOperation) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualOperation_type") :
- getString("_UI_VirtualOperation_type") + " " + label;
+ getString("_UI_VirtualOperation_type") :
+ getString("_UI_VirtualOperation_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -141,9 +148,9 @@ public class VirtualOperationItemProvider
updateChildren(notification);
switch (notification.getFeatureID(VirtualOperation.class)) {
- case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
+ case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -153,6 +160,7 @@ public class VirtualOperationItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -160,9 +168,9 @@ public class VirtualOperationItemProvider
super.collectNewChildDescriptors(newChildDescriptors, object);
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(VirtualmetamodelPackage.Literals.VIRTUAL_OPERATION__PARAMETERS,
- VirtualmetamodelFactory.eINSTANCE.createVirtualParameter()));
+ VirtualmetamodelFactory.eINSTANCE.createVirtualParameter()));
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualParameterItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualParameterItemProvider.java
index 7a62a02145a..57560297b96 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualParameterItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualParameterItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -33,11 +33,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualParameter;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualParameter} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualParameterItemProvider
- extends VirtualTypedElementItemProvider
- implements
+ extends VirtualTypedElementItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -47,6 +48,7 @@ public class VirtualParameterItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualParameterItemProvider(AdapterFactory adapterFactory) {
@@ -57,6 +59,7 @@ public class VirtualParameterItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -72,6 +75,7 @@ public class VirtualParameterItemProvider
* This returns VirtualParameter.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -83,22 +87,24 @@ public class VirtualParameterItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualParameter)object).getAliasName();
+ String label = ((VirtualParameter) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualParameter_type") :
- getString("_UI_VirtualParameter_type") + " " + label;
+ getString("_UI_VirtualParameter_type") :
+ getString("_UI_VirtualParameter_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -112,6 +118,7 @@ public class VirtualParameterItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualPropertyItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualPropertyItemProvider.java
index 34000d0bc84..b574d07b943 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualPropertyItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualPropertyItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -33,11 +33,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualPropertyItemProvider
- extends VirtualTypedElementItemProvider
- implements
+ extends VirtualTypedElementItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -47,6 +48,7 @@ public class VirtualPropertyItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualPropertyItemProvider(AdapterFactory adapterFactory) {
@@ -57,6 +59,7 @@ public class VirtualPropertyItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -72,6 +75,7 @@ public class VirtualPropertyItemProvider
* This returns VirtualProperty.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -83,22 +87,24 @@ public class VirtualPropertyItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualProperty)object).getAliasName();
+ String label = ((VirtualProperty) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualProperty_type") :
- getString("_UI_VirtualProperty_type") + " " + label;
+ getString("_UI_VirtualProperty_type") :
+ getString("_UI_VirtualProperty_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -112,6 +118,7 @@ public class VirtualPropertyItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualTypedElementItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualTypedElementItemProvider.java
index 61f53671c92..11487a12c10 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualTypedElementItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualTypedElementItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -37,11 +37,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualTypedElementItemProvider
- extends VirtualElementItemProvider
- implements
+ extends VirtualElementItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -51,6 +52,7 @@ public class VirtualTypedElementItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualTypedElementItemProvider(AdapterFactory adapterFactory) {
@@ -61,6 +63,7 @@ public class VirtualTypedElementItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -79,88 +82,93 @@ public class VirtualTypedElementItemProvider
* This adds a property descriptor for the Lower feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addLowerPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualTypedElement_lower_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualTypedElement_lower_feature", "_UI_VirtualTypedElement_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_TYPED_ELEMENT__LOWER,
- true,
- false,
- false,
- ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualTypedElement_lower_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualTypedElement_lower_feature", "_UI_VirtualTypedElement_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_TYPED_ELEMENT__LOWER,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Upper feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addUpperPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualTypedElement_upper_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualTypedElement_upper_feature", "_UI_VirtualTypedElement_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_TYPED_ELEMENT__UPPER,
- true,
- false,
- false,
- ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualTypedElement_upper_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualTypedElement_upper_feature", "_UI_VirtualTypedElement_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_TYPED_ELEMENT__UPPER,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.INTEGRAL_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Type feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addTypePropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_VirtualTypedElement_type_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_VirtualTypedElement_type_feature", "_UI_VirtualTypedElement_type"),
- VirtualmetamodelPackage.Literals.VIRTUAL_TYPED_ELEMENT__TYPE,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_VirtualTypedElement_type_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_VirtualTypedElement_type_feature", "_UI_VirtualTypedElement_type"),
+ VirtualmetamodelPackage.Literals.VIRTUAL_TYPED_ELEMENT__TYPE,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- String label = ((VirtualTypedElement)object).getAliasName();
+ String label = ((VirtualTypedElement) object).getAliasName();
return label == null || label.length() == 0 ?
- getString("_UI_VirtualTypedElement_type") :
- getString("_UI_VirtualTypedElement_type") + " " + label;
+ getString("_UI_VirtualTypedElement_type") :
+ getString("_UI_VirtualTypedElement_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -168,10 +176,10 @@ public class VirtualTypedElementItemProvider
updateChildren(notification);
switch (notification.getFeatureID(VirtualTypedElement.class)) {
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
- return;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
}
super.notifyChanged(notification);
}
@@ -181,6 +189,7 @@ public class VirtualTypedElementItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualmetamodelItemProviderAdapterFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualmetamodelItemProviderAdapterFactory.java
index 297da5680a9..bf106df4987 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualmetamodelItemProviderAdapterFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facade/virtualmetamodel/provider/VirtualmetamodelItemProviderAdapterFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -41,6 +41,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.util.VirtualmetamodelAdapterF
* Note that most of the adapters are shared among multiple instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualmetamodelItemProviderAdapterFactory extends VirtualmetamodelAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable {
@@ -48,6 +49,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of the root adapter factory that delegates to this adapter factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ComposedAdapterFactory parentAdapterFactory;
@@ -56,6 +58,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IChangeNotifier changeNotifier = new ChangeNotifier();
@@ -64,6 +67,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Object> supportedTypes = new ArrayList<Object>();
@@ -72,6 +76,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This constructs an instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelItemProviderAdapterFactory() {
@@ -86,6 +91,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualMetamodelItemProvider virtualMetamodelItemProvider;
@@ -94,6 +100,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This creates an adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -109,6 +116,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualMetaclassItemProvider virtualMetaclassItemProvider;
@@ -117,6 +125,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This creates an adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -132,6 +141,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualPropertyItemProvider virtualPropertyItemProvider;
@@ -140,6 +150,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This creates an adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -155,6 +166,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualOperationItemProvider virtualOperationItemProvider;
@@ -163,6 +175,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This creates an adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -178,6 +191,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualParameter} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualParameterItemProvider virtualParameterItemProvider;
@@ -186,6 +200,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This creates an adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualParameter}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -201,6 +216,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualDatatype} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualDatatypeItemProvider virtualDatatypeItemProvider;
@@ -209,6 +225,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This creates an adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualDatatype}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -224,6 +241,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualEnumItemProvider virtualEnumItemProvider;
@@ -232,6 +250,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This creates an adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -247,6 +266,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualLiteral} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualLiteralItemProvider virtualLiteralItemProvider;
@@ -255,6 +275,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This creates an adapter for a {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualLiteral}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -270,8 +291,10 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This returns the root adapter factory that contains this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ComposeableAdapterFactory getRootAdapterFactory() {
return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory();
}
@@ -280,8 +303,10 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This sets the composed adapter factory that contains this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) {
this.parentAdapterFactory = parentAdapterFactory;
}
@@ -289,6 +314,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -300,6 +326,7 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This implementation substitutes the factory itself as the key for the adapter.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -310,13 +337,14 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object adapt(Object object, Object type) {
if (isFactoryForType(type)) {
Object adapter = super.adapt(object, type);
- if (!(type instanceof Class<?>) || (((Class<?>)type).isInstance(adapter))) {
+ if (!(type instanceof Class<?>) || (((Class<?>) type).isInstance(adapter))) {
return adapter;
}
}
@@ -328,8 +356,10 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This adds a listener.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void addListener(INotifyChangedListener notifyChangedListener) {
changeNotifier.addListener(notifyChangedListener);
}
@@ -338,8 +368,10 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This removes a listener.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void removeListener(INotifyChangedListener notifyChangedListener) {
changeNotifier.removeListener(notifyChangedListener);
}
@@ -348,8 +380,10 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
* This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void fireNotifyChanged(Notification notification) {
changeNotifier.fireNotifyChanged(notification);
@@ -359,20 +393,38 @@ public class VirtualmetamodelItemProviderAdapterFactory extends Virtualmetamodel
}
/**
- * This disposes all of the item providers created by this factory.
+ * This disposes all of the item providers created by this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void dispose() {
- if (virtualMetamodelItemProvider != null) virtualMetamodelItemProvider.dispose();
- if (virtualMetaclassItemProvider != null) virtualMetaclassItemProvider.dispose();
- if (virtualPropertyItemProvider != null) virtualPropertyItemProvider.dispose();
- if (virtualOperationItemProvider != null) virtualOperationItemProvider.dispose();
- if (virtualParameterItemProvider != null) virtualParameterItemProvider.dispose();
- if (virtualDatatypeItemProvider != null) virtualDatatypeItemProvider.dispose();
- if (virtualEnumItemProvider != null) virtualEnumItemProvider.dispose();
- if (virtualLiteralItemProvider != null) virtualLiteralItemProvider.dispose();
+ if (virtualMetamodelItemProvider != null) {
+ virtualMetamodelItemProvider.dispose();
+ }
+ if (virtualMetaclassItemProvider != null) {
+ virtualMetaclassItemProvider.dispose();
+ }
+ if (virtualPropertyItemProvider != null) {
+ virtualPropertyItemProvider.dispose();
+ }
+ if (virtualOperationItemProvider != null) {
+ virtualOperationItemProvider.dispose();
+ }
+ if (virtualParameterItemProvider != null) {
+ virtualParameterItemProvider.dispose();
+ }
+ if (virtualDatatypeItemProvider != null) {
+ virtualDatatypeItemProvider.dispose();
+ }
+ if (virtualEnumItemProvider != null) {
+ virtualEnumItemProvider.dispose();
+ }
+ if (virtualLiteralItemProvider != null) {
+ virtualLiteralItemProvider.dispose();
+ }
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacadeMapppingItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacadeMapppingItemProvider.java
index ffd74623b5f..a9e4dcf7a97 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacadeMapppingItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacadeMapppingItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -41,11 +41,12 @@ import org.eclipse.papyrus.facademapping.FacademappingPackage;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facademapping.FacadeMappping} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeMapppingItemProvider
- extends ItemProviderAdapter
- implements
+ extends ItemProviderAdapter
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -55,6 +56,7 @@ public class FacadeMapppingItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeMapppingItemProvider(AdapterFactory adapterFactory) {
@@ -65,6 +67,7 @@ public class FacadeMapppingItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -77,11 +80,11 @@ public class FacadeMapppingItemProvider
}
/**
- * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an
- * {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
+ * This specifies how to implement {@link #getChildren} and is used to deduce an appropriate feature for an {@link org.eclipse.emf.edit.command.AddCommand}, {@link org.eclipse.emf.edit.command.RemoveCommand} or
* {@link org.eclipse.emf.edit.command.MoveCommand} in {@link #createCommand}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -96,6 +99,7 @@ public class FacadeMapppingItemProvider
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -110,6 +114,7 @@ public class FacadeMapppingItemProvider
* This returns FacadeMappping.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -121,19 +126,21 @@ public class FacadeMapppingItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
return getString("_UI_FacadeMappping_type");
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -141,9 +148,9 @@ public class FacadeMapppingItemProvider
updateChildren(notification);
switch (notification.getFeatureID(FacadeMappping.class)) {
- case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
- return;
+ case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false));
+ return;
}
super.notifyChanged(notification);
}
@@ -153,6 +160,7 @@ public class FacadeMapppingItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -160,20 +168,21 @@ public class FacadeMapppingItemProvider
super.collectNewChildDescriptors(newChildDescriptors, object);
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(FacademappingPackage.Literals.FACADE_MAPPPING__MAPPINGS,
- FacademappingFactory.eINSTANCE.createMapping()));
+ FacademappingFactory.eINSTANCE.createMapping()));
newChildDescriptors.add
- (createChildParameter
+ (createChildParameter
(FacademappingPackage.Literals.FACADE_MAPPPING__MAPPINGS,
- FacademappingFactory.eINSTANCE.createStereotypedMapping()));
+ FacademappingFactory.eINSTANCE.createStereotypedMapping()));
}
/**
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingEditPlugin.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingEditPlugin.java
index 076161cc2dc..233dcb680f9 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingEditPlugin.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingEditPlugin.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -21,6 +21,7 @@ import org.eclipse.emf.common.util.ResourceLocator;
* This is the central singleton for the Facademapping edit plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public final class FacademappingEditPlugin extends EMFPlugin {
@@ -28,6 +29,7 @@ public final class FacademappingEditPlugin extends EMFPlugin {
* Keep track of the singleton.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final FacademappingEditPlugin INSTANCE = new FacademappingEditPlugin();
@@ -36,6 +38,7 @@ public final class FacademappingEditPlugin extends EMFPlugin {
* Keep track of the singleton.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static Implementation plugin;
@@ -44,18 +47,19 @@ public final class FacademappingEditPlugin extends EMFPlugin {
* Create the instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingEditPlugin() {
- super
- (new ResourceLocator [] {
- });
+ super(new ResourceLocator[] {
+ });
}
/**
* Returns the singleton instance of the Eclipse plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the singleton instance.
* @generated
*/
@@ -68,6 +72,7 @@ public final class FacademappingEditPlugin extends EMFPlugin {
* Returns the singleton instance of the Eclipse plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the singleton instance.
* @generated
*/
@@ -79,6 +84,7 @@ public final class FacademappingEditPlugin extends EMFPlugin {
* The actual implementation of the Eclipse <b>Plugin</b>.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static class Implementation extends EclipsePlugin {
@@ -86,6 +92,7 @@ public final class FacademappingEditPlugin extends EMFPlugin {
* Creates an instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Implementation() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingItemProviderAdapterFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingItemProviderAdapterFactory.java
index e0aabc70118..1616af03ecc 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingItemProviderAdapterFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/FacademappingItemProviderAdapterFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -41,6 +41,7 @@ import org.eclipse.papyrus.facademapping.util.FacademappingAdapterFactory;
* Note that most of the adapters are shared among multiple instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacademappingItemProviderAdapterFactory extends FacademappingAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable {
@@ -48,6 +49,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This keeps track of the root adapter factory that delegates to this adapter factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ComposedAdapterFactory parentAdapterFactory;
@@ -56,6 +58,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IChangeNotifier changeNotifier = new ChangeNotifier();
@@ -64,6 +67,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Object> supportedTypes = new ArrayList<Object>();
@@ -72,6 +76,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This constructs an instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingItemProviderAdapterFactory() {
@@ -86,6 +91,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facademapping.Mapping} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected MappingItemProvider mappingItemProvider;
@@ -94,6 +100,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This creates an adapter for a {@link org.eclipse.papyrus.facademapping.Mapping}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -109,6 +116,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facademapping.StereotypedMapping} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected StereotypedMappingItemProvider stereotypedMappingItemProvider;
@@ -117,6 +125,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This creates an adapter for a {@link org.eclipse.papyrus.facademapping.StereotypedMapping}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -132,6 +141,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This keeps track of the one adapter used for all {@link org.eclipse.papyrus.facademapping.FacadeMappping} instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacadeMapppingItemProvider facadeMapppingItemProvider;
@@ -140,6 +150,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This creates an adapter for a {@link org.eclipse.papyrus.facademapping.FacadeMappping}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -155,8 +166,10 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This returns the root adapter factory that contains this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ComposeableAdapterFactory getRootAdapterFactory() {
return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory();
}
@@ -165,8 +178,10 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This sets the composed adapter factory that contains this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) {
this.parentAdapterFactory = parentAdapterFactory;
}
@@ -174,6 +189,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -185,6 +201,7 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This implementation substitutes the factory itself as the key for the adapter.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -195,13 +212,14 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object adapt(Object object, Object type) {
if (isFactoryForType(type)) {
Object adapter = super.adapt(object, type);
- if (!(type instanceof Class<?>) || (((Class<?>)type).isInstance(adapter))) {
+ if (!(type instanceof Class<?>) || (((Class<?>) type).isInstance(adapter))) {
return adapter;
}
}
@@ -213,8 +231,10 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This adds a listener.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void addListener(INotifyChangedListener notifyChangedListener) {
changeNotifier.addListener(notifyChangedListener);
}
@@ -223,8 +243,10 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This removes a listener.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void removeListener(INotifyChangedListener notifyChangedListener) {
changeNotifier.removeListener(notifyChangedListener);
}
@@ -233,8 +255,10 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
* This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void fireNotifyChanged(Notification notification) {
changeNotifier.fireNotifyChanged(notification);
@@ -244,15 +268,23 @@ public class FacademappingItemProviderAdapterFactory extends FacademappingAdapte
}
/**
- * This disposes all of the item providers created by this factory.
+ * This disposes all of the item providers created by this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void dispose() {
- if (mappingItemProvider != null) mappingItemProvider.dispose();
- if (stereotypedMappingItemProvider != null) stereotypedMappingItemProvider.dispose();
- if (facadeMapppingItemProvider != null) facadeMapppingItemProvider.dispose();
+ if (mappingItemProvider != null) {
+ mappingItemProvider.dispose();
+ }
+ if (stereotypedMappingItemProvider != null) {
+ stereotypedMappingItemProvider.dispose();
+ }
+ if (facadeMapppingItemProvider != null) {
+ facadeMapppingItemProvider.dispose();
+ }
}
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/MappingItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/MappingItemProvider.java
index b5153a71257..90e76eb5f47 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/MappingItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/MappingItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -37,11 +37,12 @@ import org.eclipse.papyrus.facademapping.FacademappingPackage;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facademapping.Mapping} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class MappingItemProvider
- extends ItemProviderAdapter
- implements
+ extends ItemProviderAdapter
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -51,6 +52,7 @@ public class MappingItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public MappingItemProvider(AdapterFactory adapterFactory) {
@@ -61,6 +63,7 @@ public class MappingItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -78,50 +81,53 @@ public class MappingItemProvider
* This adds a property descriptor for the Uml Element feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addUmlElementPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_Mapping_umlElement_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_Mapping_umlElement_feature", "_UI_Mapping_type"),
- FacademappingPackage.Literals.MAPPING__UML_ELEMENT,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Mapping_umlElement_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_Mapping_umlElement_feature", "_UI_Mapping_type"),
+ FacademappingPackage.Literals.MAPPING__UML_ELEMENT,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Specific Domain Element feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addSpecificDomainElementPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_Mapping_specificDomainElement_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_Mapping_specificDomainElement_feature", "_UI_Mapping_type"),
- FacademappingPackage.Literals.MAPPING__SPECIFIC_DOMAIN_ELEMENT,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_Mapping_specificDomainElement_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_Mapping_specificDomainElement_feature", "_UI_Mapping_type"),
+ FacademappingPackage.Literals.MAPPING__SPECIFIC_DOMAIN_ELEMENT,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This returns Mapping.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -133,19 +139,21 @@ public class MappingItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
return getString("_UI_Mapping_type");
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -159,6 +167,7 @@ public class MappingItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -170,6 +179,7 @@ public class MappingItemProvider
* Return the resource locator for this item provider's resources.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/StereotypedMappingItemProvider.java b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/StereotypedMappingItemProvider.java
index eb992b8abf8..da2a259044a 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/StereotypedMappingItemProvider.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.edit/src/org/eclipse/papyrus/facademapping/provider/StereotypedMappingItemProvider.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -38,11 +38,12 @@ import org.eclipse.papyrus.facademapping.StereotypedMapping;
* This is the item provider adapter for a {@link org.eclipse.papyrus.facademapping.StereotypedMapping} object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class StereotypedMappingItemProvider
- extends MappingItemProvider
- implements
+ extends MappingItemProvider
+ implements
IEditingDomainItemProvider,
IStructuredItemContentProvider,
ITreeItemContentProvider,
@@ -52,6 +53,7 @@ public class StereotypedMappingItemProvider
* This constructs an instance from a factory and a notifier.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public StereotypedMappingItemProvider(AdapterFactory adapterFactory) {
@@ -62,6 +64,7 @@ public class StereotypedMappingItemProvider
* This returns the property descriptors for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -79,50 +82,53 @@ public class StereotypedMappingItemProvider
* This adds a property descriptor for the Applied Stereotypes feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addAppliedStereotypesPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_StereotypedMapping_appliedStereotypes_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_StereotypedMapping_appliedStereotypes_feature", "_UI_StereotypedMapping_type"),
- FacademappingPackage.Literals.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES,
- true,
- false,
- true,
- null,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_StereotypedMapping_appliedStereotypes_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_StereotypedMapping_appliedStereotypes_feature", "_UI_StereotypedMapping_type"),
+ FacademappingPackage.Literals.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES,
+ true,
+ false,
+ true,
+ null,
+ null,
+ null));
}
/**
* This adds a property descriptor for the Kind feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void addKindPropertyDescriptor(Object object) {
itemPropertyDescriptors.add
- (createItemPropertyDescriptor
- (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(),
- getResourceLocator(),
- getString("_UI_StereotypedMapping_kind_feature"),
- getString("_UI_PropertyDescriptor_description", "_UI_StereotypedMapping_kind_feature", "_UI_StereotypedMapping_type"),
- FacademappingPackage.Literals.STEREOTYPED_MAPPING__KIND,
- true,
- false,
- false,
- ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
- null,
- null));
+ (createItemPropertyDescriptor
+ (((ComposeableAdapterFactory) adapterFactory).getRootAdapterFactory(),
+ getResourceLocator(),
+ getString("_UI_StereotypedMapping_kind_feature"),
+ getString("_UI_PropertyDescriptor_description", "_UI_StereotypedMapping_kind_feature", "_UI_StereotypedMapping_type"),
+ FacademappingPackage.Literals.STEREOTYPED_MAPPING__KIND,
+ true,
+ false,
+ false,
+ ItemPropertyDescriptor.GENERIC_VALUE_IMAGE,
+ null,
+ null));
}
/**
* This returns StereotypedMapping.gif.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -134,23 +140,25 @@ public class StereotypedMappingItemProvider
* This returns the label text for the adapted class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String getText(Object object) {
- ExtensionDefinitionKind labelValue = ((StereotypedMapping)object).getKind();
+ ExtensionDefinitionKind labelValue = ((StereotypedMapping) object).getKind();
String label = labelValue == null ? null : labelValue.toString();
return label == null || label.length() == 0 ?
- getString("_UI_StereotypedMapping_type") :
- getString("_UI_StereotypedMapping_type") + " " + label;
+ getString("_UI_StereotypedMapping_type") :
+ getString("_UI_StereotypedMapping_type") + " " + label;
}
-
+
/**
* This handles model notifications by calling {@link #updateChildren} to update any cached
* children and by creating a viewer notification, which it passes to {@link #fireNotifyChanged}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -158,9 +166,9 @@ public class StereotypedMappingItemProvider
updateChildren(notification);
switch (notification.getFeatureID(StereotypedMapping.class)) {
- case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
- fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
- return;
+ case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
+ fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true));
+ return;
}
super.notifyChanged(notification);
}
@@ -170,6 +178,7 @@ public class StereotypedMappingItemProvider
* that can be created under this object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionActionBarContributor.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionActionBarContributor.java
index c33812ffa64..e11eac3a57e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionActionBarContributor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionActionBarContributor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -56,15 +56,17 @@ import org.eclipse.ui.PartInitException;
* This is the action bar contributor for the Extensiondefinition model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensiondefinitionActionBarContributor
- extends EditingDomainActionBarContributor
- implements ISelectionChangedListener {
+ extends EditingDomainActionBarContributor
+ implements ISelectionChangedListener {
/**
* This keeps track of the active editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IEditorPart activeEditorPart;
@@ -73,6 +75,7 @@ public class ExtensiondefinitionActionBarContributor
* This keeps track of the current selection provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelectionProvider selectionProvider;
@@ -81,51 +84,54 @@ public class ExtensiondefinitionActionBarContributor
* This action opens the Properties view.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IAction showPropertiesViewAction =
- new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) {
- @Override
- public void run() {
- try {
- getPage().showView("org.eclipse.ui.views.PropertySheet");
- }
- catch (PartInitException exception) {
- FacadeEditorPlugin.INSTANCE.log(exception);
+ new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) {
+ @Override
+ public void run() {
+ try {
+ getPage().showView("org.eclipse.ui.views.PropertySheet");
+ }
+ catch (PartInitException exception) {
+ FacadeEditorPlugin.INSTANCE.log(exception);
+ }
}
- }
- };
+ };
/**
* This action refreshes the viewer of the current editor if the editor
* implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IAction refreshViewerAction =
- new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) {
- @Override
- public boolean isEnabled() {
- return activeEditorPart instanceof IViewerProvider;
- }
+ new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) {
+ @Override
+ public boolean isEnabled() {
+ return activeEditorPart instanceof IViewerProvider;
+ }
- @Override
- public void run() {
- if (activeEditorPart instanceof IViewerProvider) {
- Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer();
- if (viewer != null) {
- viewer.refresh();
+ @Override
+ public void run() {
+ if (activeEditorPart instanceof IViewerProvider) {
+ Viewer viewer = ((IViewerProvider) activeEditorPart).getViewer();
+ if (viewer != null) {
+ viewer.refresh();
+ }
}
}
- }
- };
+ };
/**
* This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor
* generated for the current selection by the item provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> createChildActions;
@@ -134,6 +140,7 @@ public class ExtensiondefinitionActionBarContributor
* This is the menu manager into which menu contribution items should be added for CreateChild actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IMenuManager createChildMenuManager;
@@ -143,6 +150,7 @@ public class ExtensiondefinitionActionBarContributor
* generated for the current selection by the item provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> createSiblingActions;
@@ -151,6 +159,7 @@ public class ExtensiondefinitionActionBarContributor
* This is the menu manager into which menu contribution items should be added for CreateSibling actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IMenuManager createSiblingMenuManager;
@@ -159,6 +168,7 @@ public class ExtensiondefinitionActionBarContributor
* This creates an instance of the contributor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionActionBarContributor() {
@@ -172,6 +182,7 @@ public class ExtensiondefinitionActionBarContributor
* This adds Separators for editor additions to the tool bar.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -185,6 +196,7 @@ public class ExtensiondefinitionActionBarContributor
* as well as the sub-menus for object creation items.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -211,11 +223,12 @@ public class ExtensiondefinitionActionBarContributor
// Force an update because Eclipse hides empty menus now.
//
submenuManager.addMenuListener
- (new IMenuListener() {
- public void menuAboutToShow(IMenuManager menuManager) {
- menuManager.updateAll(true);
- }
- });
+ (new IMenuListener() {
+ @Override
+ public void menuAboutToShow(IMenuManager menuManager) {
+ menuManager.updateAll(true);
+ }
+ });
addGlobalActions(submenuManager);
}
@@ -224,6 +237,7 @@ public class ExtensiondefinitionActionBarContributor
* When the active editor changes, this remembers the change and registers with it as a selection provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -257,8 +271,10 @@ public class ExtensiondefinitionActionBarContributor
* that can be added to the selected object and updating the menus accordingly.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
// Remove any menu items for old selection.
//
@@ -275,10 +291,10 @@ public class ExtensiondefinitionActionBarContributor
Collection<?> newSiblingDescriptors = null;
ISelection selection = event.getSelection();
- if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) {
- Object object = ((IStructuredSelection)selection).getFirstElement();
+ if (selection instanceof IStructuredSelection && ((IStructuredSelection) selection).size() == 1) {
+ Object object = ((IStructuredSelection) selection).getFirstElement();
- EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain();
+ EditingDomain domain = ((IEditingDomainProvider) activeEditorPart).getEditingDomain();
newChildDescriptors = domain.getNewChildDescriptors(object, null);
newSiblingDescriptors = domain.getNewChildDescriptors(null, object);
@@ -304,6 +320,7 @@ public class ExtensiondefinitionActionBarContributor
* and returns the collection of these actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> generateCreateChildActions(Collection<?> descriptors, ISelection selection) {
@@ -321,6 +338,7 @@ public class ExtensiondefinitionActionBarContributor
* and returns the collection of these actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> generateCreateSiblingActions(Collection<?> descriptors, ISelection selection) {
@@ -340,6 +358,7 @@ public class ExtensiondefinitionActionBarContributor
* If <code>contributionID</code> is <code>null</code>, they are simply added.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void populateManager(IContributionManager manager, Collection<? extends IAction> actions, String contributionID) {
@@ -354,12 +373,13 @@ public class ExtensiondefinitionActionBarContributor
}
}
}
-
+
/**
* This removes from the specified <code>manager</code> all {@link org.eclipse.jface.action.ActionContributionItem}s
* based on the {@link org.eclipse.jface.action.IAction}s contained in the <code>actions</code> collection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void depopulateManager(IContributionManager manager, Collection<? extends IAction> actions) {
@@ -370,13 +390,13 @@ public class ExtensiondefinitionActionBarContributor
//
IContributionItem contributionItem = items[i];
while (contributionItem instanceof SubContributionItem) {
- contributionItem = ((SubContributionItem)contributionItem).getInnerItem();
+ contributionItem = ((SubContributionItem) contributionItem).getInnerItem();
}
// Delete the ActionContributionItems with matching action.
//
if (contributionItem instanceof ActionContributionItem) {
- IAction action = ((ActionContributionItem)contributionItem).getAction();
+ IAction action = ((ActionContributionItem) contributionItem).getAction();
if (actions.contains(action)) {
manager.remove(contributionItem);
}
@@ -389,6 +409,7 @@ public class ExtensiondefinitionActionBarContributor
* This populates the pop-up menu before it appears.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -409,6 +430,7 @@ public class ExtensiondefinitionActionBarContributor
* This inserts global actions before the "additions-end" separator.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -416,7 +438,7 @@ public class ExtensiondefinitionActionBarContributor
menuManager.insertAfter("additions-end", new Separator("ui-actions"));
menuManager.insertAfter("ui-actions", showPropertiesViewAction);
- refreshViewerAction.setEnabled(refreshViewerAction.isEnabled());
+ refreshViewerAction.setEnabled(refreshViewerAction.isEnabled());
menuManager.insertAfter("ui-actions", refreshViewerAction);
super.addGlobalActions(menuManager);
@@ -426,6 +448,7 @@ public class ExtensiondefinitionActionBarContributor
* This ensures that a delete action will clean up all references to deleted objects.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionEditor.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionEditor.java
index 52e9d012c6e..d3fa4b85adb 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionEditor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionEditor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -131,7 +131,6 @@ import org.eclipse.emf.common.util.BasicDiagnostic;
import org.eclipse.emf.common.util.Diagnostic;
import org.eclipse.emf.common.util.URI;
-
import org.eclipse.emf.ecore.resource.Resource;
import org.eclipse.emf.ecore.resource.ResourceSet;
@@ -184,15 +183,17 @@ import org.eclipse.uml2.uml.edit.providers.UMLItemProviderAdapterFactory;
* This is an example of a Extensiondefinition model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensiondefinitionEditor
- extends MultiPageEditorPart
- implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker {
+ extends MultiPageEditorPart
+ implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker {
/**
* This keeps track of the editing domain that is used to track all changes to the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected AdapterFactoryEditingDomain editingDomain;
@@ -201,6 +202,7 @@ public class ExtensiondefinitionEditor
* This is the one adapter factory used for providing views of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ComposedAdapterFactory adapterFactory;
@@ -209,6 +211,7 @@ public class ExtensiondefinitionEditor
* This is the content outline page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IContentOutlinePage contentOutlinePage;
@@ -217,6 +220,7 @@ public class ExtensiondefinitionEditor
* This is a kludge...
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IStatusLineManager contentOutlineStatusLineManager;
@@ -225,6 +229,7 @@ public class ExtensiondefinitionEditor
* This is the content outline page's viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer contentOutlineViewer;
@@ -233,6 +238,7 @@ public class ExtensiondefinitionEditor
* This is the property sheet page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected List<PropertySheetPage> propertySheetPages = new ArrayList<PropertySheetPage>();
@@ -242,6 +248,7 @@ public class ExtensiondefinitionEditor
* The parent relation must be correctly defined for this to work.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer selectionViewer;
@@ -250,6 +257,7 @@ public class ExtensiondefinitionEditor
* This inverts the roll of parent and child in the content provider and show parents as a tree.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer parentViewer;
@@ -258,6 +266,7 @@ public class ExtensiondefinitionEditor
* This shows how a tree view works.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer treeViewer;
@@ -267,6 +276,7 @@ public class ExtensiondefinitionEditor
* A list viewer doesn't support icons.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ListViewer listViewer;
@@ -276,6 +286,7 @@ public class ExtensiondefinitionEditor
* A table can be used as a list with icons.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TableViewer tableViewer;
@@ -284,6 +295,7 @@ public class ExtensiondefinitionEditor
* This shows how a tree view with columns works.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer treeViewerWithColumns;
@@ -292,6 +304,7 @@ public class ExtensiondefinitionEditor
* This keeps track of the active viewer pane, in the book.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ViewerPane currentViewerPane;
@@ -300,6 +313,7 @@ public class ExtensiondefinitionEditor
* This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Viewer currentViewer;
@@ -308,6 +322,7 @@ public class ExtensiondefinitionEditor
* This listens to which ever viewer is active.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelectionChangedListener selectionChangedListener;
@@ -316,6 +331,7 @@ public class ExtensiondefinitionEditor
* This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<ISelectionChangedListener> selectionChangedListeners = new ArrayList<ISelectionChangedListener>();
@@ -324,6 +340,7 @@ public class ExtensiondefinitionEditor
* This keeps track of the selection of the editor as a whole.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelection editorSelection = StructuredSelection.EMPTY;
@@ -333,6 +350,7 @@ public class ExtensiondefinitionEditor
* in Eclipse's Problems View.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected MarkerHelper markerHelper = new EditUIMarkerHelper();
@@ -341,46 +359,57 @@ public class ExtensiondefinitionEditor
* This listens for when the outline becomes active
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IPartListener partListener =
- new IPartListener() {
- public void partActivated(IWorkbenchPart p) {
- if (p instanceof ContentOutline) {
- if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) {
- getActionBarContributor().setActiveEditor(ExtensiondefinitionEditor.this);
+ new IPartListener() {
+ @Override
+ public void partActivated(IWorkbenchPart p) {
+ if (p instanceof ContentOutline) {
+ if (((ContentOutline) p).getCurrentPage() == contentOutlinePage) {
+ getActionBarContributor().setActiveEditor(ExtensiondefinitionEditor.this);
- setCurrentViewer(contentOutlineViewer);
+ setCurrentViewer(contentOutlineViewer);
+ }
}
- }
- else if (p instanceof PropertySheet) {
- if (propertySheetPages.contains(((PropertySheet)p).getCurrentPage())) {
- getActionBarContributor().setActiveEditor(ExtensiondefinitionEditor.this);
+ else if (p instanceof PropertySheet) {
+ if (propertySheetPages.contains(((PropertySheet) p).getCurrentPage())) {
+ getActionBarContributor().setActiveEditor(ExtensiondefinitionEditor.this);
+ handleActivate();
+ }
+ }
+ else if (p == ExtensiondefinitionEditor.this) {
handleActivate();
}
}
- else if (p == ExtensiondefinitionEditor.this) {
- handleActivate();
+
+ @Override
+ public void partBroughtToTop(IWorkbenchPart p) {
+ // Ignore.
+ }
+
+ @Override
+ public void partClosed(IWorkbenchPart p) {
+ // Ignore.
+ }
+
+ @Override
+ public void partDeactivated(IWorkbenchPart p) {
+ // Ignore.
}
- }
- public void partBroughtToTop(IWorkbenchPart p) {
- // Ignore.
- }
- public void partClosed(IWorkbenchPart p) {
- // Ignore.
- }
- public void partDeactivated(IWorkbenchPart p) {
- // Ignore.
- }
- public void partOpened(IWorkbenchPart p) {
- // Ignore.
- }
- };
+
+ @Override
+ public void partOpened(IWorkbenchPart p) {
+ // Ignore.
+ }
+ };
/**
* Resources that have been removed since last activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> removedResources = new ArrayList<Resource>();
@@ -389,6 +418,7 @@ public class ExtensiondefinitionEditor
* Resources that have been changed since last activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> changedResources = new ArrayList<Resource>();
@@ -397,6 +427,7 @@ public class ExtensiondefinitionEditor
* Resources that have been saved.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> savedResources = new ArrayList<Resource>();
@@ -405,6 +436,7 @@ public class ExtensiondefinitionEditor
* Map to store the diagnostic associated with a resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Map<Resource, Diagnostic> resourceToDiagnosticMap = new LinkedHashMap<Resource, Diagnostic>();
@@ -413,6 +445,7 @@ public class ExtensiondefinitionEditor
* Controls whether the problem indication should be updated.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean updateProblemIndication = true;
@@ -421,18 +454,19 @@ public class ExtensiondefinitionEditor
* Adapter used to update the problem indication when resources are demanded loaded.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected EContentAdapter problemIndicationAdapter =
- new EContentAdapter() {
- @Override
- public void notifyChanged(Notification notification) {
- if (notification.getNotifier() instanceof Resource) {
- switch (notification.getFeatureID(Resource.class)) {
+ new EContentAdapter() {
+ @Override
+ public void notifyChanged(Notification notification) {
+ if (notification.getNotifier() instanceof Resource) {
+ switch (notification.getFeatureID(Resource.class)) {
case Resource.RESOURCE__IS_LOADED:
case Resource.RESOURCE__ERRORS:
case Resource.RESOURCE__WARNINGS: {
- Resource resource = (Resource)notification.getNotifier();
+ Resource resource = (Resource) notification.getNotifier();
Diagnostic diagnostic = analyzeResourceProblems(resource, null);
if (diagnostic.getSeverity() != Diagnostic.OK) {
resourceToDiagnosticMap.put(resource, diagnostic);
@@ -443,134 +477,142 @@ public class ExtensiondefinitionEditor
if (updateProblemIndication) {
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
}
break;
}
+ }
+ }
+ else {
+ super.notifyChanged(notification);
}
}
- else {
- super.notifyChanged(notification);
- }
- }
- @Override
- protected void setTarget(Resource target) {
- basicSetTarget(target);
- }
+ @Override
+ protected void setTarget(Resource target) {
+ basicSetTarget(target);
+ }
- @Override
- protected void unsetTarget(Resource target) {
- basicUnsetTarget(target);
- resourceToDiagnosticMap.remove(target);
- if (updateProblemIndication) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ @Override
+ protected void unsetTarget(Resource target) {
+ basicUnsetTarget(target);
+ resourceToDiagnosticMap.remove(target);
+ if (updateProblemIndication) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
+ }
}
- }
- };
+ };
/**
* This listens for workspace changes.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IResourceChangeListener resourceChangeListener =
- new IResourceChangeListener() {
- public void resourceChanged(IResourceChangeEvent event) {
- IResourceDelta delta = event.getDelta();
- try {
- class ResourceDeltaVisitor implements IResourceDeltaVisitor {
- protected ResourceSet resourceSet = editingDomain.getResourceSet();
- protected Collection<Resource> changedResources = new ArrayList<Resource>();
- protected Collection<Resource> removedResources = new ArrayList<Resource>();
-
- public boolean visit(IResourceDelta delta) {
- if (delta.getResource().getType() == IResource.FILE) {
- if (delta.getKind() == IResourceDelta.REMOVED ||
- delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) {
- Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false);
- if (resource != null) {
- if (delta.getKind() == IResourceDelta.REMOVED) {
- removedResources.add(resource);
- }
- else if (!savedResources.remove(resource)) {
- changedResources.add(resource);
+ new IResourceChangeListener() {
+ @Override
+ public void resourceChanged(IResourceChangeEvent event) {
+ IResourceDelta delta = event.getDelta();
+ try {
+ class ResourceDeltaVisitor implements IResourceDeltaVisitor {
+ protected ResourceSet resourceSet = editingDomain.getResourceSet();
+ protected Collection<Resource> changedResources = new ArrayList<Resource>();
+ protected Collection<Resource> removedResources = new ArrayList<Resource>();
+
+ @Override
+ public boolean visit(IResourceDelta delta) {
+ if (delta.getResource().getType() == IResource.FILE) {
+ if (delta.getKind() == IResourceDelta.REMOVED ||
+ delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) {
+ Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false);
+ if (resource != null) {
+ if (delta.getKind() == IResourceDelta.REMOVED) {
+ removedResources.add(resource);
+ }
+ else if (!savedResources.remove(resource)) {
+ changedResources.add(resource);
+ }
}
}
+ return false;
}
- return false;
+
+ return true;
}
- return true;
- }
+ public Collection<Resource> getChangedResources() {
+ return changedResources;
+ }
- public Collection<Resource> getChangedResources() {
- return changedResources;
+ public Collection<Resource> getRemovedResources() {
+ return removedResources;
+ }
}
- public Collection<Resource> getRemovedResources() {
- return removedResources;
- }
- }
+ final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor();
+ delta.accept(visitor);
- final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor();
- delta.accept(visitor);
+ if (!visitor.getRemovedResources().isEmpty()) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ removedResources.addAll(visitor.getRemovedResources());
+ if (!isDirty()) {
+ getSite().getPage().closeEditor(ExtensiondefinitionEditor.this, false);
+ }
+ }
+ });
+ }
- if (!visitor.getRemovedResources().isEmpty()) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- removedResources.addAll(visitor.getRemovedResources());
- if (!isDirty()) {
- getSite().getPage().closeEditor(ExtensiondefinitionEditor.this, false);
- }
- }
- });
+ if (!visitor.getChangedResources().isEmpty()) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ changedResources.addAll(visitor.getChangedResources());
+ if (getSite().getPage().getActiveEditor() == ExtensiondefinitionEditor.this) {
+ handleActivate();
+ }
+ }
+ });
+ }
}
-
- if (!visitor.getChangedResources().isEmpty()) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- changedResources.addAll(visitor.getChangedResources());
- if (getSite().getPage().getActiveEditor() == ExtensiondefinitionEditor.this) {
- handleActivate();
- }
- }
- });
+ catch (CoreException exception) {
+ FacadeEditorPlugin.INSTANCE.log(exception);
}
}
- catch (CoreException exception) {
- FacadeEditorPlugin.INSTANCE.log(exception);
- }
- }
- };
+ };
/**
* Handles activation of the editor or it's associated views.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void handleActivate() {
// Recompute the read only state.
//
if (editingDomain.getResourceToReadOnlyMap() != null) {
- editingDomain.getResourceToReadOnlyMap().clear();
+ editingDomain.getResourceToReadOnlyMap().clear();
- // Refresh any actions that may become enabled or disabled.
- //
- setSelection(getSelection());
+ // Refresh any actions that may become enabled or disabled.
+ //
+ setSelection(getSelection());
}
if (!removedResources.isEmpty()) {
@@ -595,6 +637,7 @@ public class ExtensiondefinitionEditor
* Handles what to do with changed resources on activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void handleChangedResources() {
@@ -610,8 +653,7 @@ public class ExtensiondefinitionEditor
resource.unload();
try {
resource.load(Collections.EMPTY_MAP);
- }
- catch (IOException exception) {
+ } catch (IOException exception) {
if (!resourceToDiagnosticMap.containsKey(resource)) {
resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
}
@@ -632,17 +674,18 @@ public class ExtensiondefinitionEditor
* Updates the problems indication with the information described in the specified diagnostic.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void updateProblemIndication() {
if (updateProblemIndication) {
BasicDiagnostic diagnostic =
- new BasicDiagnostic
+ new BasicDiagnostic
(Diagnostic.OK,
- "org.eclipse.papyrus.facade.editor",
- 0,
- null,
- new Object [] { editingDomain.getResourceSet() });
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ null,
+ new Object[] { editingDomain.getResourceSet() });
for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) {
if (childDiagnostic.getSeverity() != Diagnostic.OK) {
diagnostic.add(childDiagnostic);
@@ -651,7 +694,7 @@ public class ExtensiondefinitionEditor
int lastEditorPage = getPageCount() - 1;
if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) {
- ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic);
+ ((ProblemEditorPart) getEditor(lastEditorPage)).setDiagnostic(diagnostic);
if (diagnostic.getSeverity() != Diagnostic.OK) {
setActivePage(lastEditorPage);
}
@@ -665,8 +708,7 @@ public class ExtensiondefinitionEditor
setPageText(lastEditorPage, problemEditorPart.getPartName());
setActivePage(lastEditorPage);
showTabs();
- }
- catch (PartInitException exception) {
+ } catch (PartInitException exception) {
FacadeEditorPlugin.INSTANCE.log(exception);
}
}
@@ -676,8 +718,7 @@ public class ExtensiondefinitionEditor
if (diagnostic.getSeverity() != Diagnostic.OK) {
try {
markerHelper.createMarkers(diagnostic);
- }
- catch (CoreException exception) {
+ } catch (CoreException exception) {
FacadeEditorPlugin.INSTANCE.log(exception);
}
}
@@ -689,20 +730,21 @@ public class ExtensiondefinitionEditor
* Shows a dialog that asks if conflicting changes should be discarded.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean handleDirtyConflict() {
- return
- MessageDialog.openQuestion
+ return MessageDialog.openQuestion
(getSite().getShell(),
- getString("_UI_FileConflict_label"),
- getString("_WARN_FileConflict"));
+ getString("_UI_FileConflict_label"),
+ getString("_WARN_FileConflict"));
}
/**
* This creates a model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionEditor() {
@@ -714,6 +756,7 @@ public class ExtensiondefinitionEditor
* This sets up the editing domain for the model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void initializeEditingDomain() {
@@ -736,32 +779,34 @@ public class ExtensiondefinitionEditor
// Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus.
//
commandStack.addCommandStackListener
- (new CommandStackListener() {
- public void commandStackChanged(final EventObject event) {
- getContainer().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- firePropertyChange(IEditorPart.PROP_DIRTY);
-
- // Try to select the affected objects.
- //
- Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand();
- if (mostRecentCommand != null) {
- setSelectionToViewer(mostRecentCommand.getAffectedObjects());
- }
- for (Iterator<PropertySheetPage> i = propertySheetPages.iterator(); i.hasNext(); ) {
- PropertySheetPage propertySheetPage = i.next();
- if (propertySheetPage.getControl().isDisposed()) {
- i.remove();
- }
- else {
- propertySheetPage.refresh();
- }
- }
- }
- });
- }
- });
+ (new CommandStackListener() {
+ @Override
+ public void commandStackChanged(final EventObject event) {
+ getContainer().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ firePropertyChange(IEditorPart.PROP_DIRTY);
+
+ // Try to select the affected objects.
+ //
+ Command mostRecentCommand = ((CommandStack) event.getSource()).getMostRecentCommand();
+ if (mostRecentCommand != null) {
+ setSelectionToViewer(mostRecentCommand.getAffectedObjects());
+ }
+ for (Iterator<PropertySheetPage> i = propertySheetPages.iterator(); i.hasNext();) {
+ PropertySheetPage propertySheetPage = i.next();
+ if (propertySheetPage.getControl().isDisposed()) {
+ i.remove();
+ }
+ else {
+ propertySheetPage.refresh();
+ }
+ }
+ }
+ });
+ }
+ });
// Create the editing domain with a special command stack.
//
@@ -772,9 +817,10 @@ public class ExtensiondefinitionEditor
* This is here for the listener to be able to call it.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
- @Override
+ @Override
protected void firePropertyChange(int action) {
super.firePropertyChange(action);
}
@@ -783,6 +829,7 @@ public class ExtensiondefinitionEditor
* This sets the selection into whichever viewer is active.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setSelectionToViewer(Collection<?> collection) {
@@ -791,27 +838,29 @@ public class ExtensiondefinitionEditor
//
if (theSelection != null && !theSelection.isEmpty()) {
Runnable runnable =
- new Runnable() {
- public void run() {
- // Try to select the items in the current content viewer of the editor.
- //
- if (currentViewer != null) {
- currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true);
+ new Runnable() {
+ @Override
+ public void run() {
+ // Try to select the items in the current content viewer of the editor.
+ //
+ if (currentViewer != null) {
+ currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true);
+ }
}
- }
- };
+ };
getSite().getShell().getDisplay().asyncExec(runnable);
}
}
/**
* This returns the editing domain as required by the {@link IEditingDomainProvider} interface.
- * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain}
- * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}.
+ * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EditingDomain getEditingDomain() {
return editingDomain;
}
@@ -819,12 +868,14 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) {
@@ -834,10 +885,11 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
- public Object [] getElements(Object object) {
+ public Object[] getElements(Object object) {
Object parent = super.getParent(object);
return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray();
}
@@ -845,10 +897,11 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
- public Object [] getChildren(Object object) {
+ public Object[] getChildren(Object object) {
Object parent = super.getParent(object);
return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray();
}
@@ -856,6 +909,7 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -867,6 +921,7 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -878,6 +933,7 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setCurrentViewerPane(ViewerPane viewerPane) {
@@ -895,6 +951,7 @@ public class ExtensiondefinitionEditor
* is the current one.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setCurrentViewer(Viewer viewer) {
@@ -905,13 +962,14 @@ public class ExtensiondefinitionEditor
// Create the listener on demand.
//
selectionChangedListener =
- new ISelectionChangedListener() {
- // This just notifies those things that are affected by the section.
- //
- public void selectionChanged(SelectionChangedEvent selectionChangedEvent) {
- setSelection(selectionChangedEvent.getSelection());
- }
- };
+ new ISelectionChangedListener() {
+ // This just notifies those things that are affected by the section.
+ //
+ @Override
+ public void selectionChanged(SelectionChangedEvent selectionChangedEvent) {
+ setSelection(selectionChangedEvent.getSelection());
+ }
+ };
}
// Stop listening to the old one.
@@ -940,8 +998,10 @@ public class ExtensiondefinitionEditor
* This returns the viewer as required by the {@link IViewerProvider} interface.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Viewer getViewer() {
return currentViewer;
}
@@ -950,6 +1010,7 @@ public class ExtensiondefinitionEditor
* This creates a context menu for the viewer and adds a listener as well registering the menu for extension.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void createContextMenuFor(StructuredViewer viewer) {
@@ -957,7 +1018,7 @@ public class ExtensiondefinitionEditor
contextMenu.add(new Separator("additions"));
contextMenu.setRemoveAllWhenShown(true);
contextMenu.addMenuListener(this);
- Menu menu= contextMenu.createContextMenu(viewer.getControl());
+ Menu menu = contextMenu.createContextMenu(viewer.getControl());
viewer.getControl().setMenu(menu);
getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer));
@@ -971,6 +1032,7 @@ public class ExtensiondefinitionEditor
* This is the method called to load a resource into the editing domain's resource set based on the editor's input.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void createModel() {
@@ -981,15 +1043,14 @@ public class ExtensiondefinitionEditor
// Load the resource through the editing domain.
//
resource = editingDomain.getResourceSet().getResource(resourceURI, true);
- }
- catch (Exception e) {
+ } catch (Exception e) {
exception = e;
resource = editingDomain.getResourceSet().getResource(resourceURI, false);
}
Diagnostic diagnostic = analyzeResourceProblems(resource, exception);
if (diagnostic.getSeverity() != Diagnostic.OK) {
- resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
+ resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
}
editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter);
}
@@ -999,28 +1060,27 @@ public class ExtensiondefinitionEditor
* and the specified exception (if any).
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) {
if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) {
BasicDiagnostic basicDiagnostic =
- new BasicDiagnostic
+ new BasicDiagnostic
(Diagnostic.ERROR,
- "org.eclipse.papyrus.facade.editor",
- 0,
- getString("_UI_CreateModelError_message", resource.getURI()),
- new Object [] { exception == null ? (Object)resource : exception });
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ getString("_UI_CreateModelError_message", resource.getURI()),
+ new Object[] { exception == null ? (Object) resource : exception });
basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true));
return basicDiagnostic;
}
else if (exception != null) {
- return
- new BasicDiagnostic
- (Diagnostic.ERROR,
- "org.eclipse.papyrus.facade.editor",
- 0,
- getString("_UI_CreateModelError_message", resource.getURI()),
- new Object[] { exception });
+ return new BasicDiagnostic(Diagnostic.ERROR,
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ getString("_UI_CreateModelError_message", resource.getURI()),
+ new Object[] { exception });
}
else {
return Diagnostic.OK_INSTANCE;
@@ -1031,6 +1091,7 @@ public class ExtensiondefinitionEditor
* This is the method used by the framework to install your own controls.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1046,22 +1107,23 @@ public class ExtensiondefinitionEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- Tree tree = new Tree(composite, SWT.MULTI);
- TreeViewer newTreeViewer = new TreeViewer(tree);
- return newTreeViewer;
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ Tree tree = new Tree(composite, SWT.MULTI);
+ TreeViewer newTreeViewer = new TreeViewer(tree);
+ return newTreeViewer;
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- selectionViewer = (TreeViewer)viewerPane.getViewer();
+ selectionViewer = (TreeViewer) viewerPane.getViewer();
selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1080,22 +1142,23 @@ public class ExtensiondefinitionEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- Tree tree = new Tree(composite, SWT.MULTI);
- TreeViewer newTreeViewer = new TreeViewer(tree);
- return newTreeViewer;
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ Tree tree = new Tree(composite, SWT.MULTI);
+ TreeViewer newTreeViewer = new TreeViewer(tree);
+ return newTreeViewer;
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- parentViewer = (TreeViewer)viewerPane.getViewer();
+ parentViewer = (TreeViewer) viewerPane.getViewer();
parentViewer.setAutoExpandLevel(30);
parentViewer.setContentProvider(new ReverseAdapterFactoryContentProvider(adapterFactory));
parentViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1109,19 +1172,20 @@ public class ExtensiondefinitionEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new ListViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new ListViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- listViewer = (ListViewer)viewerPane.getViewer();
+ listViewer = (ListViewer) viewerPane.getViewer();
listViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
listViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1134,19 +1198,20 @@ public class ExtensiondefinitionEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TreeViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TreeViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- treeViewer = (TreeViewer)viewerPane.getViewer();
+ treeViewer = (TreeViewer) viewerPane.getViewer();
treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
treeViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1161,19 +1226,20 @@ public class ExtensiondefinitionEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TableViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TableViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- tableViewer = (TableViewer)viewerPane.getViewer();
+ tableViewer = (TableViewer) viewerPane.getViewer();
Table table = tableViewer.getTable();
TableLayout layout = new TableLayout();
@@ -1191,7 +1257,7 @@ public class ExtensiondefinitionEditor
selfColumn.setText(getString("_UI_SelfColumn_label"));
selfColumn.setResizable(true);
- tableViewer.setColumnProperties(new String [] {"a", "b"});
+ tableViewer.setColumnProperties(new String[] { "a", "b" });
tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1204,20 +1270,21 @@ public class ExtensiondefinitionEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TreeViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), ExtensiondefinitionEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TreeViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- treeViewerWithColumns = (TreeViewer)viewerPane.getViewer();
+ treeViewerWithColumns = (TreeViewer) viewerPane.getViewer();
Tree tree = treeViewerWithColumns.getTree();
tree.setLayoutData(new FillLayout());
@@ -1234,7 +1301,7 @@ public class ExtensiondefinitionEditor
selfColumn.setResizable(true);
selfColumn.setWidth(200);
- treeViewerWithColumns.setColumnProperties(new String [] {"a", "b"});
+ treeViewerWithColumns.setColumnProperties(new String[] { "a", "b" });
treeViewerWithColumns.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
treeViewerWithColumns.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1244,35 +1311,38 @@ public class ExtensiondefinitionEditor
}
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- setActivePage(0);
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ setActivePage(0);
+ }
+ });
}
// Ensures that this editor will only display the page's tab
// area if there are more than one page
//
getContainer().addControlListener
- (new ControlAdapter() {
- boolean guard = false;
- @Override
- public void controlResized(ControlEvent event) {
- if (!guard) {
- guard = true;
- hideTabs();
- guard = false;
+ (new ControlAdapter() {
+ boolean guard = false;
+
+ @Override
+ public void controlResized(ControlEvent event) {
+ if (!guard) {
+ guard = true;
+ hideTabs();
+ guard = false;
+ }
}
- }
- });
+ });
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
}
/**
@@ -1280,13 +1350,14 @@ public class ExtensiondefinitionEditor
* this hides the single tab at the bottom.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void hideTabs() {
if (getPageCount() <= 1) {
setPageText(0, "");
if (getContainer() instanceof CTabFolder) {
- ((CTabFolder)getContainer()).setTabHeight(1);
+ ((CTabFolder) getContainer()).setTabHeight(1);
Point point = getContainer().getSize();
getContainer().setSize(point.x, point.y + 6);
}
@@ -1298,13 +1369,14 @@ public class ExtensiondefinitionEditor
* this shows the tabs at the bottom.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void showTabs() {
if (getPageCount() > 1) {
setPageText(0, getString("_UI_SelectionPage_label"));
if (getContainer() instanceof CTabFolder) {
- ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT);
+ ((CTabFolder) getContainer()).setTabHeight(SWT.DEFAULT);
Point point = getContainer().getSize();
getContainer().setSize(point.x, point.y - 6);
}
@@ -1315,6 +1387,7 @@ public class ExtensiondefinitionEditor
* This is used to track the active viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1330,6 +1403,7 @@ public class ExtensiondefinitionEditor
* This is how the framework determines which interfaces we implement.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("rawtypes")
@@ -1353,6 +1427,7 @@ public class ExtensiondefinitionEditor
* This accesses a cached version of the content outliner.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IContentOutlinePage getContentOutlinePage() {
@@ -1377,9 +1452,9 @@ public class ExtensiondefinitionEditor
createContextMenuFor(contentOutlineViewer);
if (!editingDomain.getResourceSet().getResources().isEmpty()) {
- // Select the root object in the view.
- //
- contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true);
+ // Select the root object in the view.
+ //
+ contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true);
}
}
@@ -1401,13 +1476,14 @@ public class ExtensiondefinitionEditor
// Listen to selection so that we can handle it is a special way.
//
contentOutlinePage.addSelectionChangedListener
- (new ISelectionChangedListener() {
- // This ensures that we handle selections correctly.
- //
- public void selectionChanged(SelectionChangedEvent event) {
- handleContentOutlineSelection(event.getSelection());
- }
- });
+ (new ISelectionChangedListener() {
+ // This ensures that we handle selections correctly.
+ //
+ @Override
+ public void selectionChanged(SelectionChangedEvent event) {
+ handleContentOutlineSelection(event.getSelection());
+ }
+ });
}
return contentOutlinePage;
@@ -1417,23 +1493,24 @@ public class ExtensiondefinitionEditor
* This accesses a cached version of the property sheet.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IPropertySheetPage getPropertySheetPage() {
PropertySheetPage propertySheetPage =
- new ExtendedPropertySheetPage(editingDomain) {
- @Override
- public void setSelectionToViewer(List<?> selection) {
- ExtensiondefinitionEditor.this.setSelectionToViewer(selection);
- ExtensiondefinitionEditor.this.setFocus();
- }
+ new ExtendedPropertySheetPage(editingDomain) {
+ @Override
+ public void setSelectionToViewer(List<?> selection) {
+ ExtensiondefinitionEditor.this.setSelectionToViewer(selection);
+ ExtensiondefinitionEditor.this.setFocus();
+ }
- @Override
- public void setActionBars(IActionBars actionBars) {
- super.setActionBars(actionBars);
- getActionBarContributor().shareGlobalActions(this, actionBars);
- }
- };
+ @Override
+ public void setActionBars(IActionBars actionBars) {
+ super.setActionBars(actionBars);
+ getActionBarContributor().shareGlobalActions(this, actionBars);
+ }
+ };
propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory));
propertySheetPages.add(propertySheetPage);
@@ -1444,11 +1521,12 @@ public class ExtensiondefinitionEditor
* This deals with how we want selection in the outliner to affect the other views.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void handleContentOutlineSelection(ISelection selection) {
if (currentViewerPane != null && !selection.isEmpty() && selection instanceof IStructuredSelection) {
- Iterator<?> selectedElements = ((IStructuredSelection)selection).iterator();
+ Iterator<?> selectedElements = ((IStructuredSelection) selection).iterator();
if (selectedElements.hasNext()) {
// Get the first selected element.
//
@@ -1483,17 +1561,19 @@ public class ExtensiondefinitionEditor
* This is for implementing {@link IEditorPart} and simply tests the command stack.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean isDirty() {
- return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded();
+ return ((BasicCommandStack) editingDomain.getCommandStack()).isSaveNeeded();
}
/**
* This is for implementing {@link IEditorPart} and simply saves the model file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1507,31 +1587,31 @@ public class ExtensiondefinitionEditor
// Do the work within an operation because this is a long running activity that modifies the workbench.
//
WorkspaceModifyOperation operation =
- new WorkspaceModifyOperation() {
- // This is the method that gets invoked when the operation runs.
- //
- @Override
- public void execute(IProgressMonitor monitor) {
- // Save the resources to the file system.
+ new WorkspaceModifyOperation() {
+ // This is the method that gets invoked when the operation runs.
//
- boolean first = true;
- for (Resource resource : editingDomain.getResourceSet().getResources()) {
- if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) {
- try {
- long timeStamp = resource.getTimeStamp();
- resource.save(saveOptions);
- if (resource.getTimeStamp() != timeStamp) {
- savedResources.add(resource);
+ @Override
+ public void execute(IProgressMonitor monitor) {
+ // Save the resources to the file system.
+ //
+ boolean first = true;
+ for (Resource resource : editingDomain.getResourceSet().getResources()) {
+ if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) {
+ try {
+ long timeStamp = resource.getTimeStamp();
+ resource.save(saveOptions);
+ if (resource.getTimeStamp() != timeStamp) {
+ savedResources.add(resource);
+ }
}
+ catch (Exception exception) {
+ resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
+ }
+ first = false;
}
- catch (Exception exception) {
- resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
- }
- first = false;
}
}
- }
- };
+ };
updateProblemIndication = false;
try {
@@ -1541,10 +1621,9 @@ public class ExtensiondefinitionEditor
// Refresh the necessary state.
//
- ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone();
+ ((BasicCommandStack) editingDomain.getCommandStack()).saveIsDone();
firePropertyChange(IEditorPart.PROP_DIRTY);
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
// Something went wrong that shouldn't.
//
FacadeEditorPlugin.INSTANCE.log(exception);
@@ -1558,6 +1637,7 @@ public class ExtensiondefinitionEditor
* The implementation uses the URI converter from the editor's resource set to try to open an input stream.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean isPersisted(Resource resource) {
@@ -1568,8 +1648,7 @@ public class ExtensiondefinitionEditor
result = true;
stream.close();
}
- }
- catch (IOException e) {
+ } catch (IOException e) {
// Ignore
}
return result;
@@ -1579,6 +1658,7 @@ public class ExtensiondefinitionEditor
* This always returns true because it is not currently supported.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1590,6 +1670,7 @@ public class ExtensiondefinitionEditor
* This also changes the editor's input.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1608,6 +1689,7 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void doSaveAs(URI uri, IEditorInput editorInput) {
@@ -1615,17 +1697,19 @@ public class ExtensiondefinitionEditor
setInputWithNotify(editorInput);
setPartName(editorInput.getName());
IProgressMonitor progressMonitor =
- getActionBars().getStatusLineManager() != null ?
- getActionBars().getStatusLineManager().getProgressMonitor() :
- new NullProgressMonitor();
+ getActionBars().getStatusLineManager() != null ?
+ getActionBars().getStatusLineManager().getProgressMonitor() :
+ new NullProgressMonitor();
doSave(progressMonitor);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void gotoMarker(IMarker marker) {
List<?> targetObjects = markerHelper.getTargetObjects(editingDomain, marker);
if (!targetObjects.isEmpty()) {
@@ -1637,6 +1721,7 @@ public class ExtensiondefinitionEditor
* This is called during startup.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1652,6 +1737,7 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1668,8 +1754,10 @@ public class ExtensiondefinitionEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void addSelectionChangedListener(ISelectionChangedListener listener) {
selectionChangedListeners.add(listener);
}
@@ -1678,8 +1766,10 @@ public class ExtensiondefinitionEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void removeSelectionChangedListener(ISelectionChangedListener listener) {
selectionChangedListeners.remove(listener);
}
@@ -1688,8 +1778,10 @@ public class ExtensiondefinitionEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ISelection getSelection() {
return editorSelection;
}
@@ -1699,8 +1791,10 @@ public class ExtensiondefinitionEditor
* Calling this result will notify the listeners.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setSelection(ISelection selection) {
editorSelection = selection;
@@ -1713,29 +1807,30 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setStatusLineManager(ISelection selection) {
IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ?
- contentOutlineStatusLineManager : getActionBars().getStatusLineManager();
+ contentOutlineStatusLineManager : getActionBars().getStatusLineManager();
if (statusLineManager != null) {
if (selection instanceof IStructuredSelection) {
- Collection<?> collection = ((IStructuredSelection)selection).toList();
+ Collection<?> collection = ((IStructuredSelection) selection).toList();
switch (collection.size()) {
- case 0: {
- statusLineManager.setMessage(getString("_UI_NoObjectSelected"));
- break;
- }
- case 1: {
- String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next());
- statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text));
- break;
- }
- default: {
- statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size())));
- break;
- }
+ case 0: {
+ statusLineManager.setMessage(getString("_UI_NoObjectSelected"));
+ break;
+ }
+ case 1: {
+ String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next());
+ statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text));
+ break;
+ }
+ default: {
+ statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size())));
+ break;
+ }
}
}
else {
@@ -1748,6 +1843,7 @@ public class ExtensiondefinitionEditor
* This looks up a string in the plugin's plugin.properties file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static String getString(String key) {
@@ -1758,34 +1854,39 @@ public class ExtensiondefinitionEditor
* This looks up a string in plugin.properties, making a substitution.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static String getString(String key, Object s1) {
- return FacadeEditorPlugin.INSTANCE.getString(key, new Object [] { s1 });
+ return FacadeEditorPlugin.INSTANCE.getString(key, new Object[] { s1 });
}
/**
* This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void menuAboutToShow(IMenuManager menuManager) {
- ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager);
+ ((IMenuListener) getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public EditingDomainActionBarContributor getActionBarContributor() {
- return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor();
+ return (EditingDomainActionBarContributor) getEditorSite().getActionBarContributor();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IActionBars getActionBars() {
@@ -1795,6 +1896,7 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public AdapterFactory getAdapterFactory() {
@@ -1804,6 +1906,7 @@ public class ExtensiondefinitionEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1835,6 +1938,7 @@ public class ExtensiondefinitionEditor
* Returns whether the outline view should be presented to the user.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean showOutlineView() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionModelWizard.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionModelWizard.java
index 3f840dcb92c..b747a0ac0bf 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionModelWizard.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/extensiondefinition/presentation/ExtensiondefinitionModelWizard.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -84,7 +84,6 @@ import org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionFactory
import org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage;
import org.eclipse.papyrus.facade.provider.FacadeEditPlugin;
-
import org.eclipse.core.runtime.Path;
import org.eclipse.jface.viewers.ISelection;
@@ -102,6 +101,7 @@ import org.eclipse.ui.PartInitException;
* This is a simple wizard for creating a new model file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard {
@@ -109,24 +109,27 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* The supported extensions for created files.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final List<String> FILE_EXTENSIONS =
- Collections.unmodifiableList(Arrays.asList(FacadeEditorPlugin.INSTANCE.getString("_UI_ExtensiondefinitionEditorFilenameExtensions").split("\\s*,\\s*")));
+ Collections.unmodifiableList(Arrays.asList(FacadeEditorPlugin.INSTANCE.getString("_UI_ExtensiondefinitionEditorFilenameExtensions").split("\\s*,\\s*")));
/**
* A formatted list of supported file extensions, suitable for display.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final String FORMATTED_FILE_EXTENSIONS =
- FacadeEditorPlugin.INSTANCE.getString("_UI_ExtensiondefinitionEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", ");
+ FacadeEditorPlugin.INSTANCE.getString("_UI_ExtensiondefinitionEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", ");
/**
* This caches an instance of the model package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ExtensiondefinitionPackage extensiondefinitionPackage = ExtensiondefinitionPackage.eINSTANCE;
@@ -135,6 +138,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* This caches an instance of the model factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ExtensiondefinitionFactory extensiondefinitionFactory = extensiondefinitionPackage.getExtensiondefinitionFactory();
@@ -143,6 +147,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* This is the file creation page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ExtensiondefinitionModelWizardNewFileCreationPage newFileCreationPage;
@@ -151,6 +156,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* This is the initial object creation page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ExtensiondefinitionModelWizardInitialObjectCreationPage initialObjectCreationPage;
@@ -159,6 +165,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Remember the selection during initialization for populating the default container.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IStructuredSelection selection;
@@ -167,6 +174,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Remember the workbench during initialization.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IWorkbench workbench;
@@ -175,6 +183,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Caches the names of the types that can be created as the root object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected List<String> initialObjectNames;
@@ -183,8 +192,10 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* This just records the information.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void init(IWorkbench workbench, IStructuredSelection selection) {
this.workbench = workbench;
this.selection = selection;
@@ -196,6 +207,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Returns the names of the types that can be created as the root object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<String> getInitialObjectNames() {
@@ -203,7 +215,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
initialObjectNames = new ArrayList<String>();
for (EClassifier eClassifier : extensiondefinitionPackage.getEClassifiers()) {
if (eClassifier instanceof EClass) {
- EClass eClass = (EClass)eClassifier;
+ EClass eClass = (EClass) eClassifier;
if (!eClass.isAbstract()) {
initialObjectNames.add(eClass.getName());
}
@@ -218,10 +230,11 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Create a new model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected EObject createInitialModel() {
- EClass eClass = (EClass)extensiondefinitionPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName());
+ EClass eClass = (EClass) extensiondefinitionPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName());
EObject rootObject = extensiondefinitionFactory.create(eClass);
return rootObject;
}
@@ -230,6 +243,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Do the work after everything is specified.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -242,43 +256,43 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
// Do the work within an operation.
//
WorkspaceModifyOperation operation =
- new WorkspaceModifyOperation() {
- @Override
- protected void execute(IProgressMonitor progressMonitor) {
- try {
- // Create a resource set
- //
- ResourceSet resourceSet = new ResourceSetImpl();
-
- // Get the URI of the model file.
- //
- URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true);
-
- // Create a resource for this file.
- //
- Resource resource = resourceSet.createResource(fileURI);
-
- // Add the initial model object to the contents.
- //
- EObject rootObject = createInitialModel();
- if (rootObject != null) {
- resource.getContents().add(rootObject);
+ new WorkspaceModifyOperation() {
+ @Override
+ protected void execute(IProgressMonitor progressMonitor) {
+ try {
+ // Create a resource set
+ //
+ ResourceSet resourceSet = new ResourceSetImpl();
+
+ // Get the URI of the model file.
+ //
+ URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true);
+
+ // Create a resource for this file.
+ //
+ Resource resource = resourceSet.createResource(fileURI);
+
+ // Add the initial model object to the contents.
+ //
+ EObject rootObject = createInitialModel();
+ if (rootObject != null) {
+ resource.getContents().add(rootObject);
+ }
+
+ // Save the contents of the resource to the file system.
+ //
+ Map<Object, Object> options = new HashMap<Object, Object>();
+ options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding());
+ resource.save(options);
+ }
+ catch (Exception exception) {
+ FacadeEditorPlugin.INSTANCE.log(exception);
+ }
+ finally {
+ progressMonitor.done();
}
-
- // Save the contents of the resource to the file system.
- //
- Map<Object, Object> options = new HashMap<Object, Object>();
- options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding());
- resource.save(options);
- }
- catch (Exception exception) {
- FacadeEditorPlugin.INSTANCE.log(exception);
- }
- finally {
- progressMonitor.done();
}
- }
- };
+ };
getContainer().run(false, false, operation);
@@ -290,28 +304,27 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
if (activePart instanceof ISetSelectionTarget) {
final ISelection targetSelection = new StructuredSelection(modelFile);
getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- ((ISetSelectionTarget)activePart).selectReveal(targetSelection);
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ ((ISetSelectionTarget) activePart).selectReveal(targetSelection);
+ }
+ });
}
// Open an editor on the new file.
//
try {
page.openEditor
- (new FileEditorInput(modelFile),
- workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId());
- }
- catch (PartInitException exception) {
+ (new FileEditorInput(modelFile),
+ workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId());
+ } catch (PartInitException exception) {
MessageDialog.openError(workbenchWindow.getShell(), FacadeEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage());
return false;
}
return true;
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
FacadeEditorPlugin.INSTANCE.log(exception);
return false;
}
@@ -321,6 +334,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* This is the one page of the wizard.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensiondefinitionModelWizardNewFileCreationPage extends WizardNewFileCreationPage {
@@ -328,6 +342,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Pass in the selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) {
@@ -338,6 +353,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* The framework calls this to see if the file is correct.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -346,7 +362,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
String extension = new Path(getFileName()).getFileExtension();
if (extension == null || !FILE_EXTENSIONS.contains(extension)) {
String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension";
- setErrorMessage(FacadeEditorPlugin.INSTANCE.getString(key, new Object [] { FORMATTED_FILE_EXTENSIONS }));
+ setErrorMessage(FacadeEditorPlugin.INSTANCE.getString(key, new Object[] { FORMATTED_FILE_EXTENSIONS }));
return false;
}
return true;
@@ -357,6 +373,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IFile getModelFile() {
@@ -368,26 +385,29 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* This is the page where the type of object to create is selected.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensiondefinitionModelWizardInitialObjectCreationPage extends WizardPage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Combo initialObjectField;
/**
* @generated
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
*/
protected List<String> encodings;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Combo encodingField;
@@ -396,6 +416,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Pass in the selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionModelWizardInitialObjectCreationPage(String pageId) {
@@ -405,10 +426,13 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void createControl(Composite parent) {
- Composite composite = new Composite(parent, SWT.NONE); {
+ Composite composite = new Composite(parent, SWT.NONE);
+ {
GridLayout layout = new GridLayout();
layout.numColumns = 1;
layout.verticalSpacing = 12;
@@ -477,18 +501,21 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ModifyListener validator =
- new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- setPageComplete(validatePage());
- }
- };
+ new ModifyListener() {
+ @Override
+ public void modifyText(ModifyEvent e) {
+ setPageComplete(validatePage());
+ }
+ };
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean validatePage() {
@@ -498,6 +525,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -518,6 +546,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String getInitialObjectName() {
@@ -534,6 +563,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String getEncoding() {
@@ -544,13 +574,13 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Returns the label for the specified type name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected String getLabel(String typeName) {
try {
return FacadeEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type");
- }
- catch(MissingResourceException mre) {
+ } catch (MissingResourceException mre) {
FacadeEditorPlugin.INSTANCE.log(mre);
}
return typeName;
@@ -559,12 +589,13 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<String> getEncodings() {
if (encodings == null) {
encodings = new ArrayList<String>();
- for (StringTokenizer stringTokenizer = new StringTokenizer(FacadeEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens(); ) {
+ for (StringTokenizer stringTokenizer = new StringTokenizer(FacadeEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens();) {
encodings.add(stringTokenizer.nextToken());
}
}
@@ -576,9 +607,10 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* The framework calls this to create the contents of the wizard.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
- @Override
+ @Override
public void addPages() {
// Create a page, set the title, and the initial model file name.
//
@@ -597,7 +629,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
if (selectedElement instanceof IResource) {
// Get the resource parent, if its a file.
//
- IResource selectedResource = (IResource)selectedElement;
+ IResource selectedResource = (IResource) selectedElement;
if (selectedResource.getType() == IResource.FILE) {
selectedResource = selectedResource.getParent();
}
@@ -614,7 +646,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
String defaultModelBaseFilename = FacadeEditorPlugin.INSTANCE.getString("_UI_ExtensiondefinitionEditorFilenameDefaultBase");
String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0);
String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension;
- for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) {
+ for (int i = 1; ((IContainer) selectedResource).findMember(modelFilename) != null; ++i) {
modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension;
}
newFileCreationPage.setFileName(modelFilename);
@@ -631,6 +663,7 @@ public class ExtensiondefinitionModelWizard extends Wizard implements INewWizard
* Get the file from the page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IFile getModelFile() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeActionBarContributor.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeActionBarContributor.java
index 76ba15f3782..d5d543bb98d 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeActionBarContributor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeActionBarContributor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -54,15 +54,17 @@ import org.eclipse.ui.PartInitException;
* This is the action bar contributor for the Facade model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeActionBarContributor
- extends EditingDomainActionBarContributor
- implements ISelectionChangedListener {
+ extends EditingDomainActionBarContributor
+ implements ISelectionChangedListener {
/**
* This keeps track of the active editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IEditorPart activeEditorPart;
@@ -71,6 +73,7 @@ public class FacadeActionBarContributor
* This keeps track of the current selection provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelectionProvider selectionProvider;
@@ -79,51 +82,54 @@ public class FacadeActionBarContributor
* This action opens the Properties view.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IAction showPropertiesViewAction =
- new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) {
- @Override
- public void run() {
- try {
- getPage().showView("org.eclipse.ui.views.PropertySheet");
- }
- catch (PartInitException exception) {
- FacadeEditorPlugin.INSTANCE.log(exception);
+ new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) {
+ @Override
+ public void run() {
+ try {
+ getPage().showView("org.eclipse.ui.views.PropertySheet");
+ }
+ catch (PartInitException exception) {
+ FacadeEditorPlugin.INSTANCE.log(exception);
+ }
}
- }
- };
+ };
/**
* This action refreshes the viewer of the current editor if the editor
* implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IAction refreshViewerAction =
- new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) {
- @Override
- public boolean isEnabled() {
- return activeEditorPart instanceof IViewerProvider;
- }
+ new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) {
+ @Override
+ public boolean isEnabled() {
+ return activeEditorPart instanceof IViewerProvider;
+ }
- @Override
- public void run() {
- if (activeEditorPart instanceof IViewerProvider) {
- Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer();
- if (viewer != null) {
- viewer.refresh();
+ @Override
+ public void run() {
+ if (activeEditorPart instanceof IViewerProvider) {
+ Viewer viewer = ((IViewerProvider) activeEditorPart).getViewer();
+ if (viewer != null) {
+ viewer.refresh();
+ }
}
}
- }
- };
+ };
/**
* This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor
* generated for the current selection by the item provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> createChildActions;
@@ -132,6 +138,7 @@ public class FacadeActionBarContributor
* This is the menu manager into which menu contribution items should be added for CreateChild actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IMenuManager createChildMenuManager;
@@ -141,6 +148,7 @@ public class FacadeActionBarContributor
* generated for the current selection by the item provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> createSiblingActions;
@@ -149,6 +157,7 @@ public class FacadeActionBarContributor
* This is the menu manager into which menu contribution items should be added for CreateSibling actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IMenuManager createSiblingMenuManager;
@@ -157,6 +166,7 @@ public class FacadeActionBarContributor
* This creates an instance of the contributor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeActionBarContributor() {
@@ -170,6 +180,7 @@ public class FacadeActionBarContributor
* This adds Separators for editor additions to the tool bar.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -183,6 +194,7 @@ public class FacadeActionBarContributor
* as well as the sub-menus for object creation items.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -209,11 +221,12 @@ public class FacadeActionBarContributor
// Force an update because Eclipse hides empty menus now.
//
submenuManager.addMenuListener
- (new IMenuListener() {
- public void menuAboutToShow(IMenuManager menuManager) {
- menuManager.updateAll(true);
- }
- });
+ (new IMenuListener() {
+ @Override
+ public void menuAboutToShow(IMenuManager menuManager) {
+ menuManager.updateAll(true);
+ }
+ });
addGlobalActions(submenuManager);
}
@@ -222,6 +235,7 @@ public class FacadeActionBarContributor
* When the active editor changes, this remembers the change and registers with it as a selection provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -255,8 +269,10 @@ public class FacadeActionBarContributor
* that can be added to the selected object and updating the menus accordingly.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
// Remove any menu items for old selection.
//
@@ -273,10 +289,10 @@ public class FacadeActionBarContributor
Collection<?> newSiblingDescriptors = null;
ISelection selection = event.getSelection();
- if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) {
- Object object = ((IStructuredSelection)selection).getFirstElement();
+ if (selection instanceof IStructuredSelection && ((IStructuredSelection) selection).size() == 1) {
+ Object object = ((IStructuredSelection) selection).getFirstElement();
- EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain();
+ EditingDomain domain = ((IEditingDomainProvider) activeEditorPart).getEditingDomain();
newChildDescriptors = domain.getNewChildDescriptors(object, null);
newSiblingDescriptors = domain.getNewChildDescriptors(null, object);
@@ -302,6 +318,7 @@ public class FacadeActionBarContributor
* and returns the collection of these actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> generateCreateChildActions(Collection<?> descriptors, ISelection selection) {
@@ -319,6 +336,7 @@ public class FacadeActionBarContributor
* and returns the collection of these actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> generateCreateSiblingActions(Collection<?> descriptors, ISelection selection) {
@@ -338,6 +356,7 @@ public class FacadeActionBarContributor
* If <code>contributionID</code> is <code>null</code>, they are simply added.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void populateManager(IContributionManager manager, Collection<? extends IAction> actions, String contributionID) {
@@ -352,12 +371,13 @@ public class FacadeActionBarContributor
}
}
}
-
+
/**
* This removes from the specified <code>manager</code> all {@link org.eclipse.jface.action.ActionContributionItem}s
* based on the {@link org.eclipse.jface.action.IAction}s contained in the <code>actions</code> collection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void depopulateManager(IContributionManager manager, Collection<? extends IAction> actions) {
@@ -368,13 +388,13 @@ public class FacadeActionBarContributor
//
IContributionItem contributionItem = items[i];
while (contributionItem instanceof SubContributionItem) {
- contributionItem = ((SubContributionItem)contributionItem).getInnerItem();
+ contributionItem = ((SubContributionItem) contributionItem).getInnerItem();
}
// Delete the ActionContributionItems with matching action.
//
if (contributionItem instanceof ActionContributionItem) {
- IAction action = ((ActionContributionItem)contributionItem).getAction();
+ IAction action = ((ActionContributionItem) contributionItem).getAction();
if (actions.contains(action)) {
manager.remove(contributionItem);
}
@@ -387,6 +407,7 @@ public class FacadeActionBarContributor
* This populates the pop-up menu before it appears.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -407,6 +428,7 @@ public class FacadeActionBarContributor
* This inserts global actions before the "additions-end" separator.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -414,7 +436,7 @@ public class FacadeActionBarContributor
menuManager.insertAfter("additions-end", new Separator("ui-actions"));
menuManager.insertAfter("ui-actions", showPropertiesViewAction);
- refreshViewerAction.setEnabled(refreshViewerAction.isEnabled());
+ refreshViewerAction.setEnabled(refreshViewerAction.isEnabled());
menuManager.insertAfter("ui-actions", refreshViewerAction);
super.addGlobalActions(menuManager);
@@ -424,6 +446,7 @@ public class FacadeActionBarContributor
* This ensures that a delete action will clean up all references to deleted objects.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditor.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditor.java
index 816fcc903f0..fa04e6e4b9c 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -131,7 +131,6 @@ import org.eclipse.emf.common.util.BasicDiagnostic;
import org.eclipse.emf.common.util.Diagnostic;
import org.eclipse.emf.common.util.URI;
-
import org.eclipse.emf.ecore.resource.Resource;
import org.eclipse.emf.ecore.resource.ResourceSet;
@@ -182,15 +181,17 @@ import org.eclipse.uml2.uml.edit.providers.UMLItemProviderAdapterFactory;
* This is an example of a Facade model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeEditor
- extends MultiPageEditorPart
- implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker {
+ extends MultiPageEditorPart
+ implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker {
/**
* This keeps track of the editing domain that is used to track all changes to the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected AdapterFactoryEditingDomain editingDomain;
@@ -199,6 +200,7 @@ public class FacadeEditor
* This is the one adapter factory used for providing views of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ComposedAdapterFactory adapterFactory;
@@ -207,6 +209,7 @@ public class FacadeEditor
* This is the content outline page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IContentOutlinePage contentOutlinePage;
@@ -215,6 +218,7 @@ public class FacadeEditor
* This is a kludge...
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IStatusLineManager contentOutlineStatusLineManager;
@@ -223,6 +227,7 @@ public class FacadeEditor
* This is the content outline page's viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer contentOutlineViewer;
@@ -231,6 +236,7 @@ public class FacadeEditor
* This is the property sheet page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected List<PropertySheetPage> propertySheetPages = new ArrayList<PropertySheetPage>();
@@ -240,6 +246,7 @@ public class FacadeEditor
* The parent relation must be correctly defined for this to work.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer selectionViewer;
@@ -248,6 +255,7 @@ public class FacadeEditor
* This inverts the roll of parent and child in the content provider and show parents as a tree.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer parentViewer;
@@ -256,6 +264,7 @@ public class FacadeEditor
* This shows how a tree view works.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer treeViewer;
@@ -265,6 +274,7 @@ public class FacadeEditor
* A list viewer doesn't support icons.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ListViewer listViewer;
@@ -274,6 +284,7 @@ public class FacadeEditor
* A table can be used as a list with icons.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TableViewer tableViewer;
@@ -282,6 +293,7 @@ public class FacadeEditor
* This shows how a tree view with columns works.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer treeViewerWithColumns;
@@ -290,6 +302,7 @@ public class FacadeEditor
* This keeps track of the active viewer pane, in the book.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ViewerPane currentViewerPane;
@@ -298,6 +311,7 @@ public class FacadeEditor
* This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Viewer currentViewer;
@@ -306,6 +320,7 @@ public class FacadeEditor
* This listens to which ever viewer is active.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelectionChangedListener selectionChangedListener;
@@ -314,6 +329,7 @@ public class FacadeEditor
* This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<ISelectionChangedListener> selectionChangedListeners = new ArrayList<ISelectionChangedListener>();
@@ -322,6 +338,7 @@ public class FacadeEditor
* This keeps track of the selection of the editor as a whole.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelection editorSelection = StructuredSelection.EMPTY;
@@ -331,6 +348,7 @@ public class FacadeEditor
* in Eclipse's Problems View.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected MarkerHelper markerHelper = new EditUIMarkerHelper();
@@ -339,46 +357,57 @@ public class FacadeEditor
* This listens for when the outline becomes active
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IPartListener partListener =
- new IPartListener() {
- public void partActivated(IWorkbenchPart p) {
- if (p instanceof ContentOutline) {
- if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) {
- getActionBarContributor().setActiveEditor(FacadeEditor.this);
+ new IPartListener() {
+ @Override
+ public void partActivated(IWorkbenchPart p) {
+ if (p instanceof ContentOutline) {
+ if (((ContentOutline) p).getCurrentPage() == contentOutlinePage) {
+ getActionBarContributor().setActiveEditor(FacadeEditor.this);
- setCurrentViewer(contentOutlineViewer);
+ setCurrentViewer(contentOutlineViewer);
+ }
}
- }
- else if (p instanceof PropertySheet) {
- if (propertySheetPages.contains(((PropertySheet)p).getCurrentPage())) {
- getActionBarContributor().setActiveEditor(FacadeEditor.this);
+ else if (p instanceof PropertySheet) {
+ if (propertySheetPages.contains(((PropertySheet) p).getCurrentPage())) {
+ getActionBarContributor().setActiveEditor(FacadeEditor.this);
+ handleActivate();
+ }
+ }
+ else if (p == FacadeEditor.this) {
handleActivate();
}
}
- else if (p == FacadeEditor.this) {
- handleActivate();
+
+ @Override
+ public void partBroughtToTop(IWorkbenchPart p) {
+ // Ignore.
+ }
+
+ @Override
+ public void partClosed(IWorkbenchPart p) {
+ // Ignore.
+ }
+
+ @Override
+ public void partDeactivated(IWorkbenchPart p) {
+ // Ignore.
}
- }
- public void partBroughtToTop(IWorkbenchPart p) {
- // Ignore.
- }
- public void partClosed(IWorkbenchPart p) {
- // Ignore.
- }
- public void partDeactivated(IWorkbenchPart p) {
- // Ignore.
- }
- public void partOpened(IWorkbenchPart p) {
- // Ignore.
- }
- };
+
+ @Override
+ public void partOpened(IWorkbenchPart p) {
+ // Ignore.
+ }
+ };
/**
* Resources that have been removed since last activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> removedResources = new ArrayList<Resource>();
@@ -387,6 +416,7 @@ public class FacadeEditor
* Resources that have been changed since last activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> changedResources = new ArrayList<Resource>();
@@ -395,6 +425,7 @@ public class FacadeEditor
* Resources that have been saved.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> savedResources = new ArrayList<Resource>();
@@ -403,6 +434,7 @@ public class FacadeEditor
* Map to store the diagnostic associated with a resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Map<Resource, Diagnostic> resourceToDiagnosticMap = new LinkedHashMap<Resource, Diagnostic>();
@@ -411,6 +443,7 @@ public class FacadeEditor
* Controls whether the problem indication should be updated.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean updateProblemIndication = true;
@@ -419,18 +452,19 @@ public class FacadeEditor
* Adapter used to update the problem indication when resources are demanded loaded.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected EContentAdapter problemIndicationAdapter =
- new EContentAdapter() {
- @Override
- public void notifyChanged(Notification notification) {
- if (notification.getNotifier() instanceof Resource) {
- switch (notification.getFeatureID(Resource.class)) {
+ new EContentAdapter() {
+ @Override
+ public void notifyChanged(Notification notification) {
+ if (notification.getNotifier() instanceof Resource) {
+ switch (notification.getFeatureID(Resource.class)) {
case Resource.RESOURCE__IS_LOADED:
case Resource.RESOURCE__ERRORS:
case Resource.RESOURCE__WARNINGS: {
- Resource resource = (Resource)notification.getNotifier();
+ Resource resource = (Resource) notification.getNotifier();
Diagnostic diagnostic = analyzeResourceProblems(resource, null);
if (diagnostic.getSeverity() != Diagnostic.OK) {
resourceToDiagnosticMap.put(resource, diagnostic);
@@ -441,134 +475,142 @@ public class FacadeEditor
if (updateProblemIndication) {
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
}
break;
}
+ }
+ }
+ else {
+ super.notifyChanged(notification);
}
}
- else {
- super.notifyChanged(notification);
- }
- }
- @Override
- protected void setTarget(Resource target) {
- basicSetTarget(target);
- }
+ @Override
+ protected void setTarget(Resource target) {
+ basicSetTarget(target);
+ }
- @Override
- protected void unsetTarget(Resource target) {
- basicUnsetTarget(target);
- resourceToDiagnosticMap.remove(target);
- if (updateProblemIndication) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ @Override
+ protected void unsetTarget(Resource target) {
+ basicUnsetTarget(target);
+ resourceToDiagnosticMap.remove(target);
+ if (updateProblemIndication) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
+ }
}
- }
- };
+ };
/**
* This listens for workspace changes.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IResourceChangeListener resourceChangeListener =
- new IResourceChangeListener() {
- public void resourceChanged(IResourceChangeEvent event) {
- IResourceDelta delta = event.getDelta();
- try {
- class ResourceDeltaVisitor implements IResourceDeltaVisitor {
- protected ResourceSet resourceSet = editingDomain.getResourceSet();
- protected Collection<Resource> changedResources = new ArrayList<Resource>();
- protected Collection<Resource> removedResources = new ArrayList<Resource>();
-
- public boolean visit(IResourceDelta delta) {
- if (delta.getResource().getType() == IResource.FILE) {
- if (delta.getKind() == IResourceDelta.REMOVED ||
- delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) {
- Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false);
- if (resource != null) {
- if (delta.getKind() == IResourceDelta.REMOVED) {
- removedResources.add(resource);
- }
- else if (!savedResources.remove(resource)) {
- changedResources.add(resource);
+ new IResourceChangeListener() {
+ @Override
+ public void resourceChanged(IResourceChangeEvent event) {
+ IResourceDelta delta = event.getDelta();
+ try {
+ class ResourceDeltaVisitor implements IResourceDeltaVisitor {
+ protected ResourceSet resourceSet = editingDomain.getResourceSet();
+ protected Collection<Resource> changedResources = new ArrayList<Resource>();
+ protected Collection<Resource> removedResources = new ArrayList<Resource>();
+
+ @Override
+ public boolean visit(IResourceDelta delta) {
+ if (delta.getResource().getType() == IResource.FILE) {
+ if (delta.getKind() == IResourceDelta.REMOVED ||
+ delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) {
+ Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false);
+ if (resource != null) {
+ if (delta.getKind() == IResourceDelta.REMOVED) {
+ removedResources.add(resource);
+ }
+ else if (!savedResources.remove(resource)) {
+ changedResources.add(resource);
+ }
}
}
+ return false;
}
- return false;
+
+ return true;
}
- return true;
- }
+ public Collection<Resource> getChangedResources() {
+ return changedResources;
+ }
- public Collection<Resource> getChangedResources() {
- return changedResources;
+ public Collection<Resource> getRemovedResources() {
+ return removedResources;
+ }
}
- public Collection<Resource> getRemovedResources() {
- return removedResources;
- }
- }
+ final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor();
+ delta.accept(visitor);
- final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor();
- delta.accept(visitor);
+ if (!visitor.getRemovedResources().isEmpty()) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ removedResources.addAll(visitor.getRemovedResources());
+ if (!isDirty()) {
+ getSite().getPage().closeEditor(FacadeEditor.this, false);
+ }
+ }
+ });
+ }
- if (!visitor.getRemovedResources().isEmpty()) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- removedResources.addAll(visitor.getRemovedResources());
- if (!isDirty()) {
- getSite().getPage().closeEditor(FacadeEditor.this, false);
- }
- }
- });
+ if (!visitor.getChangedResources().isEmpty()) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ changedResources.addAll(visitor.getChangedResources());
+ if (getSite().getPage().getActiveEditor() == FacadeEditor.this) {
+ handleActivate();
+ }
+ }
+ });
+ }
}
-
- if (!visitor.getChangedResources().isEmpty()) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- changedResources.addAll(visitor.getChangedResources());
- if (getSite().getPage().getActiveEditor() == FacadeEditor.this) {
- handleActivate();
- }
- }
- });
+ catch (CoreException exception) {
+ FacadeEditorPlugin.INSTANCE.log(exception);
}
}
- catch (CoreException exception) {
- FacadeEditorPlugin.INSTANCE.log(exception);
- }
- }
- };
+ };
/**
* Handles activation of the editor or it's associated views.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void handleActivate() {
// Recompute the read only state.
//
if (editingDomain.getResourceToReadOnlyMap() != null) {
- editingDomain.getResourceToReadOnlyMap().clear();
+ editingDomain.getResourceToReadOnlyMap().clear();
- // Refresh any actions that may become enabled or disabled.
- //
- setSelection(getSelection());
+ // Refresh any actions that may become enabled or disabled.
+ //
+ setSelection(getSelection());
}
if (!removedResources.isEmpty()) {
@@ -593,6 +635,7 @@ public class FacadeEditor
* Handles what to do with changed resources on activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void handleChangedResources() {
@@ -608,8 +651,7 @@ public class FacadeEditor
resource.unload();
try {
resource.load(Collections.EMPTY_MAP);
- }
- catch (IOException exception) {
+ } catch (IOException exception) {
if (!resourceToDiagnosticMap.containsKey(resource)) {
resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
}
@@ -630,17 +672,18 @@ public class FacadeEditor
* Updates the problems indication with the information described in the specified diagnostic.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void updateProblemIndication() {
if (updateProblemIndication) {
BasicDiagnostic diagnostic =
- new BasicDiagnostic
+ new BasicDiagnostic
(Diagnostic.OK,
- "org.eclipse.papyrus.facade.editor",
- 0,
- null,
- new Object [] { editingDomain.getResourceSet() });
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ null,
+ new Object[] { editingDomain.getResourceSet() });
for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) {
if (childDiagnostic.getSeverity() != Diagnostic.OK) {
diagnostic.add(childDiagnostic);
@@ -649,7 +692,7 @@ public class FacadeEditor
int lastEditorPage = getPageCount() - 1;
if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) {
- ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic);
+ ((ProblemEditorPart) getEditor(lastEditorPage)).setDiagnostic(diagnostic);
if (diagnostic.getSeverity() != Diagnostic.OK) {
setActivePage(lastEditorPage);
}
@@ -663,8 +706,7 @@ public class FacadeEditor
setPageText(lastEditorPage, problemEditorPart.getPartName());
setActivePage(lastEditorPage);
showTabs();
- }
- catch (PartInitException exception) {
+ } catch (PartInitException exception) {
FacadeEditorPlugin.INSTANCE.log(exception);
}
}
@@ -674,8 +716,7 @@ public class FacadeEditor
if (diagnostic.getSeverity() != Diagnostic.OK) {
try {
markerHelper.createMarkers(diagnostic);
- }
- catch (CoreException exception) {
+ } catch (CoreException exception) {
FacadeEditorPlugin.INSTANCE.log(exception);
}
}
@@ -687,20 +728,21 @@ public class FacadeEditor
* Shows a dialog that asks if conflicting changes should be discarded.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean handleDirtyConflict() {
- return
- MessageDialog.openQuestion
+ return MessageDialog.openQuestion
(getSite().getShell(),
- getString("_UI_FileConflict_label"),
- getString("_WARN_FileConflict"));
+ getString("_UI_FileConflict_label"),
+ getString("_WARN_FileConflict"));
}
/**
* This creates a model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeEditor() {
@@ -712,6 +754,7 @@ public class FacadeEditor
* This sets up the editing domain for the model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void initializeEditingDomain() {
@@ -734,32 +777,34 @@ public class FacadeEditor
// Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus.
//
commandStack.addCommandStackListener
- (new CommandStackListener() {
- public void commandStackChanged(final EventObject event) {
- getContainer().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- firePropertyChange(IEditorPart.PROP_DIRTY);
-
- // Try to select the affected objects.
- //
- Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand();
- if (mostRecentCommand != null) {
- setSelectionToViewer(mostRecentCommand.getAffectedObjects());
- }
- for (Iterator<PropertySheetPage> i = propertySheetPages.iterator(); i.hasNext(); ) {
- PropertySheetPage propertySheetPage = i.next();
- if (propertySheetPage.getControl().isDisposed()) {
- i.remove();
- }
- else {
- propertySheetPage.refresh();
- }
- }
- }
- });
- }
- });
+ (new CommandStackListener() {
+ @Override
+ public void commandStackChanged(final EventObject event) {
+ getContainer().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ firePropertyChange(IEditorPart.PROP_DIRTY);
+
+ // Try to select the affected objects.
+ //
+ Command mostRecentCommand = ((CommandStack) event.getSource()).getMostRecentCommand();
+ if (mostRecentCommand != null) {
+ setSelectionToViewer(mostRecentCommand.getAffectedObjects());
+ }
+ for (Iterator<PropertySheetPage> i = propertySheetPages.iterator(); i.hasNext();) {
+ PropertySheetPage propertySheetPage = i.next();
+ if (propertySheetPage.getControl().isDisposed()) {
+ i.remove();
+ }
+ else {
+ propertySheetPage.refresh();
+ }
+ }
+ }
+ });
+ }
+ });
// Create the editing domain with a special command stack.
//
@@ -770,9 +815,10 @@ public class FacadeEditor
* This is here for the listener to be able to call it.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
- @Override
+ @Override
protected void firePropertyChange(int action) {
super.firePropertyChange(action);
}
@@ -781,6 +827,7 @@ public class FacadeEditor
* This sets the selection into whichever viewer is active.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setSelectionToViewer(Collection<?> collection) {
@@ -789,27 +836,29 @@ public class FacadeEditor
//
if (theSelection != null && !theSelection.isEmpty()) {
Runnable runnable =
- new Runnable() {
- public void run() {
- // Try to select the items in the current content viewer of the editor.
- //
- if (currentViewer != null) {
- currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true);
+ new Runnable() {
+ @Override
+ public void run() {
+ // Try to select the items in the current content viewer of the editor.
+ //
+ if (currentViewer != null) {
+ currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true);
+ }
}
- }
- };
+ };
getSite().getShell().getDisplay().asyncExec(runnable);
}
}
/**
* This returns the editing domain as required by the {@link IEditingDomainProvider} interface.
- * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain}
- * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}.
+ * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EditingDomain getEditingDomain() {
return editingDomain;
}
@@ -817,12 +866,14 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) {
@@ -832,10 +883,11 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
- public Object [] getElements(Object object) {
+ public Object[] getElements(Object object) {
Object parent = super.getParent(object);
return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray();
}
@@ -843,10 +895,11 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
- public Object [] getChildren(Object object) {
+ public Object[] getChildren(Object object) {
Object parent = super.getParent(object);
return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray();
}
@@ -854,6 +907,7 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -865,6 +919,7 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -876,6 +931,7 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setCurrentViewerPane(ViewerPane viewerPane) {
@@ -893,6 +949,7 @@ public class FacadeEditor
* is the current one.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setCurrentViewer(Viewer viewer) {
@@ -903,13 +960,14 @@ public class FacadeEditor
// Create the listener on demand.
//
selectionChangedListener =
- new ISelectionChangedListener() {
- // This just notifies those things that are affected by the section.
- //
- public void selectionChanged(SelectionChangedEvent selectionChangedEvent) {
- setSelection(selectionChangedEvent.getSelection());
- }
- };
+ new ISelectionChangedListener() {
+ // This just notifies those things that are affected by the section.
+ //
+ @Override
+ public void selectionChanged(SelectionChangedEvent selectionChangedEvent) {
+ setSelection(selectionChangedEvent.getSelection());
+ }
+ };
}
// Stop listening to the old one.
@@ -938,8 +996,10 @@ public class FacadeEditor
* This returns the viewer as required by the {@link IViewerProvider} interface.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Viewer getViewer() {
return currentViewer;
}
@@ -948,6 +1008,7 @@ public class FacadeEditor
* This creates a context menu for the viewer and adds a listener as well registering the menu for extension.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void createContextMenuFor(StructuredViewer viewer) {
@@ -955,7 +1016,7 @@ public class FacadeEditor
contextMenu.add(new Separator("additions"));
contextMenu.setRemoveAllWhenShown(true);
contextMenu.addMenuListener(this);
- Menu menu= contextMenu.createContextMenu(viewer.getControl());
+ Menu menu = contextMenu.createContextMenu(viewer.getControl());
viewer.getControl().setMenu(menu);
getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer));
@@ -969,6 +1030,7 @@ public class FacadeEditor
* This is the method called to load a resource into the editing domain's resource set based on the editor's input.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void createModel() {
@@ -979,15 +1041,14 @@ public class FacadeEditor
// Load the resource through the editing domain.
//
resource = editingDomain.getResourceSet().getResource(resourceURI, true);
- }
- catch (Exception e) {
+ } catch (Exception e) {
exception = e;
resource = editingDomain.getResourceSet().getResource(resourceURI, false);
}
Diagnostic diagnostic = analyzeResourceProblems(resource, exception);
if (diagnostic.getSeverity() != Diagnostic.OK) {
- resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
+ resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
}
editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter);
}
@@ -997,28 +1058,27 @@ public class FacadeEditor
* and the specified exception (if any).
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) {
if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) {
BasicDiagnostic basicDiagnostic =
- new BasicDiagnostic
+ new BasicDiagnostic
(Diagnostic.ERROR,
- "org.eclipse.papyrus.facade.editor",
- 0,
- getString("_UI_CreateModelError_message", resource.getURI()),
- new Object [] { exception == null ? (Object)resource : exception });
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ getString("_UI_CreateModelError_message", resource.getURI()),
+ new Object[] { exception == null ? (Object) resource : exception });
basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true));
return basicDiagnostic;
}
else if (exception != null) {
- return
- new BasicDiagnostic
- (Diagnostic.ERROR,
- "org.eclipse.papyrus.facade.editor",
- 0,
- getString("_UI_CreateModelError_message", resource.getURI()),
- new Object[] { exception });
+ return new BasicDiagnostic(Diagnostic.ERROR,
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ getString("_UI_CreateModelError_message", resource.getURI()),
+ new Object[] { exception });
}
else {
return Diagnostic.OK_INSTANCE;
@@ -1029,6 +1089,7 @@ public class FacadeEditor
* This is the method used by the framework to install your own controls.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1044,22 +1105,23 @@ public class FacadeEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacadeEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- Tree tree = new Tree(composite, SWT.MULTI);
- TreeViewer newTreeViewer = new TreeViewer(tree);
- return newTreeViewer;
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacadeEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ Tree tree = new Tree(composite, SWT.MULTI);
+ TreeViewer newTreeViewer = new TreeViewer(tree);
+ return newTreeViewer;
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- selectionViewer = (TreeViewer)viewerPane.getViewer();
+ selectionViewer = (TreeViewer) viewerPane.getViewer();
selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1078,22 +1140,23 @@ public class FacadeEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacadeEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- Tree tree = new Tree(composite, SWT.MULTI);
- TreeViewer newTreeViewer = new TreeViewer(tree);
- return newTreeViewer;
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacadeEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ Tree tree = new Tree(composite, SWT.MULTI);
+ TreeViewer newTreeViewer = new TreeViewer(tree);
+ return newTreeViewer;
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- parentViewer = (TreeViewer)viewerPane.getViewer();
+ parentViewer = (TreeViewer) viewerPane.getViewer();
parentViewer.setAutoExpandLevel(30);
parentViewer.setContentProvider(new ReverseAdapterFactoryContentProvider(adapterFactory));
parentViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1107,19 +1170,20 @@ public class FacadeEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacadeEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new ListViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacadeEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new ListViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- listViewer = (ListViewer)viewerPane.getViewer();
+ listViewer = (ListViewer) viewerPane.getViewer();
listViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
listViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1132,19 +1196,20 @@ public class FacadeEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacadeEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TreeViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacadeEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TreeViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- treeViewer = (TreeViewer)viewerPane.getViewer();
+ treeViewer = (TreeViewer) viewerPane.getViewer();
treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
treeViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1159,19 +1224,20 @@ public class FacadeEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacadeEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TableViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacadeEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TableViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- tableViewer = (TableViewer)viewerPane.getViewer();
+ tableViewer = (TableViewer) viewerPane.getViewer();
Table table = tableViewer.getTable();
TableLayout layout = new TableLayout();
@@ -1189,7 +1255,7 @@ public class FacadeEditor
selfColumn.setText(getString("_UI_SelfColumn_label"));
selfColumn.setResizable(true);
- tableViewer.setColumnProperties(new String [] {"a", "b"});
+ tableViewer.setColumnProperties(new String[] { "a", "b" });
tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1202,20 +1268,21 @@ public class FacadeEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacadeEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TreeViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacadeEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TreeViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- treeViewerWithColumns = (TreeViewer)viewerPane.getViewer();
+ treeViewerWithColumns = (TreeViewer) viewerPane.getViewer();
Tree tree = treeViewerWithColumns.getTree();
tree.setLayoutData(new FillLayout());
@@ -1232,7 +1299,7 @@ public class FacadeEditor
selfColumn.setResizable(true);
selfColumn.setWidth(200);
- treeViewerWithColumns.setColumnProperties(new String [] {"a", "b"});
+ treeViewerWithColumns.setColumnProperties(new String[] { "a", "b" });
treeViewerWithColumns.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
treeViewerWithColumns.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1242,35 +1309,38 @@ public class FacadeEditor
}
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- setActivePage(0);
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ setActivePage(0);
+ }
+ });
}
// Ensures that this editor will only display the page's tab
// area if there are more than one page
//
getContainer().addControlListener
- (new ControlAdapter() {
- boolean guard = false;
- @Override
- public void controlResized(ControlEvent event) {
- if (!guard) {
- guard = true;
- hideTabs();
- guard = false;
+ (new ControlAdapter() {
+ boolean guard = false;
+
+ @Override
+ public void controlResized(ControlEvent event) {
+ if (!guard) {
+ guard = true;
+ hideTabs();
+ guard = false;
+ }
}
- }
- });
+ });
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
}
/**
@@ -1278,13 +1348,14 @@ public class FacadeEditor
* this hides the single tab at the bottom.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void hideTabs() {
if (getPageCount() <= 1) {
setPageText(0, "");
if (getContainer() instanceof CTabFolder) {
- ((CTabFolder)getContainer()).setTabHeight(1);
+ ((CTabFolder) getContainer()).setTabHeight(1);
Point point = getContainer().getSize();
getContainer().setSize(point.x, point.y + 6);
}
@@ -1296,13 +1367,14 @@ public class FacadeEditor
* this shows the tabs at the bottom.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void showTabs() {
if (getPageCount() > 1) {
setPageText(0, getString("_UI_SelectionPage_label"));
if (getContainer() instanceof CTabFolder) {
- ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT);
+ ((CTabFolder) getContainer()).setTabHeight(SWT.DEFAULT);
Point point = getContainer().getSize();
getContainer().setSize(point.x, point.y - 6);
}
@@ -1313,6 +1385,7 @@ public class FacadeEditor
* This is used to track the active viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1328,6 +1401,7 @@ public class FacadeEditor
* This is how the framework determines which interfaces we implement.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("rawtypes")
@@ -1351,6 +1425,7 @@ public class FacadeEditor
* This accesses a cached version of the content outliner.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IContentOutlinePage getContentOutlinePage() {
@@ -1375,9 +1450,9 @@ public class FacadeEditor
createContextMenuFor(contentOutlineViewer);
if (!editingDomain.getResourceSet().getResources().isEmpty()) {
- // Select the root object in the view.
- //
- contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true);
+ // Select the root object in the view.
+ //
+ contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true);
}
}
@@ -1399,13 +1474,14 @@ public class FacadeEditor
// Listen to selection so that we can handle it is a special way.
//
contentOutlinePage.addSelectionChangedListener
- (new ISelectionChangedListener() {
- // This ensures that we handle selections correctly.
- //
- public void selectionChanged(SelectionChangedEvent event) {
- handleContentOutlineSelection(event.getSelection());
- }
- });
+ (new ISelectionChangedListener() {
+ // This ensures that we handle selections correctly.
+ //
+ @Override
+ public void selectionChanged(SelectionChangedEvent event) {
+ handleContentOutlineSelection(event.getSelection());
+ }
+ });
}
return contentOutlinePage;
@@ -1415,23 +1491,24 @@ public class FacadeEditor
* This accesses a cached version of the property sheet.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IPropertySheetPage getPropertySheetPage() {
PropertySheetPage propertySheetPage =
- new ExtendedPropertySheetPage(editingDomain) {
- @Override
- public void setSelectionToViewer(List<?> selection) {
- FacadeEditor.this.setSelectionToViewer(selection);
- FacadeEditor.this.setFocus();
- }
+ new ExtendedPropertySheetPage(editingDomain) {
+ @Override
+ public void setSelectionToViewer(List<?> selection) {
+ FacadeEditor.this.setSelectionToViewer(selection);
+ FacadeEditor.this.setFocus();
+ }
- @Override
- public void setActionBars(IActionBars actionBars) {
- super.setActionBars(actionBars);
- getActionBarContributor().shareGlobalActions(this, actionBars);
- }
- };
+ @Override
+ public void setActionBars(IActionBars actionBars) {
+ super.setActionBars(actionBars);
+ getActionBarContributor().shareGlobalActions(this, actionBars);
+ }
+ };
propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory));
propertySheetPages.add(propertySheetPage);
@@ -1442,11 +1519,12 @@ public class FacadeEditor
* This deals with how we want selection in the outliner to affect the other views.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void handleContentOutlineSelection(ISelection selection) {
if (currentViewerPane != null && !selection.isEmpty() && selection instanceof IStructuredSelection) {
- Iterator<?> selectedElements = ((IStructuredSelection)selection).iterator();
+ Iterator<?> selectedElements = ((IStructuredSelection) selection).iterator();
if (selectedElements.hasNext()) {
// Get the first selected element.
//
@@ -1481,17 +1559,19 @@ public class FacadeEditor
* This is for implementing {@link IEditorPart} and simply tests the command stack.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean isDirty() {
- return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded();
+ return ((BasicCommandStack) editingDomain.getCommandStack()).isSaveNeeded();
}
/**
* This is for implementing {@link IEditorPart} and simply saves the model file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1505,31 +1585,31 @@ public class FacadeEditor
// Do the work within an operation because this is a long running activity that modifies the workbench.
//
WorkspaceModifyOperation operation =
- new WorkspaceModifyOperation() {
- // This is the method that gets invoked when the operation runs.
- //
- @Override
- public void execute(IProgressMonitor monitor) {
- // Save the resources to the file system.
+ new WorkspaceModifyOperation() {
+ // This is the method that gets invoked when the operation runs.
//
- boolean first = true;
- for (Resource resource : editingDomain.getResourceSet().getResources()) {
- if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) {
- try {
- long timeStamp = resource.getTimeStamp();
- resource.save(saveOptions);
- if (resource.getTimeStamp() != timeStamp) {
- savedResources.add(resource);
+ @Override
+ public void execute(IProgressMonitor monitor) {
+ // Save the resources to the file system.
+ //
+ boolean first = true;
+ for (Resource resource : editingDomain.getResourceSet().getResources()) {
+ if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) {
+ try {
+ long timeStamp = resource.getTimeStamp();
+ resource.save(saveOptions);
+ if (resource.getTimeStamp() != timeStamp) {
+ savedResources.add(resource);
+ }
}
+ catch (Exception exception) {
+ resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
+ }
+ first = false;
}
- catch (Exception exception) {
- resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
- }
- first = false;
}
}
- }
- };
+ };
updateProblemIndication = false;
try {
@@ -1539,10 +1619,9 @@ public class FacadeEditor
// Refresh the necessary state.
//
- ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone();
+ ((BasicCommandStack) editingDomain.getCommandStack()).saveIsDone();
firePropertyChange(IEditorPart.PROP_DIRTY);
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
// Something went wrong that shouldn't.
//
FacadeEditorPlugin.INSTANCE.log(exception);
@@ -1556,6 +1635,7 @@ public class FacadeEditor
* The implementation uses the URI converter from the editor's resource set to try to open an input stream.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean isPersisted(Resource resource) {
@@ -1566,8 +1646,7 @@ public class FacadeEditor
result = true;
stream.close();
}
- }
- catch (IOException e) {
+ } catch (IOException e) {
// Ignore
}
return result;
@@ -1577,6 +1656,7 @@ public class FacadeEditor
* This always returns true because it is not currently supported.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1588,6 +1668,7 @@ public class FacadeEditor
* This also changes the editor's input.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1606,6 +1687,7 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void doSaveAs(URI uri, IEditorInput editorInput) {
@@ -1613,17 +1695,19 @@ public class FacadeEditor
setInputWithNotify(editorInput);
setPartName(editorInput.getName());
IProgressMonitor progressMonitor =
- getActionBars().getStatusLineManager() != null ?
- getActionBars().getStatusLineManager().getProgressMonitor() :
- new NullProgressMonitor();
+ getActionBars().getStatusLineManager() != null ?
+ getActionBars().getStatusLineManager().getProgressMonitor() :
+ new NullProgressMonitor();
doSave(progressMonitor);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void gotoMarker(IMarker marker) {
List<?> targetObjects = markerHelper.getTargetObjects(editingDomain, marker);
if (!targetObjects.isEmpty()) {
@@ -1635,6 +1719,7 @@ public class FacadeEditor
* This is called during startup.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1650,6 +1735,7 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1666,8 +1752,10 @@ public class FacadeEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void addSelectionChangedListener(ISelectionChangedListener listener) {
selectionChangedListeners.add(listener);
}
@@ -1676,8 +1764,10 @@ public class FacadeEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void removeSelectionChangedListener(ISelectionChangedListener listener) {
selectionChangedListeners.remove(listener);
}
@@ -1686,8 +1776,10 @@ public class FacadeEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ISelection getSelection() {
return editorSelection;
}
@@ -1697,8 +1789,10 @@ public class FacadeEditor
* Calling this result will notify the listeners.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setSelection(ISelection selection) {
editorSelection = selection;
@@ -1711,29 +1805,30 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setStatusLineManager(ISelection selection) {
IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ?
- contentOutlineStatusLineManager : getActionBars().getStatusLineManager();
+ contentOutlineStatusLineManager : getActionBars().getStatusLineManager();
if (statusLineManager != null) {
if (selection instanceof IStructuredSelection) {
- Collection<?> collection = ((IStructuredSelection)selection).toList();
+ Collection<?> collection = ((IStructuredSelection) selection).toList();
switch (collection.size()) {
- case 0: {
- statusLineManager.setMessage(getString("_UI_NoObjectSelected"));
- break;
- }
- case 1: {
- String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next());
- statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text));
- break;
- }
- default: {
- statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size())));
- break;
- }
+ case 0: {
+ statusLineManager.setMessage(getString("_UI_NoObjectSelected"));
+ break;
+ }
+ case 1: {
+ String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next());
+ statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text));
+ break;
+ }
+ default: {
+ statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size())));
+ break;
+ }
}
}
else {
@@ -1746,6 +1841,7 @@ public class FacadeEditor
* This looks up a string in the plugin's plugin.properties file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static String getString(String key) {
@@ -1756,34 +1852,39 @@ public class FacadeEditor
* This looks up a string in plugin.properties, making a substitution.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static String getString(String key, Object s1) {
- return FacadeEditorPlugin.INSTANCE.getString(key, new Object [] { s1 });
+ return FacadeEditorPlugin.INSTANCE.getString(key, new Object[] { s1 });
}
/**
* This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void menuAboutToShow(IMenuManager menuManager) {
- ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager);
+ ((IMenuListener) getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public EditingDomainActionBarContributor getActionBarContributor() {
- return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor();
+ return (EditingDomainActionBarContributor) getEditorSite().getActionBarContributor();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IActionBars getActionBars() {
@@ -1793,6 +1894,7 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public AdapterFactory getAdapterFactory() {
@@ -1802,6 +1904,7 @@ public class FacadeEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1833,6 +1936,7 @@ public class FacadeEditor
* Returns whether the outline view should be presented to the user.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean showOutlineView() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditorPlugin.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditorPlugin.java
index 832d46959a4..605905553bc 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditorPlugin.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeEditorPlugin.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.uml2.uml.edit.UMLEditPlugin;
* This is the central singleton for the Facade editor plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public final class FacadeEditorPlugin extends EMFPlugin {
@@ -34,14 +35,16 @@ public final class FacadeEditorPlugin extends EMFPlugin {
* Keep track of the singleton.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final FacadeEditorPlugin INSTANCE = new FacadeEditorPlugin();
-
+
/**
* Keep track of the singleton.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static Implementation plugin;
@@ -50,20 +53,21 @@ public final class FacadeEditorPlugin extends EMFPlugin {
* Create the instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeEditorPlugin() {
- super
- (new ResourceLocator [] {
+ super(new ResourceLocator[] {
EcoreEditPlugin.INSTANCE,
UMLEditPlugin.INSTANCE,
- });
+ });
}
/**
* Returns the singleton instance of the Eclipse plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the singleton instance.
* @generated
*/
@@ -71,22 +75,24 @@ public final class FacadeEditorPlugin extends EMFPlugin {
public ResourceLocator getPluginResourceLocator() {
return plugin;
}
-
+
/**
* Returns the singleton instance of the Eclipse plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the singleton instance.
* @generated
*/
public static Implementation getPlugin() {
return plugin;
}
-
+
/**
* The actual implementation of the Eclipse <b>Plugin</b>.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static class Implementation extends EclipseUIPlugin {
@@ -94,11 +100,12 @@ public final class FacadeEditorPlugin extends EMFPlugin {
* Creates an instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Implementation() {
super();
-
+
// Remember the static instance.
//
plugin = this;
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeModelWizard.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeModelWizard.java
index 43356721e73..31642fbdd27 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeModelWizard.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/presentation/FacadeModelWizard.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -84,7 +84,6 @@ import org.eclipse.papyrus.facade.FacadeFactory;
import org.eclipse.papyrus.facade.FacadePackage;
import org.eclipse.papyrus.facade.provider.FacadeEditPlugin;
-
import org.eclipse.core.runtime.Path;
import org.eclipse.jface.viewers.ISelection;
@@ -100,6 +99,7 @@ import org.eclipse.ui.PartInitException;
* This is a simple wizard for creating a new model file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeModelWizard extends Wizard implements INewWizard {
@@ -107,24 +107,27 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* The supported extensions for created files.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final List<String> FILE_EXTENSIONS =
- Collections.unmodifiableList(Arrays.asList(FacadeEditorPlugin.INSTANCE.getString("_UI_FacadeEditorFilenameExtensions").split("\\s*,\\s*")));
+ Collections.unmodifiableList(Arrays.asList(FacadeEditorPlugin.INSTANCE.getString("_UI_FacadeEditorFilenameExtensions").split("\\s*,\\s*")));
/**
* A formatted list of supported file extensions, suitable for display.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final String FORMATTED_FILE_EXTENSIONS =
- FacadeEditorPlugin.INSTANCE.getString("_UI_FacadeEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", ");
+ FacadeEditorPlugin.INSTANCE.getString("_UI_FacadeEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", ");
/**
* This caches an instance of the model package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacadePackage facadePackage = FacadePackage.eINSTANCE;
@@ -133,6 +136,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* This caches an instance of the model factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacadeFactory facadeFactory = facadePackage.getFacadeFactory();
@@ -141,6 +145,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* This is the file creation page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacadeModelWizardNewFileCreationPage newFileCreationPage;
@@ -149,6 +154,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* This is the initial object creation page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacadeModelWizardInitialObjectCreationPage initialObjectCreationPage;
@@ -157,6 +163,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Remember the selection during initialization for populating the default container.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IStructuredSelection selection;
@@ -165,6 +172,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Remember the workbench during initialization.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IWorkbench workbench;
@@ -173,6 +181,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Caches the names of the types that can be created as the root object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected List<String> initialObjectNames;
@@ -181,8 +190,10 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* This just records the information.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void init(IWorkbench workbench, IStructuredSelection selection) {
this.workbench = workbench;
this.selection = selection;
@@ -194,6 +205,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Returns the names of the types that can be created as the root object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<String> getInitialObjectNames() {
@@ -201,7 +213,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
initialObjectNames = new ArrayList<String>();
for (EClassifier eClassifier : facadePackage.getEClassifiers()) {
if (eClassifier instanceof EClass) {
- EClass eClass = (EClass)eClassifier;
+ EClass eClass = (EClass) eClassifier;
if (!eClass.isAbstract()) {
initialObjectNames.add(eClass.getName());
}
@@ -216,10 +228,11 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Create a new model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected EObject createInitialModel() {
- EClass eClass = (EClass)facadePackage.getEClassifier(initialObjectCreationPage.getInitialObjectName());
+ EClass eClass = (EClass) facadePackage.getEClassifier(initialObjectCreationPage.getInitialObjectName());
EObject rootObject = facadeFactory.create(eClass);
return rootObject;
}
@@ -228,6 +241,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Do the work after everything is specified.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -240,43 +254,43 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
// Do the work within an operation.
//
WorkspaceModifyOperation operation =
- new WorkspaceModifyOperation() {
- @Override
- protected void execute(IProgressMonitor progressMonitor) {
- try {
- // Create a resource set
- //
- ResourceSet resourceSet = new ResourceSetImpl();
-
- // Get the URI of the model file.
- //
- URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true);
-
- // Create a resource for this file.
- //
- Resource resource = resourceSet.createResource(fileURI);
-
- // Add the initial model object to the contents.
- //
- EObject rootObject = createInitialModel();
- if (rootObject != null) {
- resource.getContents().add(rootObject);
+ new WorkspaceModifyOperation() {
+ @Override
+ protected void execute(IProgressMonitor progressMonitor) {
+ try {
+ // Create a resource set
+ //
+ ResourceSet resourceSet = new ResourceSetImpl();
+
+ // Get the URI of the model file.
+ //
+ URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true);
+
+ // Create a resource for this file.
+ //
+ Resource resource = resourceSet.createResource(fileURI);
+
+ // Add the initial model object to the contents.
+ //
+ EObject rootObject = createInitialModel();
+ if (rootObject != null) {
+ resource.getContents().add(rootObject);
+ }
+
+ // Save the contents of the resource to the file system.
+ //
+ Map<Object, Object> options = new HashMap<Object, Object>();
+ options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding());
+ resource.save(options);
+ }
+ catch (Exception exception) {
+ FacadeEditorPlugin.INSTANCE.log(exception);
+ }
+ finally {
+ progressMonitor.done();
}
-
- // Save the contents of the resource to the file system.
- //
- Map<Object, Object> options = new HashMap<Object, Object>();
- options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding());
- resource.save(options);
- }
- catch (Exception exception) {
- FacadeEditorPlugin.INSTANCE.log(exception);
- }
- finally {
- progressMonitor.done();
}
- }
- };
+ };
getContainer().run(false, false, operation);
@@ -288,28 +302,27 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
if (activePart instanceof ISetSelectionTarget) {
final ISelection targetSelection = new StructuredSelection(modelFile);
getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- ((ISetSelectionTarget)activePart).selectReveal(targetSelection);
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ ((ISetSelectionTarget) activePart).selectReveal(targetSelection);
+ }
+ });
}
// Open an editor on the new file.
//
try {
page.openEditor
- (new FileEditorInput(modelFile),
- workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId());
- }
- catch (PartInitException exception) {
+ (new FileEditorInput(modelFile),
+ workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId());
+ } catch (PartInitException exception) {
MessageDialog.openError(workbenchWindow.getShell(), FacadeEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage());
return false;
}
return true;
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
FacadeEditorPlugin.INSTANCE.log(exception);
return false;
}
@@ -319,6 +332,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* This is the one page of the wizard.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeModelWizardNewFileCreationPage extends WizardNewFileCreationPage {
@@ -326,6 +340,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Pass in the selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) {
@@ -336,6 +351,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* The framework calls this to see if the file is correct.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -344,7 +360,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
String extension = new Path(getFileName()).getFileExtension();
if (extension == null || !FILE_EXTENSIONS.contains(extension)) {
String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension";
- setErrorMessage(FacadeEditorPlugin.INSTANCE.getString(key, new Object [] { FORMATTED_FILE_EXTENSIONS }));
+ setErrorMessage(FacadeEditorPlugin.INSTANCE.getString(key, new Object[] { FORMATTED_FILE_EXTENSIONS }));
return false;
}
return true;
@@ -355,6 +371,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IFile getModelFile() {
@@ -366,26 +383,29 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* This is the page where the type of object to create is selected.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeModelWizardInitialObjectCreationPage extends WizardPage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Combo initialObjectField;
/**
* @generated
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
*/
protected List<String> encodings;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Combo encodingField;
@@ -394,6 +414,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Pass in the selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeModelWizardInitialObjectCreationPage(String pageId) {
@@ -403,10 +424,13 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void createControl(Composite parent) {
- Composite composite = new Composite(parent, SWT.NONE); {
+ Composite composite = new Composite(parent, SWT.NONE);
+ {
GridLayout layout = new GridLayout();
layout.numColumns = 1;
layout.verticalSpacing = 12;
@@ -475,18 +499,21 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ModifyListener validator =
- new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- setPageComplete(validatePage());
- }
- };
+ new ModifyListener() {
+ @Override
+ public void modifyText(ModifyEvent e) {
+ setPageComplete(validatePage());
+ }
+ };
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean validatePage() {
@@ -496,6 +523,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -516,6 +544,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String getInitialObjectName() {
@@ -532,6 +561,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String getEncoding() {
@@ -542,13 +572,13 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Returns the label for the specified type name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected String getLabel(String typeName) {
try {
return FacadeEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type");
- }
- catch(MissingResourceException mre) {
+ } catch (MissingResourceException mre) {
FacadeEditorPlugin.INSTANCE.log(mre);
}
return typeName;
@@ -557,12 +587,13 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<String> getEncodings() {
if (encodings == null) {
encodings = new ArrayList<String>();
- for (StringTokenizer stringTokenizer = new StringTokenizer(FacadeEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens(); ) {
+ for (StringTokenizer stringTokenizer = new StringTokenizer(FacadeEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens();) {
encodings.add(stringTokenizer.nextToken());
}
}
@@ -574,9 +605,10 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* The framework calls this to create the contents of the wizard.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
- @Override
+ @Override
public void addPages() {
// Create a page, set the title, and the initial model file name.
//
@@ -595,7 +627,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
if (selectedElement instanceof IResource) {
// Get the resource parent, if its a file.
//
- IResource selectedResource = (IResource)selectedElement;
+ IResource selectedResource = (IResource) selectedElement;
if (selectedResource.getType() == IResource.FILE) {
selectedResource = selectedResource.getParent();
}
@@ -612,7 +644,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
String defaultModelBaseFilename = FacadeEditorPlugin.INSTANCE.getString("_UI_FacadeEditorFilenameDefaultBase");
String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0);
String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension;
- for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) {
+ for (int i = 1; ((IContainer) selectedResource).findMember(modelFilename) != null; ++i) {
modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension;
}
newFileCreationPage.setFileName(modelFilename);
@@ -629,6 +661,7 @@ public class FacadeModelWizard extends Wizard implements INewWizard {
* Get the file from the page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IFile getModelFile() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelActionBarContributor.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelActionBarContributor.java
index 9a0a2d5727f..1f8bde54aec 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelActionBarContributor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelActionBarContributor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -56,15 +56,17 @@ import org.eclipse.ui.PartInitException;
* This is the action bar contributor for the Virtualmetamodel model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualmetamodelActionBarContributor
- extends EditingDomainActionBarContributor
- implements ISelectionChangedListener {
+ extends EditingDomainActionBarContributor
+ implements ISelectionChangedListener {
/**
* This keeps track of the active editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IEditorPart activeEditorPart;
@@ -73,6 +75,7 @@ public class VirtualmetamodelActionBarContributor
* This keeps track of the current selection provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelectionProvider selectionProvider;
@@ -81,51 +84,54 @@ public class VirtualmetamodelActionBarContributor
* This action opens the Properties view.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IAction showPropertiesViewAction =
- new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) {
- @Override
- public void run() {
- try {
- getPage().showView("org.eclipse.ui.views.PropertySheet");
- }
- catch (PartInitException exception) {
- FacadeEditorPlugin.INSTANCE.log(exception);
+ new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) {
+ @Override
+ public void run() {
+ try {
+ getPage().showView("org.eclipse.ui.views.PropertySheet");
+ }
+ catch (PartInitException exception) {
+ FacadeEditorPlugin.INSTANCE.log(exception);
+ }
}
- }
- };
+ };
/**
* This action refreshes the viewer of the current editor if the editor
* implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IAction refreshViewerAction =
- new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) {
- @Override
- public boolean isEnabled() {
- return activeEditorPart instanceof IViewerProvider;
- }
+ new Action(FacadeEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) {
+ @Override
+ public boolean isEnabled() {
+ return activeEditorPart instanceof IViewerProvider;
+ }
- @Override
- public void run() {
- if (activeEditorPart instanceof IViewerProvider) {
- Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer();
- if (viewer != null) {
- viewer.refresh();
+ @Override
+ public void run() {
+ if (activeEditorPart instanceof IViewerProvider) {
+ Viewer viewer = ((IViewerProvider) activeEditorPart).getViewer();
+ if (viewer != null) {
+ viewer.refresh();
+ }
}
}
- }
- };
+ };
/**
* This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor
* generated for the current selection by the item provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> createChildActions;
@@ -134,6 +140,7 @@ public class VirtualmetamodelActionBarContributor
* This is the menu manager into which menu contribution items should be added for CreateChild actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IMenuManager createChildMenuManager;
@@ -143,6 +150,7 @@ public class VirtualmetamodelActionBarContributor
* generated for the current selection by the item provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> createSiblingActions;
@@ -151,6 +159,7 @@ public class VirtualmetamodelActionBarContributor
* This is the menu manager into which menu contribution items should be added for CreateSibling actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IMenuManager createSiblingMenuManager;
@@ -159,6 +168,7 @@ public class VirtualmetamodelActionBarContributor
* This creates an instance of the contributor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelActionBarContributor() {
@@ -172,6 +182,7 @@ public class VirtualmetamodelActionBarContributor
* This adds Separators for editor additions to the tool bar.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -185,6 +196,7 @@ public class VirtualmetamodelActionBarContributor
* as well as the sub-menus for object creation items.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -211,11 +223,12 @@ public class VirtualmetamodelActionBarContributor
// Force an update because Eclipse hides empty menus now.
//
submenuManager.addMenuListener
- (new IMenuListener() {
- public void menuAboutToShow(IMenuManager menuManager) {
- menuManager.updateAll(true);
- }
- });
+ (new IMenuListener() {
+ @Override
+ public void menuAboutToShow(IMenuManager menuManager) {
+ menuManager.updateAll(true);
+ }
+ });
addGlobalActions(submenuManager);
}
@@ -224,6 +237,7 @@ public class VirtualmetamodelActionBarContributor
* When the active editor changes, this remembers the change and registers with it as a selection provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -257,8 +271,10 @@ public class VirtualmetamodelActionBarContributor
* that can be added to the selected object and updating the menus accordingly.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
// Remove any menu items for old selection.
//
@@ -275,10 +291,10 @@ public class VirtualmetamodelActionBarContributor
Collection<?> newSiblingDescriptors = null;
ISelection selection = event.getSelection();
- if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) {
- Object object = ((IStructuredSelection)selection).getFirstElement();
+ if (selection instanceof IStructuredSelection && ((IStructuredSelection) selection).size() == 1) {
+ Object object = ((IStructuredSelection) selection).getFirstElement();
- EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain();
+ EditingDomain domain = ((IEditingDomainProvider) activeEditorPart).getEditingDomain();
newChildDescriptors = domain.getNewChildDescriptors(object, null);
newSiblingDescriptors = domain.getNewChildDescriptors(null, object);
@@ -304,6 +320,7 @@ public class VirtualmetamodelActionBarContributor
* and returns the collection of these actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> generateCreateChildActions(Collection<?> descriptors, ISelection selection) {
@@ -321,6 +338,7 @@ public class VirtualmetamodelActionBarContributor
* and returns the collection of these actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> generateCreateSiblingActions(Collection<?> descriptors, ISelection selection) {
@@ -340,6 +358,7 @@ public class VirtualmetamodelActionBarContributor
* If <code>contributionID</code> is <code>null</code>, they are simply added.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void populateManager(IContributionManager manager, Collection<? extends IAction> actions, String contributionID) {
@@ -354,12 +373,13 @@ public class VirtualmetamodelActionBarContributor
}
}
}
-
+
/**
* This removes from the specified <code>manager</code> all {@link org.eclipse.jface.action.ActionContributionItem}s
* based on the {@link org.eclipse.jface.action.IAction}s contained in the <code>actions</code> collection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void depopulateManager(IContributionManager manager, Collection<? extends IAction> actions) {
@@ -370,13 +390,13 @@ public class VirtualmetamodelActionBarContributor
//
IContributionItem contributionItem = items[i];
while (contributionItem instanceof SubContributionItem) {
- contributionItem = ((SubContributionItem)contributionItem).getInnerItem();
+ contributionItem = ((SubContributionItem) contributionItem).getInnerItem();
}
// Delete the ActionContributionItems with matching action.
//
if (contributionItem instanceof ActionContributionItem) {
- IAction action = ((ActionContributionItem)contributionItem).getAction();
+ IAction action = ((ActionContributionItem) contributionItem).getAction();
if (actions.contains(action)) {
manager.remove(contributionItem);
}
@@ -389,6 +409,7 @@ public class VirtualmetamodelActionBarContributor
* This populates the pop-up menu before it appears.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -409,6 +430,7 @@ public class VirtualmetamodelActionBarContributor
* This inserts global actions before the "additions-end" separator.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -416,7 +438,7 @@ public class VirtualmetamodelActionBarContributor
menuManager.insertAfter("additions-end", new Separator("ui-actions"));
menuManager.insertAfter("ui-actions", showPropertiesViewAction);
- refreshViewerAction.setEnabled(refreshViewerAction.isEnabled());
+ refreshViewerAction.setEnabled(refreshViewerAction.isEnabled());
menuManager.insertAfter("ui-actions", refreshViewerAction);
super.addGlobalActions(menuManager);
@@ -426,6 +448,7 @@ public class VirtualmetamodelActionBarContributor
* This ensures that a delete action will clean up all references to deleted objects.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelEditor.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelEditor.java
index 1710b7760c4..16d165208ea 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelEditor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelEditor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -131,7 +131,6 @@ import org.eclipse.emf.common.util.BasicDiagnostic;
import org.eclipse.emf.common.util.Diagnostic;
import org.eclipse.emf.common.util.URI;
-
import org.eclipse.emf.ecore.resource.Resource;
import org.eclipse.emf.ecore.resource.ResourceSet;
@@ -184,15 +183,17 @@ import org.eclipse.uml2.uml.edit.providers.UMLItemProviderAdapterFactory;
* This is an example of a Virtualmetamodel model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualmetamodelEditor
- extends MultiPageEditorPart
- implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker {
+ extends MultiPageEditorPart
+ implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker {
/**
* This keeps track of the editing domain that is used to track all changes to the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected AdapterFactoryEditingDomain editingDomain;
@@ -201,6 +202,7 @@ public class VirtualmetamodelEditor
* This is the one adapter factory used for providing views of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ComposedAdapterFactory adapterFactory;
@@ -209,6 +211,7 @@ public class VirtualmetamodelEditor
* This is the content outline page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IContentOutlinePage contentOutlinePage;
@@ -217,6 +220,7 @@ public class VirtualmetamodelEditor
* This is a kludge...
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IStatusLineManager contentOutlineStatusLineManager;
@@ -225,6 +229,7 @@ public class VirtualmetamodelEditor
* This is the content outline page's viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer contentOutlineViewer;
@@ -233,6 +238,7 @@ public class VirtualmetamodelEditor
* This is the property sheet page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected List<PropertySheetPage> propertySheetPages = new ArrayList<PropertySheetPage>();
@@ -242,6 +248,7 @@ public class VirtualmetamodelEditor
* The parent relation must be correctly defined for this to work.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer selectionViewer;
@@ -250,6 +257,7 @@ public class VirtualmetamodelEditor
* This inverts the roll of parent and child in the content provider and show parents as a tree.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer parentViewer;
@@ -258,6 +266,7 @@ public class VirtualmetamodelEditor
* This shows how a tree view works.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer treeViewer;
@@ -267,6 +276,7 @@ public class VirtualmetamodelEditor
* A list viewer doesn't support icons.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ListViewer listViewer;
@@ -276,6 +286,7 @@ public class VirtualmetamodelEditor
* A table can be used as a list with icons.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TableViewer tableViewer;
@@ -284,6 +295,7 @@ public class VirtualmetamodelEditor
* This shows how a tree view with columns works.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer treeViewerWithColumns;
@@ -292,6 +304,7 @@ public class VirtualmetamodelEditor
* This keeps track of the active viewer pane, in the book.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ViewerPane currentViewerPane;
@@ -300,6 +313,7 @@ public class VirtualmetamodelEditor
* This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Viewer currentViewer;
@@ -308,6 +322,7 @@ public class VirtualmetamodelEditor
* This listens to which ever viewer is active.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelectionChangedListener selectionChangedListener;
@@ -316,6 +331,7 @@ public class VirtualmetamodelEditor
* This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<ISelectionChangedListener> selectionChangedListeners = new ArrayList<ISelectionChangedListener>();
@@ -324,6 +340,7 @@ public class VirtualmetamodelEditor
* This keeps track of the selection of the editor as a whole.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelection editorSelection = StructuredSelection.EMPTY;
@@ -333,6 +350,7 @@ public class VirtualmetamodelEditor
* in Eclipse's Problems View.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected MarkerHelper markerHelper = new EditUIMarkerHelper();
@@ -341,46 +359,57 @@ public class VirtualmetamodelEditor
* This listens for when the outline becomes active
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IPartListener partListener =
- new IPartListener() {
- public void partActivated(IWorkbenchPart p) {
- if (p instanceof ContentOutline) {
- if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) {
- getActionBarContributor().setActiveEditor(VirtualmetamodelEditor.this);
+ new IPartListener() {
+ @Override
+ public void partActivated(IWorkbenchPart p) {
+ if (p instanceof ContentOutline) {
+ if (((ContentOutline) p).getCurrentPage() == contentOutlinePage) {
+ getActionBarContributor().setActiveEditor(VirtualmetamodelEditor.this);
- setCurrentViewer(contentOutlineViewer);
+ setCurrentViewer(contentOutlineViewer);
+ }
}
- }
- else if (p instanceof PropertySheet) {
- if (propertySheetPages.contains(((PropertySheet)p).getCurrentPage())) {
- getActionBarContributor().setActiveEditor(VirtualmetamodelEditor.this);
+ else if (p instanceof PropertySheet) {
+ if (propertySheetPages.contains(((PropertySheet) p).getCurrentPage())) {
+ getActionBarContributor().setActiveEditor(VirtualmetamodelEditor.this);
+ handleActivate();
+ }
+ }
+ else if (p == VirtualmetamodelEditor.this) {
handleActivate();
}
}
- else if (p == VirtualmetamodelEditor.this) {
- handleActivate();
+
+ @Override
+ public void partBroughtToTop(IWorkbenchPart p) {
+ // Ignore.
+ }
+
+ @Override
+ public void partClosed(IWorkbenchPart p) {
+ // Ignore.
+ }
+
+ @Override
+ public void partDeactivated(IWorkbenchPart p) {
+ // Ignore.
}
- }
- public void partBroughtToTop(IWorkbenchPart p) {
- // Ignore.
- }
- public void partClosed(IWorkbenchPart p) {
- // Ignore.
- }
- public void partDeactivated(IWorkbenchPart p) {
- // Ignore.
- }
- public void partOpened(IWorkbenchPart p) {
- // Ignore.
- }
- };
+
+ @Override
+ public void partOpened(IWorkbenchPart p) {
+ // Ignore.
+ }
+ };
/**
* Resources that have been removed since last activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> removedResources = new ArrayList<Resource>();
@@ -389,6 +418,7 @@ public class VirtualmetamodelEditor
* Resources that have been changed since last activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> changedResources = new ArrayList<Resource>();
@@ -397,6 +427,7 @@ public class VirtualmetamodelEditor
* Resources that have been saved.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> savedResources = new ArrayList<Resource>();
@@ -405,6 +436,7 @@ public class VirtualmetamodelEditor
* Map to store the diagnostic associated with a resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Map<Resource, Diagnostic> resourceToDiagnosticMap = new LinkedHashMap<Resource, Diagnostic>();
@@ -413,6 +445,7 @@ public class VirtualmetamodelEditor
* Controls whether the problem indication should be updated.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean updateProblemIndication = true;
@@ -421,18 +454,19 @@ public class VirtualmetamodelEditor
* Adapter used to update the problem indication when resources are demanded loaded.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected EContentAdapter problemIndicationAdapter =
- new EContentAdapter() {
- @Override
- public void notifyChanged(Notification notification) {
- if (notification.getNotifier() instanceof Resource) {
- switch (notification.getFeatureID(Resource.class)) {
+ new EContentAdapter() {
+ @Override
+ public void notifyChanged(Notification notification) {
+ if (notification.getNotifier() instanceof Resource) {
+ switch (notification.getFeatureID(Resource.class)) {
case Resource.RESOURCE__IS_LOADED:
case Resource.RESOURCE__ERRORS:
case Resource.RESOURCE__WARNINGS: {
- Resource resource = (Resource)notification.getNotifier();
+ Resource resource = (Resource) notification.getNotifier();
Diagnostic diagnostic = analyzeResourceProblems(resource, null);
if (diagnostic.getSeverity() != Diagnostic.OK) {
resourceToDiagnosticMap.put(resource, diagnostic);
@@ -443,134 +477,142 @@ public class VirtualmetamodelEditor
if (updateProblemIndication) {
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
}
break;
}
+ }
+ }
+ else {
+ super.notifyChanged(notification);
}
}
- else {
- super.notifyChanged(notification);
- }
- }
- @Override
- protected void setTarget(Resource target) {
- basicSetTarget(target);
- }
+ @Override
+ protected void setTarget(Resource target) {
+ basicSetTarget(target);
+ }
- @Override
- protected void unsetTarget(Resource target) {
- basicUnsetTarget(target);
- resourceToDiagnosticMap.remove(target);
- if (updateProblemIndication) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ @Override
+ protected void unsetTarget(Resource target) {
+ basicUnsetTarget(target);
+ resourceToDiagnosticMap.remove(target);
+ if (updateProblemIndication) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
+ }
}
- }
- };
+ };
/**
* This listens for workspace changes.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IResourceChangeListener resourceChangeListener =
- new IResourceChangeListener() {
- public void resourceChanged(IResourceChangeEvent event) {
- IResourceDelta delta = event.getDelta();
- try {
- class ResourceDeltaVisitor implements IResourceDeltaVisitor {
- protected ResourceSet resourceSet = editingDomain.getResourceSet();
- protected Collection<Resource> changedResources = new ArrayList<Resource>();
- protected Collection<Resource> removedResources = new ArrayList<Resource>();
-
- public boolean visit(IResourceDelta delta) {
- if (delta.getResource().getType() == IResource.FILE) {
- if (delta.getKind() == IResourceDelta.REMOVED ||
- delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) {
- Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false);
- if (resource != null) {
- if (delta.getKind() == IResourceDelta.REMOVED) {
- removedResources.add(resource);
- }
- else if (!savedResources.remove(resource)) {
- changedResources.add(resource);
+ new IResourceChangeListener() {
+ @Override
+ public void resourceChanged(IResourceChangeEvent event) {
+ IResourceDelta delta = event.getDelta();
+ try {
+ class ResourceDeltaVisitor implements IResourceDeltaVisitor {
+ protected ResourceSet resourceSet = editingDomain.getResourceSet();
+ protected Collection<Resource> changedResources = new ArrayList<Resource>();
+ protected Collection<Resource> removedResources = new ArrayList<Resource>();
+
+ @Override
+ public boolean visit(IResourceDelta delta) {
+ if (delta.getResource().getType() == IResource.FILE) {
+ if (delta.getKind() == IResourceDelta.REMOVED ||
+ delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) {
+ Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false);
+ if (resource != null) {
+ if (delta.getKind() == IResourceDelta.REMOVED) {
+ removedResources.add(resource);
+ }
+ else if (!savedResources.remove(resource)) {
+ changedResources.add(resource);
+ }
}
}
+ return false;
}
- return false;
+
+ return true;
}
- return true;
- }
+ public Collection<Resource> getChangedResources() {
+ return changedResources;
+ }
- public Collection<Resource> getChangedResources() {
- return changedResources;
+ public Collection<Resource> getRemovedResources() {
+ return removedResources;
+ }
}
- public Collection<Resource> getRemovedResources() {
- return removedResources;
- }
- }
+ final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor();
+ delta.accept(visitor);
- final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor();
- delta.accept(visitor);
+ if (!visitor.getRemovedResources().isEmpty()) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ removedResources.addAll(visitor.getRemovedResources());
+ if (!isDirty()) {
+ getSite().getPage().closeEditor(VirtualmetamodelEditor.this, false);
+ }
+ }
+ });
+ }
- if (!visitor.getRemovedResources().isEmpty()) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- removedResources.addAll(visitor.getRemovedResources());
- if (!isDirty()) {
- getSite().getPage().closeEditor(VirtualmetamodelEditor.this, false);
- }
- }
- });
+ if (!visitor.getChangedResources().isEmpty()) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ changedResources.addAll(visitor.getChangedResources());
+ if (getSite().getPage().getActiveEditor() == VirtualmetamodelEditor.this) {
+ handleActivate();
+ }
+ }
+ });
+ }
}
-
- if (!visitor.getChangedResources().isEmpty()) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- changedResources.addAll(visitor.getChangedResources());
- if (getSite().getPage().getActiveEditor() == VirtualmetamodelEditor.this) {
- handleActivate();
- }
- }
- });
+ catch (CoreException exception) {
+ FacadeEditorPlugin.INSTANCE.log(exception);
}
}
- catch (CoreException exception) {
- FacadeEditorPlugin.INSTANCE.log(exception);
- }
- }
- };
+ };
/**
* Handles activation of the editor or it's associated views.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void handleActivate() {
// Recompute the read only state.
//
if (editingDomain.getResourceToReadOnlyMap() != null) {
- editingDomain.getResourceToReadOnlyMap().clear();
+ editingDomain.getResourceToReadOnlyMap().clear();
- // Refresh any actions that may become enabled or disabled.
- //
- setSelection(getSelection());
+ // Refresh any actions that may become enabled or disabled.
+ //
+ setSelection(getSelection());
}
if (!removedResources.isEmpty()) {
@@ -595,6 +637,7 @@ public class VirtualmetamodelEditor
* Handles what to do with changed resources on activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void handleChangedResources() {
@@ -610,8 +653,7 @@ public class VirtualmetamodelEditor
resource.unload();
try {
resource.load(Collections.EMPTY_MAP);
- }
- catch (IOException exception) {
+ } catch (IOException exception) {
if (!resourceToDiagnosticMap.containsKey(resource)) {
resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
}
@@ -632,17 +674,18 @@ public class VirtualmetamodelEditor
* Updates the problems indication with the information described in the specified diagnostic.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void updateProblemIndication() {
if (updateProblemIndication) {
BasicDiagnostic diagnostic =
- new BasicDiagnostic
+ new BasicDiagnostic
(Diagnostic.OK,
- "org.eclipse.papyrus.facade.editor",
- 0,
- null,
- new Object [] { editingDomain.getResourceSet() });
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ null,
+ new Object[] { editingDomain.getResourceSet() });
for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) {
if (childDiagnostic.getSeverity() != Diagnostic.OK) {
diagnostic.add(childDiagnostic);
@@ -651,7 +694,7 @@ public class VirtualmetamodelEditor
int lastEditorPage = getPageCount() - 1;
if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) {
- ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic);
+ ((ProblemEditorPart) getEditor(lastEditorPage)).setDiagnostic(diagnostic);
if (diagnostic.getSeverity() != Diagnostic.OK) {
setActivePage(lastEditorPage);
}
@@ -665,8 +708,7 @@ public class VirtualmetamodelEditor
setPageText(lastEditorPage, problemEditorPart.getPartName());
setActivePage(lastEditorPage);
showTabs();
- }
- catch (PartInitException exception) {
+ } catch (PartInitException exception) {
FacadeEditorPlugin.INSTANCE.log(exception);
}
}
@@ -676,8 +718,7 @@ public class VirtualmetamodelEditor
if (diagnostic.getSeverity() != Diagnostic.OK) {
try {
markerHelper.createMarkers(diagnostic);
- }
- catch (CoreException exception) {
+ } catch (CoreException exception) {
FacadeEditorPlugin.INSTANCE.log(exception);
}
}
@@ -689,20 +730,21 @@ public class VirtualmetamodelEditor
* Shows a dialog that asks if conflicting changes should be discarded.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean handleDirtyConflict() {
- return
- MessageDialog.openQuestion
+ return MessageDialog.openQuestion
(getSite().getShell(),
- getString("_UI_FileConflict_label"),
- getString("_WARN_FileConflict"));
+ getString("_UI_FileConflict_label"),
+ getString("_WARN_FileConflict"));
}
/**
* This creates a model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelEditor() {
@@ -714,6 +756,7 @@ public class VirtualmetamodelEditor
* This sets up the editing domain for the model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void initializeEditingDomain() {
@@ -736,32 +779,34 @@ public class VirtualmetamodelEditor
// Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus.
//
commandStack.addCommandStackListener
- (new CommandStackListener() {
- public void commandStackChanged(final EventObject event) {
- getContainer().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- firePropertyChange(IEditorPart.PROP_DIRTY);
-
- // Try to select the affected objects.
- //
- Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand();
- if (mostRecentCommand != null) {
- setSelectionToViewer(mostRecentCommand.getAffectedObjects());
- }
- for (Iterator<PropertySheetPage> i = propertySheetPages.iterator(); i.hasNext(); ) {
- PropertySheetPage propertySheetPage = i.next();
- if (propertySheetPage.getControl().isDisposed()) {
- i.remove();
- }
- else {
- propertySheetPage.refresh();
- }
- }
- }
- });
- }
- });
+ (new CommandStackListener() {
+ @Override
+ public void commandStackChanged(final EventObject event) {
+ getContainer().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ firePropertyChange(IEditorPart.PROP_DIRTY);
+
+ // Try to select the affected objects.
+ //
+ Command mostRecentCommand = ((CommandStack) event.getSource()).getMostRecentCommand();
+ if (mostRecentCommand != null) {
+ setSelectionToViewer(mostRecentCommand.getAffectedObjects());
+ }
+ for (Iterator<PropertySheetPage> i = propertySheetPages.iterator(); i.hasNext();) {
+ PropertySheetPage propertySheetPage = i.next();
+ if (propertySheetPage.getControl().isDisposed()) {
+ i.remove();
+ }
+ else {
+ propertySheetPage.refresh();
+ }
+ }
+ }
+ });
+ }
+ });
// Create the editing domain with a special command stack.
//
@@ -772,9 +817,10 @@ public class VirtualmetamodelEditor
* This is here for the listener to be able to call it.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
- @Override
+ @Override
protected void firePropertyChange(int action) {
super.firePropertyChange(action);
}
@@ -783,6 +829,7 @@ public class VirtualmetamodelEditor
* This sets the selection into whichever viewer is active.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setSelectionToViewer(Collection<?> collection) {
@@ -791,27 +838,29 @@ public class VirtualmetamodelEditor
//
if (theSelection != null && !theSelection.isEmpty()) {
Runnable runnable =
- new Runnable() {
- public void run() {
- // Try to select the items in the current content viewer of the editor.
- //
- if (currentViewer != null) {
- currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true);
+ new Runnable() {
+ @Override
+ public void run() {
+ // Try to select the items in the current content viewer of the editor.
+ //
+ if (currentViewer != null) {
+ currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true);
+ }
}
- }
- };
+ };
getSite().getShell().getDisplay().asyncExec(runnable);
}
}
/**
* This returns the editing domain as required by the {@link IEditingDomainProvider} interface.
- * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain}
- * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}.
+ * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EditingDomain getEditingDomain() {
return editingDomain;
}
@@ -819,12 +868,14 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) {
@@ -834,10 +885,11 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
- public Object [] getElements(Object object) {
+ public Object[] getElements(Object object) {
Object parent = super.getParent(object);
return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray();
}
@@ -845,10 +897,11 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
- public Object [] getChildren(Object object) {
+ public Object[] getChildren(Object object) {
Object parent = super.getParent(object);
return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray();
}
@@ -856,6 +909,7 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -867,6 +921,7 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -878,6 +933,7 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setCurrentViewerPane(ViewerPane viewerPane) {
@@ -895,6 +951,7 @@ public class VirtualmetamodelEditor
* is the current one.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setCurrentViewer(Viewer viewer) {
@@ -905,13 +962,14 @@ public class VirtualmetamodelEditor
// Create the listener on demand.
//
selectionChangedListener =
- new ISelectionChangedListener() {
- // This just notifies those things that are affected by the section.
- //
- public void selectionChanged(SelectionChangedEvent selectionChangedEvent) {
- setSelection(selectionChangedEvent.getSelection());
- }
- };
+ new ISelectionChangedListener() {
+ // This just notifies those things that are affected by the section.
+ //
+ @Override
+ public void selectionChanged(SelectionChangedEvent selectionChangedEvent) {
+ setSelection(selectionChangedEvent.getSelection());
+ }
+ };
}
// Stop listening to the old one.
@@ -940,8 +998,10 @@ public class VirtualmetamodelEditor
* This returns the viewer as required by the {@link IViewerProvider} interface.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Viewer getViewer() {
return currentViewer;
}
@@ -950,6 +1010,7 @@ public class VirtualmetamodelEditor
* This creates a context menu for the viewer and adds a listener as well registering the menu for extension.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void createContextMenuFor(StructuredViewer viewer) {
@@ -957,7 +1018,7 @@ public class VirtualmetamodelEditor
contextMenu.add(new Separator("additions"));
contextMenu.setRemoveAllWhenShown(true);
contextMenu.addMenuListener(this);
- Menu menu= contextMenu.createContextMenu(viewer.getControl());
+ Menu menu = contextMenu.createContextMenu(viewer.getControl());
viewer.getControl().setMenu(menu);
getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer));
@@ -971,6 +1032,7 @@ public class VirtualmetamodelEditor
* This is the method called to load a resource into the editing domain's resource set based on the editor's input.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void createModel() {
@@ -981,15 +1043,14 @@ public class VirtualmetamodelEditor
// Load the resource through the editing domain.
//
resource = editingDomain.getResourceSet().getResource(resourceURI, true);
- }
- catch (Exception e) {
+ } catch (Exception e) {
exception = e;
resource = editingDomain.getResourceSet().getResource(resourceURI, false);
}
Diagnostic diagnostic = analyzeResourceProblems(resource, exception);
if (diagnostic.getSeverity() != Diagnostic.OK) {
- resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
+ resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
}
editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter);
}
@@ -999,28 +1060,27 @@ public class VirtualmetamodelEditor
* and the specified exception (if any).
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) {
if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) {
BasicDiagnostic basicDiagnostic =
- new BasicDiagnostic
+ new BasicDiagnostic
(Diagnostic.ERROR,
- "org.eclipse.papyrus.facade.editor",
- 0,
- getString("_UI_CreateModelError_message", resource.getURI()),
- new Object [] { exception == null ? (Object)resource : exception });
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ getString("_UI_CreateModelError_message", resource.getURI()),
+ new Object[] { exception == null ? (Object) resource : exception });
basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true));
return basicDiagnostic;
}
else if (exception != null) {
- return
- new BasicDiagnostic
- (Diagnostic.ERROR,
- "org.eclipse.papyrus.facade.editor",
- 0,
- getString("_UI_CreateModelError_message", resource.getURI()),
- new Object[] { exception });
+ return new BasicDiagnostic(Diagnostic.ERROR,
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ getString("_UI_CreateModelError_message", resource.getURI()),
+ new Object[] { exception });
}
else {
return Diagnostic.OK_INSTANCE;
@@ -1031,6 +1091,7 @@ public class VirtualmetamodelEditor
* This is the method used by the framework to install your own controls.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1046,22 +1107,23 @@ public class VirtualmetamodelEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- Tree tree = new Tree(composite, SWT.MULTI);
- TreeViewer newTreeViewer = new TreeViewer(tree);
- return newTreeViewer;
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ Tree tree = new Tree(composite, SWT.MULTI);
+ TreeViewer newTreeViewer = new TreeViewer(tree);
+ return newTreeViewer;
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- selectionViewer = (TreeViewer)viewerPane.getViewer();
+ selectionViewer = (TreeViewer) viewerPane.getViewer();
selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1080,22 +1142,23 @@ public class VirtualmetamodelEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- Tree tree = new Tree(composite, SWT.MULTI);
- TreeViewer newTreeViewer = new TreeViewer(tree);
- return newTreeViewer;
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ Tree tree = new Tree(composite, SWT.MULTI);
+ TreeViewer newTreeViewer = new TreeViewer(tree);
+ return newTreeViewer;
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- parentViewer = (TreeViewer)viewerPane.getViewer();
+ parentViewer = (TreeViewer) viewerPane.getViewer();
parentViewer.setAutoExpandLevel(30);
parentViewer.setContentProvider(new ReverseAdapterFactoryContentProvider(adapterFactory));
parentViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1109,19 +1172,20 @@ public class VirtualmetamodelEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new ListViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new ListViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- listViewer = (ListViewer)viewerPane.getViewer();
+ listViewer = (ListViewer) viewerPane.getViewer();
listViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
listViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1134,19 +1198,20 @@ public class VirtualmetamodelEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TreeViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TreeViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- treeViewer = (TreeViewer)viewerPane.getViewer();
+ treeViewer = (TreeViewer) viewerPane.getViewer();
treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
treeViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1161,19 +1226,20 @@ public class VirtualmetamodelEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TableViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TableViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- tableViewer = (TableViewer)viewerPane.getViewer();
+ tableViewer = (TableViewer) viewerPane.getViewer();
Table table = tableViewer.getTable();
TableLayout layout = new TableLayout();
@@ -1191,7 +1257,7 @@ public class VirtualmetamodelEditor
selfColumn.setText(getString("_UI_SelfColumn_label"));
selfColumn.setResizable(true);
- tableViewer.setColumnProperties(new String [] {"a", "b"});
+ tableViewer.setColumnProperties(new String[] { "a", "b" });
tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1204,20 +1270,21 @@ public class VirtualmetamodelEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TreeViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), VirtualmetamodelEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TreeViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- treeViewerWithColumns = (TreeViewer)viewerPane.getViewer();
+ treeViewerWithColumns = (TreeViewer) viewerPane.getViewer();
Tree tree = treeViewerWithColumns.getTree();
tree.setLayoutData(new FillLayout());
@@ -1234,7 +1301,7 @@ public class VirtualmetamodelEditor
selfColumn.setResizable(true);
selfColumn.setWidth(200);
- treeViewerWithColumns.setColumnProperties(new String [] {"a", "b"});
+ treeViewerWithColumns.setColumnProperties(new String[] { "a", "b" });
treeViewerWithColumns.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
treeViewerWithColumns.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1244,35 +1311,38 @@ public class VirtualmetamodelEditor
}
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- setActivePage(0);
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ setActivePage(0);
+ }
+ });
}
// Ensures that this editor will only display the page's tab
// area if there are more than one page
//
getContainer().addControlListener
- (new ControlAdapter() {
- boolean guard = false;
- @Override
- public void controlResized(ControlEvent event) {
- if (!guard) {
- guard = true;
- hideTabs();
- guard = false;
+ (new ControlAdapter() {
+ boolean guard = false;
+
+ @Override
+ public void controlResized(ControlEvent event) {
+ if (!guard) {
+ guard = true;
+ hideTabs();
+ guard = false;
+ }
}
- }
- });
+ });
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
}
/**
@@ -1280,13 +1350,14 @@ public class VirtualmetamodelEditor
* this hides the single tab at the bottom.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void hideTabs() {
if (getPageCount() <= 1) {
setPageText(0, "");
if (getContainer() instanceof CTabFolder) {
- ((CTabFolder)getContainer()).setTabHeight(1);
+ ((CTabFolder) getContainer()).setTabHeight(1);
Point point = getContainer().getSize();
getContainer().setSize(point.x, point.y + 6);
}
@@ -1298,13 +1369,14 @@ public class VirtualmetamodelEditor
* this shows the tabs at the bottom.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void showTabs() {
if (getPageCount() > 1) {
setPageText(0, getString("_UI_SelectionPage_label"));
if (getContainer() instanceof CTabFolder) {
- ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT);
+ ((CTabFolder) getContainer()).setTabHeight(SWT.DEFAULT);
Point point = getContainer().getSize();
getContainer().setSize(point.x, point.y - 6);
}
@@ -1315,6 +1387,7 @@ public class VirtualmetamodelEditor
* This is used to track the active viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1330,6 +1403,7 @@ public class VirtualmetamodelEditor
* This is how the framework determines which interfaces we implement.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("rawtypes")
@@ -1353,6 +1427,7 @@ public class VirtualmetamodelEditor
* This accesses a cached version of the content outliner.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IContentOutlinePage getContentOutlinePage() {
@@ -1377,9 +1452,9 @@ public class VirtualmetamodelEditor
createContextMenuFor(contentOutlineViewer);
if (!editingDomain.getResourceSet().getResources().isEmpty()) {
- // Select the root object in the view.
- //
- contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true);
+ // Select the root object in the view.
+ //
+ contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true);
}
}
@@ -1401,13 +1476,14 @@ public class VirtualmetamodelEditor
// Listen to selection so that we can handle it is a special way.
//
contentOutlinePage.addSelectionChangedListener
- (new ISelectionChangedListener() {
- // This ensures that we handle selections correctly.
- //
- public void selectionChanged(SelectionChangedEvent event) {
- handleContentOutlineSelection(event.getSelection());
- }
- });
+ (new ISelectionChangedListener() {
+ // This ensures that we handle selections correctly.
+ //
+ @Override
+ public void selectionChanged(SelectionChangedEvent event) {
+ handleContentOutlineSelection(event.getSelection());
+ }
+ });
}
return contentOutlinePage;
@@ -1417,23 +1493,24 @@ public class VirtualmetamodelEditor
* This accesses a cached version of the property sheet.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IPropertySheetPage getPropertySheetPage() {
PropertySheetPage propertySheetPage =
- new ExtendedPropertySheetPage(editingDomain) {
- @Override
- public void setSelectionToViewer(List<?> selection) {
- VirtualmetamodelEditor.this.setSelectionToViewer(selection);
- VirtualmetamodelEditor.this.setFocus();
- }
+ new ExtendedPropertySheetPage(editingDomain) {
+ @Override
+ public void setSelectionToViewer(List<?> selection) {
+ VirtualmetamodelEditor.this.setSelectionToViewer(selection);
+ VirtualmetamodelEditor.this.setFocus();
+ }
- @Override
- public void setActionBars(IActionBars actionBars) {
- super.setActionBars(actionBars);
- getActionBarContributor().shareGlobalActions(this, actionBars);
- }
- };
+ @Override
+ public void setActionBars(IActionBars actionBars) {
+ super.setActionBars(actionBars);
+ getActionBarContributor().shareGlobalActions(this, actionBars);
+ }
+ };
propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory));
propertySheetPages.add(propertySheetPage);
@@ -1444,11 +1521,12 @@ public class VirtualmetamodelEditor
* This deals with how we want selection in the outliner to affect the other views.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void handleContentOutlineSelection(ISelection selection) {
if (currentViewerPane != null && !selection.isEmpty() && selection instanceof IStructuredSelection) {
- Iterator<?> selectedElements = ((IStructuredSelection)selection).iterator();
+ Iterator<?> selectedElements = ((IStructuredSelection) selection).iterator();
if (selectedElements.hasNext()) {
// Get the first selected element.
//
@@ -1483,17 +1561,19 @@ public class VirtualmetamodelEditor
* This is for implementing {@link IEditorPart} and simply tests the command stack.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean isDirty() {
- return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded();
+ return ((BasicCommandStack) editingDomain.getCommandStack()).isSaveNeeded();
}
/**
* This is for implementing {@link IEditorPart} and simply saves the model file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1507,31 +1587,31 @@ public class VirtualmetamodelEditor
// Do the work within an operation because this is a long running activity that modifies the workbench.
//
WorkspaceModifyOperation operation =
- new WorkspaceModifyOperation() {
- // This is the method that gets invoked when the operation runs.
- //
- @Override
- public void execute(IProgressMonitor monitor) {
- // Save the resources to the file system.
+ new WorkspaceModifyOperation() {
+ // This is the method that gets invoked when the operation runs.
//
- boolean first = true;
- for (Resource resource : editingDomain.getResourceSet().getResources()) {
- if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) {
- try {
- long timeStamp = resource.getTimeStamp();
- resource.save(saveOptions);
- if (resource.getTimeStamp() != timeStamp) {
- savedResources.add(resource);
+ @Override
+ public void execute(IProgressMonitor monitor) {
+ // Save the resources to the file system.
+ //
+ boolean first = true;
+ for (Resource resource : editingDomain.getResourceSet().getResources()) {
+ if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) {
+ try {
+ long timeStamp = resource.getTimeStamp();
+ resource.save(saveOptions);
+ if (resource.getTimeStamp() != timeStamp) {
+ savedResources.add(resource);
+ }
}
+ catch (Exception exception) {
+ resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
+ }
+ first = false;
}
- catch (Exception exception) {
- resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
- }
- first = false;
}
}
- }
- };
+ };
updateProblemIndication = false;
try {
@@ -1541,10 +1621,9 @@ public class VirtualmetamodelEditor
// Refresh the necessary state.
//
- ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone();
+ ((BasicCommandStack) editingDomain.getCommandStack()).saveIsDone();
firePropertyChange(IEditorPart.PROP_DIRTY);
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
// Something went wrong that shouldn't.
//
FacadeEditorPlugin.INSTANCE.log(exception);
@@ -1558,6 +1637,7 @@ public class VirtualmetamodelEditor
* The implementation uses the URI converter from the editor's resource set to try to open an input stream.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean isPersisted(Resource resource) {
@@ -1568,8 +1648,7 @@ public class VirtualmetamodelEditor
result = true;
stream.close();
}
- }
- catch (IOException e) {
+ } catch (IOException e) {
// Ignore
}
return result;
@@ -1579,6 +1658,7 @@ public class VirtualmetamodelEditor
* This always returns true because it is not currently supported.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1590,6 +1670,7 @@ public class VirtualmetamodelEditor
* This also changes the editor's input.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1608,6 +1689,7 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void doSaveAs(URI uri, IEditorInput editorInput) {
@@ -1615,17 +1697,19 @@ public class VirtualmetamodelEditor
setInputWithNotify(editorInput);
setPartName(editorInput.getName());
IProgressMonitor progressMonitor =
- getActionBars().getStatusLineManager() != null ?
- getActionBars().getStatusLineManager().getProgressMonitor() :
- new NullProgressMonitor();
+ getActionBars().getStatusLineManager() != null ?
+ getActionBars().getStatusLineManager().getProgressMonitor() :
+ new NullProgressMonitor();
doSave(progressMonitor);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void gotoMarker(IMarker marker) {
List<?> targetObjects = markerHelper.getTargetObjects(editingDomain, marker);
if (!targetObjects.isEmpty()) {
@@ -1637,6 +1721,7 @@ public class VirtualmetamodelEditor
* This is called during startup.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1652,6 +1737,7 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1668,8 +1754,10 @@ public class VirtualmetamodelEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void addSelectionChangedListener(ISelectionChangedListener listener) {
selectionChangedListeners.add(listener);
}
@@ -1678,8 +1766,10 @@ public class VirtualmetamodelEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void removeSelectionChangedListener(ISelectionChangedListener listener) {
selectionChangedListeners.remove(listener);
}
@@ -1688,8 +1778,10 @@ public class VirtualmetamodelEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ISelection getSelection() {
return editorSelection;
}
@@ -1699,8 +1791,10 @@ public class VirtualmetamodelEditor
* Calling this result will notify the listeners.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setSelection(ISelection selection) {
editorSelection = selection;
@@ -1713,29 +1807,30 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setStatusLineManager(ISelection selection) {
IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ?
- contentOutlineStatusLineManager : getActionBars().getStatusLineManager();
+ contentOutlineStatusLineManager : getActionBars().getStatusLineManager();
if (statusLineManager != null) {
if (selection instanceof IStructuredSelection) {
- Collection<?> collection = ((IStructuredSelection)selection).toList();
+ Collection<?> collection = ((IStructuredSelection) selection).toList();
switch (collection.size()) {
- case 0: {
- statusLineManager.setMessage(getString("_UI_NoObjectSelected"));
- break;
- }
- case 1: {
- String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next());
- statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text));
- break;
- }
- default: {
- statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size())));
- break;
- }
+ case 0: {
+ statusLineManager.setMessage(getString("_UI_NoObjectSelected"));
+ break;
+ }
+ case 1: {
+ String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next());
+ statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text));
+ break;
+ }
+ default: {
+ statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size())));
+ break;
+ }
}
}
else {
@@ -1748,6 +1843,7 @@ public class VirtualmetamodelEditor
* This looks up a string in the plugin's plugin.properties file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static String getString(String key) {
@@ -1758,34 +1854,39 @@ public class VirtualmetamodelEditor
* This looks up a string in plugin.properties, making a substitution.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static String getString(String key, Object s1) {
- return FacadeEditorPlugin.INSTANCE.getString(key, new Object [] { s1 });
+ return FacadeEditorPlugin.INSTANCE.getString(key, new Object[] { s1 });
}
/**
* This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void menuAboutToShow(IMenuManager menuManager) {
- ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager);
+ ((IMenuListener) getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public EditingDomainActionBarContributor getActionBarContributor() {
- return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor();
+ return (EditingDomainActionBarContributor) getEditorSite().getActionBarContributor();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IActionBars getActionBars() {
@@ -1795,6 +1896,7 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public AdapterFactory getAdapterFactory() {
@@ -1804,6 +1906,7 @@ public class VirtualmetamodelEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1835,6 +1938,7 @@ public class VirtualmetamodelEditor
* Returns whether the outline view should be presented to the user.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean showOutlineView() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelModelWizard.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelModelWizard.java
index bf18db68a5b..fdf39ac3ee9 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelModelWizard.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facade/virtualmetamodel/presentation/VirtualmetamodelModelWizard.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -84,7 +84,6 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelFactory;
import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
import org.eclipse.papyrus.facade.provider.FacadeEditPlugin;
-
import org.eclipse.core.runtime.Path;
import org.eclipse.jface.viewers.ISelection;
@@ -102,6 +101,7 @@ import org.eclipse.ui.PartInitException;
* This is a simple wizard for creating a new model file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
@@ -109,24 +109,27 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* The supported extensions for created files.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final List<String> FILE_EXTENSIONS =
- Collections.unmodifiableList(Arrays.asList(FacadeEditorPlugin.INSTANCE.getString("_UI_VirtualmetamodelEditorFilenameExtensions").split("\\s*,\\s*")));
+ Collections.unmodifiableList(Arrays.asList(FacadeEditorPlugin.INSTANCE.getString("_UI_VirtualmetamodelEditorFilenameExtensions").split("\\s*,\\s*")));
/**
* A formatted list of supported file extensions, suitable for display.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final String FORMATTED_FILE_EXTENSIONS =
- FacadeEditorPlugin.INSTANCE.getString("_UI_VirtualmetamodelEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", ");
+ FacadeEditorPlugin.INSTANCE.getString("_UI_VirtualmetamodelEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", ");
/**
* This caches an instance of the model package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualmetamodelPackage virtualmetamodelPackage = VirtualmetamodelPackage.eINSTANCE;
@@ -135,6 +138,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* This caches an instance of the model factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualmetamodelFactory virtualmetamodelFactory = virtualmetamodelPackage.getVirtualmetamodelFactory();
@@ -143,6 +147,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* This is the file creation page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualmetamodelModelWizardNewFileCreationPage newFileCreationPage;
@@ -151,6 +156,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* This is the initial object creation page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualmetamodelModelWizardInitialObjectCreationPage initialObjectCreationPage;
@@ -159,6 +165,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Remember the selection during initialization for populating the default container.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IStructuredSelection selection;
@@ -167,6 +174,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Remember the workbench during initialization.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IWorkbench workbench;
@@ -175,6 +183,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Caches the names of the types that can be created as the root object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected List<String> initialObjectNames;
@@ -183,8 +192,10 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* This just records the information.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void init(IWorkbench workbench, IStructuredSelection selection) {
this.workbench = workbench;
this.selection = selection;
@@ -196,6 +207,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Returns the names of the types that can be created as the root object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<String> getInitialObjectNames() {
@@ -203,7 +215,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
initialObjectNames = new ArrayList<String>();
for (EClassifier eClassifier : virtualmetamodelPackage.getEClassifiers()) {
if (eClassifier instanceof EClass) {
- EClass eClass = (EClass)eClassifier;
+ EClass eClass = (EClass) eClassifier;
if (!eClass.isAbstract()) {
initialObjectNames.add(eClass.getName());
}
@@ -218,10 +230,11 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Create a new model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected EObject createInitialModel() {
- EClass eClass = (EClass)virtualmetamodelPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName());
+ EClass eClass = (EClass) virtualmetamodelPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName());
EObject rootObject = virtualmetamodelFactory.create(eClass);
return rootObject;
}
@@ -230,6 +243,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Do the work after everything is specified.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -242,43 +256,43 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
// Do the work within an operation.
//
WorkspaceModifyOperation operation =
- new WorkspaceModifyOperation() {
- @Override
- protected void execute(IProgressMonitor progressMonitor) {
- try {
- // Create a resource set
- //
- ResourceSet resourceSet = new ResourceSetImpl();
-
- // Get the URI of the model file.
- //
- URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true);
-
- // Create a resource for this file.
- //
- Resource resource = resourceSet.createResource(fileURI);
-
- // Add the initial model object to the contents.
- //
- EObject rootObject = createInitialModel();
- if (rootObject != null) {
- resource.getContents().add(rootObject);
+ new WorkspaceModifyOperation() {
+ @Override
+ protected void execute(IProgressMonitor progressMonitor) {
+ try {
+ // Create a resource set
+ //
+ ResourceSet resourceSet = new ResourceSetImpl();
+
+ // Get the URI of the model file.
+ //
+ URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true);
+
+ // Create a resource for this file.
+ //
+ Resource resource = resourceSet.createResource(fileURI);
+
+ // Add the initial model object to the contents.
+ //
+ EObject rootObject = createInitialModel();
+ if (rootObject != null) {
+ resource.getContents().add(rootObject);
+ }
+
+ // Save the contents of the resource to the file system.
+ //
+ Map<Object, Object> options = new HashMap<Object, Object>();
+ options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding());
+ resource.save(options);
+ }
+ catch (Exception exception) {
+ FacadeEditorPlugin.INSTANCE.log(exception);
+ }
+ finally {
+ progressMonitor.done();
}
-
- // Save the contents of the resource to the file system.
- //
- Map<Object, Object> options = new HashMap<Object, Object>();
- options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding());
- resource.save(options);
- }
- catch (Exception exception) {
- FacadeEditorPlugin.INSTANCE.log(exception);
- }
- finally {
- progressMonitor.done();
}
- }
- };
+ };
getContainer().run(false, false, operation);
@@ -290,28 +304,27 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
if (activePart instanceof ISetSelectionTarget) {
final ISelection targetSelection = new StructuredSelection(modelFile);
getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- ((ISetSelectionTarget)activePart).selectReveal(targetSelection);
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ ((ISetSelectionTarget) activePart).selectReveal(targetSelection);
+ }
+ });
}
// Open an editor on the new file.
//
try {
page.openEditor
- (new FileEditorInput(modelFile),
- workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId());
- }
- catch (PartInitException exception) {
+ (new FileEditorInput(modelFile),
+ workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId());
+ } catch (PartInitException exception) {
MessageDialog.openError(workbenchWindow.getShell(), FacadeEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage());
return false;
}
return true;
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
FacadeEditorPlugin.INSTANCE.log(exception);
return false;
}
@@ -321,6 +334,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* This is the one page of the wizard.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualmetamodelModelWizardNewFileCreationPage extends WizardNewFileCreationPage {
@@ -328,6 +342,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Pass in the selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) {
@@ -338,6 +353,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* The framework calls this to see if the file is correct.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -346,7 +362,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
String extension = new Path(getFileName()).getFileExtension();
if (extension == null || !FILE_EXTENSIONS.contains(extension)) {
String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension";
- setErrorMessage(FacadeEditorPlugin.INSTANCE.getString(key, new Object [] { FORMATTED_FILE_EXTENSIONS }));
+ setErrorMessage(FacadeEditorPlugin.INSTANCE.getString(key, new Object[] { FORMATTED_FILE_EXTENSIONS }));
return false;
}
return true;
@@ -357,6 +373,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IFile getModelFile() {
@@ -368,26 +385,29 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* This is the page where the type of object to create is selected.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualmetamodelModelWizardInitialObjectCreationPage extends WizardPage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Combo initialObjectField;
/**
* @generated
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
*/
protected List<String> encodings;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Combo encodingField;
@@ -396,6 +416,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Pass in the selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelModelWizardInitialObjectCreationPage(String pageId) {
@@ -405,10 +426,13 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void createControl(Composite parent) {
- Composite composite = new Composite(parent, SWT.NONE); {
+ Composite composite = new Composite(parent, SWT.NONE);
+ {
GridLayout layout = new GridLayout();
layout.numColumns = 1;
layout.verticalSpacing = 12;
@@ -477,18 +501,21 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ModifyListener validator =
- new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- setPageComplete(validatePage());
- }
- };
+ new ModifyListener() {
+ @Override
+ public void modifyText(ModifyEvent e) {
+ setPageComplete(validatePage());
+ }
+ };
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean validatePage() {
@@ -498,6 +525,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -518,6 +546,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String getInitialObjectName() {
@@ -534,6 +563,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String getEncoding() {
@@ -544,13 +574,13 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Returns the label for the specified type name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected String getLabel(String typeName) {
try {
return FacadeEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type");
- }
- catch(MissingResourceException mre) {
+ } catch (MissingResourceException mre) {
FacadeEditorPlugin.INSTANCE.log(mre);
}
return typeName;
@@ -559,12 +589,13 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<String> getEncodings() {
if (encodings == null) {
encodings = new ArrayList<String>();
- for (StringTokenizer stringTokenizer = new StringTokenizer(FacadeEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens(); ) {
+ for (StringTokenizer stringTokenizer = new StringTokenizer(FacadeEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens();) {
encodings.add(stringTokenizer.nextToken());
}
}
@@ -576,9 +607,10 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* The framework calls this to create the contents of the wizard.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
- @Override
+ @Override
public void addPages() {
// Create a page, set the title, and the initial model file name.
//
@@ -597,7 +629,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
if (selectedElement instanceof IResource) {
// Get the resource parent, if its a file.
//
- IResource selectedResource = (IResource)selectedElement;
+ IResource selectedResource = (IResource) selectedElement;
if (selectedResource.getType() == IResource.FILE) {
selectedResource = selectedResource.getParent();
}
@@ -614,7 +646,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
String defaultModelBaseFilename = FacadeEditorPlugin.INSTANCE.getString("_UI_VirtualmetamodelEditorFilenameDefaultBase");
String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0);
String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension;
- for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) {
+ for (int i = 1; ((IContainer) selectedResource).findMember(modelFilename) != null; ++i) {
modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension;
}
newFileCreationPage.setFileName(modelFilename);
@@ -631,6 +663,7 @@ public class VirtualmetamodelModelWizard extends Wizard implements INewWizard {
* Get the file from the page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IFile getModelFile() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingActionBarContributor.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingActionBarContributor.java
index 3bb39a269d2..6c4fae0fff4 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingActionBarContributor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingActionBarContributor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -54,15 +54,17 @@ import org.eclipse.ui.PartInitException;
* This is the action bar contributor for the Facademapping model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacademappingActionBarContributor
- extends EditingDomainActionBarContributor
- implements ISelectionChangedListener {
+ extends EditingDomainActionBarContributor
+ implements ISelectionChangedListener {
/**
* This keeps track of the active editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IEditorPart activeEditorPart;
@@ -71,6 +73,7 @@ public class FacademappingActionBarContributor
* This keeps track of the current selection provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelectionProvider selectionProvider;
@@ -79,51 +82,54 @@ public class FacademappingActionBarContributor
* This action opens the Properties view.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IAction showPropertiesViewAction =
- new Action(FacademappingEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) {
- @Override
- public void run() {
- try {
- getPage().showView("org.eclipse.ui.views.PropertySheet");
- }
- catch (PartInitException exception) {
- FacademappingEditorPlugin.INSTANCE.log(exception);
+ new Action(FacademappingEditorPlugin.INSTANCE.getString("_UI_ShowPropertiesView_menu_item")) {
+ @Override
+ public void run() {
+ try {
+ getPage().showView("org.eclipse.ui.views.PropertySheet");
+ }
+ catch (PartInitException exception) {
+ FacademappingEditorPlugin.INSTANCE.log(exception);
+ }
}
- }
- };
+ };
/**
* This action refreshes the viewer of the current editor if the editor
* implements {@link org.eclipse.emf.common.ui.viewer.IViewerProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IAction refreshViewerAction =
- new Action(FacademappingEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) {
- @Override
- public boolean isEnabled() {
- return activeEditorPart instanceof IViewerProvider;
- }
+ new Action(FacademappingEditorPlugin.INSTANCE.getString("_UI_RefreshViewer_menu_item")) {
+ @Override
+ public boolean isEnabled() {
+ return activeEditorPart instanceof IViewerProvider;
+ }
- @Override
- public void run() {
- if (activeEditorPart instanceof IViewerProvider) {
- Viewer viewer = ((IViewerProvider)activeEditorPart).getViewer();
- if (viewer != null) {
- viewer.refresh();
+ @Override
+ public void run() {
+ if (activeEditorPart instanceof IViewerProvider) {
+ Viewer viewer = ((IViewerProvider) activeEditorPart).getViewer();
+ if (viewer != null) {
+ viewer.refresh();
+ }
}
}
- }
- };
+ };
/**
* This will contain one {@link org.eclipse.emf.edit.ui.action.CreateChildAction} corresponding to each descriptor
* generated for the current selection by the item provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> createChildActions;
@@ -132,6 +138,7 @@ public class FacademappingActionBarContributor
* This is the menu manager into which menu contribution items should be added for CreateChild actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IMenuManager createChildMenuManager;
@@ -141,6 +148,7 @@ public class FacademappingActionBarContributor
* generated for the current selection by the item provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> createSiblingActions;
@@ -149,6 +157,7 @@ public class FacademappingActionBarContributor
* This is the menu manager into which menu contribution items should be added for CreateSibling actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IMenuManager createSiblingMenuManager;
@@ -157,6 +166,7 @@ public class FacademappingActionBarContributor
* This creates an instance of the contributor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingActionBarContributor() {
@@ -170,6 +180,7 @@ public class FacademappingActionBarContributor
* This adds Separators for editor additions to the tool bar.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -183,6 +194,7 @@ public class FacademappingActionBarContributor
* as well as the sub-menus for object creation items.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -209,11 +221,12 @@ public class FacademappingActionBarContributor
// Force an update because Eclipse hides empty menus now.
//
submenuManager.addMenuListener
- (new IMenuListener() {
- public void menuAboutToShow(IMenuManager menuManager) {
- menuManager.updateAll(true);
- }
- });
+ (new IMenuListener() {
+ @Override
+ public void menuAboutToShow(IMenuManager menuManager) {
+ menuManager.updateAll(true);
+ }
+ });
addGlobalActions(submenuManager);
}
@@ -222,6 +235,7 @@ public class FacademappingActionBarContributor
* When the active editor changes, this remembers the change and registers with it as a selection provider.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -255,8 +269,10 @@ public class FacademappingActionBarContributor
* that can be added to the selected object and updating the menus accordingly.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void selectionChanged(SelectionChangedEvent event) {
// Remove any menu items for old selection.
//
@@ -273,10 +289,10 @@ public class FacademappingActionBarContributor
Collection<?> newSiblingDescriptors = null;
ISelection selection = event.getSelection();
- if (selection instanceof IStructuredSelection && ((IStructuredSelection)selection).size() == 1) {
- Object object = ((IStructuredSelection)selection).getFirstElement();
+ if (selection instanceof IStructuredSelection && ((IStructuredSelection) selection).size() == 1) {
+ Object object = ((IStructuredSelection) selection).getFirstElement();
- EditingDomain domain = ((IEditingDomainProvider)activeEditorPart).getEditingDomain();
+ EditingDomain domain = ((IEditingDomainProvider) activeEditorPart).getEditingDomain();
newChildDescriptors = domain.getNewChildDescriptors(object, null);
newSiblingDescriptors = domain.getNewChildDescriptors(null, object);
@@ -302,6 +318,7 @@ public class FacademappingActionBarContributor
* and returns the collection of these actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> generateCreateChildActions(Collection<?> descriptors, ISelection selection) {
@@ -319,6 +336,7 @@ public class FacademappingActionBarContributor
* and returns the collection of these actions.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<IAction> generateCreateSiblingActions(Collection<?> descriptors, ISelection selection) {
@@ -338,6 +356,7 @@ public class FacademappingActionBarContributor
* If <code>contributionID</code> is <code>null</code>, they are simply added.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void populateManager(IContributionManager manager, Collection<? extends IAction> actions, String contributionID) {
@@ -352,12 +371,13 @@ public class FacademappingActionBarContributor
}
}
}
-
+
/**
* This removes from the specified <code>manager</code> all {@link org.eclipse.jface.action.ActionContributionItem}s
* based on the {@link org.eclipse.jface.action.IAction}s contained in the <code>actions</code> collection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void depopulateManager(IContributionManager manager, Collection<? extends IAction> actions) {
@@ -368,13 +388,13 @@ public class FacademappingActionBarContributor
//
IContributionItem contributionItem = items[i];
while (contributionItem instanceof SubContributionItem) {
- contributionItem = ((SubContributionItem)contributionItem).getInnerItem();
+ contributionItem = ((SubContributionItem) contributionItem).getInnerItem();
}
// Delete the ActionContributionItems with matching action.
//
if (contributionItem instanceof ActionContributionItem) {
- IAction action = ((ActionContributionItem)contributionItem).getAction();
+ IAction action = ((ActionContributionItem) contributionItem).getAction();
if (actions.contains(action)) {
manager.remove(contributionItem);
}
@@ -387,6 +407,7 @@ public class FacademappingActionBarContributor
* This populates the pop-up menu before it appears.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -407,6 +428,7 @@ public class FacademappingActionBarContributor
* This inserts global actions before the "additions-end" separator.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -414,7 +436,7 @@ public class FacademappingActionBarContributor
menuManager.insertAfter("additions-end", new Separator("ui-actions"));
menuManager.insertAfter("ui-actions", showPropertiesViewAction);
- refreshViewerAction.setEnabled(refreshViewerAction.isEnabled());
+ refreshViewerAction.setEnabled(refreshViewerAction.isEnabled());
menuManager.insertAfter("ui-actions", refreshViewerAction);
super.addGlobalActions(menuManager);
@@ -424,6 +446,7 @@ public class FacademappingActionBarContributor
* This ensures that a delete action will clean up all references to deleted objects.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditor.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditor.java
index 0fa2b9fd3cd..c2451199f46 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -131,7 +131,6 @@ import org.eclipse.emf.common.util.BasicDiagnostic;
import org.eclipse.emf.common.util.Diagnostic;
import org.eclipse.emf.common.util.URI;
-
import org.eclipse.emf.ecore.resource.Resource;
import org.eclipse.emf.ecore.resource.ResourceSet;
@@ -174,15 +173,17 @@ import org.eclipse.ui.actions.WorkspaceModifyOperation;
* This is an example of a Facademapping model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacademappingEditor
- extends MultiPageEditorPart
- implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker {
+ extends MultiPageEditorPart
+ implements IEditingDomainProvider, ISelectionProvider, IMenuListener, IViewerProvider, IGotoMarker {
/**
* This keeps track of the editing domain that is used to track all changes to the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected AdapterFactoryEditingDomain editingDomain;
@@ -191,6 +192,7 @@ public class FacademappingEditor
* This is the one adapter factory used for providing views of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ComposedAdapterFactory adapterFactory;
@@ -199,6 +201,7 @@ public class FacademappingEditor
* This is the content outline page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IContentOutlinePage contentOutlinePage;
@@ -207,6 +210,7 @@ public class FacademappingEditor
* This is a kludge...
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IStatusLineManager contentOutlineStatusLineManager;
@@ -215,6 +219,7 @@ public class FacademappingEditor
* This is the content outline page's viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer contentOutlineViewer;
@@ -223,6 +228,7 @@ public class FacademappingEditor
* This is the property sheet page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected List<PropertySheetPage> propertySheetPages = new ArrayList<PropertySheetPage>();
@@ -232,6 +238,7 @@ public class FacademappingEditor
* The parent relation must be correctly defined for this to work.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer selectionViewer;
@@ -240,6 +247,7 @@ public class FacademappingEditor
* This inverts the roll of parent and child in the content provider and show parents as a tree.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer parentViewer;
@@ -248,6 +256,7 @@ public class FacademappingEditor
* This shows how a tree view works.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer treeViewer;
@@ -257,6 +266,7 @@ public class FacademappingEditor
* A list viewer doesn't support icons.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ListViewer listViewer;
@@ -266,6 +276,7 @@ public class FacademappingEditor
* A table can be used as a list with icons.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TableViewer tableViewer;
@@ -274,6 +285,7 @@ public class FacademappingEditor
* This shows how a tree view with columns works.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected TreeViewer treeViewerWithColumns;
@@ -282,6 +294,7 @@ public class FacademappingEditor
* This keeps track of the active viewer pane, in the book.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ViewerPane currentViewerPane;
@@ -290,6 +303,7 @@ public class FacademappingEditor
* This keeps track of the active content viewer, which may be either one of the viewers in the pages or the content outline viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Viewer currentViewer;
@@ -298,6 +312,7 @@ public class FacademappingEditor
* This listens to which ever viewer is active.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelectionChangedListener selectionChangedListener;
@@ -306,6 +321,7 @@ public class FacademappingEditor
* This keeps track of all the {@link org.eclipse.jface.viewers.ISelectionChangedListener}s that are listening to this editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<ISelectionChangedListener> selectionChangedListeners = new ArrayList<ISelectionChangedListener>();
@@ -314,6 +330,7 @@ public class FacademappingEditor
* This keeps track of the selection of the editor as a whole.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ISelection editorSelection = StructuredSelection.EMPTY;
@@ -323,6 +340,7 @@ public class FacademappingEditor
* in Eclipse's Problems View.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected MarkerHelper markerHelper = new EditUIMarkerHelper();
@@ -331,46 +349,57 @@ public class FacademappingEditor
* This listens for when the outline becomes active
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IPartListener partListener =
- new IPartListener() {
- public void partActivated(IWorkbenchPart p) {
- if (p instanceof ContentOutline) {
- if (((ContentOutline)p).getCurrentPage() == contentOutlinePage) {
- getActionBarContributor().setActiveEditor(FacademappingEditor.this);
+ new IPartListener() {
+ @Override
+ public void partActivated(IWorkbenchPart p) {
+ if (p instanceof ContentOutline) {
+ if (((ContentOutline) p).getCurrentPage() == contentOutlinePage) {
+ getActionBarContributor().setActiveEditor(FacademappingEditor.this);
- setCurrentViewer(contentOutlineViewer);
+ setCurrentViewer(contentOutlineViewer);
+ }
}
- }
- else if (p instanceof PropertySheet) {
- if (propertySheetPages.contains(((PropertySheet)p).getCurrentPage())) {
- getActionBarContributor().setActiveEditor(FacademappingEditor.this);
+ else if (p instanceof PropertySheet) {
+ if (propertySheetPages.contains(((PropertySheet) p).getCurrentPage())) {
+ getActionBarContributor().setActiveEditor(FacademappingEditor.this);
+ handleActivate();
+ }
+ }
+ else if (p == FacademappingEditor.this) {
handleActivate();
}
}
- else if (p == FacademappingEditor.this) {
- handleActivate();
+
+ @Override
+ public void partBroughtToTop(IWorkbenchPart p) {
+ // Ignore.
+ }
+
+ @Override
+ public void partClosed(IWorkbenchPart p) {
+ // Ignore.
+ }
+
+ @Override
+ public void partDeactivated(IWorkbenchPart p) {
+ // Ignore.
}
- }
- public void partBroughtToTop(IWorkbenchPart p) {
- // Ignore.
- }
- public void partClosed(IWorkbenchPart p) {
- // Ignore.
- }
- public void partDeactivated(IWorkbenchPart p) {
- // Ignore.
- }
- public void partOpened(IWorkbenchPart p) {
- // Ignore.
- }
- };
+
+ @Override
+ public void partOpened(IWorkbenchPart p) {
+ // Ignore.
+ }
+ };
/**
* Resources that have been removed since last activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> removedResources = new ArrayList<Resource>();
@@ -379,6 +408,7 @@ public class FacademappingEditor
* Resources that have been changed since last activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> changedResources = new ArrayList<Resource>();
@@ -387,6 +417,7 @@ public class FacademappingEditor
* Resources that have been saved.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<Resource> savedResources = new ArrayList<Resource>();
@@ -395,6 +426,7 @@ public class FacademappingEditor
* Map to store the diagnostic associated with a resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Map<Resource, Diagnostic> resourceToDiagnosticMap = new LinkedHashMap<Resource, Diagnostic>();
@@ -403,6 +435,7 @@ public class FacademappingEditor
* Controls whether the problem indication should be updated.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean updateProblemIndication = true;
@@ -411,18 +444,19 @@ public class FacademappingEditor
* Adapter used to update the problem indication when resources are demanded loaded.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected EContentAdapter problemIndicationAdapter =
- new EContentAdapter() {
- @Override
- public void notifyChanged(Notification notification) {
- if (notification.getNotifier() instanceof Resource) {
- switch (notification.getFeatureID(Resource.class)) {
+ new EContentAdapter() {
+ @Override
+ public void notifyChanged(Notification notification) {
+ if (notification.getNotifier() instanceof Resource) {
+ switch (notification.getFeatureID(Resource.class)) {
case Resource.RESOURCE__IS_LOADED:
case Resource.RESOURCE__ERRORS:
case Resource.RESOURCE__WARNINGS: {
- Resource resource = (Resource)notification.getNotifier();
+ Resource resource = (Resource) notification.getNotifier();
Diagnostic diagnostic = analyzeResourceProblems(resource, null);
if (diagnostic.getSeverity() != Diagnostic.OK) {
resourceToDiagnosticMap.put(resource, diagnostic);
@@ -433,134 +467,142 @@ public class FacademappingEditor
if (updateProblemIndication) {
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
}
break;
}
+ }
+ }
+ else {
+ super.notifyChanged(notification);
}
}
- else {
- super.notifyChanged(notification);
- }
- }
- @Override
- protected void setTarget(Resource target) {
- basicSetTarget(target);
- }
+ @Override
+ protected void setTarget(Resource target) {
+ basicSetTarget(target);
+ }
- @Override
- protected void unsetTarget(Resource target) {
- basicUnsetTarget(target);
- resourceToDiagnosticMap.remove(target);
- if (updateProblemIndication) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ @Override
+ protected void unsetTarget(Resource target) {
+ basicUnsetTarget(target);
+ resourceToDiagnosticMap.remove(target);
+ if (updateProblemIndication) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
+ }
}
- }
- };
+ };
/**
* This listens for workspace changes.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IResourceChangeListener resourceChangeListener =
- new IResourceChangeListener() {
- public void resourceChanged(IResourceChangeEvent event) {
- IResourceDelta delta = event.getDelta();
- try {
- class ResourceDeltaVisitor implements IResourceDeltaVisitor {
- protected ResourceSet resourceSet = editingDomain.getResourceSet();
- protected Collection<Resource> changedResources = new ArrayList<Resource>();
- protected Collection<Resource> removedResources = new ArrayList<Resource>();
-
- public boolean visit(IResourceDelta delta) {
- if (delta.getResource().getType() == IResource.FILE) {
- if (delta.getKind() == IResourceDelta.REMOVED ||
- delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) {
- Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false);
- if (resource != null) {
- if (delta.getKind() == IResourceDelta.REMOVED) {
- removedResources.add(resource);
- }
- else if (!savedResources.remove(resource)) {
- changedResources.add(resource);
+ new IResourceChangeListener() {
+ @Override
+ public void resourceChanged(IResourceChangeEvent event) {
+ IResourceDelta delta = event.getDelta();
+ try {
+ class ResourceDeltaVisitor implements IResourceDeltaVisitor {
+ protected ResourceSet resourceSet = editingDomain.getResourceSet();
+ protected Collection<Resource> changedResources = new ArrayList<Resource>();
+ protected Collection<Resource> removedResources = new ArrayList<Resource>();
+
+ @Override
+ public boolean visit(IResourceDelta delta) {
+ if (delta.getResource().getType() == IResource.FILE) {
+ if (delta.getKind() == IResourceDelta.REMOVED ||
+ delta.getKind() == IResourceDelta.CHANGED && delta.getFlags() != IResourceDelta.MARKERS) {
+ Resource resource = resourceSet.getResource(URI.createPlatformResourceURI(delta.getFullPath().toString(), true), false);
+ if (resource != null) {
+ if (delta.getKind() == IResourceDelta.REMOVED) {
+ removedResources.add(resource);
+ }
+ else if (!savedResources.remove(resource)) {
+ changedResources.add(resource);
+ }
}
}
+ return false;
}
- return false;
+
+ return true;
}
- return true;
- }
+ public Collection<Resource> getChangedResources() {
+ return changedResources;
+ }
- public Collection<Resource> getChangedResources() {
- return changedResources;
+ public Collection<Resource> getRemovedResources() {
+ return removedResources;
+ }
}
- public Collection<Resource> getRemovedResources() {
- return removedResources;
- }
- }
+ final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor();
+ delta.accept(visitor);
- final ResourceDeltaVisitor visitor = new ResourceDeltaVisitor();
- delta.accept(visitor);
+ if (!visitor.getRemovedResources().isEmpty()) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ removedResources.addAll(visitor.getRemovedResources());
+ if (!isDirty()) {
+ getSite().getPage().closeEditor(FacademappingEditor.this, false);
+ }
+ }
+ });
+ }
- if (!visitor.getRemovedResources().isEmpty()) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- removedResources.addAll(visitor.getRemovedResources());
- if (!isDirty()) {
- getSite().getPage().closeEditor(FacademappingEditor.this, false);
- }
- }
- });
+ if (!visitor.getChangedResources().isEmpty()) {
+ getSite().getShell().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ changedResources.addAll(visitor.getChangedResources());
+ if (getSite().getPage().getActiveEditor() == FacademappingEditor.this) {
+ handleActivate();
+ }
+ }
+ });
+ }
}
-
- if (!visitor.getChangedResources().isEmpty()) {
- getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- changedResources.addAll(visitor.getChangedResources());
- if (getSite().getPage().getActiveEditor() == FacademappingEditor.this) {
- handleActivate();
- }
- }
- });
+ catch (CoreException exception) {
+ FacademappingEditorPlugin.INSTANCE.log(exception);
}
}
- catch (CoreException exception) {
- FacademappingEditorPlugin.INSTANCE.log(exception);
- }
- }
- };
+ };
/**
* Handles activation of the editor or it's associated views.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void handleActivate() {
// Recompute the read only state.
//
if (editingDomain.getResourceToReadOnlyMap() != null) {
- editingDomain.getResourceToReadOnlyMap().clear();
+ editingDomain.getResourceToReadOnlyMap().clear();
- // Refresh any actions that may become enabled or disabled.
- //
- setSelection(getSelection());
+ // Refresh any actions that may become enabled or disabled.
+ //
+ setSelection(getSelection());
}
if (!removedResources.isEmpty()) {
@@ -585,6 +627,7 @@ public class FacademappingEditor
* Handles what to do with changed resources on activation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void handleChangedResources() {
@@ -600,8 +643,7 @@ public class FacademappingEditor
resource.unload();
try {
resource.load(Collections.EMPTY_MAP);
- }
- catch (IOException exception) {
+ } catch (IOException exception) {
if (!resourceToDiagnosticMap.containsKey(resource)) {
resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
}
@@ -622,17 +664,18 @@ public class FacademappingEditor
* Updates the problems indication with the information described in the specified diagnostic.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void updateProblemIndication() {
if (updateProblemIndication) {
BasicDiagnostic diagnostic =
- new BasicDiagnostic
+ new BasicDiagnostic
(Diagnostic.OK,
- "org.eclipse.papyrus.facade.editor",
- 0,
- null,
- new Object [] { editingDomain.getResourceSet() });
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ null,
+ new Object[] { editingDomain.getResourceSet() });
for (Diagnostic childDiagnostic : resourceToDiagnosticMap.values()) {
if (childDiagnostic.getSeverity() != Diagnostic.OK) {
diagnostic.add(childDiagnostic);
@@ -641,7 +684,7 @@ public class FacademappingEditor
int lastEditorPage = getPageCount() - 1;
if (lastEditorPage >= 0 && getEditor(lastEditorPage) instanceof ProblemEditorPart) {
- ((ProblemEditorPart)getEditor(lastEditorPage)).setDiagnostic(diagnostic);
+ ((ProblemEditorPart) getEditor(lastEditorPage)).setDiagnostic(diagnostic);
if (diagnostic.getSeverity() != Diagnostic.OK) {
setActivePage(lastEditorPage);
}
@@ -655,8 +698,7 @@ public class FacademappingEditor
setPageText(lastEditorPage, problemEditorPart.getPartName());
setActivePage(lastEditorPage);
showTabs();
- }
- catch (PartInitException exception) {
+ } catch (PartInitException exception) {
FacademappingEditorPlugin.INSTANCE.log(exception);
}
}
@@ -666,8 +708,7 @@ public class FacademappingEditor
if (diagnostic.getSeverity() != Diagnostic.OK) {
try {
markerHelper.createMarkers(diagnostic);
- }
- catch (CoreException exception) {
+ } catch (CoreException exception) {
FacademappingEditorPlugin.INSTANCE.log(exception);
}
}
@@ -679,20 +720,21 @@ public class FacademappingEditor
* Shows a dialog that asks if conflicting changes should be discarded.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean handleDirtyConflict() {
- return
- MessageDialog.openQuestion
+ return MessageDialog.openQuestion
(getSite().getShell(),
- getString("_UI_FileConflict_label"),
- getString("_WARN_FileConflict"));
+ getString("_UI_FileConflict_label"),
+ getString("_WARN_FileConflict"));
}
/**
* This creates a model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingEditor() {
@@ -704,6 +746,7 @@ public class FacademappingEditor
* This sets up the editing domain for the model editor.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void initializeEditingDomain() {
@@ -722,32 +765,34 @@ public class FacademappingEditor
// Add a listener to set the most recent command's affected objects to be the selection of the viewer with focus.
//
commandStack.addCommandStackListener
- (new CommandStackListener() {
- public void commandStackChanged(final EventObject event) {
- getContainer().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- firePropertyChange(IEditorPart.PROP_DIRTY);
-
- // Try to select the affected objects.
- //
- Command mostRecentCommand = ((CommandStack)event.getSource()).getMostRecentCommand();
- if (mostRecentCommand != null) {
- setSelectionToViewer(mostRecentCommand.getAffectedObjects());
- }
- for (Iterator<PropertySheetPage> i = propertySheetPages.iterator(); i.hasNext(); ) {
- PropertySheetPage propertySheetPage = i.next();
- if (propertySheetPage.getControl().isDisposed()) {
- i.remove();
- }
- else {
- propertySheetPage.refresh();
- }
- }
- }
- });
- }
- });
+ (new CommandStackListener() {
+ @Override
+ public void commandStackChanged(final EventObject event) {
+ getContainer().getDisplay().asyncExec
+ (new Runnable() {
+ @Override
+ public void run() {
+ firePropertyChange(IEditorPart.PROP_DIRTY);
+
+ // Try to select the affected objects.
+ //
+ Command mostRecentCommand = ((CommandStack) event.getSource()).getMostRecentCommand();
+ if (mostRecentCommand != null) {
+ setSelectionToViewer(mostRecentCommand.getAffectedObjects());
+ }
+ for (Iterator<PropertySheetPage> i = propertySheetPages.iterator(); i.hasNext();) {
+ PropertySheetPage propertySheetPage = i.next();
+ if (propertySheetPage.getControl().isDisposed()) {
+ i.remove();
+ }
+ else {
+ propertySheetPage.refresh();
+ }
+ }
+ }
+ });
+ }
+ });
// Create the editing domain with a special command stack.
//
@@ -758,9 +803,10 @@ public class FacademappingEditor
* This is here for the listener to be able to call it.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
- @Override
+ @Override
protected void firePropertyChange(int action) {
super.firePropertyChange(action);
}
@@ -769,6 +815,7 @@ public class FacademappingEditor
* This sets the selection into whichever viewer is active.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setSelectionToViewer(Collection<?> collection) {
@@ -777,27 +824,29 @@ public class FacademappingEditor
//
if (theSelection != null && !theSelection.isEmpty()) {
Runnable runnable =
- new Runnable() {
- public void run() {
- // Try to select the items in the current content viewer of the editor.
- //
- if (currentViewer != null) {
- currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true);
+ new Runnable() {
+ @Override
+ public void run() {
+ // Try to select the items in the current content viewer of the editor.
+ //
+ if (currentViewer != null) {
+ currentViewer.setSelection(new StructuredSelection(theSelection.toArray()), true);
+ }
}
- }
- };
+ };
getSite().getShell().getDisplay().asyncExec(runnable);
}
}
/**
* This returns the editing domain as required by the {@link IEditingDomainProvider} interface.
- * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain}
- * and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}.
+ * This is important for implementing the static methods of {@link AdapterFactoryEditingDomain} and for supporting {@link org.eclipse.emf.edit.ui.action.CommandAction}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EditingDomain getEditingDomain() {
return editingDomain;
}
@@ -805,12 +854,14 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ReverseAdapterFactoryContentProvider extends AdapterFactoryContentProvider {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ReverseAdapterFactoryContentProvider(AdapterFactory adapterFactory) {
@@ -820,10 +871,11 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
- public Object [] getElements(Object object) {
+ public Object[] getElements(Object object) {
Object parent = super.getParent(object);
return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray();
}
@@ -831,10 +883,11 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
- public Object [] getChildren(Object object) {
+ public Object[] getChildren(Object object) {
Object parent = super.getParent(object);
return (parent == null ? Collections.EMPTY_SET : Collections.singleton(parent)).toArray();
}
@@ -842,6 +895,7 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -853,6 +907,7 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -864,6 +919,7 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setCurrentViewerPane(ViewerPane viewerPane) {
@@ -881,6 +937,7 @@ public class FacademappingEditor
* is the current one.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setCurrentViewer(Viewer viewer) {
@@ -891,13 +948,14 @@ public class FacademappingEditor
// Create the listener on demand.
//
selectionChangedListener =
- new ISelectionChangedListener() {
- // This just notifies those things that are affected by the section.
- //
- public void selectionChanged(SelectionChangedEvent selectionChangedEvent) {
- setSelection(selectionChangedEvent.getSelection());
- }
- };
+ new ISelectionChangedListener() {
+ // This just notifies those things that are affected by the section.
+ //
+ @Override
+ public void selectionChanged(SelectionChangedEvent selectionChangedEvent) {
+ setSelection(selectionChangedEvent.getSelection());
+ }
+ };
}
// Stop listening to the old one.
@@ -926,8 +984,10 @@ public class FacademappingEditor
* This returns the viewer as required by the {@link IViewerProvider} interface.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Viewer getViewer() {
return currentViewer;
}
@@ -936,6 +996,7 @@ public class FacademappingEditor
* This creates a context menu for the viewer and adds a listener as well registering the menu for extension.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void createContextMenuFor(StructuredViewer viewer) {
@@ -943,7 +1004,7 @@ public class FacademappingEditor
contextMenu.add(new Separator("additions"));
contextMenu.setRemoveAllWhenShown(true);
contextMenu.addMenuListener(this);
- Menu menu= contextMenu.createContextMenu(viewer.getControl());
+ Menu menu = contextMenu.createContextMenu(viewer.getControl());
viewer.getControl().setMenu(menu);
getSite().registerContextMenu(contextMenu, new UnwrappingSelectionProvider(viewer));
@@ -957,6 +1018,7 @@ public class FacademappingEditor
* This is the method called to load a resource into the editing domain's resource set based on the editor's input.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void createModel() {
@@ -967,15 +1029,14 @@ public class FacademappingEditor
// Load the resource through the editing domain.
//
resource = editingDomain.getResourceSet().getResource(resourceURI, true);
- }
- catch (Exception e) {
+ } catch (Exception e) {
exception = e;
resource = editingDomain.getResourceSet().getResource(resourceURI, false);
}
Diagnostic diagnostic = analyzeResourceProblems(resource, exception);
if (diagnostic.getSeverity() != Diagnostic.OK) {
- resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
+ resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
}
editingDomain.getResourceSet().eAdapters().add(problemIndicationAdapter);
}
@@ -985,28 +1046,27 @@ public class FacademappingEditor
* and the specified exception (if any).
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Diagnostic analyzeResourceProblems(Resource resource, Exception exception) {
if (!resource.getErrors().isEmpty() || !resource.getWarnings().isEmpty()) {
BasicDiagnostic basicDiagnostic =
- new BasicDiagnostic
+ new BasicDiagnostic
(Diagnostic.ERROR,
- "org.eclipse.papyrus.facade.editor",
- 0,
- getString("_UI_CreateModelError_message", resource.getURI()),
- new Object [] { exception == null ? (Object)resource : exception });
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ getString("_UI_CreateModelError_message", resource.getURI()),
+ new Object[] { exception == null ? (Object) resource : exception });
basicDiagnostic.merge(EcoreUtil.computeDiagnostic(resource, true));
return basicDiagnostic;
}
else if (exception != null) {
- return
- new BasicDiagnostic
- (Diagnostic.ERROR,
- "org.eclipse.papyrus.facade.editor",
- 0,
- getString("_UI_CreateModelError_message", resource.getURI()),
- new Object[] { exception });
+ return new BasicDiagnostic(Diagnostic.ERROR,
+ "org.eclipse.papyrus.facade.editor",
+ 0,
+ getString("_UI_CreateModelError_message", resource.getURI()),
+ new Object[] { exception });
}
else {
return Diagnostic.OK_INSTANCE;
@@ -1017,6 +1077,7 @@ public class FacademappingEditor
* This is the method used by the framework to install your own controls.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1032,22 +1093,23 @@ public class FacademappingEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- Tree tree = new Tree(composite, SWT.MULTI);
- TreeViewer newTreeViewer = new TreeViewer(tree);
- return newTreeViewer;
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ Tree tree = new Tree(composite, SWT.MULTI);
+ TreeViewer newTreeViewer = new TreeViewer(tree);
+ return newTreeViewer;
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- selectionViewer = (TreeViewer)viewerPane.getViewer();
+ selectionViewer = (TreeViewer) viewerPane.getViewer();
selectionViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
selectionViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1066,22 +1128,23 @@ public class FacademappingEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- Tree tree = new Tree(composite, SWT.MULTI);
- TreeViewer newTreeViewer = new TreeViewer(tree);
- return newTreeViewer;
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ Tree tree = new Tree(composite, SWT.MULTI);
+ TreeViewer newTreeViewer = new TreeViewer(tree);
+ return newTreeViewer;
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- parentViewer = (TreeViewer)viewerPane.getViewer();
+ parentViewer = (TreeViewer) viewerPane.getViewer();
parentViewer.setAutoExpandLevel(30);
parentViewer.setContentProvider(new ReverseAdapterFactoryContentProvider(adapterFactory));
parentViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1095,19 +1158,20 @@ public class FacademappingEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new ListViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new ListViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- listViewer = (ListViewer)viewerPane.getViewer();
+ listViewer = (ListViewer) viewerPane.getViewer();
listViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
listViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1120,19 +1184,20 @@ public class FacademappingEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TreeViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TreeViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- treeViewer = (TreeViewer)viewerPane.getViewer();
+ treeViewer = (TreeViewer) viewerPane.getViewer();
treeViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
treeViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1147,19 +1212,20 @@ public class FacademappingEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TableViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TableViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- tableViewer = (TableViewer)viewerPane.getViewer();
+ tableViewer = (TableViewer) viewerPane.getViewer();
Table table = tableViewer.getTable();
TableLayout layout = new TableLayout();
@@ -1177,7 +1243,7 @@ public class FacademappingEditor
selfColumn.setText(getString("_UI_SelfColumn_label"));
selfColumn.setResizable(true);
- tableViewer.setColumnProperties(new String [] {"a", "b"});
+ tableViewer.setColumnProperties(new String[] { "a", "b" });
tableViewer.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
tableViewer.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1190,20 +1256,21 @@ public class FacademappingEditor
//
{
ViewerPane viewerPane =
- new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
- @Override
- public Viewer createViewer(Composite composite) {
- return new TreeViewer(composite);
- }
- @Override
- public void requestActivation() {
- super.requestActivation();
- setCurrentViewerPane(this);
- }
- };
+ new ViewerPane(getSite().getPage(), FacademappingEditor.this) {
+ @Override
+ public Viewer createViewer(Composite composite) {
+ return new TreeViewer(composite);
+ }
+
+ @Override
+ public void requestActivation() {
+ super.requestActivation();
+ setCurrentViewerPane(this);
+ }
+ };
viewerPane.createControl(getContainer());
- treeViewerWithColumns = (TreeViewer)viewerPane.getViewer();
+ treeViewerWithColumns = (TreeViewer) viewerPane.getViewer();
Tree tree = treeViewerWithColumns.getTree();
tree.setLayoutData(new FillLayout());
@@ -1220,7 +1287,7 @@ public class FacademappingEditor
selfColumn.setResizable(true);
selfColumn.setWidth(200);
- treeViewerWithColumns.setColumnProperties(new String [] {"a", "b"});
+ treeViewerWithColumns.setColumnProperties(new String[] { "a", "b" });
treeViewerWithColumns.setContentProvider(new AdapterFactoryContentProvider(adapterFactory));
treeViewerWithColumns.setLabelProvider(new AdapterFactoryLabelProvider(adapterFactory));
@@ -1230,35 +1297,38 @@ public class FacademappingEditor
}
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- setActivePage(0);
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ setActivePage(0);
+ }
+ });
}
// Ensures that this editor will only display the page's tab
// area if there are more than one page
//
getContainer().addControlListener
- (new ControlAdapter() {
- boolean guard = false;
- @Override
- public void controlResized(ControlEvent event) {
- if (!guard) {
- guard = true;
- hideTabs();
- guard = false;
+ (new ControlAdapter() {
+ boolean guard = false;
+
+ @Override
+ public void controlResized(ControlEvent event) {
+ if (!guard) {
+ guard = true;
+ hideTabs();
+ guard = false;
+ }
}
- }
- });
+ });
getSite().getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- updateProblemIndication();
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ updateProblemIndication();
+ }
+ });
}
/**
@@ -1266,13 +1336,14 @@ public class FacademappingEditor
* this hides the single tab at the bottom.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void hideTabs() {
if (getPageCount() <= 1) {
setPageText(0, "");
if (getContainer() instanceof CTabFolder) {
- ((CTabFolder)getContainer()).setTabHeight(1);
+ ((CTabFolder) getContainer()).setTabHeight(1);
Point point = getContainer().getSize();
getContainer().setSize(point.x, point.y + 6);
}
@@ -1284,13 +1355,14 @@ public class FacademappingEditor
* this shows the tabs at the bottom.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void showTabs() {
if (getPageCount() > 1) {
setPageText(0, getString("_UI_SelectionPage_label"));
if (getContainer() instanceof CTabFolder) {
- ((CTabFolder)getContainer()).setTabHeight(SWT.DEFAULT);
+ ((CTabFolder) getContainer()).setTabHeight(SWT.DEFAULT);
Point point = getContainer().getSize();
getContainer().setSize(point.x, point.y - 6);
}
@@ -1301,6 +1373,7 @@ public class FacademappingEditor
* This is used to track the active viewer.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1316,6 +1389,7 @@ public class FacademappingEditor
* This is how the framework determines which interfaces we implement.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("rawtypes")
@@ -1339,6 +1413,7 @@ public class FacademappingEditor
* This accesses a cached version of the content outliner.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IContentOutlinePage getContentOutlinePage() {
@@ -1363,9 +1438,9 @@ public class FacademappingEditor
createContextMenuFor(contentOutlineViewer);
if (!editingDomain.getResourceSet().getResources().isEmpty()) {
- // Select the root object in the view.
- //
- contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true);
+ // Select the root object in the view.
+ //
+ contentOutlineViewer.setSelection(new StructuredSelection(editingDomain.getResourceSet().getResources().get(0)), true);
}
}
@@ -1387,13 +1462,14 @@ public class FacademappingEditor
// Listen to selection so that we can handle it is a special way.
//
contentOutlinePage.addSelectionChangedListener
- (new ISelectionChangedListener() {
- // This ensures that we handle selections correctly.
- //
- public void selectionChanged(SelectionChangedEvent event) {
- handleContentOutlineSelection(event.getSelection());
- }
- });
+ (new ISelectionChangedListener() {
+ // This ensures that we handle selections correctly.
+ //
+ @Override
+ public void selectionChanged(SelectionChangedEvent event) {
+ handleContentOutlineSelection(event.getSelection());
+ }
+ });
}
return contentOutlinePage;
@@ -1403,23 +1479,24 @@ public class FacademappingEditor
* This accesses a cached version of the property sheet.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IPropertySheetPage getPropertySheetPage() {
PropertySheetPage propertySheetPage =
- new ExtendedPropertySheetPage(editingDomain) {
- @Override
- public void setSelectionToViewer(List<?> selection) {
- FacademappingEditor.this.setSelectionToViewer(selection);
- FacademappingEditor.this.setFocus();
- }
+ new ExtendedPropertySheetPage(editingDomain) {
+ @Override
+ public void setSelectionToViewer(List<?> selection) {
+ FacademappingEditor.this.setSelectionToViewer(selection);
+ FacademappingEditor.this.setFocus();
+ }
- @Override
- public void setActionBars(IActionBars actionBars) {
- super.setActionBars(actionBars);
- getActionBarContributor().shareGlobalActions(this, actionBars);
- }
- };
+ @Override
+ public void setActionBars(IActionBars actionBars) {
+ super.setActionBars(actionBars);
+ getActionBarContributor().shareGlobalActions(this, actionBars);
+ }
+ };
propertySheetPage.setPropertySourceProvider(new AdapterFactoryContentProvider(adapterFactory));
propertySheetPages.add(propertySheetPage);
@@ -1430,11 +1507,12 @@ public class FacademappingEditor
* This deals with how we want selection in the outliner to affect the other views.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void handleContentOutlineSelection(ISelection selection) {
if (currentViewerPane != null && !selection.isEmpty() && selection instanceof IStructuredSelection) {
- Iterator<?> selectedElements = ((IStructuredSelection)selection).iterator();
+ Iterator<?> selectedElements = ((IStructuredSelection) selection).iterator();
if (selectedElements.hasNext()) {
// Get the first selected element.
//
@@ -1469,17 +1547,19 @@ public class FacademappingEditor
* This is for implementing {@link IEditorPart} and simply tests the command stack.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean isDirty() {
- return ((BasicCommandStack)editingDomain.getCommandStack()).isSaveNeeded();
+ return ((BasicCommandStack) editingDomain.getCommandStack()).isSaveNeeded();
}
/**
* This is for implementing {@link IEditorPart} and simply saves the model file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1493,31 +1573,31 @@ public class FacademappingEditor
// Do the work within an operation because this is a long running activity that modifies the workbench.
//
WorkspaceModifyOperation operation =
- new WorkspaceModifyOperation() {
- // This is the method that gets invoked when the operation runs.
- //
- @Override
- public void execute(IProgressMonitor monitor) {
- // Save the resources to the file system.
+ new WorkspaceModifyOperation() {
+ // This is the method that gets invoked when the operation runs.
//
- boolean first = true;
- for (Resource resource : editingDomain.getResourceSet().getResources()) {
- if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) {
- try {
- long timeStamp = resource.getTimeStamp();
- resource.save(saveOptions);
- if (resource.getTimeStamp() != timeStamp) {
- savedResources.add(resource);
+ @Override
+ public void execute(IProgressMonitor monitor) {
+ // Save the resources to the file system.
+ //
+ boolean first = true;
+ for (Resource resource : editingDomain.getResourceSet().getResources()) {
+ if ((first || !resource.getContents().isEmpty() || isPersisted(resource)) && !editingDomain.isReadOnly(resource)) {
+ try {
+ long timeStamp = resource.getTimeStamp();
+ resource.save(saveOptions);
+ if (resource.getTimeStamp() != timeStamp) {
+ savedResources.add(resource);
+ }
}
+ catch (Exception exception) {
+ resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
+ }
+ first = false;
}
- catch (Exception exception) {
- resourceToDiagnosticMap.put(resource, analyzeResourceProblems(resource, exception));
- }
- first = false;
}
}
- }
- };
+ };
updateProblemIndication = false;
try {
@@ -1527,10 +1607,9 @@ public class FacademappingEditor
// Refresh the necessary state.
//
- ((BasicCommandStack)editingDomain.getCommandStack()).saveIsDone();
+ ((BasicCommandStack) editingDomain.getCommandStack()).saveIsDone();
firePropertyChange(IEditorPart.PROP_DIRTY);
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
// Something went wrong that shouldn't.
//
FacademappingEditorPlugin.INSTANCE.log(exception);
@@ -1544,6 +1623,7 @@ public class FacademappingEditor
* The implementation uses the URI converter from the editor's resource set to try to open an input stream.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean isPersisted(Resource resource) {
@@ -1554,8 +1634,7 @@ public class FacademappingEditor
result = true;
stream.close();
}
- }
- catch (IOException e) {
+ } catch (IOException e) {
// Ignore
}
return result;
@@ -1565,6 +1644,7 @@ public class FacademappingEditor
* This always returns true because it is not currently supported.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1576,6 +1656,7 @@ public class FacademappingEditor
* This also changes the editor's input.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1594,6 +1675,7 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected void doSaveAs(URI uri, IEditorInput editorInput) {
@@ -1601,17 +1683,19 @@ public class FacademappingEditor
setInputWithNotify(editorInput);
setPartName(editorInput.getName());
IProgressMonitor progressMonitor =
- getActionBars().getStatusLineManager() != null ?
- getActionBars().getStatusLineManager().getProgressMonitor() :
- new NullProgressMonitor();
+ getActionBars().getStatusLineManager() != null ?
+ getActionBars().getStatusLineManager().getProgressMonitor() :
+ new NullProgressMonitor();
doSave(progressMonitor);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void gotoMarker(IMarker marker) {
List<?> targetObjects = markerHelper.getTargetObjects(editingDomain, marker);
if (!targetObjects.isEmpty()) {
@@ -1623,6 +1707,7 @@ public class FacademappingEditor
* This is called during startup.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1638,6 +1723,7 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1654,8 +1740,10 @@ public class FacademappingEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void addSelectionChangedListener(ISelectionChangedListener listener) {
selectionChangedListeners.add(listener);
}
@@ -1664,8 +1752,10 @@ public class FacademappingEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider}.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void removeSelectionChangedListener(ISelectionChangedListener listener) {
selectionChangedListeners.remove(listener);
}
@@ -1674,8 +1764,10 @@ public class FacademappingEditor
* This implements {@link org.eclipse.jface.viewers.ISelectionProvider} to return this editor's overall selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ISelection getSelection() {
return editorSelection;
}
@@ -1685,8 +1777,10 @@ public class FacademappingEditor
* Calling this result will notify the listeners.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setSelection(ISelection selection) {
editorSelection = selection;
@@ -1699,29 +1793,30 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void setStatusLineManager(ISelection selection) {
IStatusLineManager statusLineManager = currentViewer != null && currentViewer == contentOutlineViewer ?
- contentOutlineStatusLineManager : getActionBars().getStatusLineManager();
+ contentOutlineStatusLineManager : getActionBars().getStatusLineManager();
if (statusLineManager != null) {
if (selection instanceof IStructuredSelection) {
- Collection<?> collection = ((IStructuredSelection)selection).toList();
+ Collection<?> collection = ((IStructuredSelection) selection).toList();
switch (collection.size()) {
- case 0: {
- statusLineManager.setMessage(getString("_UI_NoObjectSelected"));
- break;
- }
- case 1: {
- String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next());
- statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text));
- break;
- }
- default: {
- statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size())));
- break;
- }
+ case 0: {
+ statusLineManager.setMessage(getString("_UI_NoObjectSelected"));
+ break;
+ }
+ case 1: {
+ String text = new AdapterFactoryItemDelegator(adapterFactory).getText(collection.iterator().next());
+ statusLineManager.setMessage(getString("_UI_SingleObjectSelected", text));
+ break;
+ }
+ default: {
+ statusLineManager.setMessage(getString("_UI_MultiObjectSelected", Integer.toString(collection.size())));
+ break;
+ }
}
}
else {
@@ -1734,6 +1829,7 @@ public class FacademappingEditor
* This looks up a string in the plugin's plugin.properties file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static String getString(String key) {
@@ -1744,34 +1840,39 @@ public class FacademappingEditor
* This looks up a string in plugin.properties, making a substitution.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static String getString(String key, Object s1) {
- return FacademappingEditorPlugin.INSTANCE.getString(key, new Object [] { s1 });
+ return FacademappingEditorPlugin.INSTANCE.getString(key, new Object[] { s1 });
}
/**
* This implements {@link org.eclipse.jface.action.IMenuListener} to help fill the context menus with contributions from the Edit menu.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void menuAboutToShow(IMenuManager menuManager) {
- ((IMenuListener)getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager);
+ ((IMenuListener) getEditorSite().getActionBarContributor()).menuAboutToShow(menuManager);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public EditingDomainActionBarContributor getActionBarContributor() {
- return (EditingDomainActionBarContributor)getEditorSite().getActionBarContributor();
+ return (EditingDomainActionBarContributor) getEditorSite().getActionBarContributor();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IActionBars getActionBars() {
@@ -1781,6 +1882,7 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public AdapterFactory getAdapterFactory() {
@@ -1790,6 +1892,7 @@ public class FacademappingEditor
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -1821,6 +1924,7 @@ public class FacademappingEditor
* Returns whether the outline view should be presented to the user.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean showOutlineView() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditorPlugin.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditorPlugin.java
index 196e507c472..954ed75dccc 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditorPlugin.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingEditorPlugin.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,6 +23,7 @@ import org.eclipse.emf.common.util.ResourceLocator;
* This is the central singleton for the Facademapping editor plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public final class FacademappingEditorPlugin extends EMFPlugin {
@@ -30,14 +31,16 @@ public final class FacademappingEditorPlugin extends EMFPlugin {
* Keep track of the singleton.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final FacademappingEditorPlugin INSTANCE = new FacademappingEditorPlugin();
-
+
/**
* Keep track of the singleton.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static Implementation plugin;
@@ -46,18 +49,19 @@ public final class FacademappingEditorPlugin extends EMFPlugin {
* Create the instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingEditorPlugin() {
- super
- (new ResourceLocator [] {
- });
+ super(new ResourceLocator[] {
+ });
}
/**
* Returns the singleton instance of the Eclipse plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the singleton instance.
* @generated
*/
@@ -65,22 +69,24 @@ public final class FacademappingEditorPlugin extends EMFPlugin {
public ResourceLocator getPluginResourceLocator() {
return plugin;
}
-
+
/**
* Returns the singleton instance of the Eclipse plugin.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the singleton instance.
* @generated
*/
public static Implementation getPlugin() {
return plugin;
}
-
+
/**
* The actual implementation of the Eclipse <b>Plugin</b>.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static class Implementation extends EclipseUIPlugin {
@@ -88,11 +94,12 @@ public final class FacademappingEditorPlugin extends EMFPlugin {
* Creates an instance.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Implementation() {
super();
-
+
// Remember the static instance.
//
plugin = this;
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingModelWizard.java b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingModelWizard.java
index 37492ec1cb6..6578e3b77a8 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingModelWizard.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.editor/src/org/eclipse/papyrus/facademapping/presentation/FacademappingModelWizard.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -84,7 +84,6 @@ import org.eclipse.papyrus.facademapping.FacademappingFactory;
import org.eclipse.papyrus.facademapping.FacademappingPackage;
import org.eclipse.papyrus.facademapping.provider.FacademappingEditPlugin;
-
import org.eclipse.core.runtime.Path;
import org.eclipse.jface.viewers.ISelection;
@@ -100,6 +99,7 @@ import org.eclipse.ui.PartInitException;
* This is a simple wizard for creating a new model file.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacademappingModelWizard extends Wizard implements INewWizard {
@@ -107,24 +107,27 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* The supported extensions for created files.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final List<String> FILE_EXTENSIONS =
- Collections.unmodifiableList(Arrays.asList(FacademappingEditorPlugin.INSTANCE.getString("_UI_FacademappingEditorFilenameExtensions").split("\\s*,\\s*")));
+ Collections.unmodifiableList(Arrays.asList(FacademappingEditorPlugin.INSTANCE.getString("_UI_FacademappingEditorFilenameExtensions").split("\\s*,\\s*")));
/**
* A formatted list of supported file extensions, suitable for display.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final String FORMATTED_FILE_EXTENSIONS =
- FacademappingEditorPlugin.INSTANCE.getString("_UI_FacademappingEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", ");
+ FacademappingEditorPlugin.INSTANCE.getString("_UI_FacademappingEditorFilenameExtensions").replaceAll("\\s*,\\s*", ", ");
/**
* This caches an instance of the model package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacademappingPackage facademappingPackage = FacademappingPackage.eINSTANCE;
@@ -133,6 +136,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* This caches an instance of the model factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacademappingFactory facademappingFactory = facademappingPackage.getFacademappingFactory();
@@ -141,6 +145,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* This is the file creation page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacademappingModelWizardNewFileCreationPage newFileCreationPage;
@@ -149,6 +154,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* This is the initial object creation page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacademappingModelWizardInitialObjectCreationPage initialObjectCreationPage;
@@ -157,6 +163,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Remember the selection during initialization for populating the default container.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IStructuredSelection selection;
@@ -165,6 +172,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Remember the workbench during initialization.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected IWorkbench workbench;
@@ -173,6 +181,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Caches the names of the types that can be created as the root object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected List<String> initialObjectNames;
@@ -181,8 +190,10 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* This just records the information.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void init(IWorkbench workbench, IStructuredSelection selection) {
this.workbench = workbench;
this.selection = selection;
@@ -194,6 +205,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Returns the names of the types that can be created as the root object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<String> getInitialObjectNames() {
@@ -201,7 +213,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
initialObjectNames = new ArrayList<String>();
for (EClassifier eClassifier : facademappingPackage.getEClassifiers()) {
if (eClassifier instanceof EClass) {
- EClass eClass = (EClass)eClassifier;
+ EClass eClass = (EClass) eClassifier;
if (!eClass.isAbstract()) {
initialObjectNames.add(eClass.getName());
}
@@ -216,10 +228,11 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Create a new model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected EObject createInitialModel() {
- EClass eClass = (EClass)facademappingPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName());
+ EClass eClass = (EClass) facademappingPackage.getEClassifier(initialObjectCreationPage.getInitialObjectName());
EObject rootObject = facademappingFactory.create(eClass);
return rootObject;
}
@@ -228,6 +241,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Do the work after everything is specified.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -240,43 +254,43 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
// Do the work within an operation.
//
WorkspaceModifyOperation operation =
- new WorkspaceModifyOperation() {
- @Override
- protected void execute(IProgressMonitor progressMonitor) {
- try {
- // Create a resource set
- //
- ResourceSet resourceSet = new ResourceSetImpl();
-
- // Get the URI of the model file.
- //
- URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true);
-
- // Create a resource for this file.
- //
- Resource resource = resourceSet.createResource(fileURI);
-
- // Add the initial model object to the contents.
- //
- EObject rootObject = createInitialModel();
- if (rootObject != null) {
- resource.getContents().add(rootObject);
+ new WorkspaceModifyOperation() {
+ @Override
+ protected void execute(IProgressMonitor progressMonitor) {
+ try {
+ // Create a resource set
+ //
+ ResourceSet resourceSet = new ResourceSetImpl();
+
+ // Get the URI of the model file.
+ //
+ URI fileURI = URI.createPlatformResourceURI(modelFile.getFullPath().toString(), true);
+
+ // Create a resource for this file.
+ //
+ Resource resource = resourceSet.createResource(fileURI);
+
+ // Add the initial model object to the contents.
+ //
+ EObject rootObject = createInitialModel();
+ if (rootObject != null) {
+ resource.getContents().add(rootObject);
+ }
+
+ // Save the contents of the resource to the file system.
+ //
+ Map<Object, Object> options = new HashMap<Object, Object>();
+ options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding());
+ resource.save(options);
+ }
+ catch (Exception exception) {
+ FacademappingEditorPlugin.INSTANCE.log(exception);
+ }
+ finally {
+ progressMonitor.done();
}
-
- // Save the contents of the resource to the file system.
- //
- Map<Object, Object> options = new HashMap<Object, Object>();
- options.put(XMLResource.OPTION_ENCODING, initialObjectCreationPage.getEncoding());
- resource.save(options);
- }
- catch (Exception exception) {
- FacademappingEditorPlugin.INSTANCE.log(exception);
- }
- finally {
- progressMonitor.done();
}
- }
- };
+ };
getContainer().run(false, false, operation);
@@ -288,28 +302,27 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
if (activePart instanceof ISetSelectionTarget) {
final ISelection targetSelection = new StructuredSelection(modelFile);
getShell().getDisplay().asyncExec
- (new Runnable() {
- public void run() {
- ((ISetSelectionTarget)activePart).selectReveal(targetSelection);
- }
- });
+ (new Runnable() {
+ @Override
+ public void run() {
+ ((ISetSelectionTarget) activePart).selectReveal(targetSelection);
+ }
+ });
}
// Open an editor on the new file.
//
try {
page.openEditor
- (new FileEditorInput(modelFile),
- workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId());
- }
- catch (PartInitException exception) {
+ (new FileEditorInput(modelFile),
+ workbench.getEditorRegistry().getDefaultEditor(modelFile.getFullPath().toString()).getId());
+ } catch (PartInitException exception) {
MessageDialog.openError(workbenchWindow.getShell(), FacademappingEditorPlugin.INSTANCE.getString("_UI_OpenEditorError_label"), exception.getMessage());
return false;
}
return true;
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
FacademappingEditorPlugin.INSTANCE.log(exception);
return false;
}
@@ -319,6 +332,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* This is the one page of the wizard.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacademappingModelWizardNewFileCreationPage extends WizardNewFileCreationPage {
@@ -326,6 +340,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Pass in the selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingModelWizardNewFileCreationPage(String pageId, IStructuredSelection selection) {
@@ -336,6 +351,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* The framework calls this to see if the file is correct.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -344,7 +360,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
String extension = new Path(getFileName()).getFileExtension();
if (extension == null || !FILE_EXTENSIONS.contains(extension)) {
String key = FILE_EXTENSIONS.size() > 1 ? "_WARN_FilenameExtensions" : "_WARN_FilenameExtension";
- setErrorMessage(FacademappingEditorPlugin.INSTANCE.getString(key, new Object [] { FORMATTED_FILE_EXTENSIONS }));
+ setErrorMessage(FacademappingEditorPlugin.INSTANCE.getString(key, new Object[] { FORMATTED_FILE_EXTENSIONS }));
return false;
}
return true;
@@ -355,6 +371,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IFile getModelFile() {
@@ -366,26 +383,29 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* This is the page where the type of object to create is selected.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacademappingModelWizardInitialObjectCreationPage extends WizardPage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Combo initialObjectField;
/**
* @generated
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
+ * <!-- begin-user-doc -->
+ * <!-- end-user-doc -->
*/
protected List<String> encodings;
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Combo encodingField;
@@ -394,6 +414,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Pass in the selection.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingModelWizardInitialObjectCreationPage(String pageId) {
@@ -403,8 +424,10 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void createControl(Composite parent) {
Composite composite = new Composite(parent, SWT.NONE);
{
@@ -476,18 +499,21 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ModifyListener validator =
- new ModifyListener() {
- public void modifyText(ModifyEvent e) {
- setPageComplete(validatePage());
- }
- };
+ new ModifyListener() {
+ @Override
+ public void modifyText(ModifyEvent e) {
+ setPageComplete(validatePage());
+ }
+ };
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected boolean validatePage() {
@@ -497,6 +523,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -517,6 +544,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String getInitialObjectName() {
@@ -533,6 +561,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String getEncoding() {
@@ -543,13 +572,13 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Returns the label for the specified type name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected String getLabel(String typeName) {
try {
return FacademappingEditPlugin.INSTANCE.getString("_UI_" + typeName + "_type");
- }
- catch(MissingResourceException mre) {
+ } catch (MissingResourceException mre) {
FacademappingEditorPlugin.INSTANCE.log(mre);
}
return typeName;
@@ -558,12 +587,13 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected Collection<String> getEncodings() {
if (encodings == null) {
encodings = new ArrayList<String>();
- for (StringTokenizer stringTokenizer = new StringTokenizer(FacademappingEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens(); ) {
+ for (StringTokenizer stringTokenizer = new StringTokenizer(FacademappingEditorPlugin.INSTANCE.getString("_UI_XMLEncodingChoices")); stringTokenizer.hasMoreTokens();) {
encodings.add(stringTokenizer.nextToken());
}
}
@@ -575,9 +605,10 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* The framework calls this to create the contents of the wizard.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
- @Override
+ @Override
public void addPages() {
// Create a page, set the title, and the initial model file name.
//
@@ -596,7 +627,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
if (selectedElement instanceof IResource) {
// Get the resource parent, if its a file.
//
- IResource selectedResource = (IResource)selectedElement;
+ IResource selectedResource = (IResource) selectedElement;
if (selectedResource.getType() == IResource.FILE) {
selectedResource = selectedResource.getParent();
}
@@ -613,7 +644,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
String defaultModelBaseFilename = FacademappingEditorPlugin.INSTANCE.getString("_UI_FacademappingEditorFilenameDefaultBase");
String defaultModelFilenameExtension = FILE_EXTENSIONS.get(0);
String modelFilename = defaultModelBaseFilename + "." + defaultModelFilenameExtension;
- for (int i = 1; ((IContainer)selectedResource).findMember(modelFilename) != null; ++i) {
+ for (int i = 1; ((IContainer) selectedResource).findMember(modelFilename) != null; ++i) {
modelFilename = defaultModelBaseFilename + i + "." + defaultModelFilenameExtension;
}
newFileCreationPage.setFileName(modelFilename);
@@ -630,6 +661,7 @@ public class FacademappingModelWizard extends Wizard implements INewWizard {
* Get the file from the page.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public IFile getModelFile() {
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/CombinationGenerator.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/CombinationGenerator.java
index 2a36a6e662e..7ce3794566d 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/CombinationGenerator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/CombinationGenerator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -28,10 +28,10 @@ public class CombinationGenerator {
private BigInteger total;
public CombinationGenerator(int n, int r) {
- if(r > n) {
+ if (r > n) {
throw new IllegalArgumentException();
}
- if(n < 1) {
+ if (n < 1) {
throw new IllegalArgumentException();
}
this.n = n;
@@ -48,7 +48,7 @@ public class CombinationGenerator {
* Reset the generator
*/
public void reset() {
- for(int i = 0; i < a.length; i++) {
+ for (int i = 0; i < a.length; i++) {
a[i] = i;
}
numLeft = new BigInteger(total.toString());
@@ -56,7 +56,7 @@ public class CombinationGenerator {
/**
- *
+ *
* @return
* number of combinations not yet generated
*/
@@ -65,7 +65,7 @@ public class CombinationGenerator {
}
/**
- *
+ *
* @return true if there are more combinations
*/
public boolean hasMore() {
@@ -73,7 +73,7 @@ public class CombinationGenerator {
}
/**
- *
+ *
* @return total number of combinations
*/
public BigInteger getTotal() {
@@ -83,13 +83,13 @@ public class CombinationGenerator {
/**
* Compute the factorial of n
- *
+ *
* @param n
* @return fact(n)
*/
private static BigInteger getFactorial(int n) {
BigInteger fact = BigInteger.ONE;
- for(int i = n; i > 1; i--) {
+ for (int i = n; i > 1; i--) {
fact = fact.multiply(new BigInteger(Integer.toString(i)));
}
return fact;
@@ -97,22 +97,22 @@ public class CombinationGenerator {
/**
* Generate next combination (algorithm from Rosen)
- *
+ *
* @return next combination from generator
*/
public int[] getNext() {
- if(numLeft.equals(total)) {
+ if (numLeft.equals(total)) {
numLeft = numLeft.subtract(BigInteger.ONE);
return a;
}
int i = r - 1;
- while(a[i] == n - r + i) {
+ while (a[i] == n - r + i) {
i--;
}
a[i] = a[i] + 1;
- for(int j = i + 1; j < r; j++) {
+ for (int j = i + 1; j < r; j++) {
a[j] = a[i] + j - i;
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/FacadeUtilsActivator.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/FacadeUtilsActivator.java
index 82baa70e6ea..4bff41a65f6 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/FacadeUtilsActivator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/FacadeUtilsActivator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -26,16 +26,20 @@ public class FacadeUtilsActivator implements BundleActivator {
/*
* (non-Javadoc)
+ *
* @see org.osgi.framework.BundleActivator#start(org.osgi.framework.BundleContext)
*/
+ @Override
public void start(BundleContext bundleContext) throws Exception {
FacadeUtilsActivator.context = bundleContext;
}
/*
* (non-Javadoc)
+ *
* @see org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext)
*/
+ @Override
public void stop(BundleContext bundleContext) throws Exception {
FacadeUtilsActivator.context = null;
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/RepresentingElement.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/RepresentingElement.java
index 8fc3d8e8d8c..b7dd3a32af0 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/RepresentingElement.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/RepresentingElement.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentEList.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentEList.java
index 7e24cdc34e1..85cfea5b35f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentEList.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentEList.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -33,81 +33,81 @@ public class WrappingEObjectContainmentEList<E extends RepresentingElement> exte
@Override
public boolean add(E object) {
- if(!representedElementList.contains(((E)object).get__Represented())) {
- representedElementList.add((Element)((E)object).get__Represented());
+ if (!representedElementList.contains(object.get__Represented())) {
+ representedElementList.add((Element) object.get__Represented());
}
- if(isUnique() && contains(object)) {
+ if (isUnique() && contains(object)) {
return false;
} else {
super.doAddUnique(object);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(object, null);
}
return true;
}
- // return super.add(object);
+ // return super.add(object);
}
@Override
public void add(int index, E e) {
- if(!representedElementList.contains((e).get__Represented())) {
- representedElementList.add((Element)(e).get__Represented());
+ if (!representedElementList.contains((e).get__Represented())) {
+ representedElementList.add((Element) (e).get__Represented());
}
super.doAddUnique(index, e);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(e, null);
}
- // super.add(index, e);
+ // super.add(index, e);
}
@Override
public boolean addAll(Collection<? extends E> collection) {
- for(E e : collection) {
- if(!representedElementList.contains(e.get__Represented())) {
- representedElementList.add((Element)e.get__Represented());
+ for (E e : collection) {
+ if (!representedElementList.contains(e.get__Represented())) {
+ representedElementList.add((Element) e.get__Represented());
}
}
- if(collection.isEmpty()) {
+ if (collection.isEmpty()) {
return false;
} else {
- for(E e : collection) {
+ for (E e : collection) {
super.doAddUnique(e);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(e, null);
}
}
return true;
}
- // return super.addAll(collection);
+ // return super.addAll(collection);
}
@Override
public boolean addAll(int index, Collection<? extends E> collection) {
- for(E e : collection) {
- if(!representedElementList.contains(e.get__Represented())) {
- representedElementList.add((Element)e.get__Represented());
+ for (E e : collection) {
+ if (!representedElementList.contains(e.get__Represented())) {
+ representedElementList.add((Element) e.get__Represented());
}
}
- if(collection.isEmpty()) {
+ if (collection.isEmpty()) {
return false;
} else {
int collectionSize = collection.size();
super.doAddAllUnique(index, collection);
- if(hasInverse()) {
+ if (hasInverse()) {
int lastIndex = index + collectionSize;
- for(int i = index; i < lastIndex; ++i) {
+ for (int i = index; i < lastIndex; ++i) {
@SuppressWarnings("unchecked")
- E object = (E)data[i];
+ E object = (E) data[i];
inverseAdd(object, null);
}
}
@@ -118,51 +118,51 @@ public class WrappingEObjectContainmentEList<E extends RepresentingElement> exte
@Override
public boolean remove(Object object) {
- Object representedElement = ((RepresentingElement)object).get__Represented();
+ Object representedElement = ((RepresentingElement) object).get__Represented();
representedElementList.remove(representedElement);
- if(this.contains(object)) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
return true;
} else {
return false;
}
- // return oldObject;
+ // return oldObject;
- // return super.remove(object);
+ // return super.remove(object);
}
@Override
public E remove(int index) {
- Object representedElement = ((RepresentingElement)this.get(index)).get__Represented();
+ Object representedElement = ((RepresentingElement) this.get(index)).get__Represented();
representedElementList.remove(representedElement);
E oldObject = doRemove(index);
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
return oldObject;
- // return super.remove(index);
+ // return super.remove(index);
}
@Override
public boolean removeAll(Collection<?> collection) {
- for(Object object : collection) {
- Object representedElement = ((RepresentingElement)object).get__Represented();
+ for (Object object : collection) {
+ Object representedElement = ((RepresentingElement) object).get__Represented();
representedElementList.remove(representedElement);
}
boolean result = false;
- for(Object object : collection) {
- if(this.contains(object)) {
+ for (Object object : collection) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
result = true;
@@ -170,7 +170,7 @@ public class WrappingEObjectContainmentEList<E extends RepresentingElement> exte
}
return result;
- // return super.removeAll(collection);
+ // return super.removeAll(collection);
}
@Override
@@ -178,10 +178,10 @@ public class WrappingEObjectContainmentEList<E extends RepresentingElement> exte
representedElementList.clear();
- for(Object object : this) {
- if(this.contains(object)) {
+ for (Object object : this) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
@@ -189,7 +189,7 @@ public class WrappingEObjectContainmentEList<E extends RepresentingElement> exte
}
- // super.clear();
+ // super.clear();
}
@Override
@@ -213,7 +213,7 @@ public class WrappingEObjectContainmentEList<E extends RepresentingElement> exte
public void silentAdd(int index, E object) {
super.doAddUnique(index, object);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(object, null);
}
@@ -223,7 +223,7 @@ public class WrappingEObjectContainmentEList<E extends RepresentingElement> exte
@Override
public E silentRemove(int index) {
E oldObject = super.doRemove(index);
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentWithInverseEList.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentWithInverseEList.java
index 687ec82a940..2546ec9d202 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentWithInverseEList.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectContainmentWithInverseEList.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -33,80 +33,80 @@ public class WrappingEObjectContainmentWithInverseEList<E extends RepresentingEl
@Override
public boolean add(E object) {
- if(!representedElementList.contains(((E)object).get__Represented())) {
- representedElementList.add((Element)((E)object).get__Represented());
+ if (!representedElementList.contains(object.get__Represented())) {
+ representedElementList.add((Element) object.get__Represented());
}
- if(isUnique() && contains(object)) {
+ if (isUnique() && contains(object)) {
return false;
} else {
super.doAddUnique(object);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(object, null);
}
return true;
}
- // return super.add(object);
+ // return super.add(object);
}
@Override
public void add(int index, E e) {
- if(!representedElementList.contains((e).get__Represented())) {
- representedElementList.add((Element)(e).get__Represented());
+ if (!representedElementList.contains((e).get__Represented())) {
+ representedElementList.add((Element) (e).get__Represented());
}
super.doAddUnique(index, e);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(e, null);
}
- // super.add(index, e);
+ // super.add(index, e);
}
@Override
public boolean addAll(Collection<? extends E> collection) {
- for(E e : collection) {
- if(!representedElementList.contains(e.get__Represented())) {
- representedElementList.add((Element)e.get__Represented());
+ for (E e : collection) {
+ if (!representedElementList.contains(e.get__Represented())) {
+ representedElementList.add((Element) e.get__Represented());
}
}
- if(collection.isEmpty()) {
+ if (collection.isEmpty()) {
return false;
} else {
- for(E e : collection) {
+ for (E e : collection) {
super.doAddUnique(e);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(e, null);
}
}
return true;
}
- // return super.addAll(collection);
+ // return super.addAll(collection);
}
@Override
public boolean addAll(int index, Collection<? extends E> collection) {
- for(E e : collection) {
- if(!representedElementList.contains(e.get__Represented())) {
- representedElementList.add((Element)e.get__Represented());
+ for (E e : collection) {
+ if (!representedElementList.contains(e.get__Represented())) {
+ representedElementList.add((Element) e.get__Represented());
}
}
- if(collection.isEmpty()) {
+ if (collection.isEmpty()) {
return false;
} else {
int collectionSize = collection.size();
super.doAddAllUnique(index, collection);
- if(hasInverse()) {
+ if (hasInverse()) {
int lastIndex = index + collectionSize;
- for(int i = index; i < lastIndex; ++i) {
+ for (int i = index; i < lastIndex; ++i) {
@SuppressWarnings("unchecked")
- E object = (E)data[i];
+ E object = (E) data[i];
inverseAdd(object, null);
}
}
@@ -116,51 +116,51 @@ public class WrappingEObjectContainmentWithInverseEList<E extends RepresentingEl
@Override
public boolean remove(Object object) {
- Object representedElement = ((RepresentingElement)object).get__Represented();
+ Object representedElement = ((RepresentingElement) object).get__Represented();
representedElementList.remove(representedElement);
- if(this.contains(object)) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
return true;
} else {
return false;
}
- // return oldObject;
+ // return oldObject;
- // return super.remove(object);
+ // return super.remove(object);
}
@Override
public E remove(int index) {
- Object representedElement = ((RepresentingElement)this.get(index)).get__Represented();
+ Object representedElement = ((RepresentingElement) this.get(index)).get__Represented();
representedElementList.remove(representedElement);
E oldObject = doRemove(index);
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
return oldObject;
- // return super.remove(index);
+ // return super.remove(index);
}
@Override
public boolean removeAll(Collection<?> collection) {
- for(Object object : collection) {
- Object representedElement = ((RepresentingElement)object).get__Represented();
+ for (Object object : collection) {
+ Object representedElement = ((RepresentingElement) object).get__Represented();
representedElementList.remove(representedElement);
}
boolean result = false;
- for(Object object : collection) {
- if(this.contains(object)) {
+ for (Object object : collection) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
result = true;
@@ -168,23 +168,23 @@ public class WrappingEObjectContainmentWithInverseEList<E extends RepresentingEl
}
return result;
- // return super.removeAll(collection);
+ // return super.removeAll(collection);
}
@Override
public void clear() {
representedElementList.clear();
- for(Object object : this) {
- if(this.contains(object)) {
+ for (Object object : this) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
}
}
- // super.clear();
+ // super.clear();
}
@Override
@@ -200,7 +200,7 @@ public class WrappingEObjectContainmentWithInverseEList<E extends RepresentingEl
@Override
public void silentAdd(int index, E object) {
super.doAddUnique(index, object);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(object, null);
}
}
@@ -208,7 +208,7 @@ public class WrappingEObjectContainmentWithInverseEList<E extends RepresentingEl
@Override
public E silentRemove(int index) {
E oldObject = super.doRemove(index);
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectEList.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectEList.java
index 003f90e1f01..98f58ad8d7e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectEList.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectEList.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -33,81 +33,81 @@ public class WrappingEObjectEList<E extends RepresentingElement> extends EObject
@Override
public boolean add(E object) {
- if(!representedElementList.contains(((E)object).get__Represented())) {
- representedElementList.add((Element)((E)object).get__Represented());
+ if (!representedElementList.contains(object.get__Represented())) {
+ representedElementList.add((Element) object.get__Represented());
}
- if(isUnique() && contains(object)) {
+ if (isUnique() && contains(object)) {
return false;
} else {
super.doAddUnique(object);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(object, null);
}
return true;
}
- // return super.add(object);
+ // return super.add(object);
}
@Override
public void add(int index, E e) {
- if(!representedElementList.contains((e).get__Represented())) {
- representedElementList.add((Element)(e).get__Represented());
+ if (!representedElementList.contains((e).get__Represented())) {
+ representedElementList.add((Element) (e).get__Represented());
}
super.doAddUnique(index, e);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(e, null);
}
- // super.add(index, e);
+ // super.add(index, e);
}
@Override
public boolean addAll(Collection<? extends E> collection) {
- for(E e : collection) {
- if(!representedElementList.contains(e.get__Represented())) {
- representedElementList.add((Element)e.get__Represented());
+ for (E e : collection) {
+ if (!representedElementList.contains(e.get__Represented())) {
+ representedElementList.add((Element) e.get__Represented());
}
}
- if(collection.isEmpty()) {
+ if (collection.isEmpty()) {
return false;
} else {
- for(E e : collection) {
+ for (E e : collection) {
super.doAddUnique(e);
- if(hasInverse()) {
+ if (hasInverse()) {
inverseAdd(e, null);
}
}
return true;
}
- // return super.addAll(collection);
+ // return super.addAll(collection);
}
@Override
public boolean addAll(int index, Collection<? extends E> collection) {
- for(E e : collection) {
- if(!representedElementList.contains(e.get__Represented())) {
- representedElementList.add((Element)e.get__Represented());
+ for (E e : collection) {
+ if (!representedElementList.contains(e.get__Represented())) {
+ representedElementList.add((Element) e.get__Represented());
}
}
- if(collection.isEmpty()) {
+ if (collection.isEmpty()) {
return false;
} else {
int collectionSize = collection.size();
super.doAddAllUnique(index, collection);
- if(hasInverse()) {
+ if (hasInverse()) {
int lastIndex = index + collectionSize;
- for(int i = index; i < lastIndex; ++i) {
+ for (int i = index; i < lastIndex; ++i) {
@SuppressWarnings("unchecked")
- E object = (E)data[i];
+ E object = (E) data[i];
inverseAdd(object, null);
}
}
@@ -118,51 +118,51 @@ public class WrappingEObjectEList<E extends RepresentingElement> extends EObject
@Override
public boolean remove(Object object) {
- Object representedElement = ((RepresentingElement)object).get__Represented();
+ Object representedElement = ((RepresentingElement) object).get__Represented();
representedElementList.remove(representedElement);
- if(this.contains(object)) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
return true;
} else {
return false;
}
- // return oldObject;
+ // return oldObject;
- // return super.remove(object);
+ // return super.remove(object);
}
@Override
public E remove(int index) {
- Object representedElement = ((RepresentingElement)this.get(index)).get__Represented();
+ Object representedElement = ((RepresentingElement) this.get(index)).get__Represented();
representedElementList.remove(representedElement);
E oldObject = doRemove(index);
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
return oldObject;
- // return super.remove(index);
+ // return super.remove(index);
}
@Override
public boolean removeAll(Collection<?> collection) {
- for(Object object : collection) {
- Object representedElement = ((RepresentingElement)object).get__Represented();
+ for (Object object : collection) {
+ Object representedElement = ((RepresentingElement) object).get__Represented();
representedElementList.remove(representedElement);
}
boolean result = false;
- for(Object object : collection) {
- if(this.contains(object)) {
+ for (Object object : collection) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
result = true;
@@ -170,7 +170,7 @@ public class WrappingEObjectEList<E extends RepresentingElement> extends EObject
}
return result;
- // return super.removeAll(collection);
+ // return super.removeAll(collection);
}
@Override
@@ -178,10 +178,10 @@ public class WrappingEObjectEList<E extends RepresentingElement> extends EObject
representedElementList.clear();
- for(Object object : this) {
- if(this.contains(object)) {
+ for (Object object : this) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
- if(hasInverse() && oldObject != null) {
+ if (hasInverse() && oldObject != null) {
inverseRemove(oldObject, null);
}
@@ -189,7 +189,7 @@ public class WrappingEObjectEList<E extends RepresentingElement> extends EObject
}
- // super.clear();
+ // super.clear();
}
@Override
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectWithInverseEList.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectWithInverseEList.java
index 1c66135c8d1..ab8bc3817da 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectWithInverseEList.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingEObjectWithInverseEList.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -47,11 +47,11 @@ public class WrappingEObjectWithInverseEList<E extends RepresentingElement> exte
@Override
public boolean add(E object) {
- if(!representedElementList.contains(((E)object).get__Represented())) {
- representedElementList.add((Element)((E)object).get__Represented());
+ if (!representedElementList.contains(object.get__Represented())) {
+ representedElementList.add((Element) object.get__Represented());
}
- if(isUnique() && contains(object)) {
+ if (isUnique() && contains(object)) {
return false;
} else {
super.doAddUnique(object);
@@ -63,8 +63,8 @@ public class WrappingEObjectWithInverseEList<E extends RepresentingElement> exte
@Override
public void add(int index, E e) {
- if(!representedElementList.contains((e).get__Represented())) {
- representedElementList.add((Element)(e).get__Represented());
+ if (!representedElementList.contains((e).get__Represented())) {
+ representedElementList.add((Element) (e).get__Represented());
}
super.doAddUnique(index, e);
@@ -72,16 +72,16 @@ public class WrappingEObjectWithInverseEList<E extends RepresentingElement> exte
@Override
public boolean addAll(Collection<? extends E> collection) {
- for(E e : collection) {
- if(!representedElementList.contains(e.get__Represented())) {
- representedElementList.add((Element)e.get__Represented());
+ for (E e : collection) {
+ if (!representedElementList.contains(e.get__Represented())) {
+ representedElementList.add((Element) e.get__Represented());
}
}
- if(collection.isEmpty()) {
+ if (collection.isEmpty()) {
return false;
} else {
- for(E e : collection) {
+ for (E e : collection) {
super.doAddUnique(e);
}
return true;
@@ -91,13 +91,13 @@ public class WrappingEObjectWithInverseEList<E extends RepresentingElement> exte
@Override
public boolean addAll(int index, Collection<? extends E> collection) {
- for(E e : collection) {
- if(!representedElementList.contains(e.get__Represented())) {
- representedElementList.add((Element)e.get__Represented());
+ for (E e : collection) {
+ if (!representedElementList.contains(e.get__Represented())) {
+ representedElementList.add((Element) e.get__Represented());
}
}
- if(collection.isEmpty()) {
+ if (collection.isEmpty()) {
return false;
} else {
super.doAddAllUnique(index, collection);
@@ -108,10 +108,10 @@ public class WrappingEObjectWithInverseEList<E extends RepresentingElement> exte
@Override
public boolean remove(Object object) {
- Object representedElement = ((RepresentingElement)object).get__Represented();
+ Object representedElement = ((RepresentingElement) object).get__Represented();
representedElementList.remove(representedElement);
- if(this.contains(object)) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
return true;
} else {
@@ -122,7 +122,7 @@ public class WrappingEObjectWithInverseEList<E extends RepresentingElement> exte
@Override
public E remove(int index) {
- Object representedElement = ((RepresentingElement)this.get(index)).get__Represented();
+ Object representedElement = ((RepresentingElement) this.get(index)).get__Represented();
representedElementList.remove(representedElement);
@@ -133,15 +133,15 @@ public class WrappingEObjectWithInverseEList<E extends RepresentingElement> exte
@Override
public boolean removeAll(Collection<?> collection) {
- for(Object object : collection) {
- Object representedElement = ((RepresentingElement)object).get__Represented();
+ for (Object object : collection) {
+ Object representedElement = ((RepresentingElement) object).get__Represented();
representedElementList.remove(representedElement);
}
boolean result = false;
- for(Object object : collection) {
- if(this.contains(object)) {
+ for (Object object : collection) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
result = true;
}
@@ -154,8 +154,8 @@ public class WrappingEObjectWithInverseEList<E extends RepresentingElement> exte
representedElementList.clear();
- for(Object object : this) {
- if(this.contains(object)) {
+ for (Object object : this) {
+ if (this.contains(object)) {
E oldObject = doRemove(indexOf(object));
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingList.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingList.java
index 923d14dd4f1..a0c48a772bd 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingList.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/WrappingList.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentEList.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentEList.java
index d4cdc0f8ed1..cdf928ba2fc 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentEList.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentEList.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -31,158 +31,158 @@ public class WrappingSubsetEObjectContainmentEList<E extends RepresentingElement
public WrappingSubsetEObjectContainmentEList(Class<?> dataClass, InternalEObject owner, int featureID, Collection<Element> representedElementList, WrappingList<E>... representingSuperSets) {
super(dataClass, owner, featureID, representedElementList);
this.representingSuperSets = new ArrayList<WrappingList<E>>();
- for(int i = 0; i < representingSuperSets.length; i++) {
+ for (int i = 0; i < representingSuperSets.length; i++) {
this.representingSuperSets.add(representingSuperSets[i]);
}
}
- // @Override
- // public boolean add(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean add(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
//
- // list.getEObject().eNotify(notification);
+ // list.getEObject().eNotify(notification);
//
- // // if(!representingSuperSet.contains(object)) {
- // // representingSuperSet.notWrappingAdd(object);
- // // }
- // }
+ // // if(!representingSuperSet.contains(object)) {
+ // // representingSuperSet.notWrappingAdd(object);
+ // // }
+ // }
//
//
- // return super.add(object);
- // }
+ // return super.add(object);
+ // }
//
- // @Override
- // public void add(int index, E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // if(!representingSuperSet.contains(object)) {
- // // representingSuperSet.notWrappingAdd(object);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public void add(int index, E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // if(!representingSuperSet.contains(object)) {
+ // // representingSuperSet.notWrappingAdd(object);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // super.add(index, object);
- // }
+ // super.add(index, object);
+ // }
//
- // @Override
- // public boolean addAll(Collection<? extends E> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(E e : collection) {
- // if(!representingSuperSet.contains(e)) {
- // // representingSuperSet.notWrappingAdd(e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean addAll(Collection<? extends E> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(E e : collection) {
+ // if(!representingSuperSet.contains(e)) {
+ // // representingSuperSet.notWrappingAdd(e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
+ // }
//
- // return super.addAll(collection);
- // }
+ // return super.addAll(collection);
+ // }
//
- // @Override
- // public boolean addAll(int index, Collection<? extends E> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(E e : collection) {
- // if(!representingSuperSet.contains(e)) {
- // // representingSuperSet.notWrappingAdd(e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean addAll(int index, Collection<? extends E> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(E e : collection) {
+ // if(!representingSuperSet.contains(e)) {
+ // // representingSuperSet.notWrappingAdd(e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
+ // }
//
- // return super.addAll(index, collection);
- // }
+ // return super.addAll(index, collection);
+ // }
//
- // @Override
- // public boolean remove(Object object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // // representingSuperSet.notWrappingRemove((E)object);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean remove(Object object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // // representingSuperSet.notWrappingRemove((E)object);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), object, null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), object, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
+ // list.getEObject().eNotify(notification);
+ // }
//
- // return super.remove(object);
- // }
+ // return super.remove(object);
+ // }
//
- // @Override
- // public E remove(int index) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // // representingSuperSet.notWrappingRemove(get(index));
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public E remove(int index) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // // representingSuperSet.notWrappingRemove(get(index));
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), get(index), null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), get(index), null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
+ // list.getEObject().eNotify(notification);
+ // }
//
- // return super.remove(index);
- // }
+ // return super.remove(index);
+ // }
//
- // @Override
- // public boolean removeAll(Collection<?> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(Object e : collection) {
- // // representingSuperSet.notWrappingRemove((E)e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean removeAll(Collection<?> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(Object e : collection) {
+ // // representingSuperSet.notWrappingRemove((E)e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // return super.removeAll(collection);
- // }
+ // return super.removeAll(collection);
+ // }
//
- // @Override
- // public void clear() {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(Object e : this) {
- // // representingSuperSet.notWrappingRemove((E)e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
- //
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
+ // @Override
+ // public void clear() {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(Object e : this) {
+ // // representingSuperSet.notWrappingRemove((E)e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ //
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // super.clear();
- // }
- //
- // @Override
- // public void notWrappingAdd(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // if(!representingSuperSet.contains(object)) {
- // representingSuperSet.notWrappingAdd(object);
- // }
- // }
- //
- // doAddUnique(object);
- // }
+ // super.clear();
+ // }
+ //
+ // @Override
+ // public void notWrappingAdd(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // if(!representingSuperSet.contains(object)) {
+ // representingSuperSet.notWrappingAdd(object);
+ // }
+ // }
+ //
+ // doAddUnique(object);
+ // }
//
- // @Override
- // public E notWrappingRemove(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // representingSuperSet.notWrappingRemove(object);
- // }
+ // @Override
+ // public E notWrappingRemove(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // representingSuperSet.notWrappingRemove(object);
+ // }
//
- // return doRemove(indexOf(object));
- // }
+ // return doRemove(indexOf(object));
+ // }
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentWithInverseEList.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentWithInverseEList.java
index 520b9474cc2..29737f1f162 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentWithInverseEList.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectContainmentWithInverseEList.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -31,160 +31,160 @@ public class WrappingSubsetEObjectContainmentWithInverseEList<E extends Represen
public WrappingSubsetEObjectContainmentWithInverseEList(Class<?> dataClass, InternalEObject owner, int featureID, int inverseFeatureID, Collection<Element> representedElementList, WrappingList<E>... representingSuperSets) {
super(dataClass, owner, featureID, inverseFeatureID, representedElementList);
this.representingSuperSets = new ArrayList<WrappingList<E>>();
- for(int i = 0; i < representingSuperSets.length; i++) {
+ for (int i = 0; i < representingSuperSets.length; i++) {
this.representingSuperSets.add(representingSuperSets[i]);
}
}
- // @Override
- // public boolean add(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean add(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
//
- // list.getEObject().eNotify(notification);
+ // list.getEObject().eNotify(notification);
//
- // // if(!representingSuperSet.contains(object)) {
- // // representingSuperSet.notWrappingAdd(object);
- // // }
- // }
+ // // if(!representingSuperSet.contains(object)) {
+ // // representingSuperSet.notWrappingAdd(object);
+ // // }
+ // }
//
//
- // return super.add(object);
- // }
+ // return super.add(object);
+ // }
//
- // @Override
- // public void add(int index, E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // if(!representingSuperSet.contains(object)) {
- // // representingSuperSet.notWrappingAdd(object);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public void add(int index, E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // if(!representingSuperSet.contains(object)) {
+ // // representingSuperSet.notWrappingAdd(object);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // super.add(index, object);
- // }
+ // super.add(index, object);
+ // }
//
- // @Override
- // public boolean addAll(Collection<? extends E> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(E e : collection) {
- // if(!representingSuperSet.contains(e)) {
- // // representingSuperSet.notWrappingAdd(e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean addAll(Collection<? extends E> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(E e : collection) {
+ // if(!representingSuperSet.contains(e)) {
+ // // representingSuperSet.notWrappingAdd(e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
+ // }
//
- // return super.addAll(collection);
- // }
+ // return super.addAll(collection);
+ // }
//
- // @Override
- // public boolean addAll(int index, Collection<? extends E> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(E e : collection) {
- // if(!representingSuperSet.contains(e)) {
- // // representingSuperSet.notWrappingAdd(e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean addAll(int index, Collection<? extends E> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(E e : collection) {
+ // if(!representingSuperSet.contains(e)) {
+ // // representingSuperSet.notWrappingAdd(e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
+ // }
//
- // return super.addAll(index, collection);
- // }
+ // return super.addAll(index, collection);
+ // }
//
- // @Override
- // public boolean remove(Object object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // // representingSuperSet.notWrappingRemove((E)object);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean remove(Object object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // // representingSuperSet.notWrappingRemove((E)object);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), object, null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), object, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
+ // list.getEObject().eNotify(notification);
+ // }
//
- // return super.remove(object);
- // }
+ // return super.remove(object);
+ // }
//
- // @Override
- // public E remove(int index) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // // representingSuperSet.notWrappingRemove(get(index));
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public E remove(int index) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // // representingSuperSet.notWrappingRemove(get(index));
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), get(index), null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), get(index), null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
+ // list.getEObject().eNotify(notification);
+ // }
//
- // return super.remove(index);
- // }
+ // return super.remove(index);
+ // }
//
- // @Override
- // public boolean removeAll(Collection<?> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(Object e : collection) {
- // // representingSuperSet.notWrappingRemove((E)e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean removeAll(Collection<?> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(Object e : collection) {
+ // // representingSuperSet.notWrappingRemove((E)e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // return super.removeAll(collection);
- // }
+ // return super.removeAll(collection);
+ // }
//
- // @Override
- // public void clear() {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(Object e : this) {
- // // representingSuperSet.notWrappingRemove((E)e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
- //
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
+ // @Override
+ // public void clear() {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(Object e : this) {
+ // // representingSuperSet.notWrappingRemove((E)e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ //
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // super.clear();
- // }
- //
- // @Override
- // public void notWrappingAdd(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // if(!representingSuperSet.contains(object)) {
- // representingSuperSet.notWrappingAdd(object);
- // }
- // }
- //
- // doAddUnique(object);
- // }
+ // super.clear();
+ // }
+ //
+ // @Override
+ // public void notWrappingAdd(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // if(!representingSuperSet.contains(object)) {
+ // representingSuperSet.notWrappingAdd(object);
+ // }
+ // }
+ //
+ // doAddUnique(object);
+ // }
//
- // @Override
- // public E notWrappingRemove(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // representingSuperSet.notWrappingRemove(object);
- // }
+ // @Override
+ // public E notWrappingRemove(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // representingSuperSet.notWrappingRemove(object);
+ // }
//
- // return doRemove(indexOf(object));
- // }
+ // return doRemove(indexOf(object));
+ // }
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectEList.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectEList.java
index c71cc49f253..ffe44e415a9 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectEList.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectEList.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -32,160 +32,160 @@ public class WrappingSubsetEObjectEList<E extends RepresentingElement> extends W
public WrappingSubsetEObjectEList(Class<?> dataClass, InternalEObject owner, int featureID, Collection<Element> representedElementList, WrappingList<E>... representingSuperSets) {
super(dataClass, owner, featureID, representedElementList);
this.representingSuperSets = new ArrayList<WrappingList<E>>();
- for(int i = 0; i < representingSuperSets.length; i++) {
+ for (int i = 0; i < representingSuperSets.length; i++) {
this.representingSuperSets.add(representingSuperSets[i]);
}
}
//
- // @Override
- // public boolean add(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean add(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
//
- // list.getEObject().eNotify(notification);
+ // list.getEObject().eNotify(notification);
//
- // // if(!representingSuperSet.contains(object)) {
- // // representingSuperSet.notWrappingAdd(object);
- // // }
- // }
+ // // if(!representingSuperSet.contains(object)) {
+ // // representingSuperSet.notWrappingAdd(object);
+ // // }
+ // }
//
//
- // return super.add(object);
- // }
+ // return super.add(object);
+ // }
//
- // @Override
- // public void add(int index, E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // if(!representingSuperSet.contains(object)) {
- // // representingSuperSet.notWrappingAdd(object);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public void add(int index, E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // if(!representingSuperSet.contains(object)) {
+ // // representingSuperSet.notWrappingAdd(object);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // super.add(index, object);
- // }
+ // super.add(index, object);
+ // }
//
- // @Override
- // public boolean addAll(Collection<? extends E> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(E e : collection) {
- // if(!representingSuperSet.contains(e)) {
- // // representingSuperSet.notWrappingAdd(e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean addAll(Collection<? extends E> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(E e : collection) {
+ // if(!representingSuperSet.contains(e)) {
+ // // representingSuperSet.notWrappingAdd(e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
+ // }
//
- // return super.addAll(collection);
- // }
+ // return super.addAll(collection);
+ // }
//
- // @Override
- // public boolean addAll(int index, Collection<? extends E> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(E e : collection) {
- // if(!representingSuperSet.contains(e)) {
- // // representingSuperSet.notWrappingAdd(e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean addAll(int index, Collection<? extends E> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(E e : collection) {
+ // if(!representingSuperSet.contains(e)) {
+ // // representingSuperSet.notWrappingAdd(e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
+ // }
//
- // return super.addAll(index, collection);
- // }
+ // return super.addAll(index, collection);
+ // }
//
- // @Override
- // public boolean remove(Object object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // // representingSuperSet.notWrappingRemove((E)object);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean remove(Object object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // // representingSuperSet.notWrappingRemove((E)object);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), object, null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), object, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
+ // list.getEObject().eNotify(notification);
+ // }
//
- // return super.remove(object);
- // }
+ // return super.remove(object);
+ // }
//
- // @Override
- // public E remove(int index) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // // representingSuperSet.notWrappingRemove(get(index));
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public E remove(int index) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // // representingSuperSet.notWrappingRemove(get(index));
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), get(index), null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), get(index), null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
+ // list.getEObject().eNotify(notification);
+ // }
//
- // return super.remove(index);
- // }
+ // return super.remove(index);
+ // }
//
- // @Override
- // public boolean removeAll(Collection<?> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(Object e : collection) {
- // // representingSuperSet.notWrappingRemove((E)e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean removeAll(Collection<?> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(Object e : collection) {
+ // // representingSuperSet.notWrappingRemove((E)e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // return super.removeAll(collection);
- // }
+ // return super.removeAll(collection);
+ // }
//
- // @Override
- // public void clear() {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(Object e : this) {
- // // representingSuperSet.notWrappingRemove((E)e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
- //
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
+ // @Override
+ // public void clear() {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(Object e : this) {
+ // // representingSuperSet.notWrappingRemove((E)e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ //
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // super.clear();
- // }
- //
- // @Override
- // public void notWrappingAdd(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // if(!representingSuperSet.contains(object)) {
- // representingSuperSet.notWrappingAdd(object);
- // }
- // }
- //
- // super.notWrappingAdd(object);
- // }
+ // super.clear();
+ // }
+ //
+ // @Override
+ // public void notWrappingAdd(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // if(!representingSuperSet.contains(object)) {
+ // representingSuperSet.notWrappingAdd(object);
+ // }
+ // }
+ //
+ // super.notWrappingAdd(object);
+ // }
//
- // @Override
- // public E notWrappingRemove(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // representingSuperSet.notWrappingRemove(object);
- // }
+ // @Override
+ // public E notWrappingRemove(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // representingSuperSet.notWrappingRemove(object);
+ // }
//
- // return super.notWrappingRemove(object);
- // }
+ // return super.notWrappingRemove(object);
+ // }
//
//
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectWithInverseEList.java b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectWithInverseEList.java
index be82b916c77..7bcf508406f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectWithInverseEList.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade.utils/src/org/eclipse/papyrus/facade/utils/wrappinglist/subset/WrappingSubsetEObjectWithInverseEList.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -45,159 +45,159 @@ public class WrappingSubsetEObjectWithInverseEList<E extends RepresentingElement
public WrappingSubsetEObjectWithInverseEList(Class<?> dataClass, InternalEObject owner, int featureID, int inverseFeatureID, Collection<Element> representedElementList, WrappingList<E>... representingSuperSets) {
super(dataClass, owner, featureID, inverseFeatureID, representedElementList);
this.representingSuperSets = new ArrayList<WrappingList<E>>();
- for(int i = 0; i < representingSuperSets.length; i++) {
+ for (int i = 0; i < representingSuperSets.length; i++) {
this.representingSuperSets.add(representingSuperSets[i]);
}
}
- // @Override
- // public boolean add(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean add(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
//
- // list.getEObject().eNotify(notification);
+ // list.getEObject().eNotify(notification);
//
- // // if(!representingSuperSet.contains(object)) {
- // // representingSuperSet.notWrappingAdd(object);
- // // }
- // }
+ // // if(!representingSuperSet.contains(object)) {
+ // // representingSuperSet.notWrappingAdd(object);
+ // // }
+ // }
//
//
- // return super.add(object);
- // }
+ // return super.add(object);
+ // }
//
- // @Override
- // public void add(int index, E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // if(!representingSuperSet.contains(object)) {
- // // representingSuperSet.notWrappingAdd(object);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public void add(int index, E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // if(!representingSuperSet.contains(object)) {
+ // // representingSuperSet.notWrappingAdd(object);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, object, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // super.add(index, object);
- // }
+ // super.add(index, object);
+ // }
//
- // @Override
- // public boolean addAll(Collection<? extends E> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(E e : collection) {
- // if(!representingSuperSet.contains(e)) {
- // // representingSuperSet.notWrappingAdd(e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean addAll(Collection<? extends E> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(E e : collection) {
+ // if(!representingSuperSet.contains(e)) {
+ // // representingSuperSet.notWrappingAdd(e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
+ // }
//
- // return super.addAll(collection);
- // }
+ // return super.addAll(collection);
+ // }
//
- // @Override
- // public boolean addAll(int index, Collection<? extends E> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(E e : collection) {
- // if(!representingSuperSet.contains(e)) {
- // // representingSuperSet.notWrappingAdd(e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean addAll(int index, Collection<? extends E> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(E e : collection) {
+ // if(!representingSuperSet.contains(e)) {
+ // // representingSuperSet.notWrappingAdd(e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.ADD, list.getEStructuralFeature(), null, e, list.size(), true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
+ // }
//
- // return super.addAll(index, collection);
- // }
+ // return super.addAll(index, collection);
+ // }
//
- // @Override
- // public boolean remove(Object object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // // representingSuperSet.notWrappingRemove((E)object);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean remove(Object object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // // representingSuperSet.notWrappingRemove((E)object);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), object, null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), object, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
+ // list.getEObject().eNotify(notification);
+ // }
//
- // return super.remove(object);
- // }
+ // return super.remove(object);
+ // }
//
- // @Override
- // public E remove(int index) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // // representingSuperSet.notWrappingRemove(get(index));
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public E remove(int index) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // // representingSuperSet.notWrappingRemove(get(index));
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), get(index), null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), get(index), null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
+ // list.getEObject().eNotify(notification);
+ // }
//
- // return super.remove(index);
- // }
+ // return super.remove(index);
+ // }
//
- // @Override
- // public boolean removeAll(Collection<?> collection) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(Object e : collection) {
- // // representingSuperSet.notWrappingRemove((E)e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ // @Override
+ // public boolean removeAll(Collection<?> collection) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(Object e : collection) {
+ // // representingSuperSet.notWrappingRemove((E)e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
//
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // return super.removeAll(collection);
- // }
+ // return super.removeAll(collection);
+ // }
//
- // @Override
- // public void clear() {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // for(Object e : this) {
- // // representingSuperSet.notWrappingRemove((E)e);
- // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
- //
- // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
+ // @Override
+ // public void clear() {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // for(Object e : this) {
+ // // representingSuperSet.notWrappingRemove((E)e);
+ // EcoreEList<E> list = ((EcoreEList<E>)representingSuperSet);
+ //
+ // Notification notification = new ENotificationImpl((InternalEObject)list.getEObject(), Notification.REMOVE, list.getEStructuralFeature(), e, null, list.size() - 1, true);
//
- // list.getEObject().eNotify(notification);
- // }
- // }
+ // list.getEObject().eNotify(notification);
+ // }
+ // }
//
- // super.clear();
- // }
- //
- // @Override
- // public void notWrappingAdd(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // if(!representingSuperSet.contains(object)) {
- // representingSuperSet.notWrappingAdd(object);
- // }
- // }
- //
- // doAddUnique(object);
- // }
+ // super.clear();
+ // }
+ //
+ // @Override
+ // public void notWrappingAdd(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // if(!representingSuperSet.contains(object)) {
+ // representingSuperSet.notWrappingAdd(object);
+ // }
+ // }
+ //
+ // doAddUnique(object);
+ // }
//
- // @Override
- // public E notWrappingRemove(E object) {
- // for(WrappingList representingSuperSet : representingSuperSets) {
- // representingSuperSet.notWrappingRemove(object);
- // }
+ // @Override
+ // public E notWrappingRemove(E object) {
+ // for(WrappingList representingSuperSet : representingSuperSets) {
+ // representingSuperSet.notWrappingRemove(object);
+ // }
//
- // return doRemove(indexOf(object));
- // }
+ // return doRemove(indexOf(object));
+ // }
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Facade.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Facade.java
index dbd3ff5c558..464b40973f4 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Facade.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Facade.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -22,7 +22,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel;
* <!-- begin-user-doc -->
* A representation of the model object '<em><b>Facade</b></em>'.
* <!-- end-user-doc -->
- *
+ *
* <p>
* The following features are supported:
* <ul>
@@ -30,7 +30,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel;
* <li>{@link org.eclipse.papyrus.facade.Facade#getVirtualmetamodel <em>Virtualmetamodel</em>}</li>
* </ul>
* </p>
- *
+ *
* @see org.eclipse.papyrus.facade.FacadePackage#getFacade()
* @model
* @generated
@@ -43,11 +43,10 @@ public interface Facade extends EObject {
* It is bidirectional and its opposite is '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getFacade <em>Facade</em>}'.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Extension Definitions</em>' containment reference list isn't clear, there really should be more of a description
- * here...
+ * If the meaning of the '<em>Extension Definitions</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
- *
+ *
* @return the value of the '<em>Extension Definitions</em>' containment reference list.
* @see org.eclipse.papyrus.facade.FacadePackage#getFacade_ExtensionDefinitions()
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getFacade
@@ -64,7 +63,7 @@ public interface Facade extends EObject {
* If the meaning of the '<em>Virtualmetamodel</em>' containment reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
- *
+ *
* @return the value of the '<em>Virtualmetamodel</em>' containment reference.
* @see #setVirtualmetamodel(VirtualMetamodel)
* @see org.eclipse.papyrus.facade.FacadePackage#getFacade_Virtualmetamodel()
@@ -78,9 +77,9 @@ public interface Facade extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.Facade#getVirtualmetamodel <em>Virtualmetamodel</em>}' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- *
+ *
* @param value
- * the new value of the '<em>Virtualmetamodel</em>' containment reference.
+ * the new value of the '<em>Virtualmetamodel</em>' containment reference.
* @see #getVirtualmetamodel()
* @generated
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeActivator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeActivator.java
index e12cf20f787..fe9ab4d4a0e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeActivator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeActivator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -32,7 +32,7 @@ public class FacadeActivator extends AbstractUIPlugin {
/**
* Gets the context.
- *
+ *
* @return the context
*/
static BundleContext getContext() {
@@ -46,7 +46,7 @@ public class FacadeActivator extends AbstractUIPlugin {
*/
/**
* @see org.eclipse.ui.plugin.AbstractUIPlugin#start(org.osgi.framework.BundleContext)
- *
+ *
* @param bundleContext
* @throws Exception
*/
@@ -64,7 +64,7 @@ public class FacadeActivator extends AbstractUIPlugin {
*/
/**
* @see org.eclipse.ui.plugin.AbstractUIPlugin#stop(org.osgi.framework.BundleContext)
- *
+ *
* @param bundleContext
* @throws Exception
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeFactory.java
index 5f04c5f44b2..ca14ad6c43b 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadeFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -20,6 +20,7 @@ import org.eclipse.emf.ecore.EFactory;
* The <b>Factory</b> for the model.
* It provides a create method for each non-abstract class of the model.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.FacadePackage
* @generated
*/
@@ -28,6 +29,7 @@ public interface FacadeFactory extends EFactory {
* The singleton instance of the factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
FacadeFactory eINSTANCE = org.eclipse.papyrus.facade.impl.FacadeFactoryImpl.init();
@@ -36,6 +38,7 @@ public interface FacadeFactory extends EFactory {
* Returns a new object of class '<em>Facade</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Facade</em>'.
* @generated
*/
@@ -45,9 +48,10 @@ public interface FacadeFactory extends EFactory {
* Returns the package supported by this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the package supported by this factory.
* @generated
*/
FacadePackage getFacadePackage();
-} //FacadeFactory
+} // FacadeFactory
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadePackage.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadePackage.java
index baca9d18fb7..bf1e117a145 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadePackage.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/FacadePackage.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -22,13 +22,14 @@ import org.eclipse.emf.ecore.EReference;
* The <b>Package</b> for the model.
* It contains accessors for the meta objects to represent
* <ul>
- * <li>each class,</li>
- * <li>each feature of each class,</li>
- * <li>each operation of each class,</li>
- * <li>each enum,</li>
- * <li>and each data type</li>
+ * <li>each class,</li>
+ * <li>each feature of each class,</li>
+ * <li>each operation of each class,</li>
+ * <li>each enum,</li>
+ * <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.FacadeFactory
* @model kind="package"
* @generated
@@ -38,6 +39,7 @@ public interface FacadePackage extends EPackage {
* The package name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNAME = "facade";
@@ -46,6 +48,7 @@ public interface FacadePackage extends EPackage {
* The package namespace URI.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNS_URI = "http://www.eclipse.org/papyrus/facade";
@@ -54,6 +57,7 @@ public interface FacadePackage extends EPackage {
* The package namespace name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNS_PREFIX = "facade";
@@ -62,6 +66,7 @@ public interface FacadePackage extends EPackage {
* The singleton instance of the package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
FacadePackage eINSTANCE = org.eclipse.papyrus.facade.impl.FacadePackageImpl.init();
@@ -70,6 +75,7 @@ public interface FacadePackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.impl.FacadeImpl <em>Facade</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.impl.FacadeImpl
* @see org.eclipse.papyrus.facade.impl.FacadePackageImpl#getFacade()
* @generated
@@ -80,6 +86,7 @@ public interface FacadePackage extends EPackage {
* The feature id for the '<em><b>Extension Definitions</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -89,6 +96,7 @@ public interface FacadePackage extends EPackage {
* The feature id for the '<em><b>Virtualmetamodel</b></em>' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -98,6 +106,7 @@ public interface FacadePackage extends EPackage {
* The number of structural features of the '<em>Facade</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -107,6 +116,7 @@ public interface FacadePackage extends EPackage {
* The number of operations of the '<em>Facade</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -117,6 +127,7 @@ public interface FacadePackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.Facade <em>Facade</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Facade</em>'.
* @see org.eclipse.papyrus.facade.Facade
* @generated
@@ -127,6 +138,7 @@ public interface FacadePackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facade.Facade#getExtensionDefinitions <em>Extension Definitions</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Extension Definitions</em>'.
* @see org.eclipse.papyrus.facade.Facade#getExtensionDefinitions()
* @see #getFacade()
@@ -138,6 +150,7 @@ public interface FacadePackage extends EPackage {
* Returns the meta object for the containment reference '{@link org.eclipse.papyrus.facade.Facade#getVirtualmetamodel <em>Virtualmetamodel</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference '<em>Virtualmetamodel</em>'.
* @see org.eclipse.papyrus.facade.Facade#getVirtualmetamodel()
* @see #getFacade()
@@ -149,6 +162,7 @@ public interface FacadePackage extends EPackage {
* Returns the factory that creates the instances of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the factory that creates the instances of the model.
* @generated
*/
@@ -158,13 +172,14 @@ public interface FacadePackage extends EPackage {
* <!-- begin-user-doc -->
* Defines literals for the meta objects that represent
* <ul>
- * <li>each class,</li>
- * <li>each feature of each class,</li>
- * <li>each operation of each class,</li>
- * <li>each enum,</li>
- * <li>and each data type</li>
+ * <li>each class,</li>
+ * <li>each feature of each class,</li>
+ * <li>each operation of each class,</li>
+ * <li>each enum,</li>
+ * <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
+ *
* @generated
*/
interface Literals {
@@ -172,6 +187,7 @@ public interface FacadePackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.impl.FacadeImpl <em>Facade</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.impl.FacadeImpl
* @see org.eclipse.papyrus.facade.impl.FacadePackageImpl#getFacade()
* @generated
@@ -182,6 +198,7 @@ public interface FacadePackage extends EPackage {
* The meta object literal for the '<em><b>Extension Definitions</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference FACADE__EXTENSION_DEFINITIONS = eINSTANCE.getFacade_ExtensionDefinitions();
@@ -190,10 +207,11 @@ public interface FacadePackage extends EPackage {
* The meta object literal for the '<em><b>Virtualmetamodel</b></em>' containment reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference FACADE__VIRTUALMETAMODEL = eINSTANCE.getFacade_Virtualmetamodel();
}
-} //FacadePackage
+} // FacadePackage
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Messages.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Messages.java
index 591feb59e96..78753b94719 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Messages.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/Messages.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/BaseMetaclass.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/BaseMetaclass.java
index 12af73d2ab3..5f78bf4bd66 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/BaseMetaclass.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/BaseMetaclass.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,11 +25,11 @@ import org.eclipse.emf.ecore.EObject;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getIncompatibleStereotypes <em>Incompatible Stereotypes</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getBase <em>Base</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getExtensionDefinition <em>Extension Definition</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getCompatibleStereotypes <em>Compatible Stereotypes</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#isPossible <em>Possible</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getIncompatibleStereotypes <em>Incompatible Stereotypes</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getBase <em>Base</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getExtensionDefinition <em>Extension Definition</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getCompatibleStereotypes <em>Compatible Stereotypes</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#isPossible <em>Possible</em>}</li>
* </ul>
* </p>
*
@@ -43,10 +43,10 @@ public interface BaseMetaclass extends EObject {
* The list contents are of type {@link org.eclipse.papyrus.facade.extensiondefinition.Combination}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Incompatible Stereotypes</em>' containment reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Incompatible Stereotypes</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Incompatible Stereotypes</em>' containment reference list.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getBaseMetaclass_IncompatibleStereotypes()
* @model containment="true"
@@ -58,10 +58,10 @@ public interface BaseMetaclass extends EObject {
* Returns the value of the '<em><b>Base</b></em>' reference.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Base</em>' reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Base</em>' reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Base</em>' reference.
* @see #setBase(EObject)
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getBaseMetaclass_Base()
@@ -74,7 +74,9 @@ public interface BaseMetaclass extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getBase <em>Base</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Base</em>' reference.
+ *
+ * @param value
+ * the new value of the '<em>Base</em>' reference.
* @see #getBase()
* @generated
*/
@@ -85,10 +87,10 @@ public interface BaseMetaclass extends EObject {
* It is bidirectional and its opposite is '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getBaseMetaclasses <em>Base Metaclasses</em>}'.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Extension Definition</em>' container reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Extension Definition</em>' container reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Extension Definition</em>' container reference.
* @see #setExtensionDefinition(ExtensionDefinition)
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getBaseMetaclass_ExtensionDefinition()
@@ -102,7 +104,9 @@ public interface BaseMetaclass extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getExtensionDefinition <em>Extension Definition</em>}' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Extension Definition</em>' container reference.
+ *
+ * @param value
+ * the new value of the '<em>Extension Definition</em>' container reference.
* @see #getExtensionDefinition()
* @generated
*/
@@ -113,10 +117,10 @@ public interface BaseMetaclass extends EObject {
* The list contents are of type {@link org.eclipse.papyrus.facade.extensiondefinition.Combination}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Compatible Stereotypes</em>' containment reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Compatible Stereotypes</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Compatible Stereotypes</em>' containment reference list.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getBaseMetaclass_CompatibleStereotypes()
* @model containment="true"
@@ -128,10 +132,10 @@ public interface BaseMetaclass extends EObject {
* Returns the value of the '<em><b>Possible</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Possible</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Possible</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Possible</em>' attribute.
* @see #setPossible(boolean)
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getBaseMetaclass_Possible()
@@ -144,7 +148,9 @@ public interface BaseMetaclass extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#isPossible <em>Possible</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Possible</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Possible</em>' attribute.
* @see #isPossible()
* @generated
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/Combination.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/Combination.java
index 7cdd737aa62..b86b39f8f95 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/Combination.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/Combination.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,7 +25,7 @@ import org.eclipse.emf.ecore.EObject;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.Combination#getMembers <em>Members</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.Combination#getMembers <em>Members</em>}</li>
* </ul>
* </p>
*
@@ -39,10 +39,10 @@ public interface Combination extends EObject {
* The list contents are of type {@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Members</em>' reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Members</em>' reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Members</em>' reference list.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getCombination_Members()
* @model
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinition.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinition.java
index 2ec7c5abd30..de1d7f671bf 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinition.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinition.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -30,11 +30,11 @@ import org.eclipse.uml2.uml.Stereotype;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getExtension <em>Extension</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getBaseMetaclasses <em>Base Metaclasses</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getFacade <em>Facade</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getStereotype <em>Stereotype</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getKind <em>Kind</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getExtension <em>Extension</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getBaseMetaclasses <em>Base Metaclasses</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getFacade <em>Facade</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getStereotype <em>Stereotype</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getKind <em>Kind</em>}</li>
* </ul>
* </p>
*
@@ -47,10 +47,10 @@ public interface ExtensionDefinition extends EObject {
* Returns the value of the '<em><b>Extension</b></em>' reference.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Extension</em>' reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Extension</em>' reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Extension</em>' reference.
* @see #setExtension(Extension)
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getExtensionDefinition_Extension()
@@ -63,7 +63,9 @@ public interface ExtensionDefinition extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getExtension <em>Extension</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Extension</em>' reference.
+ *
+ * @param value
+ * the new value of the '<em>Extension</em>' reference.
* @see #getExtension()
* @generated
*/
@@ -75,10 +77,10 @@ public interface ExtensionDefinition extends EObject {
* It is bidirectional and its opposite is '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getExtensionDefinition <em>Extension Definition</em>}'.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Base Metaclasses</em>' containment reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Base Metaclasses</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Base Metaclasses</em>' containment reference list.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getExtensionDefinition_BaseMetaclasses()
* @see org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getExtensionDefinition
@@ -92,10 +94,10 @@ public interface ExtensionDefinition extends EObject {
* It is bidirectional and its opposite is '{@link org.eclipse.papyrus.facade.Facade#getExtensionDefinitions <em>Extension Definitions</em>}'.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Facade</em>' container reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Facade</em>' container reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Facade</em>' container reference.
* @see #setFacade(Facade)
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getExtensionDefinition_Facade()
@@ -109,7 +111,9 @@ public interface ExtensionDefinition extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getFacade <em>Facade</em>}' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Facade</em>' container reference.
+ *
+ * @param value
+ * the new value of the '<em>Facade</em>' container reference.
* @see #getFacade()
* @generated
*/
@@ -119,10 +123,10 @@ public interface ExtensionDefinition extends EObject {
* Returns the value of the '<em><b>Stereotype</b></em>' reference.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Stereotype</em>' reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Stereotype</em>' reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Stereotype</em>' reference.
* @see #setStereotype(Stereotype)
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getExtensionDefinition_Stereotype()
@@ -135,7 +139,9 @@ public interface ExtensionDefinition extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getStereotype <em>Stereotype</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Stereotype</em>' reference.
+ *
+ * @param value
+ * the new value of the '<em>Stereotype</em>' reference.
* @see #getStereotype()
* @generated
*/
@@ -146,10 +152,10 @@ public interface ExtensionDefinition extends EObject {
* The literals are from the enumeration {@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Kind</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Kind</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Kind</em>' attribute.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind
* @see #setKind(ExtensionDefinitionKind)
@@ -163,7 +169,9 @@ public interface ExtensionDefinition extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getKind <em>Kind</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Kind</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Kind</em>' attribute.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind
* @see #getKind()
* @generated
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinitionKind.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinitionKind.java
index bc28f92de5e..657486c0d96 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinitionKind.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensionDefinitionKind.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -24,6 +24,7 @@ import org.eclipse.emf.common.util.Enumerator;
* A representation of the literals of the enumeration '<em><b>Extension Definition Kind</b></em>',
* and utility methods for working with them.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#getExtensionDefinitionKind()
* @model
* @generated
@@ -33,6 +34,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Association</b></em>' literal object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #ASSOCIATION_VALUE
* @generated
* @ordered
@@ -43,6 +45,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Generalization</b></em>' literal object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #GENERALIZATION_VALUE
* @generated
* @ordered
@@ -53,6 +56,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Multi Generalization</b></em>' literal object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #MULTI_GENERALIZATION_VALUE
* @generated
* @ordered
@@ -63,6 +67,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Fusion</b></em>' literal object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #FUSION_VALUE
* @generated
* @ordered
@@ -73,10 +78,10 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Association</b></em>' literal value.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of '<em><b>Association</b></em>' literal object isn't clear,
- * there really should be more of a description here...
+ * If the meaning of '<em><b>Association</b></em>' literal object isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @see #ASSOCIATION
* @model name="Association"
* @generated
@@ -88,10 +93,10 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Generalization</b></em>' literal value.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of '<em><b>Generalization</b></em>' literal object isn't clear,
- * there really should be more of a description here...
+ * If the meaning of '<em><b>Generalization</b></em>' literal object isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @see #GENERALIZATION
* @model name="Generalization"
* @generated
@@ -103,10 +108,10 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Multi Generalization</b></em>' literal value.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of '<em><b>Multi Generalization</b></em>' literal object isn't clear,
- * there really should be more of a description here...
+ * If the meaning of '<em><b>Multi Generalization</b></em>' literal object isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @see #MULTI_GENERALIZATION
* @model name="MultiGeneralization"
* @generated
@@ -118,10 +123,10 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Fusion</b></em>' literal value.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of '<em><b>Fusion</b></em>' literal object isn't clear,
- * there really should be more of a description here...
+ * If the meaning of '<em><b>Fusion</b></em>' literal object isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @see #FUSION
* @model name="Fusion"
* @generated
@@ -133,20 +138,22 @@ public enum ExtensionDefinitionKind implements Enumerator {
* An array of all the '<em><b>Extension Definition Kind</b></em>' enumerators.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static final ExtensionDefinitionKind[] VALUES_ARRAY =
- new ExtensionDefinitionKind[] {
- ASSOCIATION,
- GENERALIZATION,
- MULTI_GENERALIZATION,
- FUSION,
- };
+ new ExtensionDefinitionKind[] {
+ ASSOCIATION,
+ GENERALIZATION,
+ MULTI_GENERALIZATION,
+ FUSION,
+ };
/**
* A public read-only list of all the '<em><b>Extension Definition Kind</b></em>' enumerators.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final List<ExtensionDefinitionKind> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY));
@@ -155,6 +162,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* Returns the '<em><b>Extension Definition Kind</b></em>' literal with the specified literal value.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static ExtensionDefinitionKind get(String literal) {
@@ -171,6 +179,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* Returns the '<em><b>Extension Definition Kind</b></em>' literal with the specified name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static ExtensionDefinitionKind getByName(String name) {
@@ -187,14 +196,19 @@ public enum ExtensionDefinitionKind implements Enumerator {
* Returns the '<em><b>Extension Definition Kind</b></em>' literal with the specified integer value.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static ExtensionDefinitionKind get(int value) {
switch (value) {
- case ASSOCIATION_VALUE: return ASSOCIATION;
- case GENERALIZATION_VALUE: return GENERALIZATION;
- case MULTI_GENERALIZATION_VALUE: return MULTI_GENERALIZATION;
- case FUSION_VALUE: return FUSION;
+ case ASSOCIATION_VALUE:
+ return ASSOCIATION;
+ case GENERALIZATION_VALUE:
+ return GENERALIZATION;
+ case MULTI_GENERALIZATION_VALUE:
+ return MULTI_GENERALIZATION;
+ case FUSION_VALUE:
+ return FUSION;
}
return null;
}
@@ -202,6 +216,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private final int value;
@@ -209,6 +224,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private final String name;
@@ -216,6 +232,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private final String literal;
@@ -224,6 +241,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* Only this class can construct instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private ExtensionDefinitionKind(int value, String name, String literal) {
@@ -235,39 +253,46 @@ public enum ExtensionDefinitionKind implements Enumerator {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public int getValue() {
- return value;
+ return value;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public String getName() {
- return name;
+ return name;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public String getLiteral() {
- return literal;
+ return literal;
}
/**
* Returns the literal value of the enumerator, which is its string representation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String toString() {
return literal;
}
-
-} //ExtensionDefinitionKind
+
+} // ExtensionDefinitionKind
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionFactory.java
index e27620f6dd9..d0e731a6de7 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -20,6 +20,7 @@ import org.eclipse.emf.ecore.EFactory;
* The <b>Factory</b> for the model.
* It provides a create method for each non-abstract class of the model.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage
* @generated
*/
@@ -28,6 +29,7 @@ public interface ExtensiondefinitionFactory extends EFactory {
* The singleton instance of the factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
ExtensiondefinitionFactory eINSTANCE = org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionFactoryImpl.init();
@@ -36,6 +38,7 @@ public interface ExtensiondefinitionFactory extends EFactory {
* Returns a new object of class '<em>Extension Definition</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Extension Definition</em>'.
* @generated
*/
@@ -45,6 +48,7 @@ public interface ExtensiondefinitionFactory extends EFactory {
* Returns a new object of class '<em>Base Metaclass</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Base Metaclass</em>'.
* @generated
*/
@@ -54,6 +58,7 @@ public interface ExtensiondefinitionFactory extends EFactory {
* Returns a new object of class '<em>Combination</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Combination</em>'.
* @generated
*/
@@ -63,9 +68,10 @@ public interface ExtensiondefinitionFactory extends EFactory {
* Returns the package supported by this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the package supported by this factory.
* @generated
*/
ExtensiondefinitionPackage getExtensiondefinitionPackage();
-} //ExtensiondefinitionFactory
+} // ExtensiondefinitionFactory
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionPackage.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionPackage.java
index b1f9cc40a6e..62dfc5532d2 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionPackage.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/ExtensiondefinitionPackage.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -24,13 +24,14 @@ import org.eclipse.emf.ecore.EReference;
* The <b>Package</b> for the model.
* It contains accessors for the meta objects to represent
* <ul>
- * <li>each class,</li>
- * <li>each feature of each class,</li>
- * <li>each operation of each class,</li>
- * <li>each enum,</li>
- * <li>and each data type</li>
+ * <li>each class,</li>
+ * <li>each feature of each class,</li>
+ * <li>each operation of each class,</li>
+ * <li>each enum,</li>
+ * <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionFactory
* @model kind="package"
* @generated
@@ -40,6 +41,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The package name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNAME = "extensiondefinition";
@@ -48,6 +50,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The package namespace URI.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNS_URI = "http://www.eclipse.org/papyrus/extensiondefinition";
@@ -56,6 +59,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The package namespace name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNS_PREFIX = "extensiondefinition";
@@ -64,6 +68,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The singleton instance of the package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
ExtensiondefinitionPackage eINSTANCE = org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionPackageImpl.init();
@@ -72,6 +77,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl <em>Extension Definition</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionPackageImpl#getExtensionDefinition()
* @generated
@@ -82,6 +88,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Extension</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -91,6 +98,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Base Metaclasses</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -100,6 +108,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Facade</b></em>' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -109,6 +118,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Stereotype</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -118,6 +128,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Kind</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -127,6 +138,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The number of structural features of the '<em>Extension Definition</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -136,6 +148,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The number of operations of the '<em>Extension Definition</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -145,6 +158,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl <em>Base Metaclass</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionPackageImpl#getBaseMetaclass()
* @generated
@@ -155,6 +169,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Incompatible Stereotypes</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -164,6 +179,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Base</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -173,6 +189,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Extension Definition</b></em>' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -182,6 +199,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Compatible Stereotypes</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -191,6 +209,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Possible</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -200,6 +219,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The number of structural features of the '<em>Base Metaclass</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -209,6 +229,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The number of operations of the '<em>Base Metaclass</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -218,6 +239,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.extensiondefinition.impl.CombinationImpl <em>Combination</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.CombinationImpl
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionPackageImpl#getCombination()
* @generated
@@ -228,6 +250,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The feature id for the '<em><b>Members</b></em>' reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -237,6 +260,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The number of structural features of the '<em>Combination</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -246,6 +270,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The number of operations of the '<em>Combination</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -255,6 +280,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind <em>Extension Definition Kind</em>}' enum.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionPackageImpl#getExtensionDefinitionKind()
* @generated
@@ -266,6 +292,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition <em>Extension Definition</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Extension Definition</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition
* @generated
@@ -276,6 +303,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the reference '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getExtension <em>Extension</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference '<em>Extension</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getExtension()
* @see #getExtensionDefinition()
@@ -287,6 +315,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getBaseMetaclasses <em>Base Metaclasses</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Base Metaclasses</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getBaseMetaclasses()
* @see #getExtensionDefinition()
@@ -298,6 +327,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the container reference '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getFacade <em>Facade</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the container reference '<em>Facade</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getFacade()
* @see #getExtensionDefinition()
@@ -309,6 +339,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the reference '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getStereotype <em>Stereotype</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference '<em>Stereotype</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getStereotype()
* @see #getExtensionDefinition()
@@ -320,6 +351,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getKind <em>Kind</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Kind</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition#getKind()
* @see #getExtensionDefinition()
@@ -331,6 +363,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass <em>Base Metaclass</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Base Metaclass</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass
* @generated
@@ -341,6 +374,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getIncompatibleStereotypes <em>Incompatible Stereotypes</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Incompatible Stereotypes</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getIncompatibleStereotypes()
* @see #getBaseMetaclass()
@@ -352,6 +386,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the reference '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getBase <em>Base</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference '<em>Base</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getBase()
* @see #getBaseMetaclass()
@@ -363,6 +398,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the container reference '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getExtensionDefinition <em>Extension Definition</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the container reference '<em>Extension Definition</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getExtensionDefinition()
* @see #getBaseMetaclass()
@@ -374,6 +410,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getCompatibleStereotypes <em>Compatible Stereotypes</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Compatible Stereotypes</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#getCompatibleStereotypes()
* @see #getBaseMetaclass()
@@ -385,6 +422,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#isPossible <em>Possible</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Possible</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass#isPossible()
* @see #getBaseMetaclass()
@@ -396,6 +434,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.extensiondefinition.Combination <em>Combination</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Combination</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.Combination
* @generated
@@ -406,6 +445,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for the reference list '{@link org.eclipse.papyrus.facade.extensiondefinition.Combination#getMembers <em>Members</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference list '<em>Members</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.Combination#getMembers()
* @see #getCombination()
@@ -417,6 +457,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the meta object for enum '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind <em>Extension Definition Kind</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for enum '<em>Extension Definition Kind</em>'.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind
* @generated
@@ -427,6 +468,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* Returns the factory that creates the instances of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the factory that creates the instances of the model.
* @generated
*/
@@ -436,13 +478,14 @@ public interface ExtensiondefinitionPackage extends EPackage {
* <!-- begin-user-doc -->
* Defines literals for the meta objects that represent
* <ul>
- * <li>each class,</li>
- * <li>each feature of each class,</li>
- * <li>each operation of each class,</li>
- * <li>each enum,</li>
- * <li>and each data type</li>
+ * <li>each class,</li>
+ * <li>each feature of each class,</li>
+ * <li>each operation of each class,</li>
+ * <li>each enum,</li>
+ * <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
+ *
* @generated
*/
interface Literals {
@@ -450,6 +493,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl <em>Extension Definition</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionPackageImpl#getExtensionDefinition()
* @generated
@@ -460,6 +504,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Extension</b></em>' reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference EXTENSION_DEFINITION__EXTENSION = eINSTANCE.getExtensionDefinition_Extension();
@@ -468,6 +513,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Base Metaclasses</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference EXTENSION_DEFINITION__BASE_METACLASSES = eINSTANCE.getExtensionDefinition_BaseMetaclasses();
@@ -476,6 +522,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Facade</b></em>' container reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference EXTENSION_DEFINITION__FACADE = eINSTANCE.getExtensionDefinition_Facade();
@@ -484,6 +531,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Stereotype</b></em>' reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference EXTENSION_DEFINITION__STEREOTYPE = eINSTANCE.getExtensionDefinition_Stereotype();
@@ -492,6 +540,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Kind</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute EXTENSION_DEFINITION__KIND = eINSTANCE.getExtensionDefinition_Kind();
@@ -500,6 +549,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl <em>Base Metaclass</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionPackageImpl#getBaseMetaclass()
* @generated
@@ -510,6 +560,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Incompatible Stereotypes</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference BASE_METACLASS__INCOMPATIBLE_STEREOTYPES = eINSTANCE.getBaseMetaclass_IncompatibleStereotypes();
@@ -518,6 +569,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Base</b></em>' reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference BASE_METACLASS__BASE = eINSTANCE.getBaseMetaclass_Base();
@@ -526,6 +578,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Extension Definition</b></em>' container reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference BASE_METACLASS__EXTENSION_DEFINITION = eINSTANCE.getBaseMetaclass_ExtensionDefinition();
@@ -534,6 +587,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Compatible Stereotypes</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference BASE_METACLASS__COMPATIBLE_STEREOTYPES = eINSTANCE.getBaseMetaclass_CompatibleStereotypes();
@@ -542,6 +596,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Possible</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute BASE_METACLASS__POSSIBLE = eINSTANCE.getBaseMetaclass_Possible();
@@ -550,6 +605,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.extensiondefinition.impl.CombinationImpl <em>Combination</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.CombinationImpl
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionPackageImpl#getCombination()
* @generated
@@ -560,6 +616,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '<em><b>Members</b></em>' reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference COMBINATION__MEMBERS = eINSTANCE.getCombination_Members();
@@ -568,6 +625,7 @@ public interface ExtensiondefinitionPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind <em>Extension Definition Kind</em>}' enum.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinitionKind
* @see org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensiondefinitionPackageImpl#getExtensionDefinitionKind()
* @generated
@@ -576,4 +634,4 @@ public interface ExtensiondefinitionPackage extends EPackage {
}
-} //ExtensiondefinitionPackage
+} // ExtensiondefinitionPackage
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/BaseMetaclassImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/BaseMetaclassImpl.java
index 18c745ae4e4..22802ee79fa 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/BaseMetaclassImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/BaseMetaclassImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -43,11 +43,11 @@ import org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#getIncompatibleStereotypes <em>Incompatible Stereotypes</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#getBase <em>Base</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#getExtensionDefinition <em>Extension Definition</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#getCompatibleStereotypes <em>Compatible Stereotypes</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#isPossible <em>Possible</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#getIncompatibleStereotypes <em>Incompatible Stereotypes</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#getBase <em>Base</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#getExtensionDefinition <em>Extension Definition</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#getCompatibleStereotypes <em>Compatible Stereotypes</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.BaseMetaclassImpl#isPossible <em>Possible</em>}</li>
* </ul>
* </p>
*
@@ -58,6 +58,7 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
* The cached value of the '{@link #getIncompatibleStereotypes() <em>Incompatible Stereotypes</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getIncompatibleStereotypes()
* @generated
* @ordered
@@ -68,6 +69,7 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
* The cached value of the '{@link #getBase() <em>Base</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getBase()
* @generated
* @ordered
@@ -78,6 +80,7 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
* The cached value of the '{@link #getCompatibleStereotypes() <em>Compatible Stereotypes</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getCompatibleStereotypes()
* @generated
* @ordered
@@ -88,6 +91,7 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
* The default value of the '{@link #isPossible() <em>Possible</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isPossible()
* @generated
* @ordered
@@ -98,6 +102,7 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
* The cached value of the '{@link #isPossible() <em>Possible</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isPossible()
* @generated
* @ordered
@@ -107,6 +112,7 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected BaseMetaclassImpl() {
@@ -116,6 +122,7 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -126,8 +133,10 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<Combination> getIncompatibleStereotypes() {
if (incompatibleStereotypes == null) {
incompatibleStereotypes = new EObjectContainmentEList<Combination>(Combination.class, this, ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES);
@@ -138,15 +147,18 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EObject getBase() {
if (base != null && base.eIsProxy()) {
- InternalEObject oldBase = (InternalEObject)base;
+ InternalEObject oldBase = (InternalEObject) base;
base = eResolveProxy(oldBase);
if (base != oldBase) {
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.RESOLVE, ExtensiondefinitionPackage.BASE_METACLASS__BASE, oldBase, base));
+ }
}
}
return base;
@@ -155,6 +167,7 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public EObject basicGetBase() {
@@ -164,61 +177,79 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setBase(EObject newBase) {
EObject oldBase = base;
base = newBase;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, ExtensiondefinitionPackage.BASE_METACLASS__BASE, oldBase, base));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ExtensionDefinition getExtensionDefinition() {
- if (eContainerFeatureID() != ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION) return null;
- return (ExtensionDefinition)eInternalContainer();
+ if (eContainerFeatureID() != ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION) {
+ return null;
+ }
+ return (ExtensionDefinition) eInternalContainer();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public NotificationChain basicSetExtensionDefinition(ExtensionDefinition newExtensionDefinition, NotificationChain msgs) {
- msgs = eBasicSetContainer((InternalEObject)newExtensionDefinition, ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION, msgs);
+ msgs = eBasicSetContainer((InternalEObject) newExtensionDefinition, ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION, msgs);
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setExtensionDefinition(ExtensionDefinition newExtensionDefinition) {
if (newExtensionDefinition != eInternalContainer() || (eContainerFeatureID() != ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION && newExtensionDefinition != null)) {
- if (EcoreUtil.isAncestor(this, newExtensionDefinition))
+ if (EcoreUtil.isAncestor(this, newExtensionDefinition)) {
throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
+ }
NotificationChain msgs = null;
- if (eInternalContainer() != null)
+ if (eInternalContainer() != null) {
msgs = eBasicRemoveFromContainer(msgs);
- if (newExtensionDefinition != null)
- msgs = ((InternalEObject)newExtensionDefinition).eInverseAdd(this, ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES, ExtensionDefinition.class, msgs);
+ }
+ if (newExtensionDefinition != null) {
+ msgs = ((InternalEObject) newExtensionDefinition).eInverseAdd(this, ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES, ExtensionDefinition.class, msgs);
+ }
msgs = basicSetExtensionDefinition(newExtensionDefinition, msgs);
- if (msgs != null) msgs.dispatch();
+ if (msgs != null) {
+ msgs.dispatch();
+ }
}
- else if (eNotificationRequired())
+ else if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION, newExtensionDefinition, newExtensionDefinition));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<Combination> getCompatibleStereotypes() {
if (compatibleStereotypes == null) {
compatibleStereotypes = new EObjectContainmentEList<Combination>(Combination.class, this, ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES);
@@ -229,8 +260,10 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public boolean isPossible() {
return possible;
}
@@ -238,27 +271,32 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setPossible(boolean newPossible) {
boolean oldPossible = possible;
possible = newPossible;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE, oldPossible, possible));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
- if (eInternalContainer() != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return basicSetExtensionDefinition((ExtensionDefinition)otherEnd, msgs);
+ case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
+ if (eInternalContainer() != null) {
+ msgs = eBasicRemoveFromContainer(msgs);
+ }
+ return basicSetExtensionDefinition((ExtensionDefinition) otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
}
@@ -266,17 +304,18 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
- return ((InternalEList<?>)getIncompatibleStereotypes()).basicRemove(otherEnd, msgs);
- case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
- return basicSetExtensionDefinition(null, msgs);
- case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
- return ((InternalEList<?>)getCompatibleStereotypes()).basicRemove(otherEnd, msgs);
+ case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
+ return ((InternalEList<?>) getIncompatibleStereotypes()).basicRemove(otherEnd, msgs);
+ case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
+ return basicSetExtensionDefinition(null, msgs);
+ case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
+ return ((InternalEList<?>) getCompatibleStereotypes()).basicRemove(otherEnd, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -284,13 +323,14 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) {
switch (eContainerFeatureID()) {
- case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
- return eInternalContainer().eInverseRemove(this, ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES, ExtensionDefinition.class, msgs);
+ case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
+ return eInternalContainer().eInverseRemove(this, ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES, ExtensionDefinition.class, msgs);
}
return super.eBasicRemoveFromContainerFeature(msgs);
}
@@ -298,22 +338,25 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
- return getIncompatibleStereotypes();
- case ExtensiondefinitionPackage.BASE_METACLASS__BASE:
- if (resolve) return getBase();
- return basicGetBase();
- case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
- return getExtensionDefinition();
- case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
- return getCompatibleStereotypes();
- case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
- return isPossible();
+ case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
+ return getIncompatibleStereotypes();
+ case ExtensiondefinitionPackage.BASE_METACLASS__BASE:
+ if (resolve) {
+ return getBase();
+ }
+ return basicGetBase();
+ case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
+ return getExtensionDefinition();
+ case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
+ return getCompatibleStereotypes();
+ case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
+ return isPossible();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -321,29 +364,30 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
- getIncompatibleStereotypes().clear();
- getIncompatibleStereotypes().addAll((Collection<? extends Combination>)newValue);
- return;
- case ExtensiondefinitionPackage.BASE_METACLASS__BASE:
- setBase((EObject)newValue);
- return;
- case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
- setExtensionDefinition((ExtensionDefinition)newValue);
- return;
- case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
- getCompatibleStereotypes().clear();
- getCompatibleStereotypes().addAll((Collection<? extends Combination>)newValue);
- return;
- case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
- setPossible((Boolean)newValue);
- return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
+ getIncompatibleStereotypes().clear();
+ getIncompatibleStereotypes().addAll((Collection<? extends Combination>) newValue);
+ return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__BASE:
+ setBase((EObject) newValue);
+ return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
+ setExtensionDefinition((ExtensionDefinition) newValue);
+ return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
+ getCompatibleStereotypes().clear();
+ getCompatibleStereotypes().addAll((Collection<? extends Combination>) newValue);
+ return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
+ setPossible((Boolean) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -351,26 +395,27 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
- getIncompatibleStereotypes().clear();
- return;
- case ExtensiondefinitionPackage.BASE_METACLASS__BASE:
- setBase((EObject)null);
- return;
- case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
- setExtensionDefinition((ExtensionDefinition)null);
- return;
- case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
- getCompatibleStereotypes().clear();
- return;
- case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
- setPossible(POSSIBLE_EDEFAULT);
- return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
+ getIncompatibleStereotypes().clear();
+ return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__BASE:
+ setBase((EObject) null);
+ return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
+ setExtensionDefinition((ExtensionDefinition) null);
+ return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
+ getCompatibleStereotypes().clear();
+ return;
+ case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
+ setPossible(POSSIBLE_EDEFAULT);
+ return;
}
super.eUnset(featureID);
}
@@ -378,21 +423,22 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
- return incompatibleStereotypes != null && !incompatibleStereotypes.isEmpty();
- case ExtensiondefinitionPackage.BASE_METACLASS__BASE:
- return base != null;
- case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
- return getExtensionDefinition() != null;
- case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
- return compatibleStereotypes != null && !compatibleStereotypes.isEmpty();
- case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
- return possible != POSSIBLE_EDEFAULT;
+ case ExtensiondefinitionPackage.BASE_METACLASS__INCOMPATIBLE_STEREOTYPES:
+ return incompatibleStereotypes != null && !incompatibleStereotypes.isEmpty();
+ case ExtensiondefinitionPackage.BASE_METACLASS__BASE:
+ return base != null;
+ case ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION:
+ return getExtensionDefinition() != null;
+ case ExtensiondefinitionPackage.BASE_METACLASS__COMPATIBLE_STEREOTYPES:
+ return compatibleStereotypes != null && !compatibleStereotypes.isEmpty();
+ case ExtensiondefinitionPackage.BASE_METACLASS__POSSIBLE:
+ return possible != POSSIBLE_EDEFAULT;
}
return super.eIsSet(featureID);
}
@@ -400,11 +446,14 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
/**
* <!-- 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(" (possible: ");
@@ -413,4 +462,4 @@ public class BaseMetaclassImpl extends MinimalEObjectImpl.Container implements B
return result.toString();
}
-} //BaseMetaclassImpl
+} // BaseMetaclassImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/CombinationImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/CombinationImpl.java
index 83226abb3d7..b72b823b933 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/CombinationImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/CombinationImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -34,7 +34,7 @@ import org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.CombinationImpl#getMembers <em>Members</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.CombinationImpl#getMembers <em>Members</em>}</li>
* </ul>
* </p>
*
@@ -45,6 +45,7 @@ public class CombinationImpl extends MinimalEObjectImpl.Container implements Com
* The cached value of the '{@link #getMembers() <em>Members</em>}' reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getMembers()
* @generated
* @ordered
@@ -54,6 +55,7 @@ public class CombinationImpl extends MinimalEObjectImpl.Container implements Com
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected CombinationImpl() {
@@ -63,6 +65,7 @@ public class CombinationImpl extends MinimalEObjectImpl.Container implements Com
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -73,8 +76,10 @@ public class CombinationImpl extends MinimalEObjectImpl.Container implements Com
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<BaseMetaclass> getMembers() {
if (members == null) {
members = new EObjectResolvingEList<BaseMetaclass>(BaseMetaclass.class, this, ExtensiondefinitionPackage.COMBINATION__MEMBERS);
@@ -85,13 +90,14 @@ public class CombinationImpl extends MinimalEObjectImpl.Container implements Com
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case ExtensiondefinitionPackage.COMBINATION__MEMBERS:
- return getMembers();
+ case ExtensiondefinitionPackage.COMBINATION__MEMBERS:
+ return getMembers();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -99,16 +105,17 @@ public class CombinationImpl extends MinimalEObjectImpl.Container implements Com
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case ExtensiondefinitionPackage.COMBINATION__MEMBERS:
- getMembers().clear();
- getMembers().addAll((Collection<? extends BaseMetaclass>)newValue);
- return;
+ case ExtensiondefinitionPackage.COMBINATION__MEMBERS:
+ getMembers().clear();
+ getMembers().addAll((Collection<? extends BaseMetaclass>) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -116,14 +123,15 @@ public class CombinationImpl extends MinimalEObjectImpl.Container implements Com
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case ExtensiondefinitionPackage.COMBINATION__MEMBERS:
- getMembers().clear();
- return;
+ case ExtensiondefinitionPackage.COMBINATION__MEMBERS:
+ getMembers().clear();
+ return;
}
super.eUnset(featureID);
}
@@ -131,15 +139,16 @@ public class CombinationImpl extends MinimalEObjectImpl.Container implements Com
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case ExtensiondefinitionPackage.COMBINATION__MEMBERS:
- return members != null && !members.isEmpty();
+ case ExtensiondefinitionPackage.COMBINATION__MEMBERS:
+ return members != null && !members.isEmpty();
}
return super.eIsSet(featureID);
}
-} //CombinationImpl
+} // CombinationImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensionDefinitionImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensionDefinitionImpl.java
index de353f188c6..7fe30876f0e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensionDefinitionImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensionDefinitionImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -48,11 +48,11 @@ import org.eclipse.uml2.uml.Stereotype;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getExtension <em>Extension</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getBaseMetaclasses <em>Base Metaclasses</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getFacade <em>Facade</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getStereotype <em>Stereotype</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getKind <em>Kind</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getExtension <em>Extension</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getBaseMetaclasses <em>Base Metaclasses</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getFacade <em>Facade</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getStereotype <em>Stereotype</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.extensiondefinition.impl.ExtensionDefinitionImpl#getKind <em>Kind</em>}</li>
* </ul>
* </p>
*
@@ -63,6 +63,7 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
* The cached value of the '{@link #getExtension() <em>Extension</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getExtension()
* @generated
* @ordered
@@ -73,6 +74,7 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
* The cached value of the '{@link #getBaseMetaclasses() <em>Base Metaclasses</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getBaseMetaclasses()
* @generated
* @ordered
@@ -83,6 +85,7 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
* The cached value of the '{@link #getStereotype() <em>Stereotype</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getStereotype()
* @generated
* @ordered
@@ -93,6 +96,7 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
* The default value of the '{@link #getKind() <em>Kind</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getKind()
* @generated
* @ordered
@@ -103,6 +107,7 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
* The cached value of the '{@link #getKind() <em>Kind</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getKind()
* @generated
* @ordered
@@ -112,6 +117,7 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ExtensionDefinitionImpl() {
@@ -121,6 +127,7 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -131,15 +138,18 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Extension getExtension() {
if (extension != null && extension.eIsProxy()) {
- InternalEObject oldExtension = (InternalEObject)extension;
- extension = (Extension)eResolveProxy(oldExtension);
+ InternalEObject oldExtension = (InternalEObject) extension;
+ extension = (Extension) eResolveProxy(oldExtension);
if (extension != oldExtension) {
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.RESOLVE, ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION, oldExtension, extension));
+ }
}
}
return extension;
@@ -148,6 +158,7 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Extension basicGetExtension() {
@@ -157,20 +168,25 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setExtension(Extension newExtension) {
Extension oldExtension = extension;
extension = newExtension;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION, oldExtension, extension));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<BaseMetaclass> getBaseMetaclasses() {
if (baseMetaclasses == null) {
baseMetaclasses = new EObjectContainmentWithInverseEList<BaseMetaclass>(BaseMetaclass.class, this, ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES, ExtensiondefinitionPackage.BASE_METACLASS__EXTENSION_DEFINITION);
@@ -181,56 +197,72 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Facade getFacade() {
- if (eContainerFeatureID() != ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE) return null;
- return (Facade)eInternalContainer();
+ if (eContainerFeatureID() != ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE) {
+ return null;
+ }
+ return (Facade) eInternalContainer();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public NotificationChain basicSetFacade(Facade newFacade, NotificationChain msgs) {
- msgs = eBasicSetContainer((InternalEObject)newFacade, ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE, msgs);
+ msgs = eBasicSetContainer((InternalEObject) newFacade, ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE, msgs);
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setFacade(Facade newFacade) {
if (newFacade != eInternalContainer() || (eContainerFeatureID() != ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE && newFacade != null)) {
- if (EcoreUtil.isAncestor(this, newFacade))
+ if (EcoreUtil.isAncestor(this, newFacade)) {
throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
+ }
NotificationChain msgs = null;
- if (eInternalContainer() != null)
+ if (eInternalContainer() != null) {
msgs = eBasicRemoveFromContainer(msgs);
- if (newFacade != null)
- msgs = ((InternalEObject)newFacade).eInverseAdd(this, FacadePackage.FACADE__EXTENSION_DEFINITIONS, Facade.class, msgs);
+ }
+ if (newFacade != null) {
+ msgs = ((InternalEObject) newFacade).eInverseAdd(this, FacadePackage.FACADE__EXTENSION_DEFINITIONS, Facade.class, msgs);
+ }
msgs = basicSetFacade(newFacade, msgs);
- if (msgs != null) msgs.dispatch();
+ if (msgs != null) {
+ msgs.dispatch();
+ }
}
- else if (eNotificationRequired())
+ else if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE, newFacade, newFacade));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Stereotype getStereotype() {
if (stereotype != null && stereotype.eIsProxy()) {
- InternalEObject oldStereotype = (InternalEObject)stereotype;
- stereotype = (Stereotype)eResolveProxy(oldStereotype);
+ InternalEObject oldStereotype = (InternalEObject) stereotype;
+ stereotype = (Stereotype) eResolveProxy(oldStereotype);
if (stereotype != oldStereotype) {
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.RESOLVE, ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE, oldStereotype, stereotype));
+ }
}
}
return stereotype;
@@ -239,6 +271,7 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public Stereotype basicGetStereotype() {
@@ -248,20 +281,25 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setStereotype(Stereotype newStereotype) {
Stereotype oldStereotype = stereotype;
stereotype = newStereotype;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE, oldStereotype, stereotype));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ExtensionDefinitionKind getKind() {
return kind;
}
@@ -269,30 +307,35 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setKind(ExtensionDefinitionKind newKind) {
ExtensionDefinitionKind oldKind = kind;
kind = newKind == null ? KIND_EDEFAULT : newKind;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND, oldKind, kind));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
- return ((InternalEList<InternalEObject>)(InternalEList<?>)getBaseMetaclasses()).basicAdd(otherEnd, msgs);
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
- if (eInternalContainer() != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return basicSetFacade((Facade)otherEnd, msgs);
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
+ return ((InternalEList<InternalEObject>) (InternalEList<?>) getBaseMetaclasses()).basicAdd(otherEnd, msgs);
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
+ if (eInternalContainer() != null) {
+ msgs = eBasicRemoveFromContainer(msgs);
+ }
+ return basicSetFacade((Facade) otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
}
@@ -300,15 +343,16 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
- return ((InternalEList<?>)getBaseMetaclasses()).basicRemove(otherEnd, msgs);
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
- return basicSetFacade(null, msgs);
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
+ return ((InternalEList<?>) getBaseMetaclasses()).basicRemove(otherEnd, msgs);
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
+ return basicSetFacade(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -316,13 +360,14 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) {
switch (eContainerFeatureID()) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
- return eInternalContainer().eInverseRemove(this, FacadePackage.FACADE__EXTENSION_DEFINITIONS, Facade.class, msgs);
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
+ return eInternalContainer().eInverseRemove(this, FacadePackage.FACADE__EXTENSION_DEFINITIONS, Facade.class, msgs);
}
return super.eBasicRemoveFromContainerFeature(msgs);
}
@@ -330,23 +375,28 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION:
- if (resolve) return getExtension();
- return basicGetExtension();
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
- return getBaseMetaclasses();
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
- return getFacade();
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE:
- if (resolve) return getStereotype();
- return basicGetStereotype();
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
- return getKind();
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION:
+ if (resolve) {
+ return getExtension();
+ }
+ return basicGetExtension();
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
+ return getBaseMetaclasses();
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
+ return getFacade();
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE:
+ if (resolve) {
+ return getStereotype();
+ }
+ return basicGetStereotype();
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
+ return getKind();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -354,28 +404,29 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION:
- setExtension((Extension)newValue);
- return;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
- getBaseMetaclasses().clear();
- getBaseMetaclasses().addAll((Collection<? extends BaseMetaclass>)newValue);
- return;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
- setFacade((Facade)newValue);
- return;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE:
- setStereotype((Stereotype)newValue);
- return;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
- setKind((ExtensionDefinitionKind)newValue);
- return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION:
+ setExtension((Extension) newValue);
+ return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
+ getBaseMetaclasses().clear();
+ getBaseMetaclasses().addAll((Collection<? extends BaseMetaclass>) newValue);
+ return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
+ setFacade((Facade) newValue);
+ return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE:
+ setStereotype((Stereotype) newValue);
+ return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
+ setKind((ExtensionDefinitionKind) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -383,26 +434,27 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION:
- setExtension((Extension)null);
- return;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
- getBaseMetaclasses().clear();
- return;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
- setFacade((Facade)null);
- return;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE:
- setStereotype((Stereotype)null);
- return;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
- setKind(KIND_EDEFAULT);
- return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION:
+ setExtension((Extension) null);
+ return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
+ getBaseMetaclasses().clear();
+ return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
+ setFacade((Facade) null);
+ return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE:
+ setStereotype((Stereotype) null);
+ return;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
+ setKind(KIND_EDEFAULT);
+ return;
}
super.eUnset(featureID);
}
@@ -410,21 +462,22 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION:
- return extension != null;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
- return baseMetaclasses != null && !baseMetaclasses.isEmpty();
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
- return getFacade() != null;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE:
- return stereotype != null;
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
- return kind != KIND_EDEFAULT;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__EXTENSION:
+ return extension != null;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__BASE_METACLASSES:
+ return baseMetaclasses != null && !baseMetaclasses.isEmpty();
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE:
+ return getFacade() != null;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__STEREOTYPE:
+ return stereotype != null;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION__KIND:
+ return kind != KIND_EDEFAULT;
}
return super.eIsSet(featureID);
}
@@ -432,11 +485,14 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
/**
* <!-- 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(" (kind: ");
@@ -445,4 +501,4 @@ public class ExtensionDefinitionImpl extends MinimalEObjectImpl.Container implem
return result.toString();
}
-} //ExtensionDefinitionImpl
+} // ExtensionDefinitionImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionFactoryImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionFactoryImpl.java
index 1579e918529..94cce749a61 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionFactoryImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionFactoryImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -28,6 +28,7 @@ import org.eclipse.papyrus.facade.extensiondefinition.*;
* <!-- begin-user-doc -->
* An implementation of the model <b>Factory</b>.
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensiondefinitionFactoryImpl extends EFactoryImpl implements ExtensiondefinitionFactory {
@@ -35,16 +36,16 @@ public class ExtensiondefinitionFactoryImpl extends EFactoryImpl implements Exte
* Creates the default factory implementation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static ExtensiondefinitionFactory init() {
try {
- ExtensiondefinitionFactory theExtensiondefinitionFactory = (ExtensiondefinitionFactory)EPackage.Registry.INSTANCE.getEFactory(ExtensiondefinitionPackage.eNS_URI);
+ ExtensiondefinitionFactory theExtensiondefinitionFactory = (ExtensiondefinitionFactory) EPackage.Registry.INSTANCE.getEFactory(ExtensiondefinitionPackage.eNS_URI);
if (theExtensiondefinitionFactory != null) {
return theExtensiondefinitionFactory;
}
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
EcorePlugin.INSTANCE.log(exception);
}
return new ExtensiondefinitionFactoryImpl();
@@ -54,6 +55,7 @@ public class ExtensiondefinitionFactoryImpl extends EFactoryImpl implements Exte
* Creates an instance of the factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionFactoryImpl() {
@@ -63,54 +65,62 @@ public class ExtensiondefinitionFactoryImpl extends EFactoryImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public EObject create(EClass eClass) {
switch (eClass.getClassifierID()) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION: return createExtensionDefinition();
- case ExtensiondefinitionPackage.BASE_METACLASS: return createBaseMetaclass();
- case ExtensiondefinitionPackage.COMBINATION: return createCombination();
- default:
- throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION:
+ return createExtensionDefinition();
+ case ExtensiondefinitionPackage.BASE_METACLASS:
+ return createBaseMetaclass();
+ case ExtensiondefinitionPackage.COMBINATION:
+ return createCombination();
+ default:
+ throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object createFromString(EDataType eDataType, String initialValue) {
switch (eDataType.getClassifierID()) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION_KIND:
- return createExtensionDefinitionKindFromString(eDataType, initialValue);
- default:
- throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION_KIND:
+ return createExtensionDefinitionKindFromString(eDataType, initialValue);
+ default:
+ throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String convertToString(EDataType eDataType, Object instanceValue) {
switch (eDataType.getClassifierID()) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION_KIND:
- return convertExtensionDefinitionKindToString(eDataType, instanceValue);
- default:
- throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION_KIND:
+ return convertExtensionDefinitionKindToString(eDataType, instanceValue);
+ default:
+ throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ExtensionDefinition createExtensionDefinition() {
ExtensionDefinitionImpl extensionDefinition = new ExtensionDefinitionImpl();
return extensionDefinition;
@@ -119,8 +129,10 @@ public class ExtensiondefinitionFactoryImpl extends EFactoryImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public BaseMetaclass createBaseMetaclass() {
BaseMetaclassImpl baseMetaclass = new BaseMetaclassImpl();
return baseMetaclass;
@@ -129,8 +141,10 @@ public class ExtensiondefinitionFactoryImpl extends EFactoryImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Combination createCombination() {
CombinationImpl combination = new CombinationImpl();
return combination;
@@ -139,17 +153,21 @@ public class ExtensiondefinitionFactoryImpl extends EFactoryImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensionDefinitionKind createExtensionDefinitionKindFromString(EDataType eDataType, String initialValue) {
ExtensionDefinitionKind result = ExtensionDefinitionKind.get(initialValue);
- if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'");
+ if (result == null) {
+ throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'");
+ }
return result;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String convertExtensionDefinitionKindToString(EDataType eDataType, Object instanceValue) {
@@ -159,15 +177,18 @@ public class ExtensiondefinitionFactoryImpl extends EFactoryImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ExtensiondefinitionPackage getExtensiondefinitionPackage() {
- return (ExtensiondefinitionPackage)getEPackage();
+ return (ExtensiondefinitionPackage) getEPackage();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @deprecated
* @generated
*/
@@ -176,4 +197,4 @@ public class ExtensiondefinitionFactoryImpl extends EFactoryImpl implements Exte
return ExtensiondefinitionPackage.eINSTANCE;
}
-} //ExtensiondefinitionFactoryImpl
+} // ExtensiondefinitionFactoryImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionPackageImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionPackageImpl.java
index 36401e929c8..c683d62085f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionPackageImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/impl/ExtensiondefinitionPackageImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -42,12 +42,14 @@ import org.eclipse.uml2.uml.UMLPackage;
* <!-- begin-user-doc -->
* An implementation of the model <b>Package</b>.
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensiondefinitionPackageImpl extends EPackageImpl implements ExtensiondefinitionPackage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass extensionDefinitionEClass = null;
@@ -55,6 +57,7 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass baseMetaclassEClass = null;
@@ -62,6 +65,7 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass combinationEClass = null;
@@ -69,20 +73,17 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EEnum extensionDefinitionKindEEnum = null;
/**
- * Creates an instance of the model <b>Package</b>, registered with
- * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
+ * Creates an instance of the model <b>Package</b>, registered with {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
* package URI value.
- * <p>Note: the correct way to create the package is via the static
- * factory method {@link #init init()}, which also performs
- * initialization of the package, or returns the registered package,
- * if one already exists.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
+ * <p>
+ * Note: the correct way to create the package is via the static factory method {@link #init init()}, which also performs initialization of the package, or returns the registered package, if one already exists. <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
* @see org.eclipse.emf.ecore.EPackage.Registry
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage#eNS_URI
* @see #init()
@@ -95,27 +96,31 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static boolean isInited = false;
/**
* Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends.
+ *
+ * <p>
+ * This method is used to initialize {@link ExtensiondefinitionPackage#eINSTANCE} when that field is accessed. Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. <!-- begin-user-doc --> <!--
+ * end-user-doc -->
*
- * <p>This method is used to initialize {@link ExtensiondefinitionPackage#eINSTANCE} when that field is accessed.
- * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
* @see #eNS_URI
* @see #createPackageContents()
* @see #initializePackageContents()
* @generated
*/
public static ExtensiondefinitionPackage init() {
- if (isInited) return (ExtensiondefinitionPackage)EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI);
+ if (isInited) {
+ return (ExtensiondefinitionPackage) EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI);
+ }
// Obtain or create and register package
- ExtensiondefinitionPackageImpl theExtensiondefinitionPackage = (ExtensiondefinitionPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof ExtensiondefinitionPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new ExtensiondefinitionPackageImpl());
+ ExtensiondefinitionPackageImpl theExtensiondefinitionPackage = (ExtensiondefinitionPackageImpl) (EPackage.Registry.INSTANCE.get(eNS_URI) instanceof ExtensiondefinitionPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI)
+ : new ExtensiondefinitionPackageImpl());
isInited = true;
@@ -123,8 +128,9 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
UMLPackage.eINSTANCE.eClass();
// Obtain or create and register interdependencies
- FacadePackageImpl theFacadePackage = (FacadePackageImpl)(EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI) instanceof FacadePackageImpl ? EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI) : FacadePackage.eINSTANCE);
- VirtualmetamodelPackageImpl theVirtualmetamodelPackage = (VirtualmetamodelPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI) instanceof VirtualmetamodelPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI) : VirtualmetamodelPackage.eINSTANCE);
+ FacadePackageImpl theFacadePackage = (FacadePackageImpl) (EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI) instanceof FacadePackageImpl ? EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI) : FacadePackage.eINSTANCE);
+ VirtualmetamodelPackageImpl theVirtualmetamodelPackage = (VirtualmetamodelPackageImpl) (EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI) instanceof VirtualmetamodelPackageImpl ? EPackage.Registry.INSTANCE
+ .getEPackage(VirtualmetamodelPackage.eNS_URI) : VirtualmetamodelPackage.eINSTANCE);
// Create package meta-data objects
theExtensiondefinitionPackage.createPackageContents();
@@ -139,7 +145,7 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
// Mark meta-data to indicate it can't be changed
theExtensiondefinitionPackage.freeze();
-
+
// Update the registry and return the package
EPackage.Registry.INSTANCE.put(ExtensiondefinitionPackage.eNS_URI, theExtensiondefinitionPackage);
return theExtensiondefinitionPackage;
@@ -148,8 +154,10 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getExtensionDefinition() {
return extensionDefinitionEClass;
}
@@ -157,53 +165,65 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getExtensionDefinition_Extension() {
- return (EReference)extensionDefinitionEClass.getEStructuralFeatures().get(0);
+ return (EReference) extensionDefinitionEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getExtensionDefinition_BaseMetaclasses() {
- return (EReference)extensionDefinitionEClass.getEStructuralFeatures().get(1);
+ return (EReference) extensionDefinitionEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getExtensionDefinition_Facade() {
- return (EReference)extensionDefinitionEClass.getEStructuralFeatures().get(2);
+ return (EReference) extensionDefinitionEClass.getEStructuralFeatures().get(2);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getExtensionDefinition_Stereotype() {
- return (EReference)extensionDefinitionEClass.getEStructuralFeatures().get(3);
+ return (EReference) extensionDefinitionEClass.getEStructuralFeatures().get(3);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getExtensionDefinition_Kind() {
- return (EAttribute)extensionDefinitionEClass.getEStructuralFeatures().get(4);
+ return (EAttribute) extensionDefinitionEClass.getEStructuralFeatures().get(4);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getBaseMetaclass() {
return baseMetaclassEClass;
}
@@ -211,53 +231,65 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getBaseMetaclass_IncompatibleStereotypes() {
- return (EReference)baseMetaclassEClass.getEStructuralFeatures().get(0);
+ return (EReference) baseMetaclassEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getBaseMetaclass_Base() {
- return (EReference)baseMetaclassEClass.getEStructuralFeatures().get(1);
+ return (EReference) baseMetaclassEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getBaseMetaclass_ExtensionDefinition() {
- return (EReference)baseMetaclassEClass.getEStructuralFeatures().get(2);
+ return (EReference) baseMetaclassEClass.getEStructuralFeatures().get(2);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getBaseMetaclass_CompatibleStereotypes() {
- return (EReference)baseMetaclassEClass.getEStructuralFeatures().get(3);
+ return (EReference) baseMetaclassEClass.getEStructuralFeatures().get(3);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getBaseMetaclass_Possible() {
- return (EAttribute)baseMetaclassEClass.getEStructuralFeatures().get(4);
+ return (EAttribute) baseMetaclassEClass.getEStructuralFeatures().get(4);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getCombination() {
return combinationEClass;
}
@@ -265,17 +297,21 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getCombination_Members() {
- return (EReference)combinationEClass.getEStructuralFeatures().get(0);
+ return (EReference) combinationEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EEnum getExtensionDefinitionKind() {
return extensionDefinitionKindEEnum;
}
@@ -283,28 +319,34 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ExtensiondefinitionFactory getExtensiondefinitionFactory() {
- return (ExtensiondefinitionFactory)getEFactoryInstance();
+ return (ExtensiondefinitionFactory) getEFactoryInstance();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private boolean isCreated = false;
/**
- * Creates the meta-model objects for the package. This method is
+ * Creates the meta-model objects for the package. This method is
* guarded to have no affect on any invocation but its first.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void createPackageContents() {
- if (isCreated) return;
+ if (isCreated) {
+ return;
+ }
isCreated = true;
// Create classes and their features
@@ -332,19 +374,23 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private boolean isInitialized = false;
/**
- * Complete the initialization of the package and its meta-model. This
+ * Complete the initialization of the package and its meta-model. This
* method is guarded to have no affect on any invocation but its first.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void initializePackageContents() {
- if (isInitialized) return;
+ if (isInitialized) {
+ return;
+ }
isInitialized = true;
// Initialize package
@@ -353,8 +399,8 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
setNsURI(eNS_URI);
// Obtain other dependent packages
- UMLPackage theUMLPackage = (UMLPackage)EPackage.Registry.INSTANCE.getEPackage(UMLPackage.eNS_URI);
- FacadePackage theFacadePackage = (FacadePackage)EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI);
+ UMLPackage theUMLPackage = (UMLPackage) EPackage.Registry.INSTANCE.getEPackage(UMLPackage.eNS_URI);
+ FacadePackage theFacadePackage = (FacadePackage) EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI);
// Create type parameters
@@ -364,17 +410,24 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
// Initialize classes, features, and operations; add parameters
initEClass(extensionDefinitionEClass, ExtensionDefinition.class, "ExtensionDefinition", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getExtensionDefinition_Extension(), theUMLPackage.getExtension(), null, "extension", null, 1, 1, ExtensionDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getExtensionDefinition_BaseMetaclasses(), this.getBaseMetaclass(), this.getBaseMetaclass_ExtensionDefinition(), "baseMetaclasses", null, 0, -1, ExtensionDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getExtensionDefinition_Facade(), theFacadePackage.getFacade(), theFacadePackage.getFacade_ExtensionDefinitions(), "facade", null, 1, 1, ExtensionDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getExtensionDefinition_Stereotype(), theUMLPackage.getStereotype(), null, "stereotype", null, 1, 1, ExtensionDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getExtensionDefinition_Extension(), theUMLPackage.getExtension(), null, "extension", null, 1, 1, ExtensionDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
+ !IS_DERIVED, IS_ORDERED);
+ initEReference(getExtensionDefinition_BaseMetaclasses(), this.getBaseMetaclass(), this.getBaseMetaclass_ExtensionDefinition(), "baseMetaclasses", null, 0, -1, ExtensionDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getExtensionDefinition_Facade(), theFacadePackage.getFacade(), theFacadePackage.getFacade_ExtensionDefinitions(), "facade", null, 1, 1, ExtensionDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getExtensionDefinition_Stereotype(), theUMLPackage.getStereotype(), null, "stereotype", null, 1, 1, ExtensionDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
+ !IS_DERIVED, IS_ORDERED);
initEAttribute(getExtensionDefinition_Kind(), this.getExtensionDefinitionKind(), "kind", null, 1, 1, ExtensionDefinition.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(baseMetaclassEClass, BaseMetaclass.class, "BaseMetaclass", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getBaseMetaclass_IncompatibleStereotypes(), this.getCombination(), null, "incompatibleStereotypes", null, 0, -1, BaseMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getBaseMetaclass_IncompatibleStereotypes(), this.getCombination(), null, "incompatibleStereotypes", null, 0, -1, BaseMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEReference(getBaseMetaclass_Base(), ecorePackage.getEObject(), null, "base", null, 1, 1, BaseMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getBaseMetaclass_ExtensionDefinition(), this.getExtensionDefinition(), this.getExtensionDefinition_BaseMetaclasses(), "extensionDefinition", null, 1, 1, BaseMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getBaseMetaclass_CompatibleStereotypes(), this.getCombination(), null, "compatibleStereotypes", null, 0, -1, BaseMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getBaseMetaclass_ExtensionDefinition(), this.getExtensionDefinition(), this.getExtensionDefinition_BaseMetaclasses(), "extensionDefinition", null, 1, 1, BaseMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getBaseMetaclass_CompatibleStereotypes(), this.getCombination(), null, "compatibleStereotypes", null, 0, -1, BaseMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
+ !IS_DERIVED, IS_ORDERED);
initEAttribute(getBaseMetaclass_Possible(), ecorePackage.getEBoolean(), "possible", null, 1, 1, BaseMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(combinationEClass, Combination.class, "Combination", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
@@ -388,4 +441,4 @@ public class ExtensiondefinitionPackageImpl extends EPackageImpl implements Exte
addEEnumLiteral(extensionDefinitionKindEEnum, ExtensionDefinitionKind.FUSION);
}
-} //ExtensiondefinitionPackageImpl
+} // ExtensiondefinitionPackageImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionAdapterFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionAdapterFactory.java
index aa877467eb2..eb9d95bc7bb 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionAdapterFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionAdapterFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.papyrus.facade.extensiondefinition.*;
* The <b>Adapter Factory</b> for the model.
* It provides an adapter <code>createXXX</code> method for each class of the model.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage
* @generated
*/
@@ -35,6 +36,7 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
* The cached model package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected static ExtensiondefinitionPackage modelPackage;
@@ -43,6 +45,7 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
* Creates an instance of the adapter factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionAdapterFactory() {
@@ -56,6 +59,7 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
* <!-- begin-user-doc -->
* This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model.
* <!-- end-user-doc -->
+ *
* @return whether this factory is applicable for the type of the object.
* @generated
*/
@@ -65,7 +69,7 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
return true;
}
if (object instanceof EObject) {
- return ((EObject)object).eClass().getEPackage() == modelPackage;
+ return ((EObject) object).eClass().getEPackage() == modelPackage;
}
return false;
}
@@ -74,39 +78,45 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
* The switch that delegates to the <code>createXXX</code> methods.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected ExtensiondefinitionSwitch<Adapter> modelSwitch =
- new ExtensiondefinitionSwitch<Adapter>() {
- @Override
- public Adapter caseExtensionDefinition(ExtensionDefinition object) {
- return createExtensionDefinitionAdapter();
- }
- @Override
- public Adapter caseBaseMetaclass(BaseMetaclass object) {
- return createBaseMetaclassAdapter();
- }
- @Override
- public Adapter caseCombination(Combination object) {
- return createCombinationAdapter();
- }
- @Override
- public Adapter defaultCase(EObject object) {
- return createEObjectAdapter();
- }
- };
+ new ExtensiondefinitionSwitch<Adapter>() {
+ @Override
+ public Adapter caseExtensionDefinition(ExtensionDefinition object) {
+ return createExtensionDefinitionAdapter();
+ }
+
+ @Override
+ public Adapter caseBaseMetaclass(BaseMetaclass object) {
+ return createBaseMetaclassAdapter();
+ }
+
+ @Override
+ public Adapter caseCombination(Combination object) {
+ return createCombinationAdapter();
+ }
+
+ @Override
+ public Adapter defaultCase(EObject object) {
+ return createEObjectAdapter();
+ }
+ };
/**
* Creates an adapter for the <code>target</code>.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param target the object to adapt.
+ *
+ * @param target
+ * the object to adapt.
* @return the adapter for the <code>target</code>.
* @generated
*/
@Override
public Adapter createAdapter(Notifier target) {
- return modelSwitch.doSwitch((EObject)target);
+ return modelSwitch.doSwitch((EObject) target);
}
@@ -116,6 +126,7 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensionDefinition
* @generated
@@ -130,6 +141,7 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass
* @generated
@@ -144,6 +156,7 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.extensiondefinition.Combination
* @generated
@@ -157,6 +170,7 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
* <!-- begin-user-doc -->
* This default implementation returns null.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @generated
*/
@@ -164,4 +178,4 @@ public class ExtensiondefinitionAdapterFactory extends AdapterFactoryImpl {
return null;
}
-} //ExtensiondefinitionAdapterFactory
+} // ExtensiondefinitionAdapterFactory
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceFactoryImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceFactoryImpl.java
index 9a454a4be70..985bb6da4d2 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceFactoryImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceFactoryImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,6 +25,7 @@ import org.eclipse.emf.ecore.xmi.XMLResource;
* <!-- begin-user-doc -->
* The <b>Resource Factory</b> associated with the package.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.util.ExtensiondefinitionResourceImpl
* @generated
*/
@@ -33,6 +34,7 @@ public class ExtensiondefinitionResourceFactoryImpl extends ResourceFactoryImpl
* Creates an instance of the resource factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionResourceFactoryImpl() {
@@ -43,6 +45,7 @@ public class ExtensiondefinitionResourceFactoryImpl extends ResourceFactoryImpl
* Creates an instance of the resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -60,4 +63,4 @@ public class ExtensiondefinitionResourceFactoryImpl extends ResourceFactoryImpl
return result;
}
-} //ExtensiondefinitionResourceFactoryImpl
+} // ExtensiondefinitionResourceFactoryImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceImpl.java
index a7f8565be37..6d02b904f33 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionResourceImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -21,6 +21,7 @@ import org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl;
* <!-- begin-user-doc -->
* The <b>Resource </b> associated with the package.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.util.ExtensiondefinitionResourceFactoryImpl
* @generated
*/
@@ -29,11 +30,13 @@ public class ExtensiondefinitionResourceImpl extends XMLResourceImpl {
* Creates an instance of the resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param uri the URI of the new resource.
+ *
+ * @param uri
+ * the URI of the new resource.
* @generated
*/
public ExtensiondefinitionResourceImpl(URI uri) {
super(uri);
}
-} //ExtensiondefinitionResourceImpl
+} // ExtensiondefinitionResourceImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionSwitch.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionSwitch.java
index 98c443886b2..db7e8404f8b 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionSwitch.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionSwitch.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,13 +23,13 @@ import org.eclipse.papyrus.facade.extensiondefinition.*;
/**
* <!-- begin-user-doc -->
* The <b>Switch</b> for the model's inheritance hierarchy.
- * It supports the call {@link #doSwitch(EObject) doSwitch(object)}
- * to invoke the <code>caseXXX</code> method for each class of the model,
+ * It supports the call {@link #doSwitch(EObject) doSwitch(object)} to invoke the <code>caseXXX</code> method for each class of the model,
* starting with the actual class of the object
* and proceeding up the inheritance hierarchy
* until a non-null result is returned,
* which is the result of the switch.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage
* @generated
*/
@@ -38,6 +38,7 @@ public class ExtensiondefinitionSwitch<T> extends Switch<T> {
* The cached model package
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected static ExtensiondefinitionPackage modelPackage;
@@ -46,6 +47,7 @@ public class ExtensiondefinitionSwitch<T> extends Switch<T> {
* Creates an instance of the switch.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionSwitch() {
@@ -58,6 +60,7 @@ public class ExtensiondefinitionSwitch<T> extends Switch<T> {
* Checks whether this is a switch for the given package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @parameter ePackage the package in question.
* @return whether this is a switch for the given package.
* @generated
@@ -71,31 +74,39 @@ public class ExtensiondefinitionSwitch<T> extends Switch<T> {
* Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the first non-null result returned by a <code>caseXXX</code> call.
* @generated
*/
@Override
protected T doSwitch(int classifierID, EObject theEObject) {
switch (classifierID) {
- case ExtensiondefinitionPackage.EXTENSION_DEFINITION: {
- ExtensionDefinition extensionDefinition = (ExtensionDefinition)theEObject;
- T result = caseExtensionDefinition(extensionDefinition);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ case ExtensiondefinitionPackage.EXTENSION_DEFINITION: {
+ ExtensionDefinition extensionDefinition = (ExtensionDefinition) theEObject;
+ T result = caseExtensionDefinition(extensionDefinition);
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- case ExtensiondefinitionPackage.BASE_METACLASS: {
- BaseMetaclass baseMetaclass = (BaseMetaclass)theEObject;
- T result = caseBaseMetaclass(baseMetaclass);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ return result;
+ }
+ case ExtensiondefinitionPackage.BASE_METACLASS: {
+ BaseMetaclass baseMetaclass = (BaseMetaclass) theEObject;
+ T result = caseBaseMetaclass(baseMetaclass);
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- case ExtensiondefinitionPackage.COMBINATION: {
- Combination combination = (Combination)theEObject;
- T result = caseCombination(combination);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ return result;
+ }
+ case ExtensiondefinitionPackage.COMBINATION: {
+ Combination combination = (Combination) theEObject;
+ T result = caseCombination(combination);
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- default: return defaultCase(theEObject);
+ return result;
+ }
+ default:
+ return defaultCase(theEObject);
}
}
@@ -105,7 +116,9 @@ public class ExtensiondefinitionSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Extension Definition</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -120,7 +133,9 @@ public class ExtensiondefinitionSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Base Metaclass</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -135,7 +150,9 @@ public class ExtensiondefinitionSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Combination</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -150,7 +167,9 @@ public class ExtensiondefinitionSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch, but this is the last case anyway.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>EObject</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject)
* @generated
@@ -160,4 +179,4 @@ public class ExtensiondefinitionSwitch<T> extends Switch<T> {
return null;
}
-} //ExtensiondefinitionSwitch
+} // ExtensiondefinitionSwitch
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionXMLProcessor.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionXMLProcessor.java
index 1bcc65ad363..fe33ffbc4f0 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionXMLProcessor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/util/ExtensiondefinitionXMLProcessor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.papyrus.facade.extensiondefinition.ExtensiondefinitionPackage
* This class contains helper methods to serialize and deserialize XML documents
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class ExtensiondefinitionXMLProcessor extends XMLProcessor {
@@ -35,17 +36,19 @@ public class ExtensiondefinitionXMLProcessor extends XMLProcessor {
* Public constructor to instantiate the helper.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensiondefinitionXMLProcessor() {
super((EPackage.Registry.INSTANCE));
ExtensiondefinitionPackage.eINSTANCE.eClass();
}
-
+
/**
* Register for "*" and "xml" file extensions the ExtensiondefinitionResourceFactoryImpl factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -58,4 +61,4 @@ public class ExtensiondefinitionXMLProcessor extends XMLProcessor {
return registrations;
}
-} //ExtensiondefinitionXMLProcessor
+} // ExtensiondefinitionXMLProcessor
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/BaseMetaclassValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/BaseMetaclassValidator.java
index f500459e0e5..3ba855288ea 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/BaseMetaclassValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/BaseMetaclassValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -30,8 +30,12 @@ public interface BaseMetaclassValidator {
boolean validate();
boolean validateIncompatibleStereotypes(EList<Combination> value);
+
boolean validateBase(EObject value);
+
boolean validateExtensionDefinition(ExtensionDefinition value);
+
boolean validateCompatibleStereotypes(EList<Combination> value);
+
boolean validatePossible(boolean value);
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/CombinationValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/CombinationValidator.java
index ed1c600b7bc..34677553ea5 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/CombinationValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/CombinationValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/ExtensionDefinitionValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/ExtensionDefinitionValidator.java
index 2dd343ab42a..9c7f3dfdd95 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/ExtensionDefinitionValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/extensiondefinition/validation/ExtensionDefinitionValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -33,8 +33,12 @@ public interface ExtensionDefinitionValidator {
boolean validate();
boolean validateExtension(Extension value);
+
boolean validateBaseMetaclasses(EList<BaseMetaclass> value);
+
boolean validateFacade(Facade value);
+
boolean validateStereotype(Stereotype value);
+
boolean validateKind(ExtensionDefinitionKind value);
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeFactoryImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeFactoryImpl.java
index b5ae72f9bfe..e630ed04115 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeFactoryImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeFactoryImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.papyrus.facade.*;
* <!-- begin-user-doc -->
* An implementation of the model <b>Factory</b>.
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeFactoryImpl extends EFactoryImpl implements FacadeFactory {
@@ -34,16 +35,16 @@ public class FacadeFactoryImpl extends EFactoryImpl implements FacadeFactory {
* Creates the default factory implementation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static FacadeFactory init() {
try {
- FacadeFactory theFacadeFactory = (FacadeFactory)EPackage.Registry.INSTANCE.getEFactory(FacadePackage.eNS_URI);
+ FacadeFactory theFacadeFactory = (FacadeFactory) EPackage.Registry.INSTANCE.getEFactory(FacadePackage.eNS_URI);
if (theFacadeFactory != null) {
return theFacadeFactory;
}
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
EcorePlugin.INSTANCE.log(exception);
}
return new FacadeFactoryImpl();
@@ -53,6 +54,7 @@ public class FacadeFactoryImpl extends EFactoryImpl implements FacadeFactory {
* Creates an instance of the factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeFactoryImpl() {
@@ -62,22 +64,26 @@ public class FacadeFactoryImpl extends EFactoryImpl implements FacadeFactory {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public EObject create(EClass eClass) {
switch (eClass.getClassifierID()) {
- case FacadePackage.FACADE: return createFacade();
- default:
- throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
+ case FacadePackage.FACADE:
+ return createFacade();
+ default:
+ throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Facade createFacade() {
FacadeImpl facade = new FacadeImpl();
return facade;
@@ -86,15 +92,18 @@ public class FacadeFactoryImpl extends EFactoryImpl implements FacadeFactory {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public FacadePackage getFacadePackage() {
- return (FacadePackage)getEPackage();
+ return (FacadePackage) getEPackage();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @deprecated
* @generated
*/
@@ -103,4 +112,4 @@ public class FacadeFactoryImpl extends EFactoryImpl implements FacadeFactory {
return FacadePackage.eINSTANCE;
}
-} //FacadeFactoryImpl
+} // FacadeFactoryImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeImpl.java
index 94092fd6282..6978bc8ac56 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadeImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -45,8 +45,8 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.impl.FacadeImpl#getExtensionDefinitions <em>Extension Definitions</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.impl.FacadeImpl#getVirtualmetamodel <em>Virtualmetamodel</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.impl.FacadeImpl#getExtensionDefinitions <em>Extension Definitions</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.impl.FacadeImpl#getVirtualmetamodel <em>Virtualmetamodel</em>}</li>
* </ul>
* </p>
*
@@ -57,6 +57,7 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
* The cached value of the '{@link #getExtensionDefinitions() <em>Extension Definitions</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getExtensionDefinitions()
* @generated
* @ordered
@@ -67,6 +68,7 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
* The cached value of the '{@link #getVirtualmetamodel() <em>Virtualmetamodel</em>}' containment reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getVirtualmetamodel()
* @generated
* @ordered
@@ -76,6 +78,7 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacadeImpl() {
@@ -85,6 +88,7 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -95,8 +99,10 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<ExtensionDefinition> getExtensionDefinitions() {
if (extensionDefinitions == null) {
extensionDefinitions = new EObjectContainmentWithInverseEList<ExtensionDefinition>(ExtensionDefinition.class, this, FacadePackage.FACADE__EXTENSION_DEFINITIONS, ExtensiondefinitionPackage.EXTENSION_DEFINITION__FACADE);
@@ -107,8 +113,10 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualMetamodel getVirtualmetamodel() {
return virtualmetamodel;
}
@@ -116,6 +124,7 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public NotificationChain basicSetVirtualmetamodel(VirtualMetamodel newVirtualmetamodel, NotificationChain msgs) {
@@ -123,7 +132,11 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
virtualmetamodel = newVirtualmetamodel;
if (eNotificationRequired()) {
ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, FacadePackage.FACADE__VIRTUALMETAMODEL, oldVirtualmetamodel, newVirtualmetamodel);
- if (msgs == null) msgs = notification; else msgs.add(notification);
+ if (msgs == null) {
+ msgs = notification;
+ } else {
+ msgs.add(notification);
+ }
}
return msgs;
}
@@ -131,37 +144,46 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setVirtualmetamodel(VirtualMetamodel newVirtualmetamodel) {
if (newVirtualmetamodel != virtualmetamodel) {
NotificationChain msgs = null;
- if (virtualmetamodel != null)
- msgs = ((InternalEObject)virtualmetamodel).eInverseRemove(this, VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE, VirtualMetamodel.class, msgs);
- if (newVirtualmetamodel != null)
- msgs = ((InternalEObject)newVirtualmetamodel).eInverseAdd(this, VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE, VirtualMetamodel.class, msgs);
+ if (virtualmetamodel != null) {
+ msgs = ((InternalEObject) virtualmetamodel).eInverseRemove(this, VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE, VirtualMetamodel.class, msgs);
+ }
+ if (newVirtualmetamodel != null) {
+ msgs = ((InternalEObject) newVirtualmetamodel).eInverseAdd(this, VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE, VirtualMetamodel.class, msgs);
+ }
msgs = basicSetVirtualmetamodel(newVirtualmetamodel, msgs);
- if (msgs != null) msgs.dispatch();
+ if (msgs != null) {
+ msgs.dispatch();
+ }
}
- else if (eNotificationRequired())
+ else if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, FacadePackage.FACADE__VIRTUALMETAMODEL, newVirtualmetamodel, newVirtualmetamodel));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
- return ((InternalEList<InternalEObject>)(InternalEList<?>)getExtensionDefinitions()).basicAdd(otherEnd, msgs);
- case FacadePackage.FACADE__VIRTUALMETAMODEL:
- if (virtualmetamodel != null)
- msgs = ((InternalEObject)virtualmetamodel).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - FacadePackage.FACADE__VIRTUALMETAMODEL, null, msgs);
- return basicSetVirtualmetamodel((VirtualMetamodel)otherEnd, msgs);
+ case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
+ return ((InternalEList<InternalEObject>) (InternalEList<?>) getExtensionDefinitions()).basicAdd(otherEnd, msgs);
+ case FacadePackage.FACADE__VIRTUALMETAMODEL:
+ if (virtualmetamodel != null) {
+ msgs = ((InternalEObject) virtualmetamodel).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - FacadePackage.FACADE__VIRTUALMETAMODEL, null, msgs);
+ }
+ return basicSetVirtualmetamodel((VirtualMetamodel) otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
}
@@ -169,15 +191,16 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
- return ((InternalEList<?>)getExtensionDefinitions()).basicRemove(otherEnd, msgs);
- case FacadePackage.FACADE__VIRTUALMETAMODEL:
- return basicSetVirtualmetamodel(null, msgs);
+ case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
+ return ((InternalEList<?>) getExtensionDefinitions()).basicRemove(otherEnd, msgs);
+ case FacadePackage.FACADE__VIRTUALMETAMODEL:
+ return basicSetVirtualmetamodel(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -185,15 +208,16 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
- return getExtensionDefinitions();
- case FacadePackage.FACADE__VIRTUALMETAMODEL:
- return getVirtualmetamodel();
+ case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
+ return getExtensionDefinitions();
+ case FacadePackage.FACADE__VIRTUALMETAMODEL:
+ return getVirtualmetamodel();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -201,19 +225,20 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
- getExtensionDefinitions().clear();
- getExtensionDefinitions().addAll((Collection<? extends ExtensionDefinition>)newValue);
- return;
- case FacadePackage.FACADE__VIRTUALMETAMODEL:
- setVirtualmetamodel((VirtualMetamodel)newValue);
- return;
+ case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
+ getExtensionDefinitions().clear();
+ getExtensionDefinitions().addAll((Collection<? extends ExtensionDefinition>) newValue);
+ return;
+ case FacadePackage.FACADE__VIRTUALMETAMODEL:
+ setVirtualmetamodel((VirtualMetamodel) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -221,17 +246,18 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
- getExtensionDefinitions().clear();
- return;
- case FacadePackage.FACADE__VIRTUALMETAMODEL:
- setVirtualmetamodel((VirtualMetamodel)null);
- return;
+ case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
+ getExtensionDefinitions().clear();
+ return;
+ case FacadePackage.FACADE__VIRTUALMETAMODEL:
+ setVirtualmetamodel((VirtualMetamodel) null);
+ return;
}
super.eUnset(featureID);
}
@@ -239,17 +265,18 @@ public class FacadeImpl extends MinimalEObjectImpl.Container implements Facade {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
- return extensionDefinitions != null && !extensionDefinitions.isEmpty();
- case FacadePackage.FACADE__VIRTUALMETAMODEL:
- return virtualmetamodel != null;
+ case FacadePackage.FACADE__EXTENSION_DEFINITIONS:
+ return extensionDefinitions != null && !extensionDefinitions.isEmpty();
+ case FacadePackage.FACADE__VIRTUALMETAMODEL:
+ return virtualmetamodel != null;
}
return super.eIsSet(featureID);
}
-} //FacadeImpl
+} // FacadeImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadePackageImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadePackageImpl.java
index 8e007b82c48..6569ee62649 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadePackageImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/impl/FacadePackageImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -37,26 +37,24 @@ import org.eclipse.uml2.uml.UMLPackage;
* <!-- begin-user-doc -->
* An implementation of the model <b>Package</b>.
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadePackageImpl extends EPackageImpl implements FacadePackage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass facadeEClass = null;
/**
- * Creates an instance of the model <b>Package</b>, registered with
- * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
+ * Creates an instance of the model <b>Package</b>, registered with {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
* package URI value.
- * <p>Note: the correct way to create the package is via the static
- * factory method {@link #init init()}, which also performs
- * initialization of the package, or returns the registered package,
- * if one already exists.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
+ * <p>
+ * Note: the correct way to create the package is via the static factory method {@link #init init()}, which also performs initialization of the package, or returns the registered package, if one already exists. <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
* @see org.eclipse.emf.ecore.EPackage.Registry
* @see org.eclipse.papyrus.facade.FacadePackage#eNS_URI
* @see #init()
@@ -69,27 +67,29 @@ public class FacadePackageImpl extends EPackageImpl implements FacadePackage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static boolean isInited = false;
/**
* Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends.
+ *
+ * <p>
+ * This method is used to initialize {@link FacadePackage#eINSTANCE} when that field is accessed. Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. <!-- begin-user-doc --> <!-- end-user-doc -->
*
- * <p>This method is used to initialize {@link FacadePackage#eINSTANCE} when that field is accessed.
- * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
* @see #eNS_URI
* @see #createPackageContents()
* @see #initializePackageContents()
* @generated
*/
public static FacadePackage init() {
- if (isInited) return (FacadePackage)EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI);
+ if (isInited) {
+ return (FacadePackage) EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI);
+ }
// Obtain or create and register package
- FacadePackageImpl theFacadePackage = (FacadePackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof FacadePackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new FacadePackageImpl());
+ FacadePackageImpl theFacadePackage = (FacadePackageImpl) (EPackage.Registry.INSTANCE.get(eNS_URI) instanceof FacadePackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new FacadePackageImpl());
isInited = true;
@@ -97,8 +97,10 @@ public class FacadePackageImpl extends EPackageImpl implements FacadePackage {
UMLPackage.eINSTANCE.eClass();
// Obtain or create and register interdependencies
- VirtualmetamodelPackageImpl theVirtualmetamodelPackage = (VirtualmetamodelPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI) instanceof VirtualmetamodelPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI) : VirtualmetamodelPackage.eINSTANCE);
- ExtensiondefinitionPackageImpl theExtensiondefinitionPackage = (ExtensiondefinitionPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI) instanceof ExtensiondefinitionPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI) : ExtensiondefinitionPackage.eINSTANCE);
+ VirtualmetamodelPackageImpl theVirtualmetamodelPackage = (VirtualmetamodelPackageImpl) (EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI) instanceof VirtualmetamodelPackageImpl ? EPackage.Registry.INSTANCE
+ .getEPackage(VirtualmetamodelPackage.eNS_URI) : VirtualmetamodelPackage.eINSTANCE);
+ ExtensiondefinitionPackageImpl theExtensiondefinitionPackage = (ExtensiondefinitionPackageImpl) (EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI) instanceof ExtensiondefinitionPackageImpl ? EPackage.Registry.INSTANCE
+ .getEPackage(ExtensiondefinitionPackage.eNS_URI) : ExtensiondefinitionPackage.eINSTANCE);
// Create package meta-data objects
theFacadePackage.createPackageContents();
@@ -113,7 +115,7 @@ public class FacadePackageImpl extends EPackageImpl implements FacadePackage {
// Mark meta-data to indicate it can't be changed
theFacadePackage.freeze();
-
+
// Update the registry and return the package
EPackage.Registry.INSTANCE.put(FacadePackage.eNS_URI, theFacadePackage);
return theFacadePackage;
@@ -122,8 +124,10 @@ public class FacadePackageImpl extends EPackageImpl implements FacadePackage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getFacade() {
return facadeEClass;
}
@@ -131,46 +135,56 @@ public class FacadePackageImpl extends EPackageImpl implements FacadePackage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getFacade_ExtensionDefinitions() {
- return (EReference)facadeEClass.getEStructuralFeatures().get(0);
+ return (EReference) facadeEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getFacade_Virtualmetamodel() {
- return (EReference)facadeEClass.getEStructuralFeatures().get(1);
+ return (EReference) facadeEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public FacadeFactory getFacadeFactory() {
- return (FacadeFactory)getEFactoryInstance();
+ return (FacadeFactory) getEFactoryInstance();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private boolean isCreated = false;
/**
- * Creates the meta-model objects for the package. This method is
+ * Creates the meta-model objects for the package. This method is
* guarded to have no affect on any invocation but its first.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void createPackageContents() {
- if (isCreated) return;
+ if (isCreated) {
+ return;
+ }
isCreated = true;
// Create classes and their features
@@ -182,19 +196,23 @@ public class FacadePackageImpl extends EPackageImpl implements FacadePackage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private boolean isInitialized = false;
/**
- * Complete the initialization of the package and its meta-model. This
+ * Complete the initialization of the package and its meta-model. This
* method is guarded to have no affect on any invocation but its first.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void initializePackageContents() {
- if (isInitialized) return;
+ if (isInitialized) {
+ return;
+ }
isInitialized = true;
// Initialize package
@@ -203,8 +221,8 @@ public class FacadePackageImpl extends EPackageImpl implements FacadePackage {
setNsURI(eNS_URI);
// Obtain other dependent packages
- VirtualmetamodelPackage theVirtualmetamodelPackage = (VirtualmetamodelPackage)EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI);
- ExtensiondefinitionPackage theExtensiondefinitionPackage = (ExtensiondefinitionPackage)EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI);
+ VirtualmetamodelPackage theVirtualmetamodelPackage = (VirtualmetamodelPackage) EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI);
+ ExtensiondefinitionPackage theExtensiondefinitionPackage = (ExtensiondefinitionPackage) EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI);
// Add subpackages
getESubpackages().add(theVirtualmetamodelPackage);
@@ -218,11 +236,13 @@ public class FacadePackageImpl extends EPackageImpl implements FacadePackage {
// Initialize classes, features, and operations; add parameters
initEClass(facadeEClass, Facade.class, "Facade", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getFacade_ExtensionDefinitions(), theExtensiondefinitionPackage.getExtensionDefinition(), theExtensiondefinitionPackage.getExtensionDefinition_Facade(), "extensionDefinitions", null, 0, -1, Facade.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getFacade_Virtualmetamodel(), theVirtualmetamodelPackage.getVirtualMetamodel(), theVirtualmetamodelPackage.getVirtualMetamodel_Facade(), "virtualmetamodel", null, 0, 1, Facade.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getFacade_ExtensionDefinitions(), theExtensiondefinitionPackage.getExtensionDefinition(), theExtensiondefinitionPackage.getExtensionDefinition_Facade(), "extensionDefinitions", null, 0, -1, Facade.class, !IS_TRANSIENT, !IS_VOLATILE,
+ IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getFacade_Virtualmetamodel(), theVirtualmetamodelPackage.getVirtualMetamodel(), theVirtualmetamodelPackage.getVirtualMetamodel_Facade(), "virtualmetamodel", null, 0, 1, Facade.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE,
+ IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
// Create resource
createResource(eNS_URI);
}
-} //FacadePackageImpl
+} // FacadePackageImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeAdapterFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeAdapterFactory.java
index 4354eb5fc51..ec0e629a9c3 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeAdapterFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeAdapterFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.papyrus.facade.*;
* The <b>Adapter Factory</b> for the model.
* It provides an adapter <code>createXXX</code> method for each class of the model.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.FacadePackage
* @generated
*/
@@ -35,6 +36,7 @@ public class FacadeAdapterFactory extends AdapterFactoryImpl {
* The cached model package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected static FacadePackage modelPackage;
@@ -43,6 +45,7 @@ public class FacadeAdapterFactory extends AdapterFactoryImpl {
* Creates an instance of the adapter factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeAdapterFactory() {
@@ -56,6 +59,7 @@ public class FacadeAdapterFactory extends AdapterFactoryImpl {
* <!-- begin-user-doc -->
* This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model.
* <!-- end-user-doc -->
+ *
* @return whether this factory is applicable for the type of the object.
* @generated
*/
@@ -65,7 +69,7 @@ public class FacadeAdapterFactory extends AdapterFactoryImpl {
return true;
}
if (object instanceof EObject) {
- return ((EObject)object).eClass().getEPackage() == modelPackage;
+ return ((EObject) object).eClass().getEPackage() == modelPackage;
}
return false;
}
@@ -74,31 +78,35 @@ public class FacadeAdapterFactory extends AdapterFactoryImpl {
* The switch that delegates to the <code>createXXX</code> methods.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacadeSwitch<Adapter> modelSwitch =
- new FacadeSwitch<Adapter>() {
- @Override
- public Adapter caseFacade(Facade object) {
- return createFacadeAdapter();
- }
- @Override
- public Adapter defaultCase(EObject object) {
- return createEObjectAdapter();
- }
- };
+ new FacadeSwitch<Adapter>() {
+ @Override
+ public Adapter caseFacade(Facade object) {
+ return createFacadeAdapter();
+ }
+
+ @Override
+ public Adapter defaultCase(EObject object) {
+ return createEObjectAdapter();
+ }
+ };
/**
* Creates an adapter for the <code>target</code>.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param target the object to adapt.
+ *
+ * @param target
+ * the object to adapt.
* @return the adapter for the <code>target</code>.
* @generated
*/
@Override
public Adapter createAdapter(Notifier target) {
- return modelSwitch.doSwitch((EObject)target);
+ return modelSwitch.doSwitch((EObject) target);
}
@@ -108,6 +116,7 @@ public class FacadeAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.Facade
* @generated
@@ -121,6 +130,7 @@ public class FacadeAdapterFactory extends AdapterFactoryImpl {
* <!-- begin-user-doc -->
* This default implementation returns null.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @generated
*/
@@ -128,4 +138,4 @@ public class FacadeAdapterFactory extends AdapterFactoryImpl {
return null;
}
-} //FacadeAdapterFactory
+} // FacadeAdapterFactory
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceFactoryImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceFactoryImpl.java
index be981087833..5d7fdbe354f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceFactoryImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceFactoryImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,6 +25,7 @@ import org.eclipse.emf.ecore.xmi.XMLResource;
* <!-- begin-user-doc -->
* The <b>Resource Factory</b> associated with the package.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.util.FacadeResourceImpl
* @generated
*/
@@ -33,6 +34,7 @@ public class FacadeResourceFactoryImpl extends ResourceFactoryImpl {
* Creates an instance of the resource factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeResourceFactoryImpl() {
@@ -43,6 +45,7 @@ public class FacadeResourceFactoryImpl extends ResourceFactoryImpl {
* Creates an instance of the resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -60,4 +63,4 @@ public class FacadeResourceFactoryImpl extends ResourceFactoryImpl {
return result;
}
-} //FacadeResourceFactoryImpl
+} // FacadeResourceFactoryImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceImpl.java
index 81be26f04c4..67719ae2914 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeResourceImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -21,6 +21,7 @@ import org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl;
* <!-- begin-user-doc -->
* The <b>Resource </b> associated with the package.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.util.FacadeResourceFactoryImpl
* @generated
*/
@@ -29,11 +30,13 @@ public class FacadeResourceImpl extends XMLResourceImpl {
* Creates an instance of the resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param uri the URI of the new resource.
+ *
+ * @param uri
+ * the URI of the new resource.
* @generated
*/
public FacadeResourceImpl(URI uri) {
super(uri);
}
-} //FacadeResourceImpl
+} // FacadeResourceImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeSwitch.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeSwitch.java
index 66a22660fc8..7769d442fda 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeSwitch.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeSwitch.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,13 +23,13 @@ import org.eclipse.papyrus.facade.*;
/**
* <!-- begin-user-doc -->
* The <b>Switch</b> for the model's inheritance hierarchy.
- * It supports the call {@link #doSwitch(EObject) doSwitch(object)}
- * to invoke the <code>caseXXX</code> method for each class of the model,
+ * It supports the call {@link #doSwitch(EObject) doSwitch(object)} to invoke the <code>caseXXX</code> method for each class of the model,
* starting with the actual class of the object
* and proceeding up the inheritance hierarchy
* until a non-null result is returned,
* which is the result of the switch.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.FacadePackage
* @generated
*/
@@ -38,6 +38,7 @@ public class FacadeSwitch<T> extends Switch<T> {
* The cached model package
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected static FacadePackage modelPackage;
@@ -46,6 +47,7 @@ public class FacadeSwitch<T> extends Switch<T> {
* Creates an instance of the switch.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeSwitch() {
@@ -58,6 +60,7 @@ public class FacadeSwitch<T> extends Switch<T> {
* Checks whether this is a switch for the given package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @parameter ePackage the package in question.
* @return whether this is a switch for the given package.
* @generated
@@ -71,19 +74,23 @@ public class FacadeSwitch<T> extends Switch<T> {
* Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the first non-null result returned by a <code>caseXXX</code> call.
* @generated
*/
@Override
protected T doSwitch(int classifierID, EObject theEObject) {
switch (classifierID) {
- case FacadePackage.FACADE: {
- Facade facade = (Facade)theEObject;
- T result = caseFacade(facade);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ case FacadePackage.FACADE: {
+ Facade facade = (Facade) theEObject;
+ T result = caseFacade(facade);
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- default: return defaultCase(theEObject);
+ return result;
+ }
+ default:
+ return defaultCase(theEObject);
}
}
@@ -93,7 +100,9 @@ public class FacadeSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Facade</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -108,7 +117,9 @@ public class FacadeSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch, but this is the last case anyway.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>EObject</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject)
* @generated
@@ -118,4 +129,4 @@ public class FacadeSwitch<T> extends Switch<T> {
return null;
}
-} //FacadeSwitch
+} // FacadeSwitch
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeXMLProcessor.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeXMLProcessor.java
index afa54db84f3..704f015acbd 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeXMLProcessor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/util/FacadeXMLProcessor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.papyrus.facade.FacadePackage;
* This class contains helper methods to serialize and deserialize XML documents
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacadeXMLProcessor extends XMLProcessor {
@@ -35,17 +36,19 @@ public class FacadeXMLProcessor extends XMLProcessor {
* Public constructor to instantiate the helper.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacadeXMLProcessor() {
super((EPackage.Registry.INSTANCE));
FacadePackage.eINSTANCE.eClass();
}
-
+
/**
* Register for "*" and "xml" file extensions the FacadeResourceFactoryImpl factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -58,4 +61,4 @@ public class FacadeXMLProcessor extends XMLProcessor {
return registrations;
}
-} //FacadeXMLProcessor
+} // FacadeXMLProcessor
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/validation/FacadeValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/validation/FacadeValidator.java
index 70d6fa82599..5c6f243616f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/validation/FacadeValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/validation/FacadeValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -29,5 +29,6 @@ public interface FacadeValidator {
boolean validate();
boolean validateExtensionDefinitions(EList<ExtensionDefinition> value);
+
boolean validateVirtualmetamodel(VirtualMetamodel value);
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualClassifier.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualClassifier.java
index 3b02cb8cd65..aefd79aebf9 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualClassifier.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualClassifier.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -22,7 +22,7 @@ package org.eclipse.papyrus.facade.virtualmetamodel;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier#getMetamodel <em>Metamodel</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier#getMetamodel <em>Metamodel</em>}</li>
* </ul>
* </p>
*
@@ -36,10 +36,10 @@ public interface VirtualClassifier extends VirtualElement {
* It is bidirectional and its opposite is '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getVirtualClassifiers <em>Virtual Classifiers</em>}'.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Metamodel</em>' container reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Metamodel</em>' container reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Metamodel</em>' container reference.
* @see #setMetamodel(VirtualMetamodel)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualClassifier_Metamodel()
@@ -53,7 +53,9 @@ public interface VirtualClassifier extends VirtualElement {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier#getMetamodel <em>Metamodel</em>}' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Metamodel</em>' container reference.
+ *
+ * @param value
+ * the new value of the '<em>Metamodel</em>' container reference.
* @see #getMetamodel()
* @generated
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualDatatype.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualDatatype.java
index 4555bafad17..66aa0b77b68 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualDatatype.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualDatatype.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualElement.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualElement.java
index 5ed677fce08..9140e268977 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualElement.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualElement.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,10 +23,10 @@ import org.eclipse.emf.ecore.EObject;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getAliasName <em>Alias Name</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isKept <em>Kept</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getRepresentedElement <em>Represented Element</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isUseRepresented <em>Use Represented</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getAliasName <em>Alias Name</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isKept <em>Kept</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getRepresentedElement <em>Represented Element</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isUseRepresented <em>Use Represented</em>}</li>
* </ul>
* </p>
*
@@ -39,10 +39,10 @@ public interface VirtualElement extends EObject {
* Returns the value of the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Alias Name</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Alias Name</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Alias Name</em>' attribute.
* @see #setAliasName(String)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualElement_AliasName()
@@ -55,7 +55,9 @@ public interface VirtualElement extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getAliasName <em>Alias Name</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Alias Name</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Alias Name</em>' attribute.
* @see #getAliasName()
* @generated
*/
@@ -65,10 +67,10 @@ public interface VirtualElement extends EObject {
* Returns the value of the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Kept</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Kept</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Kept</em>' attribute.
* @see #setKept(boolean)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualElement_Kept()
@@ -81,7 +83,9 @@ public interface VirtualElement extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isKept <em>Kept</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Kept</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Kept</em>' attribute.
* @see #isKept()
* @generated
*/
@@ -91,10 +95,10 @@ public interface VirtualElement extends EObject {
* Returns the value of the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Represented Element</em>' reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Represented Element</em>' reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Represented Element</em>' reference.
* @see #setRepresentedElement(EObject)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualElement_RepresentedElement()
@@ -107,7 +111,9 @@ public interface VirtualElement extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getRepresentedElement <em>Represented Element</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Represented Element</em>' reference.
+ *
+ * @param value
+ * the new value of the '<em>Represented Element</em>' reference.
* @see #getRepresentedElement()
* @generated
*/
@@ -117,10 +123,10 @@ public interface VirtualElement extends EObject {
* Returns the value of the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Use Represented</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Use Represented</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Use Represented</em>' attribute.
* @see #setUseRepresented(boolean)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualElement_UseRepresented()
@@ -133,7 +139,9 @@ public interface VirtualElement extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isUseRepresented <em>Use Represented</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Use Represented</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Use Represented</em>' attribute.
* @see #isUseRepresented()
* @generated
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualEnum.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualEnum.java
index 48f6927d654..c027246f043 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualEnum.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualEnum.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,7 +23,7 @@ import org.eclipse.emf.common.util.EList;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum#getLiterals <em>Literals</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum#getLiterals <em>Literals</em>}</li>
* </ul>
* </p>
*
@@ -37,10 +37,10 @@ public interface VirtualEnum extends VirtualClassifier {
* The list contents are of type {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualLiteral}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Literals</em>' containment reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Literals</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Literals</em>' containment reference list.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualEnum_Literals()
* @model containment="true"
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualLiteral.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualLiteral.java
index 603511899ad..e045e4d42be 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualLiteral.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualLiteral.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetaclass.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetaclass.java
index 96e532c9afe..d1e81b13f8f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetaclass.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetaclass.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,12 +25,12 @@ import org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isAbstract <em>Abstract</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getAppliedStereotypes <em>Applied Stereotypes</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getOperations <em>Operations</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getParents <em>Parents</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getProperties <em>Properties</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isStereotypeInterface <em>Stereotype Interface</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isAbstract <em>Abstract</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getAppliedStereotypes <em>Applied Stereotypes</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getOperations <em>Operations</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getParents <em>Parents</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getProperties <em>Properties</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isStereotypeInterface <em>Stereotype Interface</em>}</li>
* </ul>
* </p>
*
@@ -43,10 +43,10 @@ public interface VirtualMetaclass extends VirtualClassifier {
* Returns the value of the '<em><b>Abstract</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Abstract</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Abstract</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Abstract</em>' attribute.
* @see #setAbstract(boolean)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetaclass_Abstract()
@@ -59,7 +59,9 @@ public interface VirtualMetaclass extends VirtualClassifier {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isAbstract <em>Abstract</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Abstract</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Abstract</em>' attribute.
* @see #isAbstract()
* @generated
*/
@@ -70,10 +72,10 @@ public interface VirtualMetaclass extends VirtualClassifier {
* The list contents are of type {@link org.eclipse.papyrus.facade.extensiondefinition.BaseMetaclass}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Applied Stereotypes</em>' reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Applied Stereotypes</em>' reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Applied Stereotypes</em>' reference list.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetaclass_AppliedStereotypes()
* @model
@@ -86,10 +88,10 @@ public interface VirtualMetaclass extends VirtualClassifier {
* The list contents are of type {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Operations</em>' containment reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Operations</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Operations</em>' containment reference list.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetaclass_Operations()
* @model containment="true"
@@ -102,10 +104,10 @@ public interface VirtualMetaclass extends VirtualClassifier {
* The list contents are of type {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Parents</em>' reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Parents</em>' reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Parents</em>' reference list.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetaclass_Parents()
* @model
@@ -119,10 +121,10 @@ public interface VirtualMetaclass extends VirtualClassifier {
* It is bidirectional and its opposite is '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty#getVirtualMetaclass <em>Virtual Metaclass</em>}'.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Properties</em>' containment reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Properties</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Properties</em>' containment reference list.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetaclass_Properties()
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty#getVirtualMetaclass
@@ -135,10 +137,10 @@ public interface VirtualMetaclass extends VirtualClassifier {
* Returns the value of the '<em><b>Stereotype Interface</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Stereotype Interface</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Stereotype Interface</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Stereotype Interface</em>' attribute.
* @see #setStereotypeInterface(boolean)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetaclass_StereotypeInterface()
@@ -151,7 +153,9 @@ public interface VirtualMetaclass extends VirtualClassifier {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isStereotypeInterface <em>Stereotype Interface</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Stereotype Interface</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Stereotype Interface</em>' attribute.
* @see #isStereotypeInterface()
* @generated
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetamodel.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetamodel.java
index 322f9f60cea..b62d2456475 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetamodel.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualMetamodel.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,11 +27,11 @@ import org.eclipse.papyrus.facade.Facade;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getName <em>Name</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsPrefix <em>Ns Prefix</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsURI <em>Ns URI</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getVirtualClassifiers <em>Virtual Classifiers</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getFacade <em>Facade</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getName <em>Name</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsPrefix <em>Ns Prefix</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsURI <em>Ns URI</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getVirtualClassifiers <em>Virtual Classifiers</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getFacade <em>Facade</em>}</li>
* </ul>
* </p>
*
@@ -44,10 +44,10 @@ public interface VirtualMetamodel extends EObject {
* Returns the value of the '<em><b>Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Name</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Name</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Name</em>' attribute.
* @see #setName(String)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetamodel_Name()
@@ -60,7 +60,9 @@ public interface VirtualMetamodel extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getName <em>Name</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Name</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Name</em>' attribute.
* @see #getName()
* @generated
*/
@@ -70,10 +72,10 @@ public interface VirtualMetamodel extends EObject {
* Returns the value of the '<em><b>Ns Prefix</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Ns Prefix</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Ns Prefix</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Ns Prefix</em>' attribute.
* @see #setNsPrefix(String)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetamodel_NsPrefix()
@@ -86,7 +88,9 @@ public interface VirtualMetamodel extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsPrefix <em>Ns Prefix</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Ns Prefix</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Ns Prefix</em>' attribute.
* @see #getNsPrefix()
* @generated
*/
@@ -96,10 +100,10 @@ public interface VirtualMetamodel extends EObject {
* Returns the value of the '<em><b>Ns URI</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Ns URI</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Ns URI</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Ns URI</em>' attribute.
* @see #setNsURI(String)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetamodel_NsURI()
@@ -112,7 +116,9 @@ public interface VirtualMetamodel extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsURI <em>Ns URI</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Ns URI</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Ns URI</em>' attribute.
* @see #getNsURI()
* @generated
*/
@@ -124,10 +130,10 @@ public interface VirtualMetamodel extends EObject {
* It is bidirectional and its opposite is '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier#getMetamodel <em>Metamodel</em>}'.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Virtual Classifiers</em>' containment reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Virtual Classifiers</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Virtual Classifiers</em>' containment reference list.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetamodel_VirtualClassifiers()
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier#getMetamodel
@@ -141,10 +147,10 @@ public interface VirtualMetamodel extends EObject {
* It is bidirectional and its opposite is '{@link org.eclipse.papyrus.facade.Facade#getVirtualmetamodel <em>Virtualmetamodel</em>}'.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Facade</em>' container reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Facade</em>' container reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Facade</em>' container reference.
* @see #setFacade(Facade)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualMetamodel_Facade()
@@ -158,7 +164,9 @@ public interface VirtualMetamodel extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getFacade <em>Facade</em>}' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Facade</em>' container reference.
+ *
+ * @param value
+ * the new value of the '<em>Facade</em>' container reference.
* @see #getFacade()
* @generated
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualOperation.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualOperation.java
index 9d6941f4a33..f2c55103802 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualOperation.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualOperation.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,7 +23,7 @@ import org.eclipse.emf.common.util.EList;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation#getParameters <em>Parameters</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation#getParameters <em>Parameters</em>}</li>
* </ul>
* </p>
*
@@ -37,10 +37,10 @@ public interface VirtualOperation extends VirtualTypedElement {
* The list contents are of type {@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualParameter}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Parameters</em>' containment reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Parameters</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Parameters</em>' containment reference list.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualOperation_Parameters()
* @model containment="true"
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualParameter.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualParameter.java
index d561bf38d74..aa96bb896c4 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualParameter.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualParameter.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualProperty.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualProperty.java
index 7e206dd27c6..12b728167a5 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualProperty.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualProperty.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -22,7 +22,7 @@ package org.eclipse.papyrus.facade.virtualmetamodel;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty#getVirtualMetaclass <em>Virtual Metaclass</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty#getVirtualMetaclass <em>Virtual Metaclass</em>}</li>
* </ul>
* </p>
*
@@ -36,10 +36,10 @@ public interface VirtualProperty extends VirtualTypedElement {
* It is bidirectional and its opposite is '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getProperties <em>Properties</em>}'.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Virtual Metaclass</em>' container reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Virtual Metaclass</em>' container reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Virtual Metaclass</em>' container reference.
* @see #setVirtualMetaclass(VirtualMetaclass)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualProperty_VirtualMetaclass()
@@ -53,7 +53,9 @@ public interface VirtualProperty extends VirtualTypedElement {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty#getVirtualMetaclass <em>Virtual Metaclass</em>}' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Virtual Metaclass</em>' container reference.
+ *
+ * @param value
+ * the new value of the '<em>Virtual Metaclass</em>' container reference.
* @see #getVirtualMetaclass()
* @generated
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualTypedElement.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualTypedElement.java
index 5f5bf0964e3..780c1ea224a 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualTypedElement.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualTypedElement.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -22,9 +22,9 @@ package org.eclipse.papyrus.facade.virtualmetamodel;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getLower <em>Lower</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getUpper <em>Upper</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getType <em>Type</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getLower <em>Lower</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getUpper <em>Upper</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getType <em>Type</em>}</li>
* </ul>
* </p>
*
@@ -37,10 +37,10 @@ public interface VirtualTypedElement extends VirtualElement {
* Returns the value of the '<em><b>Lower</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Lower</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Lower</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Lower</em>' attribute.
* @see #setLower(int)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualTypedElement_Lower()
@@ -53,7 +53,9 @@ public interface VirtualTypedElement extends VirtualElement {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getLower <em>Lower</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Lower</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Lower</em>' attribute.
* @see #getLower()
* @generated
*/
@@ -63,10 +65,10 @@ public interface VirtualTypedElement extends VirtualElement {
* Returns the value of the '<em><b>Upper</b></em>' attribute.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Upper</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Upper</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Upper</em>' attribute.
* @see #setUpper(int)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualTypedElement_Upper()
@@ -79,7 +81,9 @@ public interface VirtualTypedElement extends VirtualElement {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getUpper <em>Upper</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Upper</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Upper</em>' attribute.
* @see #getUpper()
* @generated
*/
@@ -89,10 +93,10 @@ public interface VirtualTypedElement extends VirtualElement {
* Returns the value of the '<em><b>Type</b></em>' reference.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Type</em>' reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Type</em>' reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Type</em>' reference.
* @see #setType(VirtualClassifier)
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#getVirtualTypedElement_Type()
@@ -105,7 +109,9 @@ public interface VirtualTypedElement extends VirtualElement {
* Sets the value of the '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getType <em>Type</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Type</em>' reference.
+ *
+ * @param value
+ * the new value of the '<em>Type</em>' reference.
* @see #getType()
* @generated
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelFactory.java
index 3dcc2eb90d2..03174c97be1 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -20,6 +20,7 @@ import org.eclipse.emf.ecore.EFactory;
* The <b>Factory</b> for the model.
* It provides a create method for each non-abstract class of the model.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage
* @generated
*/
@@ -28,6 +29,7 @@ public interface VirtualmetamodelFactory extends EFactory {
* The singleton instance of the factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
VirtualmetamodelFactory eINSTANCE = org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelFactoryImpl.init();
@@ -36,6 +38,7 @@ public interface VirtualmetamodelFactory extends EFactory {
* Returns a new object of class '<em>Virtual Metamodel</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Virtual Metamodel</em>'.
* @generated
*/
@@ -45,6 +48,7 @@ public interface VirtualmetamodelFactory extends EFactory {
* Returns a new object of class '<em>Virtual Metaclass</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Virtual Metaclass</em>'.
* @generated
*/
@@ -54,6 +58,7 @@ public interface VirtualmetamodelFactory extends EFactory {
* Returns a new object of class '<em>Virtual Property</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Virtual Property</em>'.
* @generated
*/
@@ -63,6 +68,7 @@ public interface VirtualmetamodelFactory extends EFactory {
* Returns a new object of class '<em>Virtual Operation</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Virtual Operation</em>'.
* @generated
*/
@@ -72,6 +78,7 @@ public interface VirtualmetamodelFactory extends EFactory {
* Returns a new object of class '<em>Virtual Parameter</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Virtual Parameter</em>'.
* @generated
*/
@@ -81,6 +88,7 @@ public interface VirtualmetamodelFactory extends EFactory {
* Returns a new object of class '<em>Virtual Datatype</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Virtual Datatype</em>'.
* @generated
*/
@@ -90,6 +98,7 @@ public interface VirtualmetamodelFactory extends EFactory {
* Returns a new object of class '<em>Virtual Enum</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Virtual Enum</em>'.
* @generated
*/
@@ -99,6 +108,7 @@ public interface VirtualmetamodelFactory extends EFactory {
* Returns a new object of class '<em>Virtual Literal</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Virtual Literal</em>'.
* @generated
*/
@@ -108,9 +118,10 @@ public interface VirtualmetamodelFactory extends EFactory {
* Returns the package supported by this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the package supported by this factory.
* @generated
*/
VirtualmetamodelPackage getVirtualmetamodelPackage();
-} //VirtualmetamodelFactory
+} // VirtualmetamodelFactory
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelPackage.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelPackage.java
index 7fa7e813107..8b5dcd17f4e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelPackage.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/VirtualmetamodelPackage.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,13 +23,14 @@ import org.eclipse.emf.ecore.EReference;
* The <b>Package</b> for the model.
* It contains accessors for the meta objects to represent
* <ul>
- * <li>each class,</li>
- * <li>each feature of each class,</li>
- * <li>each operation of each class,</li>
- * <li>each enum,</li>
- * <li>and each data type</li>
+ * <li>each class,</li>
+ * <li>each feature of each class,</li>
+ * <li>each operation of each class,</li>
+ * <li>each enum,</li>
+ * <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelFactory
* @model kind="package"
* @generated
@@ -39,6 +40,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The package name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNAME = "virtualmetamodel";
@@ -47,6 +49,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The package namespace URI.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNS_URI = "http://www.eclipse.org/papyrus/virtualmetamodel";
@@ -55,6 +58,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The package namespace name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNS_PREFIX = "virtualmetamodel";
@@ -63,6 +67,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The singleton instance of the package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
VirtualmetamodelPackage eINSTANCE = org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl.init();
@@ -71,6 +76,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl <em>Virtual Metamodel</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualMetamodel()
* @generated
@@ -81,6 +87,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -90,6 +97,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Ns Prefix</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -99,6 +107,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Ns URI</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -108,6 +117,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Virtual Classifiers</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -117,6 +127,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Facade</b></em>' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -126,6 +137,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Metamodel</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -135,6 +147,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Metamodel</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -144,6 +157,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl <em>Virtual Element</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualElement()
* @generated
@@ -154,6 +168,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -163,6 +178,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -172,6 +188,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -181,6 +198,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -190,6 +208,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Element</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -199,6 +218,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Element</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -208,6 +228,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualClassifierImpl <em>Virtual Classifier</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualClassifierImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualClassifier()
* @generated
@@ -218,6 +239,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -227,6 +249,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -236,6 +259,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -245,6 +269,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -254,6 +279,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Metamodel</b></em>' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -263,6 +289,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Classifier</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -272,6 +299,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Classifier</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -281,6 +309,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl <em>Virtual Metaclass</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualMetaclass()
* @generated
@@ -291,6 +320,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -300,6 +330,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -309,6 +340,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -318,6 +350,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -327,6 +360,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Metamodel</b></em>' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -336,6 +370,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Abstract</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -345,6 +380,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Applied Stereotypes</b></em>' reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -354,6 +390,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Operations</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -363,6 +400,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Parents</b></em>' reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -372,6 +410,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Properties</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -381,6 +420,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Stereotype Interface</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -390,6 +430,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Metaclass</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -399,6 +440,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Metaclass</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -408,6 +450,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl <em>Virtual Typed Element</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualTypedElement()
* @generated
@@ -418,6 +461,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -427,6 +471,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -436,6 +481,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -445,6 +491,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -454,6 +501,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Lower</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -463,6 +511,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Upper</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -472,6 +521,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Type</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -481,6 +531,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Typed Element</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -490,6 +541,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Typed Element</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -499,6 +551,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualPropertyImpl <em>Virtual Property</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualPropertyImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualProperty()
* @generated
@@ -509,6 +562,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -518,6 +572,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -527,6 +582,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -536,6 +592,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -545,6 +602,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Lower</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -554,6 +612,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Upper</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -563,6 +622,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Type</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -572,6 +632,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Virtual Metaclass</b></em>' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -581,6 +642,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Property</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -590,6 +652,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Property</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -599,6 +662,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualOperationImpl <em>Virtual Operation</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualOperationImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualOperation()
* @generated
@@ -609,6 +673,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -618,6 +683,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -627,6 +693,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -636,6 +703,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -645,6 +713,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Lower</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -654,6 +723,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Upper</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -663,6 +733,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Type</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -672,6 +743,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Parameters</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -681,6 +753,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Operation</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -690,6 +763,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Operation</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -699,6 +773,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualParameterImpl <em>Virtual Parameter</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualParameterImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualParameter()
* @generated
@@ -709,6 +784,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -718,6 +794,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -727,6 +804,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -736,6 +814,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -745,6 +824,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Lower</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -754,6 +834,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Upper</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -763,6 +844,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Type</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -772,6 +854,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Parameter</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -781,6 +864,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Parameter</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -790,6 +874,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualDatatypeImpl <em>Virtual Datatype</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualDatatypeImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualDatatype()
* @generated
@@ -800,6 +885,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -809,6 +895,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -818,6 +905,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -827,6 +915,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -836,6 +925,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Metamodel</b></em>' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -845,6 +935,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Datatype</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -854,6 +945,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Datatype</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -863,6 +955,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualEnumImpl <em>Virtual Enum</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualEnumImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualEnum()
* @generated
@@ -873,6 +966,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -882,6 +976,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -891,6 +986,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -900,6 +996,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -909,6 +1006,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Metamodel</b></em>' container reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -918,6 +1016,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Literals</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -927,6 +1026,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Enum</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -936,6 +1036,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Enum</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -945,6 +1046,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualLiteralImpl <em>Virtual Literal</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualLiteralImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualLiteral()
* @generated
@@ -955,6 +1057,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Alias Name</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -964,6 +1067,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Kept</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -973,6 +1077,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Represented Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -982,6 +1087,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The feature id for the '<em><b>Use Represented</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -991,6 +1097,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of structural features of the '<em>Virtual Literal</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -1000,6 +1107,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The number of operations of the '<em>Virtual Literal</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -1010,6 +1118,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel <em>Virtual Metamodel</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Metamodel</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel
* @generated
@@ -1020,6 +1129,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getName <em>Name</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Name</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getName()
* @see #getVirtualMetamodel()
@@ -1031,6 +1141,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsPrefix <em>Ns Prefix</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Ns Prefix</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsPrefix()
* @see #getVirtualMetamodel()
@@ -1042,6 +1153,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsURI <em>Ns URI</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Ns URI</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getNsURI()
* @see #getVirtualMetamodel()
@@ -1053,6 +1165,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getVirtualClassifiers <em>Virtual Classifiers</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Virtual Classifiers</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getVirtualClassifiers()
* @see #getVirtualMetamodel()
@@ -1064,6 +1177,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the container reference '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getFacade <em>Facade</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the container reference '<em>Facade</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel#getFacade()
* @see #getVirtualMetamodel()
@@ -1075,6 +1189,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement <em>Virtual Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Element</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement
* @generated
@@ -1085,6 +1200,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getAliasName <em>Alias Name</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Alias Name</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getAliasName()
* @see #getVirtualElement()
@@ -1096,6 +1212,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isKept <em>Kept</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Kept</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isKept()
* @see #getVirtualElement()
@@ -1107,6 +1224,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the reference '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getRepresentedElement <em>Represented Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference '<em>Represented Element</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#getRepresentedElement()
* @see #getVirtualElement()
@@ -1118,6 +1236,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isUseRepresented <em>Use Represented</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Use Represented</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement#isUseRepresented()
* @see #getVirtualElement()
@@ -1129,6 +1248,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier <em>Virtual Classifier</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Classifier</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier
* @generated
@@ -1139,6 +1259,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the container reference '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier#getMetamodel <em>Metamodel</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the container reference '<em>Metamodel</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier#getMetamodel()
* @see #getVirtualClassifier()
@@ -1150,6 +1271,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass <em>Virtual Metaclass</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Metaclass</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass
* @generated
@@ -1160,6 +1282,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isAbstract <em>Abstract</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Abstract</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isAbstract()
* @see #getVirtualMetaclass()
@@ -1171,6 +1294,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the reference list '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getAppliedStereotypes <em>Applied Stereotypes</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference list '<em>Applied Stereotypes</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getAppliedStereotypes()
* @see #getVirtualMetaclass()
@@ -1182,6 +1306,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getOperations <em>Operations</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Operations</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getOperations()
* @see #getVirtualMetaclass()
@@ -1193,6 +1318,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the reference list '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getParents <em>Parents</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference list '<em>Parents</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getParents()
* @see #getVirtualMetaclass()
@@ -1204,6 +1330,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getProperties <em>Properties</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Properties</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#getProperties()
* @see #getVirtualMetaclass()
@@ -1215,6 +1342,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isStereotypeInterface <em>Stereotype Interface</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Stereotype Interface</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass#isStereotypeInterface()
* @see #getVirtualMetaclass()
@@ -1226,6 +1354,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty <em>Virtual Property</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Property</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty
* @generated
@@ -1236,6 +1365,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the container reference '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty#getVirtualMetaclass <em>Virtual Metaclass</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the container reference '<em>Virtual Metaclass</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty#getVirtualMetaclass()
* @see #getVirtualProperty()
@@ -1247,6 +1377,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation <em>Virtual Operation</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Operation</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation
* @generated
@@ -1257,6 +1388,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation#getParameters <em>Parameters</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Parameters</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation#getParameters()
* @see #getVirtualOperation()
@@ -1268,6 +1400,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualParameter <em>Virtual Parameter</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Parameter</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualParameter
* @generated
@@ -1278,6 +1411,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualDatatype <em>Virtual Datatype</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Datatype</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualDatatype
* @generated
@@ -1288,6 +1422,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum <em>Virtual Enum</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Enum</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum
* @generated
@@ -1298,6 +1433,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum#getLiterals <em>Literals</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Literals</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum#getLiterals()
* @see #getVirtualEnum()
@@ -1309,6 +1445,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualLiteral <em>Virtual Literal</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Literal</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualLiteral
* @generated
@@ -1319,6 +1456,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement <em>Virtual Typed Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Virtual Typed Element</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement
* @generated
@@ -1329,6 +1467,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getLower <em>Lower</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Lower</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getLower()
* @see #getVirtualTypedElement()
@@ -1340,6 +1479,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getUpper <em>Upper</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Upper</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getUpper()
* @see #getVirtualTypedElement()
@@ -1351,6 +1491,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the meta object for the reference '{@link org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getType <em>Type</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference '<em>Type</em>'.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement#getType()
* @see #getVirtualTypedElement()
@@ -1362,6 +1503,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* Returns the factory that creates the instances of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the factory that creates the instances of the model.
* @generated
*/
@@ -1371,13 +1513,14 @@ public interface VirtualmetamodelPackage extends EPackage {
* <!-- begin-user-doc -->
* Defines literals for the meta objects that represent
* <ul>
- * <li>each class,</li>
- * <li>each feature of each class,</li>
- * <li>each operation of each class,</li>
- * <li>each enum,</li>
- * <li>and each data type</li>
+ * <li>each class,</li>
+ * <li>each feature of each class,</li>
+ * <li>each operation of each class,</li>
+ * <li>each enum,</li>
+ * <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
+ *
* @generated
*/
interface Literals {
@@ -1385,6 +1528,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl <em>Virtual Metamodel</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualMetamodel()
* @generated
@@ -1395,6 +1539,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Name</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_METAMODEL__NAME = eINSTANCE.getVirtualMetamodel_Name();
@@ -1403,6 +1548,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Ns Prefix</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_METAMODEL__NS_PREFIX = eINSTANCE.getVirtualMetamodel_NsPrefix();
@@ -1411,6 +1557,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Ns URI</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_METAMODEL__NS_URI = eINSTANCE.getVirtualMetamodel_NsURI();
@@ -1419,6 +1566,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Virtual Classifiers</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS = eINSTANCE.getVirtualMetamodel_VirtualClassifiers();
@@ -1427,6 +1575,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Facade</b></em>' container reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_METAMODEL__FACADE = eINSTANCE.getVirtualMetamodel_Facade();
@@ -1435,6 +1584,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl <em>Virtual Element</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualElement()
* @generated
@@ -1445,6 +1595,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Alias Name</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_ELEMENT__ALIAS_NAME = eINSTANCE.getVirtualElement_AliasName();
@@ -1453,6 +1604,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Kept</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_ELEMENT__KEPT = eINSTANCE.getVirtualElement_Kept();
@@ -1461,6 +1613,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Represented Element</b></em>' reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_ELEMENT__REPRESENTED_ELEMENT = eINSTANCE.getVirtualElement_RepresentedElement();
@@ -1469,6 +1622,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Use Represented</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_ELEMENT__USE_REPRESENTED = eINSTANCE.getVirtualElement_UseRepresented();
@@ -1477,6 +1631,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualClassifierImpl <em>Virtual Classifier</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualClassifierImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualClassifier()
* @generated
@@ -1487,6 +1642,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Metamodel</b></em>' container reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_CLASSIFIER__METAMODEL = eINSTANCE.getVirtualClassifier_Metamodel();
@@ -1495,6 +1651,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl <em>Virtual Metaclass</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualMetaclass()
* @generated
@@ -1505,6 +1662,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Abstract</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_METACLASS__ABSTRACT = eINSTANCE.getVirtualMetaclass_Abstract();
@@ -1513,6 +1671,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Applied Stereotypes</b></em>' reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_METACLASS__APPLIED_STEREOTYPES = eINSTANCE.getVirtualMetaclass_AppliedStereotypes();
@@ -1521,6 +1680,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Operations</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_METACLASS__OPERATIONS = eINSTANCE.getVirtualMetaclass_Operations();
@@ -1529,6 +1689,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Parents</b></em>' reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_METACLASS__PARENTS = eINSTANCE.getVirtualMetaclass_Parents();
@@ -1537,6 +1698,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Properties</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_METACLASS__PROPERTIES = eINSTANCE.getVirtualMetaclass_Properties();
@@ -1545,6 +1707,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Stereotype Interface</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_METACLASS__STEREOTYPE_INTERFACE = eINSTANCE.getVirtualMetaclass_StereotypeInterface();
@@ -1553,6 +1716,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualPropertyImpl <em>Virtual Property</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualPropertyImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualProperty()
* @generated
@@ -1563,6 +1727,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Virtual Metaclass</b></em>' container reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_PROPERTY__VIRTUAL_METACLASS = eINSTANCE.getVirtualProperty_VirtualMetaclass();
@@ -1571,6 +1736,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualOperationImpl <em>Virtual Operation</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualOperationImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualOperation()
* @generated
@@ -1581,6 +1747,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Parameters</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_OPERATION__PARAMETERS = eINSTANCE.getVirtualOperation_Parameters();
@@ -1589,6 +1756,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualParameterImpl <em>Virtual Parameter</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualParameterImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualParameter()
* @generated
@@ -1599,6 +1767,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualDatatypeImpl <em>Virtual Datatype</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualDatatypeImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualDatatype()
* @generated
@@ -1609,6 +1778,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualEnumImpl <em>Virtual Enum</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualEnumImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualEnum()
* @generated
@@ -1619,6 +1789,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Literals</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_ENUM__LITERALS = eINSTANCE.getVirtualEnum_Literals();
@@ -1627,6 +1798,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualLiteralImpl <em>Virtual Literal</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualLiteralImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualLiteral()
* @generated
@@ -1637,6 +1809,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl <em>Virtual Typed Element</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl
* @see org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualmetamodelPackageImpl#getVirtualTypedElement()
* @generated
@@ -1647,6 +1820,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Lower</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_TYPED_ELEMENT__LOWER = eINSTANCE.getVirtualTypedElement_Lower();
@@ -1655,6 +1829,7 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Upper</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute VIRTUAL_TYPED_ELEMENT__UPPER = eINSTANCE.getVirtualTypedElement_Upper();
@@ -1663,10 +1838,11 @@ public interface VirtualmetamodelPackage extends EPackage {
* The meta object literal for the '<em><b>Type</b></em>' reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference VIRTUAL_TYPED_ELEMENT__TYPE = eINSTANCE.getVirtualTypedElement_Type();
}
-} //VirtualmetamodelPackage
+} // VirtualmetamodelPackage
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualClassifierImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualClassifierImpl.java
index dbf1fba6541..6a4d6d5aaad 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualClassifierImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualClassifierImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -34,7 +34,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualClassifierImpl#getMetamodel <em>Metamodel</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualClassifierImpl#getMetamodel <em>Metamodel</em>}</li>
* </ul>
* </p>
*
@@ -44,6 +44,7 @@ public abstract class VirtualClassifierImpl extends VirtualElementImpl implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualClassifierImpl() {
@@ -53,6 +54,7 @@ public abstract class VirtualClassifierImpl extends VirtualElementImpl implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -63,56 +65,71 @@ public abstract class VirtualClassifierImpl extends VirtualElementImpl implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualMetamodel getMetamodel() {
- if (eContainerFeatureID() != VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL) return null;
- return (VirtualMetamodel)eInternalContainer();
+ if (eContainerFeatureID() != VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL) {
+ return null;
+ }
+ return (VirtualMetamodel) eInternalContainer();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public NotificationChain basicSetMetamodel(VirtualMetamodel newMetamodel, NotificationChain msgs) {
- msgs = eBasicSetContainer((InternalEObject)newMetamodel, VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL, msgs);
+ msgs = eBasicSetContainer((InternalEObject) newMetamodel, VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL, msgs);
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setMetamodel(VirtualMetamodel newMetamodel) {
if (newMetamodel != eInternalContainer() || (eContainerFeatureID() != VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL && newMetamodel != null)) {
- if (EcoreUtil.isAncestor(this, newMetamodel))
+ if (EcoreUtil.isAncestor(this, newMetamodel)) {
throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
+ }
NotificationChain msgs = null;
- if (eInternalContainer() != null)
+ if (eInternalContainer() != null) {
msgs = eBasicRemoveFromContainer(msgs);
- if (newMetamodel != null)
- msgs = ((InternalEObject)newMetamodel).eInverseAdd(this, VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS, VirtualMetamodel.class, msgs);
+ }
+ if (newMetamodel != null) {
+ msgs = ((InternalEObject) newMetamodel).eInverseAdd(this, VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS, VirtualMetamodel.class, msgs);
+ }
msgs = basicSetMetamodel(newMetamodel, msgs);
- if (msgs != null) msgs.dispatch();
+ if (msgs != null) {
+ msgs.dispatch();
+ }
}
- else if (eNotificationRequired())
+ else if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL, newMetamodel, newMetamodel));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
- if (eInternalContainer() != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return basicSetMetamodel((VirtualMetamodel)otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
+ if (eInternalContainer() != null) {
+ msgs = eBasicRemoveFromContainer(msgs);
+ }
+ return basicSetMetamodel((VirtualMetamodel) otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
}
@@ -120,13 +137,14 @@ public abstract class VirtualClassifierImpl extends VirtualElementImpl implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
- return basicSetMetamodel(null, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
+ return basicSetMetamodel(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -134,13 +152,14 @@ public abstract class VirtualClassifierImpl extends VirtualElementImpl implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) {
switch (eContainerFeatureID()) {
- case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
- return eInternalContainer().eInverseRemove(this, VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS, VirtualMetamodel.class, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
+ return eInternalContainer().eInverseRemove(this, VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS, VirtualMetamodel.class, msgs);
}
return super.eBasicRemoveFromContainerFeature(msgs);
}
@@ -148,13 +167,14 @@ public abstract class VirtualClassifierImpl extends VirtualElementImpl implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
- return getMetamodel();
+ case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
+ return getMetamodel();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -162,14 +182,15 @@ public abstract class VirtualClassifierImpl extends VirtualElementImpl implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
- setMetamodel((VirtualMetamodel)newValue);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
+ setMetamodel((VirtualMetamodel) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -177,14 +198,15 @@ public abstract class VirtualClassifierImpl extends VirtualElementImpl implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
- setMetamodel((VirtualMetamodel)null);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
+ setMetamodel((VirtualMetamodel) null);
+ return;
}
super.eUnset(featureID);
}
@@ -192,15 +214,16 @@ public abstract class VirtualClassifierImpl extends VirtualElementImpl implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
- return getMetamodel() != null;
+ case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL:
+ return getMetamodel() != null;
}
return super.eIsSet(featureID);
}
-} //VirtualClassifierImpl
+} // VirtualClassifierImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualDatatypeImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualDatatypeImpl.java
index 5fbe8c5b0a0..d815c0aca4b 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualDatatypeImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualDatatypeImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -31,6 +31,7 @@ public class VirtualDatatypeImpl extends VirtualClassifierImpl implements Virtua
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualDatatypeImpl() {
@@ -40,6 +41,7 @@ public class VirtualDatatypeImpl extends VirtualClassifierImpl implements Virtua
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -47,4 +49,4 @@ public class VirtualDatatypeImpl extends VirtualClassifierImpl implements Virtua
return VirtualmetamodelPackage.Literals.VIRTUAL_DATATYPE;
}
-} //VirtualDatatypeImpl
+} // VirtualDatatypeImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualElementImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualElementImpl.java
index 5b4f901d543..9a7fd3d790f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualElementImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualElementImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -32,10 +32,10 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl#getAliasName <em>Alias Name</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl#isKept <em>Kept</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl#getRepresentedElement <em>Represented Element</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl#isUseRepresented <em>Use Represented</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl#getAliasName <em>Alias Name</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl#isKept <em>Kept</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl#getRepresentedElement <em>Represented Element</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualElementImpl#isUseRepresented <em>Use Represented</em>}</li>
* </ul>
* </p>
*
@@ -46,6 +46,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
* The default value of the '{@link #getAliasName() <em>Alias Name</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getAliasName()
* @generated
* @ordered
@@ -56,6 +57,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
* The cached value of the '{@link #getAliasName() <em>Alias Name</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getAliasName()
* @generated
* @ordered
@@ -66,6 +68,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
* The default value of the '{@link #isKept() <em>Kept</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isKept()
* @generated
* @ordered
@@ -76,6 +79,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
* The cached value of the '{@link #isKept() <em>Kept</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isKept()
* @generated
* @ordered
@@ -86,6 +90,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
* The cached value of the '{@link #getRepresentedElement() <em>Represented Element</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getRepresentedElement()
* @generated
* @ordered
@@ -96,6 +101,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
* The default value of the '{@link #isUseRepresented() <em>Use Represented</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isUseRepresented()
* @generated
* @ordered
@@ -106,6 +112,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
* The cached value of the '{@link #isUseRepresented() <em>Use Represented</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isUseRepresented()
* @generated
* @ordered
@@ -115,6 +122,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualElementImpl() {
@@ -124,6 +132,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -134,8 +143,10 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public String getAliasName() {
return aliasName;
}
@@ -143,20 +154,25 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setAliasName(String newAliasName) {
String oldAliasName = aliasName;
aliasName = newAliasName;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME, oldAliasName, aliasName));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public boolean isKept() {
return kept;
}
@@ -164,27 +180,33 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setKept(boolean newKept) {
boolean oldKept = kept;
kept = newKept;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT, oldKept, kept));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EObject getRepresentedElement() {
if (representedElement != null && representedElement.eIsProxy()) {
- InternalEObject oldRepresentedElement = (InternalEObject)representedElement;
+ InternalEObject oldRepresentedElement = (InternalEObject) representedElement;
representedElement = eResolveProxy(oldRepresentedElement);
if (representedElement != oldRepresentedElement) {
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.RESOLVE, VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT, oldRepresentedElement, representedElement));
+ }
}
}
return representedElement;
@@ -193,6 +215,7 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public EObject basicGetRepresentedElement() {
@@ -202,20 +225,25 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setRepresentedElement(EObject newRepresentedElement) {
EObject oldRepresentedElement = representedElement;
representedElement = newRepresentedElement;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT, oldRepresentedElement, representedElement));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public boolean isUseRepresented() {
return useRepresented;
}
@@ -223,32 +251,38 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setUseRepresented(boolean newUseRepresented) {
boolean oldUseRepresented = useRepresented;
useRepresented = newUseRepresented;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED, oldUseRepresented, useRepresented));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
- return getAliasName();
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
- return isKept();
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT:
- if (resolve) return getRepresentedElement();
- return basicGetRepresentedElement();
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
- return isUseRepresented();
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
+ return getAliasName();
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
+ return isKept();
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT:
+ if (resolve) {
+ return getRepresentedElement();
+ }
+ return basicGetRepresentedElement();
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
+ return isUseRepresented();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -256,23 +290,24 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
- setAliasName((String)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
- setKept((Boolean)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT:
- setRepresentedElement((EObject)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
- setUseRepresented((Boolean)newValue);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
+ setAliasName((String) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
+ setKept((Boolean) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT:
+ setRepresentedElement((EObject) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
+ setUseRepresented((Boolean) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -280,23 +315,24 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
- setAliasName(ALIAS_NAME_EDEFAULT);
- return;
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
- setKept(KEPT_EDEFAULT);
- return;
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT:
- setRepresentedElement((EObject)null);
- return;
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
- setUseRepresented(USE_REPRESENTED_EDEFAULT);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
+ setAliasName(ALIAS_NAME_EDEFAULT);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
+ setKept(KEPT_EDEFAULT);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT:
+ setRepresentedElement((EObject) null);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
+ setUseRepresented(USE_REPRESENTED_EDEFAULT);
+ return;
}
super.eUnset(featureID);
}
@@ -304,19 +340,20 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
- return ALIAS_NAME_EDEFAULT == null ? aliasName != null : !ALIAS_NAME_EDEFAULT.equals(aliasName);
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
- return kept != KEPT_EDEFAULT;
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT:
- return representedElement != null;
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
- return useRepresented != USE_REPRESENTED_EDEFAULT;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__ALIAS_NAME:
+ return ALIAS_NAME_EDEFAULT == null ? aliasName != null : !ALIAS_NAME_EDEFAULT.equals(aliasName);
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__KEPT:
+ return kept != KEPT_EDEFAULT;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__REPRESENTED_ELEMENT:
+ return representedElement != null;
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT__USE_REPRESENTED:
+ return useRepresented != USE_REPRESENTED_EDEFAULT;
}
return super.eIsSet(featureID);
}
@@ -324,11 +361,14 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
/**
* <!-- 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(" (aliasName: ");
@@ -341,4 +381,4 @@ public abstract class VirtualElementImpl extends MinimalEObjectImpl.Container im
return result.toString();
}
-} //VirtualElementImpl
+} // VirtualElementImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualEnumImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualEnumImpl.java
index a86508fc03d..4be5ec1678a 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualEnumImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualEnumImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -36,7 +36,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualEnumImpl#getLiterals <em>Literals</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualEnumImpl#getLiterals <em>Literals</em>}</li>
* </ul>
* </p>
*
@@ -47,6 +47,7 @@ public class VirtualEnumImpl extends VirtualClassifierImpl implements VirtualEnu
* The cached value of the '{@link #getLiterals() <em>Literals</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getLiterals()
* @generated
* @ordered
@@ -56,6 +57,7 @@ public class VirtualEnumImpl extends VirtualClassifierImpl implements VirtualEnu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualEnumImpl() {
@@ -65,6 +67,7 @@ public class VirtualEnumImpl extends VirtualClassifierImpl implements VirtualEnu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -75,8 +78,10 @@ public class VirtualEnumImpl extends VirtualClassifierImpl implements VirtualEnu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<VirtualLiteral> getLiterals() {
if (literals == null) {
literals = new EObjectContainmentEList<VirtualLiteral>(VirtualLiteral.class, this, VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS);
@@ -87,13 +92,14 @@ public class VirtualEnumImpl extends VirtualClassifierImpl implements VirtualEnu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
- return ((InternalEList<?>)getLiterals()).basicRemove(otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
+ return ((InternalEList<?>) getLiterals()).basicRemove(otherEnd, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -101,13 +107,14 @@ public class VirtualEnumImpl extends VirtualClassifierImpl implements VirtualEnu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
- return getLiterals();
+ case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
+ return getLiterals();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -115,16 +122,17 @@ public class VirtualEnumImpl extends VirtualClassifierImpl implements VirtualEnu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
- getLiterals().clear();
- getLiterals().addAll((Collection<? extends VirtualLiteral>)newValue);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
+ getLiterals().clear();
+ getLiterals().addAll((Collection<? extends VirtualLiteral>) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -132,14 +140,15 @@ public class VirtualEnumImpl extends VirtualClassifierImpl implements VirtualEnu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
- getLiterals().clear();
- return;
+ case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
+ getLiterals().clear();
+ return;
}
super.eUnset(featureID);
}
@@ -147,15 +156,16 @@ public class VirtualEnumImpl extends VirtualClassifierImpl implements VirtualEnu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
- return literals != null && !literals.isEmpty();
+ case VirtualmetamodelPackage.VIRTUAL_ENUM__LITERALS:
+ return literals != null && !literals.isEmpty();
}
return super.eIsSet(featureID);
}
-} //VirtualEnumImpl
+} // VirtualEnumImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualLiteralImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualLiteralImpl.java
index 64d6ba11a07..02d4c06ad81 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualLiteralImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualLiteralImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -31,6 +31,7 @@ public class VirtualLiteralImpl extends VirtualElementImpl implements VirtualLit
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualLiteralImpl() {
@@ -40,6 +41,7 @@ public class VirtualLiteralImpl extends VirtualElementImpl implements VirtualLit
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -47,4 +49,4 @@ public class VirtualLiteralImpl extends VirtualElementImpl implements VirtualLit
return VirtualmetamodelPackage.Literals.VIRTUAL_LITERAL;
}
-} //VirtualLiteralImpl
+} // VirtualLiteralImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetaclassImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetaclassImpl.java
index 0c335a03307..3183b6fdede 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetaclassImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetaclassImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -44,12 +44,12 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#isAbstract <em>Abstract</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#getAppliedStereotypes <em>Applied Stereotypes</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#getOperations <em>Operations</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#getParents <em>Parents</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#getProperties <em>Properties</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#isStereotypeInterface <em>Stereotype Interface</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#isAbstract <em>Abstract</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#getAppliedStereotypes <em>Applied Stereotypes</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#getOperations <em>Operations</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#getParents <em>Parents</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#getProperties <em>Properties</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetaclassImpl#isStereotypeInterface <em>Stereotype Interface</em>}</li>
* </ul>
* </p>
*
@@ -60,6 +60,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
* The default value of the '{@link #isAbstract() <em>Abstract</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isAbstract()
* @generated
* @ordered
@@ -70,6 +71,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
* The cached value of the '{@link #isAbstract() <em>Abstract</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isAbstract()
* @generated
* @ordered
@@ -80,6 +82,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
* The cached value of the '{@link #getAppliedStereotypes() <em>Applied Stereotypes</em>}' reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getAppliedStereotypes()
* @generated
* @ordered
@@ -90,6 +93,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
* The cached value of the '{@link #getOperations() <em>Operations</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getOperations()
* @generated
* @ordered
@@ -100,6 +104,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
* The cached value of the '{@link #getParents() <em>Parents</em>}' reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getParents()
* @generated
* @ordered
@@ -110,6 +115,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
* The cached value of the '{@link #getProperties() <em>Properties</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getProperties()
* @generated
* @ordered
@@ -120,6 +126,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
* The default value of the '{@link #isStereotypeInterface() <em>Stereotype Interface</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isStereotypeInterface()
* @generated
* @ordered
@@ -130,6 +137,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
* The cached value of the '{@link #isStereotypeInterface() <em>Stereotype Interface</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #isStereotypeInterface()
* @generated
* @ordered
@@ -139,6 +147,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualMetaclassImpl() {
@@ -148,6 +157,7 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -158,8 +168,10 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public boolean isAbstract() {
return abstract_;
}
@@ -167,20 +179,25 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setAbstract(boolean newAbstract) {
boolean oldAbstract = abstract_;
abstract_ = newAbstract;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT, oldAbstract, abstract_));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<BaseMetaclass> getAppliedStereotypes() {
if (appliedStereotypes == null) {
appliedStereotypes = new EObjectResolvingEList<BaseMetaclass>(BaseMetaclass.class, this, VirtualmetamodelPackage.VIRTUAL_METACLASS__APPLIED_STEREOTYPES);
@@ -191,8 +208,10 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<VirtualOperation> getOperations() {
if (operations == null) {
operations = new EObjectContainmentEList<VirtualOperation>(VirtualOperation.class, this, VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS);
@@ -203,8 +222,10 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<VirtualMetaclass> getParents() {
if (parents == null) {
parents = new EObjectResolvingEList<VirtualMetaclass>(VirtualMetaclass.class, this, VirtualmetamodelPackage.VIRTUAL_METACLASS__PARENTS);
@@ -215,8 +236,10 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<VirtualProperty> getProperties() {
if (properties == null) {
properties = new EObjectContainmentWithInverseEList<VirtualProperty>(VirtualProperty.class, this, VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES, VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS);
@@ -227,8 +250,10 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public boolean isStereotypeInterface() {
return stereotypeInterface;
}
@@ -236,26 +261,30 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setStereotypeInterface(boolean newStereotypeInterface) {
boolean oldStereotypeInterface = stereotypeInterface;
stereotypeInterface = newStereotypeInterface;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE, oldStereotypeInterface, stereotypeInterface));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
- return ((InternalEList<InternalEObject>)(InternalEList<?>)getProperties()).basicAdd(otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
+ return ((InternalEList<InternalEObject>) (InternalEList<?>) getProperties()).basicAdd(otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
}
@@ -263,15 +292,16 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
- return ((InternalEList<?>)getOperations()).basicRemove(otherEnd, msgs);
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
- return ((InternalEList<?>)getProperties()).basicRemove(otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
+ return ((InternalEList<?>) getOperations()).basicRemove(otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
+ return ((InternalEList<?>) getProperties()).basicRemove(otherEnd, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -279,23 +309,24 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
- return isAbstract();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__APPLIED_STEREOTYPES:
- return getAppliedStereotypes();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
- return getOperations();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PARENTS:
- return getParents();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
- return getProperties();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
- return isStereotypeInterface();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
+ return isAbstract();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__APPLIED_STEREOTYPES:
+ return getAppliedStereotypes();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
+ return getOperations();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PARENTS:
+ return getParents();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
+ return getProperties();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
+ return isStereotypeInterface();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -303,34 +334,35 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
- setAbstract((Boolean)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__APPLIED_STEREOTYPES:
- getAppliedStereotypes().clear();
- getAppliedStereotypes().addAll((Collection<? extends BaseMetaclass>)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
- getOperations().clear();
- getOperations().addAll((Collection<? extends VirtualOperation>)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PARENTS:
- getParents().clear();
- getParents().addAll((Collection<? extends VirtualMetaclass>)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
- getProperties().clear();
- getProperties().addAll((Collection<? extends VirtualProperty>)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
- setStereotypeInterface((Boolean)newValue);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
+ setAbstract((Boolean) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__APPLIED_STEREOTYPES:
+ getAppliedStereotypes().clear();
+ getAppliedStereotypes().addAll((Collection<? extends BaseMetaclass>) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
+ getOperations().clear();
+ getOperations().addAll((Collection<? extends VirtualOperation>) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PARENTS:
+ getParents().clear();
+ getParents().addAll((Collection<? extends VirtualMetaclass>) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
+ getProperties().clear();
+ getProperties().addAll((Collection<? extends VirtualProperty>) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
+ setStereotypeInterface((Boolean) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -338,29 +370,30 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
- setAbstract(ABSTRACT_EDEFAULT);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__APPLIED_STEREOTYPES:
- getAppliedStereotypes().clear();
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
- getOperations().clear();
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PARENTS:
- getParents().clear();
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
- getProperties().clear();
- return;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
- setStereotypeInterface(STEREOTYPE_INTERFACE_EDEFAULT);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
+ setAbstract(ABSTRACT_EDEFAULT);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__APPLIED_STEREOTYPES:
+ getAppliedStereotypes().clear();
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
+ getOperations().clear();
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PARENTS:
+ getParents().clear();
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
+ getProperties().clear();
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
+ setStereotypeInterface(STEREOTYPE_INTERFACE_EDEFAULT);
+ return;
}
super.eUnset(featureID);
}
@@ -368,23 +401,24 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
- return abstract_ != ABSTRACT_EDEFAULT;
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__APPLIED_STEREOTYPES:
- return appliedStereotypes != null && !appliedStereotypes.isEmpty();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
- return operations != null && !operations.isEmpty();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PARENTS:
- return parents != null && !parents.isEmpty();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
- return properties != null && !properties.isEmpty();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
- return stereotypeInterface != STEREOTYPE_INTERFACE_EDEFAULT;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__ABSTRACT:
+ return abstract_ != ABSTRACT_EDEFAULT;
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__APPLIED_STEREOTYPES:
+ return appliedStereotypes != null && !appliedStereotypes.isEmpty();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__OPERATIONS:
+ return operations != null && !operations.isEmpty();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PARENTS:
+ return parents != null && !parents.isEmpty();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES:
+ return properties != null && !properties.isEmpty();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS__STEREOTYPE_INTERFACE:
+ return stereotypeInterface != STEREOTYPE_INTERFACE_EDEFAULT;
}
return super.eIsSet(featureID);
}
@@ -392,11 +426,14 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
/**
* <!-- 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(" (abstract: ");
@@ -407,4 +444,4 @@ public class VirtualMetaclassImpl extends VirtualClassifierImpl implements Virtu
return result.toString();
}
-} //VirtualMetaclassImpl
+} // VirtualMetaclassImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetamodelImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetamodelImpl.java
index ba502115ecf..4b271c20da1 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetamodelImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualMetamodelImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -44,11 +44,11 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getName <em>Name</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getNsPrefix <em>Ns Prefix</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getNsURI <em>Ns URI</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getVirtualClassifiers <em>Virtual Classifiers</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getFacade <em>Facade</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getName <em>Name</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getNsPrefix <em>Ns Prefix</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getNsURI <em>Ns URI</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getVirtualClassifiers <em>Virtual Classifiers</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualMetamodelImpl#getFacade <em>Facade</em>}</li>
* </ul>
* </p>
*
@@ -59,6 +59,7 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
* The default value of the '{@link #getName() <em>Name</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getName()
* @generated
* @ordered
@@ -69,6 +70,7 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
* The cached value of the '{@link #getName() <em>Name</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getName()
* @generated
* @ordered
@@ -79,6 +81,7 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
* The default value of the '{@link #getNsPrefix() <em>Ns Prefix</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getNsPrefix()
* @generated
* @ordered
@@ -89,6 +92,7 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
* The cached value of the '{@link #getNsPrefix() <em>Ns Prefix</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getNsPrefix()
* @generated
* @ordered
@@ -99,6 +103,7 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
* The default value of the '{@link #getNsURI() <em>Ns URI</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getNsURI()
* @generated
* @ordered
@@ -109,6 +114,7 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
* The cached value of the '{@link #getNsURI() <em>Ns URI</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getNsURI()
* @generated
* @ordered
@@ -119,6 +125,7 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
* The cached value of the '{@link #getVirtualClassifiers() <em>Virtual Classifiers</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getVirtualClassifiers()
* @generated
* @ordered
@@ -128,6 +135,7 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualMetamodelImpl() {
@@ -137,6 +145,7 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -147,8 +156,10 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public String getName() {
return name;
}
@@ -156,20 +167,25 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setName(String newName) {
String oldName = name;
name = newName;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME, oldName, name));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public String getNsPrefix() {
return nsPrefix;
}
@@ -177,20 +193,25 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setNsPrefix(String newNsPrefix) {
String oldNsPrefix = nsPrefix;
nsPrefix = newNsPrefix;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX, oldNsPrefix, nsPrefix));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public String getNsURI() {
return nsURI;
}
@@ -198,20 +219,25 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setNsURI(String newNsURI) {
String oldNsURI = nsURI;
nsURI = newNsURI;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI, oldNsURI, nsURI));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<VirtualClassifier> getVirtualClassifiers() {
if (virtualClassifiers == null) {
virtualClassifiers = new EObjectContainmentWithInverseEList<VirtualClassifier>(VirtualClassifier.class, this, VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS, VirtualmetamodelPackage.VIRTUAL_CLASSIFIER__METAMODEL);
@@ -222,59 +248,74 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Facade getFacade() {
- if (eContainerFeatureID() != VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE) return null;
- return (Facade)eInternalContainer();
+ if (eContainerFeatureID() != VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE) {
+ return null;
+ }
+ return (Facade) eInternalContainer();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public NotificationChain basicSetFacade(Facade newFacade, NotificationChain msgs) {
- msgs = eBasicSetContainer((InternalEObject)newFacade, VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE, msgs);
+ msgs = eBasicSetContainer((InternalEObject) newFacade, VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE, msgs);
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setFacade(Facade newFacade) {
if (newFacade != eInternalContainer() || (eContainerFeatureID() != VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE && newFacade != null)) {
- if (EcoreUtil.isAncestor(this, newFacade))
+ if (EcoreUtil.isAncestor(this, newFacade)) {
throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
+ }
NotificationChain msgs = null;
- if (eInternalContainer() != null)
+ if (eInternalContainer() != null) {
msgs = eBasicRemoveFromContainer(msgs);
- if (newFacade != null)
- msgs = ((InternalEObject)newFacade).eInverseAdd(this, FacadePackage.FACADE__VIRTUALMETAMODEL, Facade.class, msgs);
+ }
+ if (newFacade != null) {
+ msgs = ((InternalEObject) newFacade).eInverseAdd(this, FacadePackage.FACADE__VIRTUALMETAMODEL, Facade.class, msgs);
+ }
msgs = basicSetFacade(newFacade, msgs);
- if (msgs != null) msgs.dispatch();
+ if (msgs != null) {
+ msgs.dispatch();
+ }
}
- else if (eNotificationRequired())
+ else if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE, newFacade, newFacade));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
- return ((InternalEList<InternalEObject>)(InternalEList<?>)getVirtualClassifiers()).basicAdd(otherEnd, msgs);
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
- if (eInternalContainer() != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return basicSetFacade((Facade)otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
+ return ((InternalEList<InternalEObject>) (InternalEList<?>) getVirtualClassifiers()).basicAdd(otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
+ if (eInternalContainer() != null) {
+ msgs = eBasicRemoveFromContainer(msgs);
+ }
+ return basicSetFacade((Facade) otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
}
@@ -282,15 +323,16 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
- return ((InternalEList<?>)getVirtualClassifiers()).basicRemove(otherEnd, msgs);
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
- return basicSetFacade(null, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
+ return ((InternalEList<?>) getVirtualClassifiers()).basicRemove(otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
+ return basicSetFacade(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -298,13 +340,14 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) {
switch (eContainerFeatureID()) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
- return eInternalContainer().eInverseRemove(this, FacadePackage.FACADE__VIRTUALMETAMODEL, Facade.class, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
+ return eInternalContainer().eInverseRemove(this, FacadePackage.FACADE__VIRTUALMETAMODEL, Facade.class, msgs);
}
return super.eBasicRemoveFromContainerFeature(msgs);
}
@@ -312,21 +355,22 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
- return getName();
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
- return getNsPrefix();
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
- return getNsURI();
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
- return getVirtualClassifiers();
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
- return getFacade();
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
+ return getName();
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
+ return getNsPrefix();
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
+ return getNsURI();
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
+ return getVirtualClassifiers();
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
+ return getFacade();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -334,28 +378,29 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
- setName((String)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
- setNsPrefix((String)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
- setNsURI((String)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
- getVirtualClassifiers().clear();
- getVirtualClassifiers().addAll((Collection<? extends VirtualClassifier>)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
- setFacade((Facade)newValue);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
+ setName((String) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
+ setNsPrefix((String) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
+ setNsURI((String) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
+ getVirtualClassifiers().clear();
+ getVirtualClassifiers().addAll((Collection<? extends VirtualClassifier>) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
+ setFacade((Facade) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -363,26 +408,27 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
- setName(NAME_EDEFAULT);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
- setNsPrefix(NS_PREFIX_EDEFAULT);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
- setNsURI(NS_URI_EDEFAULT);
- return;
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
- getVirtualClassifiers().clear();
- return;
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
- setFacade((Facade)null);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
+ setName(NAME_EDEFAULT);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
+ setNsPrefix(NS_PREFIX_EDEFAULT);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
+ setNsURI(NS_URI_EDEFAULT);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
+ getVirtualClassifiers().clear();
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
+ setFacade((Facade) null);
+ return;
}
super.eUnset(featureID);
}
@@ -390,21 +436,22 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
- return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name);
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
- return NS_PREFIX_EDEFAULT == null ? nsPrefix != null : !NS_PREFIX_EDEFAULT.equals(nsPrefix);
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
- return NS_URI_EDEFAULT == null ? nsURI != null : !NS_URI_EDEFAULT.equals(nsURI);
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
- return virtualClassifiers != null && !virtualClassifiers.isEmpty();
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
- return getFacade() != null;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NAME:
+ return NAME_EDEFAULT == null ? name != null : !NAME_EDEFAULT.equals(name);
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_PREFIX:
+ return NS_PREFIX_EDEFAULT == null ? nsPrefix != null : !NS_PREFIX_EDEFAULT.equals(nsPrefix);
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__NS_URI:
+ return NS_URI_EDEFAULT == null ? nsURI != null : !NS_URI_EDEFAULT.equals(nsURI);
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__VIRTUAL_CLASSIFIERS:
+ return virtualClassifiers != null && !virtualClassifiers.isEmpty();
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL__FACADE:
+ return getFacade() != null;
}
return super.eIsSet(featureID);
}
@@ -412,11 +459,14 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
/**
* <!-- 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(" (name: ");
@@ -429,4 +479,4 @@ public class VirtualMetamodelImpl extends MinimalEObjectImpl.Container implement
return result.toString();
}
-} //VirtualMetamodelImpl
+} // VirtualMetamodelImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualOperationImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualOperationImpl.java
index 1ea2414ac9e..440b49acc79 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualOperationImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualOperationImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -36,7 +36,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualOperationImpl#getParameters <em>Parameters</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualOperationImpl#getParameters <em>Parameters</em>}</li>
* </ul>
* </p>
*
@@ -47,6 +47,7 @@ public class VirtualOperationImpl extends VirtualTypedElementImpl implements Vir
* The cached value of the '{@link #getParameters() <em>Parameters</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getParameters()
* @generated
* @ordered
@@ -56,6 +57,7 @@ public class VirtualOperationImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualOperationImpl() {
@@ -65,6 +67,7 @@ public class VirtualOperationImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -75,8 +78,10 @@ public class VirtualOperationImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<VirtualParameter> getParameters() {
if (parameters == null) {
parameters = new EObjectContainmentEList<VirtualParameter>(VirtualParameter.class, this, VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS);
@@ -87,13 +92,14 @@ public class VirtualOperationImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
- return ((InternalEList<?>)getParameters()).basicRemove(otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
+ return ((InternalEList<?>) getParameters()).basicRemove(otherEnd, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -101,13 +107,14 @@ public class VirtualOperationImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
- return getParameters();
+ case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
+ return getParameters();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -115,16 +122,17 @@ public class VirtualOperationImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
- getParameters().clear();
- getParameters().addAll((Collection<? extends VirtualParameter>)newValue);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
+ getParameters().clear();
+ getParameters().addAll((Collection<? extends VirtualParameter>) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -132,14 +140,15 @@ public class VirtualOperationImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
- getParameters().clear();
- return;
+ case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
+ getParameters().clear();
+ return;
}
super.eUnset(featureID);
}
@@ -147,15 +156,16 @@ public class VirtualOperationImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
- return parameters != null && !parameters.isEmpty();
+ case VirtualmetamodelPackage.VIRTUAL_OPERATION__PARAMETERS:
+ return parameters != null && !parameters.isEmpty();
}
return super.eIsSet(featureID);
}
-} //VirtualOperationImpl
+} // VirtualOperationImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualParameterImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualParameterImpl.java
index 727b3b36d57..e162dae443e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualParameterImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualParameterImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -31,6 +31,7 @@ public class VirtualParameterImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualParameterImpl() {
@@ -40,6 +41,7 @@ public class VirtualParameterImpl extends VirtualTypedElementImpl implements Vir
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -47,4 +49,4 @@ public class VirtualParameterImpl extends VirtualTypedElementImpl implements Vir
return VirtualmetamodelPackage.Literals.VIRTUAL_PARAMETER;
}
-} //VirtualParameterImpl
+} // VirtualParameterImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualPropertyImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualPropertyImpl.java
index fa9e3835ea5..c792a6121b1 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualPropertyImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualPropertyImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -34,7 +34,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualPropertyImpl#getVirtualMetaclass <em>Virtual Metaclass</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualPropertyImpl#getVirtualMetaclass <em>Virtual Metaclass</em>}</li>
* </ul>
* </p>
*
@@ -44,6 +44,7 @@ public class VirtualPropertyImpl extends VirtualTypedElementImpl implements Virt
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualPropertyImpl() {
@@ -53,6 +54,7 @@ public class VirtualPropertyImpl extends VirtualTypedElementImpl implements Virt
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -63,56 +65,71 @@ public class VirtualPropertyImpl extends VirtualTypedElementImpl implements Virt
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualMetaclass getVirtualMetaclass() {
- if (eContainerFeatureID() != VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS) return null;
- return (VirtualMetaclass)eInternalContainer();
+ if (eContainerFeatureID() != VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS) {
+ return null;
+ }
+ return (VirtualMetaclass) eInternalContainer();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public NotificationChain basicSetVirtualMetaclass(VirtualMetaclass newVirtualMetaclass, NotificationChain msgs) {
- msgs = eBasicSetContainer((InternalEObject)newVirtualMetaclass, VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS, msgs);
+ msgs = eBasicSetContainer((InternalEObject) newVirtualMetaclass, VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS, msgs);
return msgs;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setVirtualMetaclass(VirtualMetaclass newVirtualMetaclass) {
if (newVirtualMetaclass != eInternalContainer() || (eContainerFeatureID() != VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS && newVirtualMetaclass != null)) {
- if (EcoreUtil.isAncestor(this, newVirtualMetaclass))
+ if (EcoreUtil.isAncestor(this, newVirtualMetaclass)) {
throw new IllegalArgumentException("Recursive containment not allowed for " + toString());
+ }
NotificationChain msgs = null;
- if (eInternalContainer() != null)
+ if (eInternalContainer() != null) {
msgs = eBasicRemoveFromContainer(msgs);
- if (newVirtualMetaclass != null)
- msgs = ((InternalEObject)newVirtualMetaclass).eInverseAdd(this, VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES, VirtualMetaclass.class, msgs);
+ }
+ if (newVirtualMetaclass != null) {
+ msgs = ((InternalEObject) newVirtualMetaclass).eInverseAdd(this, VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES, VirtualMetaclass.class, msgs);
+ }
msgs = basicSetVirtualMetaclass(newVirtualMetaclass, msgs);
- if (msgs != null) msgs.dispatch();
+ if (msgs != null) {
+ msgs.dispatch();
+ }
}
- else if (eNotificationRequired())
+ else if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS, newVirtualMetaclass, newVirtualMetaclass));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseAdd(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
- if (eInternalContainer() != null)
- msgs = eBasicRemoveFromContainer(msgs);
- return basicSetVirtualMetaclass((VirtualMetaclass)otherEnd, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
+ if (eInternalContainer() != null) {
+ msgs = eBasicRemoveFromContainer(msgs);
+ }
+ return basicSetVirtualMetaclass((VirtualMetaclass) otherEnd, msgs);
}
return super.eInverseAdd(otherEnd, featureID, msgs);
}
@@ -120,13 +137,14 @@ public class VirtualPropertyImpl extends VirtualTypedElementImpl implements Virt
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
- return basicSetVirtualMetaclass(null, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
+ return basicSetVirtualMetaclass(null, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -134,13 +152,14 @@ public class VirtualPropertyImpl extends VirtualTypedElementImpl implements Virt
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eBasicRemoveFromContainerFeature(NotificationChain msgs) {
switch (eContainerFeatureID()) {
- case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
- return eInternalContainer().eInverseRemove(this, VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES, VirtualMetaclass.class, msgs);
+ case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
+ return eInternalContainer().eInverseRemove(this, VirtualmetamodelPackage.VIRTUAL_METACLASS__PROPERTIES, VirtualMetaclass.class, msgs);
}
return super.eBasicRemoveFromContainerFeature(msgs);
}
@@ -148,13 +167,14 @@ public class VirtualPropertyImpl extends VirtualTypedElementImpl implements Virt
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
- return getVirtualMetaclass();
+ case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
+ return getVirtualMetaclass();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -162,14 +182,15 @@ public class VirtualPropertyImpl extends VirtualTypedElementImpl implements Virt
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
- setVirtualMetaclass((VirtualMetaclass)newValue);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
+ setVirtualMetaclass((VirtualMetaclass) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -177,14 +198,15 @@ public class VirtualPropertyImpl extends VirtualTypedElementImpl implements Virt
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
- setVirtualMetaclass((VirtualMetaclass)null);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
+ setVirtualMetaclass((VirtualMetaclass) null);
+ return;
}
super.eUnset(featureID);
}
@@ -192,15 +214,16 @@ public class VirtualPropertyImpl extends VirtualTypedElementImpl implements Virt
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
- return getVirtualMetaclass() != null;
+ case VirtualmetamodelPackage.VIRTUAL_PROPERTY__VIRTUAL_METACLASS:
+ return getVirtualMetaclass() != null;
}
return super.eIsSet(featureID);
}
-} //VirtualPropertyImpl
+} // VirtualPropertyImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualTypedElementImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualTypedElementImpl.java
index 22e7c04a874..47b061e2153 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualTypedElementImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualTypedElementImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -31,9 +31,9 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl#getLower <em>Lower</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl#getUpper <em>Upper</em>}</li>
- * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl#getType <em>Type</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl#getLower <em>Lower</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl#getUpper <em>Upper</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facade.virtualmetamodel.impl.VirtualTypedElementImpl#getType <em>Type</em>}</li>
* </ul>
* </p>
*
@@ -44,6 +44,7 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
* The default value of the '{@link #getLower() <em>Lower</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getLower()
* @generated
* @ordered
@@ -54,6 +55,7 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
* The cached value of the '{@link #getLower() <em>Lower</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getLower()
* @generated
* @ordered
@@ -64,6 +66,7 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
* The default value of the '{@link #getUpper() <em>Upper</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getUpper()
* @generated
* @ordered
@@ -74,6 +77,7 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
* The cached value of the '{@link #getUpper() <em>Upper</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getUpper()
* @generated
* @ordered
@@ -84,6 +88,7 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
* The cached value of the '{@link #getType() <em>Type</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getType()
* @generated
* @ordered
@@ -93,6 +98,7 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualTypedElementImpl() {
@@ -102,6 +108,7 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -112,8 +119,10 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public int getLower() {
return lower;
}
@@ -121,20 +130,25 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setLower(int newLower) {
int oldLower = lower;
lower = newLower;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER, oldLower, lower));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public int getUpper() {
return upper;
}
@@ -142,27 +156,33 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setUpper(int newUpper) {
int oldUpper = upper;
upper = newUpper;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER, oldUpper, upper));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualClassifier getType() {
if (type != null && type.eIsProxy()) {
- InternalEObject oldType = (InternalEObject)type;
- type = (VirtualClassifier)eResolveProxy(oldType);
+ InternalEObject oldType = (InternalEObject) type;
+ type = (VirtualClassifier) eResolveProxy(oldType);
if (type != oldType) {
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.RESOLVE, VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE, oldType, type));
+ }
}
}
return type;
@@ -171,6 +191,7 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualClassifier basicGetType() {
@@ -180,30 +201,36 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setType(VirtualClassifier newType) {
VirtualClassifier oldType = type;
type = newType;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE, oldType, type));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
- return getLower();
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
- return getUpper();
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE:
- if (resolve) return getType();
- return basicGetType();
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
+ return getLower();
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
+ return getUpper();
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE:
+ if (resolve) {
+ return getType();
+ }
+ return basicGetType();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -211,20 +238,21 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
- setLower((Integer)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
- setUpper((Integer)newValue);
- return;
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE:
- setType((VirtualClassifier)newValue);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
+ setLower((Integer) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
+ setUpper((Integer) newValue);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE:
+ setType((VirtualClassifier) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -232,20 +260,21 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
- setLower(LOWER_EDEFAULT);
- return;
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
- setUpper(UPPER_EDEFAULT);
- return;
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE:
- setType((VirtualClassifier)null);
- return;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
+ setLower(LOWER_EDEFAULT);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
+ setUpper(UPPER_EDEFAULT);
+ return;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE:
+ setType((VirtualClassifier) null);
+ return;
}
super.eUnset(featureID);
}
@@ -253,17 +282,18 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
- return lower != LOWER_EDEFAULT;
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
- return upper != UPPER_EDEFAULT;
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE:
- return type != null;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__LOWER:
+ return lower != LOWER_EDEFAULT;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__UPPER:
+ return upper != UPPER_EDEFAULT;
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT__TYPE:
+ return type != null;
}
return super.eIsSet(featureID);
}
@@ -271,11 +301,14 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
/**
* <!-- 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(" (lower: ");
@@ -286,4 +319,4 @@ public abstract class VirtualTypedElementImpl extends VirtualElementImpl impleme
return result.toString();
}
-} //VirtualTypedElementImpl
+} // VirtualTypedElementImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelFactoryImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelFactoryImpl.java
index 46a1d0a00fd..bbf44681922 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelFactoryImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelFactoryImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.*;
* <!-- begin-user-doc -->
* An implementation of the model <b>Factory</b>.
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements VirtualmetamodelFactory {
@@ -34,16 +35,16 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
* Creates the default factory implementation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static VirtualmetamodelFactory init() {
try {
- VirtualmetamodelFactory theVirtualmetamodelFactory = (VirtualmetamodelFactory)EPackage.Registry.INSTANCE.getEFactory(VirtualmetamodelPackage.eNS_URI);
+ VirtualmetamodelFactory theVirtualmetamodelFactory = (VirtualmetamodelFactory) EPackage.Registry.INSTANCE.getEFactory(VirtualmetamodelPackage.eNS_URI);
if (theVirtualmetamodelFactory != null) {
return theVirtualmetamodelFactory;
}
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
EcorePlugin.INSTANCE.log(exception);
}
return new VirtualmetamodelFactoryImpl();
@@ -53,6 +54,7 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
* Creates an instance of the factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelFactoryImpl() {
@@ -62,29 +64,40 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public EObject create(EClass eClass) {
switch (eClass.getClassifierID()) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL: return createVirtualMetamodel();
- case VirtualmetamodelPackage.VIRTUAL_METACLASS: return createVirtualMetaclass();
- case VirtualmetamodelPackage.VIRTUAL_PROPERTY: return createVirtualProperty();
- case VirtualmetamodelPackage.VIRTUAL_OPERATION: return createVirtualOperation();
- case VirtualmetamodelPackage.VIRTUAL_PARAMETER: return createVirtualParameter();
- case VirtualmetamodelPackage.VIRTUAL_DATATYPE: return createVirtualDatatype();
- case VirtualmetamodelPackage.VIRTUAL_ENUM: return createVirtualEnum();
- case VirtualmetamodelPackage.VIRTUAL_LITERAL: return createVirtualLiteral();
- default:
- throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL:
+ return createVirtualMetamodel();
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS:
+ return createVirtualMetaclass();
+ case VirtualmetamodelPackage.VIRTUAL_PROPERTY:
+ return createVirtualProperty();
+ case VirtualmetamodelPackage.VIRTUAL_OPERATION:
+ return createVirtualOperation();
+ case VirtualmetamodelPackage.VIRTUAL_PARAMETER:
+ return createVirtualParameter();
+ case VirtualmetamodelPackage.VIRTUAL_DATATYPE:
+ return createVirtualDatatype();
+ case VirtualmetamodelPackage.VIRTUAL_ENUM:
+ return createVirtualEnum();
+ case VirtualmetamodelPackage.VIRTUAL_LITERAL:
+ return createVirtualLiteral();
+ default:
+ throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualMetamodel createVirtualMetamodel() {
VirtualMetamodelImpl virtualMetamodel = new VirtualMetamodelImpl();
return virtualMetamodel;
@@ -93,8 +106,10 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualMetaclass createVirtualMetaclass() {
VirtualMetaclassImpl virtualMetaclass = new VirtualMetaclassImpl();
return virtualMetaclass;
@@ -103,8 +118,10 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualProperty createVirtualProperty() {
VirtualPropertyImpl virtualProperty = new VirtualPropertyImpl();
return virtualProperty;
@@ -113,8 +130,10 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualOperation createVirtualOperation() {
VirtualOperationImpl virtualOperation = new VirtualOperationImpl();
return virtualOperation;
@@ -123,8 +142,10 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualParameter createVirtualParameter() {
VirtualParameterImpl virtualParameter = new VirtualParameterImpl();
return virtualParameter;
@@ -133,8 +154,10 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualDatatype createVirtualDatatype() {
VirtualDatatypeImpl virtualDatatype = new VirtualDatatypeImpl();
return virtualDatatype;
@@ -143,8 +166,10 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualEnum createVirtualEnum() {
VirtualEnumImpl virtualEnum = new VirtualEnumImpl();
return virtualEnum;
@@ -153,8 +178,10 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualLiteral createVirtualLiteral() {
VirtualLiteralImpl virtualLiteral = new VirtualLiteralImpl();
return virtualLiteral;
@@ -163,15 +190,18 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualmetamodelPackage getVirtualmetamodelPackage() {
- return (VirtualmetamodelPackage)getEPackage();
+ return (VirtualmetamodelPackage) getEPackage();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @deprecated
* @generated
*/
@@ -180,4 +210,4 @@ public class VirtualmetamodelFactoryImpl extends EFactoryImpl implements Virtual
return VirtualmetamodelPackage.eINSTANCE;
}
-} //VirtualmetamodelFactoryImpl
+} // VirtualmetamodelFactoryImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelPackageImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelPackageImpl.java
index a2efbae1a48..8a4c33a1a5c 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelPackageImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/impl/VirtualmetamodelPackageImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -51,12 +51,14 @@ import org.eclipse.uml2.uml.UMLPackage;
* <!-- begin-user-doc -->
* An implementation of the model <b>Package</b>.
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualmetamodelPackageImpl extends EPackageImpl implements VirtualmetamodelPackage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualMetamodelEClass = null;
@@ -64,6 +66,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualElementEClass = null;
@@ -71,6 +74,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualClassifierEClass = null;
@@ -78,6 +82,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualMetaclassEClass = null;
@@ -85,6 +90,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualPropertyEClass = null;
@@ -92,6 +98,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualOperationEClass = null;
@@ -99,6 +106,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualParameterEClass = null;
@@ -106,6 +114,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualDatatypeEClass = null;
@@ -113,6 +122,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualEnumEClass = null;
@@ -120,6 +130,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualLiteralEClass = null;
@@ -127,20 +138,17 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass virtualTypedElementEClass = null;
/**
- * Creates an instance of the model <b>Package</b>, registered with
- * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
+ * Creates an instance of the model <b>Package</b>, registered with {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
* package URI value.
- * <p>Note: the correct way to create the package is via the static
- * factory method {@link #init init()}, which also performs
- * initialization of the package, or returns the registered package,
- * if one already exists.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
+ * <p>
+ * Note: the correct way to create the package is via the static factory method {@link #init init()}, which also performs initialization of the package, or returns the registered package, if one already exists. <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
* @see org.eclipse.emf.ecore.EPackage.Registry
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage#eNS_URI
* @see #init()
@@ -153,27 +161,30 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static boolean isInited = false;
/**
* Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends.
+ *
+ * <p>
+ * This method is used to initialize {@link VirtualmetamodelPackage#eINSTANCE} when that field is accessed. Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. <!-- begin-user-doc --> <!--
+ * end-user-doc -->
*
- * <p>This method is used to initialize {@link VirtualmetamodelPackage#eINSTANCE} when that field is accessed.
- * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
* @see #eNS_URI
* @see #createPackageContents()
* @see #initializePackageContents()
* @generated
*/
public static VirtualmetamodelPackage init() {
- if (isInited) return (VirtualmetamodelPackage)EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI);
+ if (isInited) {
+ return (VirtualmetamodelPackage) EPackage.Registry.INSTANCE.getEPackage(VirtualmetamodelPackage.eNS_URI);
+ }
// Obtain or create and register package
- VirtualmetamodelPackageImpl theVirtualmetamodelPackage = (VirtualmetamodelPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof VirtualmetamodelPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new VirtualmetamodelPackageImpl());
+ VirtualmetamodelPackageImpl theVirtualmetamodelPackage = (VirtualmetamodelPackageImpl) (EPackage.Registry.INSTANCE.get(eNS_URI) instanceof VirtualmetamodelPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new VirtualmetamodelPackageImpl());
isInited = true;
@@ -181,8 +192,9 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
UMLPackage.eINSTANCE.eClass();
// Obtain or create and register interdependencies
- FacadePackageImpl theFacadePackage = (FacadePackageImpl)(EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI) instanceof FacadePackageImpl ? EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI) : FacadePackage.eINSTANCE);
- ExtensiondefinitionPackageImpl theExtensiondefinitionPackage = (ExtensiondefinitionPackageImpl)(EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI) instanceof ExtensiondefinitionPackageImpl ? EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI) : ExtensiondefinitionPackage.eINSTANCE);
+ FacadePackageImpl theFacadePackage = (FacadePackageImpl) (EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI) instanceof FacadePackageImpl ? EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI) : FacadePackage.eINSTANCE);
+ ExtensiondefinitionPackageImpl theExtensiondefinitionPackage = (ExtensiondefinitionPackageImpl) (EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI) instanceof ExtensiondefinitionPackageImpl ? EPackage.Registry.INSTANCE
+ .getEPackage(ExtensiondefinitionPackage.eNS_URI) : ExtensiondefinitionPackage.eINSTANCE);
// Create package meta-data objects
theVirtualmetamodelPackage.createPackageContents();
@@ -197,7 +209,7 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
// Mark meta-data to indicate it can't be changed
theVirtualmetamodelPackage.freeze();
-
+
// Update the registry and return the package
EPackage.Registry.INSTANCE.put(VirtualmetamodelPackage.eNS_URI, theVirtualmetamodelPackage);
return theVirtualmetamodelPackage;
@@ -206,8 +218,10 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualMetamodel() {
return virtualMetamodelEClass;
}
@@ -215,53 +229,65 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualMetamodel_Name() {
- return (EAttribute)virtualMetamodelEClass.getEStructuralFeatures().get(0);
+ return (EAttribute) virtualMetamodelEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualMetamodel_NsPrefix() {
- return (EAttribute)virtualMetamodelEClass.getEStructuralFeatures().get(1);
+ return (EAttribute) virtualMetamodelEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualMetamodel_NsURI() {
- return (EAttribute)virtualMetamodelEClass.getEStructuralFeatures().get(2);
+ return (EAttribute) virtualMetamodelEClass.getEStructuralFeatures().get(2);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualMetamodel_VirtualClassifiers() {
- return (EReference)virtualMetamodelEClass.getEStructuralFeatures().get(3);
+ return (EReference) virtualMetamodelEClass.getEStructuralFeatures().get(3);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualMetamodel_Facade() {
- return (EReference)virtualMetamodelEClass.getEStructuralFeatures().get(4);
+ return (EReference) virtualMetamodelEClass.getEStructuralFeatures().get(4);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualElement() {
return virtualElementEClass;
}
@@ -269,44 +295,54 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualElement_AliasName() {
- return (EAttribute)virtualElementEClass.getEStructuralFeatures().get(0);
+ return (EAttribute) virtualElementEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualElement_Kept() {
- return (EAttribute)virtualElementEClass.getEStructuralFeatures().get(1);
+ return (EAttribute) virtualElementEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualElement_RepresentedElement() {
- return (EReference)virtualElementEClass.getEStructuralFeatures().get(2);
+ return (EReference) virtualElementEClass.getEStructuralFeatures().get(2);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualElement_UseRepresented() {
- return (EAttribute)virtualElementEClass.getEStructuralFeatures().get(3);
+ return (EAttribute) virtualElementEClass.getEStructuralFeatures().get(3);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualClassifier() {
return virtualClassifierEClass;
}
@@ -314,17 +350,21 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualClassifier_Metamodel() {
- return (EReference)virtualClassifierEClass.getEStructuralFeatures().get(0);
+ return (EReference) virtualClassifierEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualMetaclass() {
return virtualMetaclassEClass;
}
@@ -332,62 +372,76 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualMetaclass_Abstract() {
- return (EAttribute)virtualMetaclassEClass.getEStructuralFeatures().get(0);
+ return (EAttribute) virtualMetaclassEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualMetaclass_AppliedStereotypes() {
- return (EReference)virtualMetaclassEClass.getEStructuralFeatures().get(1);
+ return (EReference) virtualMetaclassEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualMetaclass_Operations() {
- return (EReference)virtualMetaclassEClass.getEStructuralFeatures().get(2);
+ return (EReference) virtualMetaclassEClass.getEStructuralFeatures().get(2);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualMetaclass_Parents() {
- return (EReference)virtualMetaclassEClass.getEStructuralFeatures().get(3);
+ return (EReference) virtualMetaclassEClass.getEStructuralFeatures().get(3);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualMetaclass_Properties() {
- return (EReference)virtualMetaclassEClass.getEStructuralFeatures().get(4);
+ return (EReference) virtualMetaclassEClass.getEStructuralFeatures().get(4);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualMetaclass_StereotypeInterface() {
- return (EAttribute)virtualMetaclassEClass.getEStructuralFeatures().get(5);
+ return (EAttribute) virtualMetaclassEClass.getEStructuralFeatures().get(5);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualProperty() {
return virtualPropertyEClass;
}
@@ -395,17 +449,21 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualProperty_VirtualMetaclass() {
- return (EReference)virtualPropertyEClass.getEStructuralFeatures().get(0);
+ return (EReference) virtualPropertyEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualOperation() {
return virtualOperationEClass;
}
@@ -413,17 +471,21 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualOperation_Parameters() {
- return (EReference)virtualOperationEClass.getEStructuralFeatures().get(0);
+ return (EReference) virtualOperationEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualParameter() {
return virtualParameterEClass;
}
@@ -431,8 +493,10 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualDatatype() {
return virtualDatatypeEClass;
}
@@ -440,8 +504,10 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualEnum() {
return virtualEnumEClass;
}
@@ -449,17 +515,21 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualEnum_Literals() {
- return (EReference)virtualEnumEClass.getEStructuralFeatures().get(0);
+ return (EReference) virtualEnumEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualLiteral() {
return virtualLiteralEClass;
}
@@ -467,8 +537,10 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getVirtualTypedElement() {
return virtualTypedElementEClass;
}
@@ -476,55 +548,67 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualTypedElement_Lower() {
- return (EAttribute)virtualTypedElementEClass.getEStructuralFeatures().get(0);
+ return (EAttribute) virtualTypedElementEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getVirtualTypedElement_Upper() {
- return (EAttribute)virtualTypedElementEClass.getEStructuralFeatures().get(1);
+ return (EAttribute) virtualTypedElementEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getVirtualTypedElement_Type() {
- return (EReference)virtualTypedElementEClass.getEStructuralFeatures().get(2);
+ return (EReference) virtualTypedElementEClass.getEStructuralFeatures().get(2);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public VirtualmetamodelFactory getVirtualmetamodelFactory() {
- return (VirtualmetamodelFactory)getEFactoryInstance();
+ return (VirtualmetamodelFactory) getEFactoryInstance();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private boolean isCreated = false;
/**
- * Creates the meta-model objects for the package. This method is
+ * Creates the meta-model objects for the package. This method is
* guarded to have no affect on any invocation but its first.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void createPackageContents() {
- if (isCreated) return;
+ if (isCreated) {
+ return;
+ }
isCreated = true;
// Create classes and their features
@@ -576,19 +660,23 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private boolean isInitialized = false;
/**
- * Complete the initialization of the package and its meta-model. This
+ * Complete the initialization of the package and its meta-model. This
* method is guarded to have no affect on any invocation but its first.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void initializePackageContents() {
- if (isInitialized) return;
+ if (isInitialized) {
+ return;
+ }
isInitialized = true;
// Initialize package
@@ -597,10 +685,10 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
setNsURI(eNS_URI);
// Obtain other dependent packages
- EcorePackage theEcorePackage = (EcorePackage)EPackage.Registry.INSTANCE.getEPackage(EcorePackage.eNS_URI);
- FacadePackage theFacadePackage = (FacadePackage)EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI);
- ExtensiondefinitionPackage theExtensiondefinitionPackage = (ExtensiondefinitionPackage)EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI);
- TypesPackage theTypesPackage = (TypesPackage)EPackage.Registry.INSTANCE.getEPackage(TypesPackage.eNS_URI);
+ EcorePackage theEcorePackage = (EcorePackage) EPackage.Registry.INSTANCE.getEPackage(EcorePackage.eNS_URI);
+ FacadePackage theFacadePackage = (FacadePackage) EPackage.Registry.INSTANCE.getEPackage(FacadePackage.eNS_URI);
+ ExtensiondefinitionPackage theExtensiondefinitionPackage = (ExtensiondefinitionPackage) EPackage.Registry.INSTANCE.getEPackage(ExtensiondefinitionPackage.eNS_URI);
+ TypesPackage theTypesPackage = (TypesPackage) EPackage.Registry.INSTANCE.getEPackage(TypesPackage.eNS_URI);
// Create type parameters
@@ -622,31 +710,41 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
initEAttribute(getVirtualMetamodel_Name(), theEcorePackage.getEString(), "name", null, 0, 1, VirtualMetamodel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getVirtualMetamodel_NsPrefix(), theEcorePackage.getEString(), "nsPrefix", null, 0, 1, VirtualMetamodel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getVirtualMetamodel_NsURI(), theEcorePackage.getEString(), "nsURI", null, 0, 1, VirtualMetamodel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getVirtualMetamodel_VirtualClassifiers(), this.getVirtualClassifier(), this.getVirtualClassifier_Metamodel(), "virtualClassifiers", null, 0, -1, VirtualMetamodel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getVirtualMetamodel_Facade(), theFacadePackage.getFacade(), theFacadePackage.getFacade_Virtualmetamodel(), "facade", null, 1, 1, VirtualMetamodel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualMetamodel_VirtualClassifiers(), this.getVirtualClassifier(), this.getVirtualClassifier_Metamodel(), "virtualClassifiers", null, 0, -1, VirtualMetamodel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualMetamodel_Facade(), theFacadePackage.getFacade(), theFacadePackage.getFacade_Virtualmetamodel(), "facade", null, 1, 1, VirtualMetamodel.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(virtualElementEClass, VirtualElement.class, "VirtualElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getVirtualElement_AliasName(), ecorePackage.getEString(), "aliasName", null, 0, 1, VirtualElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getVirtualElement_Kept(), ecorePackage.getEBoolean(), "kept", null, 1, 1, VirtualElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getVirtualElement_RepresentedElement(), theEcorePackage.getEObject(), null, "representedElement", null, 1, 1, VirtualElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualElement_RepresentedElement(), theEcorePackage.getEObject(), null, "representedElement", null, 1, 1, VirtualElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getVirtualElement_UseRepresented(), ecorePackage.getEBoolean(), "useRepresented", null, 1, 1, VirtualElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(virtualClassifierEClass, VirtualClassifier.class, "VirtualClassifier", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getVirtualClassifier_Metamodel(), this.getVirtualMetamodel(), this.getVirtualMetamodel_VirtualClassifiers(), "metamodel", null, 1, 1, VirtualClassifier.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualClassifier_Metamodel(), this.getVirtualMetamodel(), this.getVirtualMetamodel_VirtualClassifiers(), "metamodel", null, 1, 1, VirtualClassifier.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(virtualMetaclassEClass, VirtualMetaclass.class, "VirtualMetaclass", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getVirtualMetaclass_Abstract(), ecorePackage.getEBoolean(), "abstract", null, 0, 1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getVirtualMetaclass_AppliedStereotypes(), theExtensiondefinitionPackage.getBaseMetaclass(), null, "appliedStereotypes", null, 0, -1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getVirtualMetaclass_Operations(), this.getVirtualOperation(), null, "operations", null, 0, -1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getVirtualMetaclass_Parents(), this.getVirtualMetaclass(), null, "parents", null, 0, -1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getVirtualMetaclass_Properties(), this.getVirtualProperty(), this.getVirtualProperty_VirtualMetaclass(), "properties", null, 0, -1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualMetaclass_AppliedStereotypes(), theExtensiondefinitionPackage.getBaseMetaclass(), null, "appliedStereotypes", null, 0, -1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualMetaclass_Operations(), this.getVirtualOperation(), null, "operations", null, 0, -1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
+ !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualMetaclass_Parents(), this.getVirtualMetaclass(), null, "parents", null, 0, -1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED,
+ IS_ORDERED);
+ initEReference(getVirtualMetaclass_Properties(), this.getVirtualProperty(), this.getVirtualProperty_VirtualMetaclass(), "properties", null, 0, -1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES,
+ !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getVirtualMetaclass_StereotypeInterface(), theTypesPackage.getBoolean(), "stereotypeInterface", null, 1, 1, VirtualMetaclass.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(virtualPropertyEClass, VirtualProperty.class, "VirtualProperty", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getVirtualProperty_VirtualMetaclass(), this.getVirtualMetaclass(), this.getVirtualMetaclass_Properties(), "virtualMetaclass", null, 1, 1, VirtualProperty.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualProperty_VirtualMetaclass(), this.getVirtualMetaclass(), this.getVirtualMetaclass_Properties(), "virtualMetaclass", null, 1, 1, VirtualProperty.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE,
+ !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(virtualOperationEClass, VirtualOperation.class, "VirtualOperation", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getVirtualOperation_Parameters(), this.getVirtualParameter(), null, "parameters", null, 0, -1, VirtualOperation.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualOperation_Parameters(), this.getVirtualParameter(), null, "parameters", null, 0, -1, VirtualOperation.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
+ !IS_DERIVED, IS_ORDERED);
initEClass(virtualParameterEClass, VirtualParameter.class, "VirtualParameter", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
@@ -660,7 +758,8 @@ public class VirtualmetamodelPackageImpl extends EPackageImpl implements Virtual
initEClass(virtualTypedElementEClass, VirtualTypedElement.class, "VirtualTypedElement", IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEAttribute(getVirtualTypedElement_Lower(), ecorePackage.getEInt(), "lower", null, 1, 1, VirtualTypedElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getVirtualTypedElement_Upper(), ecorePackage.getEInt(), "upper", null, 1, 1, VirtualTypedElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getVirtualTypedElement_Type(), this.getVirtualClassifier(), null, "type", null, 1, 1, VirtualTypedElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getVirtualTypedElement_Type(), this.getVirtualClassifier(), null, "type", null, 1, 1, VirtualTypedElement.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED,
+ IS_ORDERED);
}
-} //VirtualmetamodelPackageImpl
+} // VirtualmetamodelPackageImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelAdapterFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelAdapterFactory.java
index 0858a849101..8f21719c74a 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelAdapterFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelAdapterFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.*;
* The <b>Adapter Factory</b> for the model.
* It provides an adapter <code>createXXX</code> method for each class of the model.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage
* @generated
*/
@@ -35,6 +36,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* The cached model package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected static VirtualmetamodelPackage modelPackage;
@@ -43,6 +45,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* Creates an instance of the adapter factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelAdapterFactory() {
@@ -56,6 +59,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* <!-- begin-user-doc -->
* This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model.
* <!-- end-user-doc -->
+ *
* @return whether this factory is applicable for the type of the object.
* @generated
*/
@@ -65,7 +69,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
return true;
}
if (object instanceof EObject) {
- return ((EObject)object).eClass().getEPackage() == modelPackage;
+ return ((EObject) object).eClass().getEPackage() == modelPackage;
}
return false;
}
@@ -74,71 +78,85 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* The switch that delegates to the <code>createXXX</code> methods.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected VirtualmetamodelSwitch<Adapter> modelSwitch =
- new VirtualmetamodelSwitch<Adapter>() {
- @Override
- public Adapter caseVirtualMetamodel(VirtualMetamodel object) {
- return createVirtualMetamodelAdapter();
- }
- @Override
- public Adapter caseVirtualElement(VirtualElement object) {
- return createVirtualElementAdapter();
- }
- @Override
- public Adapter caseVirtualClassifier(VirtualClassifier object) {
- return createVirtualClassifierAdapter();
- }
- @Override
- public Adapter caseVirtualMetaclass(VirtualMetaclass object) {
- return createVirtualMetaclassAdapter();
- }
- @Override
- public Adapter caseVirtualProperty(VirtualProperty object) {
- return createVirtualPropertyAdapter();
- }
- @Override
- public Adapter caseVirtualOperation(VirtualOperation object) {
- return createVirtualOperationAdapter();
- }
- @Override
- public Adapter caseVirtualParameter(VirtualParameter object) {
- return createVirtualParameterAdapter();
- }
- @Override
- public Adapter caseVirtualDatatype(VirtualDatatype object) {
- return createVirtualDatatypeAdapter();
- }
- @Override
- public Adapter caseVirtualEnum(VirtualEnum object) {
- return createVirtualEnumAdapter();
- }
- @Override
- public Adapter caseVirtualLiteral(VirtualLiteral object) {
- return createVirtualLiteralAdapter();
- }
- @Override
- public Adapter caseVirtualTypedElement(VirtualTypedElement object) {
- return createVirtualTypedElementAdapter();
- }
- @Override
- public Adapter defaultCase(EObject object) {
- return createEObjectAdapter();
- }
- };
+ new VirtualmetamodelSwitch<Adapter>() {
+ @Override
+ public Adapter caseVirtualMetamodel(VirtualMetamodel object) {
+ return createVirtualMetamodelAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualElement(VirtualElement object) {
+ return createVirtualElementAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualClassifier(VirtualClassifier object) {
+ return createVirtualClassifierAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualMetaclass(VirtualMetaclass object) {
+ return createVirtualMetaclassAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualProperty(VirtualProperty object) {
+ return createVirtualPropertyAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualOperation(VirtualOperation object) {
+ return createVirtualOperationAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualParameter(VirtualParameter object) {
+ return createVirtualParameterAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualDatatype(VirtualDatatype object) {
+ return createVirtualDatatypeAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualEnum(VirtualEnum object) {
+ return createVirtualEnumAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualLiteral(VirtualLiteral object) {
+ return createVirtualLiteralAdapter();
+ }
+
+ @Override
+ public Adapter caseVirtualTypedElement(VirtualTypedElement object) {
+ return createVirtualTypedElementAdapter();
+ }
+
+ @Override
+ public Adapter defaultCase(EObject object) {
+ return createEObjectAdapter();
+ }
+ };
/**
* Creates an adapter for the <code>target</code>.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param target the object to adapt.
+ *
+ * @param target
+ * the object to adapt.
* @return the adapter for the <code>target</code>.
* @generated
*/
@Override
public Adapter createAdapter(Notifier target) {
- return modelSwitch.doSwitch((EObject)target);
+ return modelSwitch.doSwitch((EObject) target);
}
@@ -148,6 +166,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetamodel
* @generated
@@ -162,6 +181,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualElement
* @generated
@@ -176,6 +196,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualClassifier
* @generated
@@ -190,6 +211,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualMetaclass
* @generated
@@ -204,6 +226,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualProperty
* @generated
@@ -218,6 +241,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualOperation
* @generated
@@ -232,6 +256,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualParameter
* @generated
@@ -246,6 +271,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualDatatype
* @generated
@@ -260,6 +286,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualEnum
* @generated
@@ -274,6 +301,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualLiteral
* @generated
@@ -288,6 +316,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualTypedElement
* @generated
@@ -301,6 +330,7 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
* <!-- begin-user-doc -->
* This default implementation returns null.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @generated
*/
@@ -308,4 +338,4 @@ public class VirtualmetamodelAdapterFactory extends AdapterFactoryImpl {
return null;
}
-} //VirtualmetamodelAdapterFactory
+} // VirtualmetamodelAdapterFactory
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceFactoryImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceFactoryImpl.java
index 590d1547367..be39f3a43ae 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceFactoryImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceFactoryImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,6 +25,7 @@ import org.eclipse.emf.ecore.xmi.XMLResource;
* <!-- begin-user-doc -->
* The <b>Resource Factory</b> associated with the package.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.util.VirtualmetamodelResourceImpl
* @generated
*/
@@ -33,6 +34,7 @@ public class VirtualmetamodelResourceFactoryImpl extends ResourceFactoryImpl {
* Creates an instance of the resource factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelResourceFactoryImpl() {
@@ -43,6 +45,7 @@ public class VirtualmetamodelResourceFactoryImpl extends ResourceFactoryImpl {
* Creates an instance of the resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -60,4 +63,4 @@ public class VirtualmetamodelResourceFactoryImpl extends ResourceFactoryImpl {
return result;
}
-} //VirtualmetamodelResourceFactoryImpl
+} // VirtualmetamodelResourceFactoryImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceImpl.java
index 18f48fa354c..a7004e4f443 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelResourceImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -21,6 +21,7 @@ import org.eclipse.emf.ecore.xmi.impl.XMLResourceImpl;
* <!-- begin-user-doc -->
* The <b>Resource </b> associated with the package.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.util.VirtualmetamodelResourceFactoryImpl
* @generated
*/
@@ -29,11 +30,13 @@ public class VirtualmetamodelResourceImpl extends XMLResourceImpl {
* Creates an instance of the resource.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param uri the URI of the new resource.
+ *
+ * @param uri
+ * the URI of the new resource.
* @generated
*/
public VirtualmetamodelResourceImpl(URI uri) {
super(uri);
}
-} //VirtualmetamodelResourceImpl
+} // VirtualmetamodelResourceImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelSwitch.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelSwitch.java
index e449716a0e3..514805d919e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelSwitch.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelSwitch.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,13 +23,13 @@ import org.eclipse.papyrus.facade.virtualmetamodel.*;
/**
* <!-- begin-user-doc -->
* The <b>Switch</b> for the model's inheritance hierarchy.
- * It supports the call {@link #doSwitch(EObject) doSwitch(object)}
- * to invoke the <code>caseXXX</code> method for each class of the model,
+ * It supports the call {@link #doSwitch(EObject) doSwitch(object)} to invoke the <code>caseXXX</code> method for each class of the model,
* starting with the actual class of the object
* and proceeding up the inheritance hierarchy
* until a non-null result is returned,
* which is the result of the switch.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage
* @generated
*/
@@ -38,6 +38,7 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* The cached model package
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected static VirtualmetamodelPackage modelPackage;
@@ -46,6 +47,7 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* Creates an instance of the switch.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelSwitch() {
@@ -58,6 +60,7 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* Checks whether this is a switch for the given package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @parameter ePackage the package in question.
* @return whether this is a switch for the given package.
* @generated
@@ -71,94 +74,148 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the first non-null result returned by a <code>caseXXX</code> call.
* @generated
*/
@Override
protected T doSwitch(int classifierID, EObject theEObject) {
switch (classifierID) {
- case VirtualmetamodelPackage.VIRTUAL_METAMODEL: {
- VirtualMetamodel virtualMetamodel = (VirtualMetamodel)theEObject;
- T result = caseVirtualMetamodel(virtualMetamodel);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ case VirtualmetamodelPackage.VIRTUAL_METAMODEL: {
+ VirtualMetamodel virtualMetamodel = (VirtualMetamodel) theEObject;
+ T result = caseVirtualMetamodel(virtualMetamodel);
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- case VirtualmetamodelPackage.VIRTUAL_ELEMENT: {
- VirtualElement virtualElement = (VirtualElement)theEObject;
- T result = caseVirtualElement(virtualElement);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_ELEMENT: {
+ VirtualElement virtualElement = (VirtualElement) theEObject;
+ T result = caseVirtualElement(virtualElement);
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER: {
- VirtualClassifier virtualClassifier = (VirtualClassifier)theEObject;
- T result = caseVirtualClassifier(virtualClassifier);
- if (result == null) result = caseVirtualElement(virtualClassifier);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_CLASSIFIER: {
+ VirtualClassifier virtualClassifier = (VirtualClassifier) theEObject;
+ T result = caseVirtualClassifier(virtualClassifier);
+ if (result == null) {
+ result = caseVirtualElement(virtualClassifier);
}
- case VirtualmetamodelPackage.VIRTUAL_METACLASS: {
- VirtualMetaclass virtualMetaclass = (VirtualMetaclass)theEObject;
- T result = caseVirtualMetaclass(virtualMetaclass);
- if (result == null) result = caseVirtualClassifier(virtualMetaclass);
- if (result == null) result = caseVirtualElement(virtualMetaclass);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- case VirtualmetamodelPackage.VIRTUAL_PROPERTY: {
- VirtualProperty virtualProperty = (VirtualProperty)theEObject;
- T result = caseVirtualProperty(virtualProperty);
- if (result == null) result = caseVirtualTypedElement(virtualProperty);
- if (result == null) result = caseVirtualElement(virtualProperty);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_METACLASS: {
+ VirtualMetaclass virtualMetaclass = (VirtualMetaclass) theEObject;
+ T result = caseVirtualMetaclass(virtualMetaclass);
+ if (result == null) {
+ result = caseVirtualClassifier(virtualMetaclass);
}
- case VirtualmetamodelPackage.VIRTUAL_OPERATION: {
- VirtualOperation virtualOperation = (VirtualOperation)theEObject;
- T result = caseVirtualOperation(virtualOperation);
- if (result == null) result = caseVirtualTypedElement(virtualOperation);
- if (result == null) result = caseVirtualElement(virtualOperation);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ if (result == null) {
+ result = caseVirtualElement(virtualMetaclass);
}
- case VirtualmetamodelPackage.VIRTUAL_PARAMETER: {
- VirtualParameter virtualParameter = (VirtualParameter)theEObject;
- T result = caseVirtualParameter(virtualParameter);
- if (result == null) result = caseVirtualTypedElement(virtualParameter);
- if (result == null) result = caseVirtualElement(virtualParameter);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- case VirtualmetamodelPackage.VIRTUAL_DATATYPE: {
- VirtualDatatype virtualDatatype = (VirtualDatatype)theEObject;
- T result = caseVirtualDatatype(virtualDatatype);
- if (result == null) result = caseVirtualClassifier(virtualDatatype);
- if (result == null) result = caseVirtualElement(virtualDatatype);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_PROPERTY: {
+ VirtualProperty virtualProperty = (VirtualProperty) theEObject;
+ T result = caseVirtualProperty(virtualProperty);
+ if (result == null) {
+ result = caseVirtualTypedElement(virtualProperty);
}
- case VirtualmetamodelPackage.VIRTUAL_ENUM: {
- VirtualEnum virtualEnum = (VirtualEnum)theEObject;
- T result = caseVirtualEnum(virtualEnum);
- if (result == null) result = caseVirtualClassifier(virtualEnum);
- if (result == null) result = caseVirtualElement(virtualEnum);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ if (result == null) {
+ result = caseVirtualElement(virtualProperty);
}
- case VirtualmetamodelPackage.VIRTUAL_LITERAL: {
- VirtualLiteral virtualLiteral = (VirtualLiteral)theEObject;
- T result = caseVirtualLiteral(virtualLiteral);
- if (result == null) result = caseVirtualElement(virtualLiteral);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT: {
- VirtualTypedElement virtualTypedElement = (VirtualTypedElement)theEObject;
- T result = caseVirtualTypedElement(virtualTypedElement);
- if (result == null) result = caseVirtualElement(virtualTypedElement);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_OPERATION: {
+ VirtualOperation virtualOperation = (VirtualOperation) theEObject;
+ T result = caseVirtualOperation(virtualOperation);
+ if (result == null) {
+ result = caseVirtualTypedElement(virtualOperation);
}
- default: return defaultCase(theEObject);
+ if (result == null) {
+ result = caseVirtualElement(virtualOperation);
+ }
+ if (result == null) {
+ result = defaultCase(theEObject);
+ }
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_PARAMETER: {
+ VirtualParameter virtualParameter = (VirtualParameter) theEObject;
+ T result = caseVirtualParameter(virtualParameter);
+ if (result == null) {
+ result = caseVirtualTypedElement(virtualParameter);
+ }
+ if (result == null) {
+ result = caseVirtualElement(virtualParameter);
+ }
+ if (result == null) {
+ result = defaultCase(theEObject);
+ }
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_DATATYPE: {
+ VirtualDatatype virtualDatatype = (VirtualDatatype) theEObject;
+ T result = caseVirtualDatatype(virtualDatatype);
+ if (result == null) {
+ result = caseVirtualClassifier(virtualDatatype);
+ }
+ if (result == null) {
+ result = caseVirtualElement(virtualDatatype);
+ }
+ if (result == null) {
+ result = defaultCase(theEObject);
+ }
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_ENUM: {
+ VirtualEnum virtualEnum = (VirtualEnum) theEObject;
+ T result = caseVirtualEnum(virtualEnum);
+ if (result == null) {
+ result = caseVirtualClassifier(virtualEnum);
+ }
+ if (result == null) {
+ result = caseVirtualElement(virtualEnum);
+ }
+ if (result == null) {
+ result = defaultCase(theEObject);
+ }
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_LITERAL: {
+ VirtualLiteral virtualLiteral = (VirtualLiteral) theEObject;
+ T result = caseVirtualLiteral(virtualLiteral);
+ if (result == null) {
+ result = caseVirtualElement(virtualLiteral);
+ }
+ if (result == null) {
+ result = defaultCase(theEObject);
+ }
+ return result;
+ }
+ case VirtualmetamodelPackage.VIRTUAL_TYPED_ELEMENT: {
+ VirtualTypedElement virtualTypedElement = (VirtualTypedElement) theEObject;
+ T result = caseVirtualTypedElement(virtualTypedElement);
+ if (result == null) {
+ result = caseVirtualElement(virtualTypedElement);
+ }
+ if (result == null) {
+ result = defaultCase(theEObject);
+ }
+ return result;
+ }
+ default:
+ return defaultCase(theEObject);
}
}
@@ -168,7 +225,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Metamodel</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -183,7 +242,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Element</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -198,7 +259,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Classifier</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -213,7 +276,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Metaclass</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -228,7 +293,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Property</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -243,7 +310,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Operation</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -258,7 +327,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Parameter</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -273,7 +344,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Datatype</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -288,7 +361,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Enum</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -303,7 +378,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Literal</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -318,7 +395,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Virtual Typed Element</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -333,7 +412,9 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch, but this is the last case anyway.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>EObject</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject)
* @generated
@@ -343,4 +424,4 @@ public class VirtualmetamodelSwitch<T> extends Switch<T> {
return null;
}
-} //VirtualmetamodelSwitch
+} // VirtualmetamodelSwitch
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelXMLProcessor.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelXMLProcessor.java
index a1c0e852e76..8d32a255dc4 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelXMLProcessor.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/util/VirtualmetamodelXMLProcessor.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.papyrus.facade.virtualmetamodel.VirtualmetamodelPackage;
* This class contains helper methods to serialize and deserialize XML documents
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public class VirtualmetamodelXMLProcessor extends XMLProcessor {
@@ -35,17 +36,19 @@ public class VirtualmetamodelXMLProcessor extends XMLProcessor {
* Public constructor to instantiate the helper.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public VirtualmetamodelXMLProcessor() {
super((EPackage.Registry.INSTANCE));
VirtualmetamodelPackage.eINSTANCE.eClass();
}
-
+
/**
* Register for "*" and "xml" file extensions the VirtualmetamodelResourceFactoryImpl factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -58,4 +61,4 @@ public class VirtualmetamodelXMLProcessor extends XMLProcessor {
return registrations;
}
-} //VirtualmetamodelXMLProcessor
+} // VirtualmetamodelXMLProcessor
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualClassifierValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualClassifierValidator.java
index f3d1abc2b6a..598deb12159 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualClassifierValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualClassifierValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualDatatypeValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualDatatypeValidator.java
index fd4ff4333ea..90942d2157c 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualDatatypeValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualDatatypeValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualElementValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualElementValidator.java
index 1247cec29b8..bce4a7a0cf5 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualElementValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualElementValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,7 +25,10 @@ public interface VirtualElementValidator {
boolean validate();
boolean validateAliasName(String value);
+
boolean validateKept(boolean value);
+
boolean validateRepresentedElement(EObject value);
+
boolean validateUseRepresented(boolean value);
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualEnumValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualEnumValidator.java
index dc20313b1a0..ac1da0df3dc 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualEnumValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualEnumValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualLiteralValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualLiteralValidator.java
index 9e736ed0b3d..a99b945c0ee 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualLiteralValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualLiteralValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetaclassValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetaclassValidator.java
index 1d6add9be35..9d6627f6f3e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetaclassValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetaclassValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -31,9 +31,14 @@ public interface VirtualMetaclassValidator {
boolean validate();
boolean validateAbstract(boolean value);
+
boolean validateAppliedStereotypes(EList<BaseMetaclass> value);
+
boolean validateOperations(EList<VirtualOperation> value);
+
boolean validateParents(EList<VirtualMetaclass> value);
+
boolean validateProperties(EList<VirtualProperty> value);
+
boolean validateStereotypeInterface(boolean value);
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetamodelValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetamodelValidator.java
index 1de291b0507..89e09b9140f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetamodelValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualMetamodelValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -29,8 +29,12 @@ public interface VirtualMetamodelValidator {
boolean validate();
boolean validateName(String value);
+
boolean validateNsPrefix(String value);
+
boolean validateNsURI(String value);
+
boolean validateVirtualClassifiers(EList<VirtualClassifier> value);
+
boolean validateFacade(Facade value);
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualOperationValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualOperationValidator.java
index c3c6b9c7a2d..7f1bd28d7a2 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualOperationValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualOperationValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualParameterValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualParameterValidator.java
index 832c52b2b3e..a8f696a9fac 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualParameterValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualParameterValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualPropertyValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualPropertyValidator.java
index 9dfc62dc8d7..1f77681e3cc 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualPropertyValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualPropertyValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualTypedElementValidator.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualTypedElementValidator.java
index 49d3ef4acd6..83c9540f86d 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualTypedElementValidator.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facade/virtualmetamodel/validation/VirtualTypedElementValidator.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,6 +25,8 @@ public interface VirtualTypedElementValidator {
boolean validate();
boolean validateLower(int value);
+
boolean validateUpper(int value);
+
boolean validateType(VirtualClassifier value);
}
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/ExtensionDefinitionKind.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/ExtensionDefinitionKind.java
index 81561e57555..4166246d005 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/ExtensionDefinitionKind.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/ExtensionDefinitionKind.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -24,6 +24,7 @@ import org.eclipse.emf.common.util.Enumerator;
* A representation of the literals of the enumeration '<em><b>Extension Definition Kind</b></em>',
* and utility methods for working with them.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.FacademappingPackage#getExtensionDefinitionKind()
* @model
* @generated
@@ -33,6 +34,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Association</b></em>' literal object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #ASSOCIATION_VALUE
* @generated
* @ordered
@@ -43,6 +45,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Generalization</b></em>' literal object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #GENERALIZATION_VALUE
* @generated
* @ordered
@@ -53,6 +56,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Multi Generalization</b></em>' literal object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #MULTI_GENERALIZATION_VALUE
* @generated
* @ordered
@@ -63,6 +67,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Fusion</b></em>' literal object.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #FUSION_VALUE
* @generated
* @ordered
@@ -73,10 +78,10 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Association</b></em>' literal value.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of '<em><b>Association</b></em>' literal object isn't clear,
- * there really should be more of a description here...
+ * If the meaning of '<em><b>Association</b></em>' literal object isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @see #ASSOCIATION
* @model name="Association"
* @generated
@@ -88,10 +93,10 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Generalization</b></em>' literal value.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of '<em><b>Generalization</b></em>' literal object isn't clear,
- * there really should be more of a description here...
+ * If the meaning of '<em><b>Generalization</b></em>' literal object isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @see #GENERALIZATION
* @model name="Generalization"
* @generated
@@ -103,10 +108,10 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Multi Generalization</b></em>' literal value.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of '<em><b>Multi Generalization</b></em>' literal object isn't clear,
- * there really should be more of a description here...
+ * If the meaning of '<em><b>Multi Generalization</b></em>' literal object isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @see #MULTI_GENERALIZATION
* @model name="MultiGeneralization"
* @generated
@@ -118,10 +123,10 @@ public enum ExtensionDefinitionKind implements Enumerator {
* The '<em><b>Fusion</b></em>' literal value.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of '<em><b>Fusion</b></em>' literal object isn't clear,
- * there really should be more of a description here...
+ * If the meaning of '<em><b>Fusion</b></em>' literal object isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @see #FUSION
* @model name="Fusion"
* @generated
@@ -133,20 +138,22 @@ public enum ExtensionDefinitionKind implements Enumerator {
* An array of all the '<em><b>Extension Definition Kind</b></em>' enumerators.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static final ExtensionDefinitionKind[] VALUES_ARRAY =
- new ExtensionDefinitionKind[] {
- ASSOCIATION,
- GENERALIZATION,
- MULTI_GENERALIZATION,
- FUSION,
- };
+ new ExtensionDefinitionKind[] {
+ ASSOCIATION,
+ GENERALIZATION,
+ MULTI_GENERALIZATION,
+ FUSION,
+ };
/**
* A public read-only list of all the '<em><b>Extension Definition Kind</b></em>' enumerators.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static final List<ExtensionDefinitionKind> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY));
@@ -155,6 +162,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* Returns the '<em><b>Extension Definition Kind</b></em>' literal with the specified literal value.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static ExtensionDefinitionKind get(String literal) {
@@ -171,6 +179,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* Returns the '<em><b>Extension Definition Kind</b></em>' literal with the specified name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static ExtensionDefinitionKind getByName(String name) {
@@ -187,14 +196,19 @@ public enum ExtensionDefinitionKind implements Enumerator {
* Returns the '<em><b>Extension Definition Kind</b></em>' literal with the specified integer value.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static ExtensionDefinitionKind get(int value) {
switch (value) {
- case ASSOCIATION_VALUE: return ASSOCIATION;
- case GENERALIZATION_VALUE: return GENERALIZATION;
- case MULTI_GENERALIZATION_VALUE: return MULTI_GENERALIZATION;
- case FUSION_VALUE: return FUSION;
+ case ASSOCIATION_VALUE:
+ return ASSOCIATION;
+ case GENERALIZATION_VALUE:
+ return GENERALIZATION;
+ case MULTI_GENERALIZATION_VALUE:
+ return MULTI_GENERALIZATION;
+ case FUSION_VALUE:
+ return FUSION;
}
return null;
}
@@ -202,6 +216,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private final int value;
@@ -209,6 +224,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private final String name;
@@ -216,6 +232,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private final String literal;
@@ -224,6 +241,7 @@ public enum ExtensionDefinitionKind implements Enumerator {
* Only this class can construct instances.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private ExtensionDefinitionKind(int value, String name, String literal) {
@@ -235,39 +253,46 @@ public enum ExtensionDefinitionKind implements Enumerator {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public int getValue() {
- return value;
+ return value;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public String getName() {
- return name;
+ return name;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public String getLiteral() {
- return literal;
+ return literal;
}
/**
* Returns the literal value of the enumerator, which is its string representation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String toString() {
return literal;
}
-
-} //ExtensionDefinitionKind
+
+} // ExtensionDefinitionKind
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacadeMappping.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacadeMappping.java
index 9deacd57b8a..8bf2c5d042e 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacadeMappping.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacadeMappping.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,7 +25,7 @@ import org.eclipse.emf.ecore.EObject;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facademapping.FacadeMappping#getMappings <em>Mappings</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.FacadeMappping#getMappings <em>Mappings</em>}</li>
* </ul>
* </p>
*
@@ -39,10 +39,10 @@ public interface FacadeMappping extends EObject {
* The list contents are of type {@link org.eclipse.papyrus.facademapping.Mapping}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Mappings</em>' containment reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Mappings</em>' containment reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Mappings</em>' containment reference list.
* @see org.eclipse.papyrus.facademapping.FacademappingPackage#getFacadeMappping_Mappings()
* @model containment="true"
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingFactory.java
index b0db3005c29..6857db3ecf2 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -20,6 +20,7 @@ import org.eclipse.emf.ecore.EFactory;
* The <b>Factory</b> for the model.
* It provides a create method for each non-abstract class of the model.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.FacademappingPackage
* @generated
*/
@@ -28,6 +29,7 @@ public interface FacademappingFactory extends EFactory {
* The singleton instance of the factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
FacademappingFactory eINSTANCE = org.eclipse.papyrus.facademapping.impl.FacademappingFactoryImpl.init();
@@ -36,6 +38,7 @@ public interface FacademappingFactory extends EFactory {
* Returns a new object of class '<em>Mapping</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Mapping</em>'.
* @generated
*/
@@ -45,6 +48,7 @@ public interface FacademappingFactory extends EFactory {
* Returns a new object of class '<em>Stereotyped Mapping</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Stereotyped Mapping</em>'.
* @generated
*/
@@ -54,6 +58,7 @@ public interface FacademappingFactory extends EFactory {
* Returns a new object of class '<em>Facade Mappping</em>'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return a new object of class '<em>Facade Mappping</em>'.
* @generated
*/
@@ -63,9 +68,10 @@ public interface FacademappingFactory extends EFactory {
* Returns the package supported by this factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the package supported by this factory.
* @generated
*/
FacademappingPackage getFacademappingPackage();
-} //FacademappingFactory
+} // FacademappingFactory
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingPackage.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingPackage.java
index 6cb348b3d0d..98c34c12fb0 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingPackage.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/FacademappingPackage.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -24,13 +24,14 @@ import org.eclipse.emf.ecore.EReference;
* The <b>Package</b> for the model.
* It contains accessors for the meta objects to represent
* <ul>
- * <li>each class,</li>
- * <li>each feature of each class,</li>
- * <li>each operation of each class,</li>
- * <li>each enum,</li>
- * <li>and each data type</li>
+ * <li>each class,</li>
+ * <li>each feature of each class,</li>
+ * <li>each operation of each class,</li>
+ * <li>each enum,</li>
+ * <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.FacademappingFactory
* @model kind="package"
* @generated
@@ -40,6 +41,7 @@ public interface FacademappingPackage extends EPackage {
* The package name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNAME = "facademapping";
@@ -48,6 +50,7 @@ public interface FacademappingPackage extends EPackage {
* The package namespace URI.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNS_URI = "http://www.eclipse.org/papyrus/facademapping";
@@ -56,6 +59,7 @@ public interface FacademappingPackage extends EPackage {
* The package namespace name.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
String eNS_PREFIX = "facademapping";
@@ -64,6 +68,7 @@ public interface FacademappingPackage extends EPackage {
* The singleton instance of the package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
FacademappingPackage eINSTANCE = org.eclipse.papyrus.facademapping.impl.FacademappingPackageImpl.init();
@@ -72,6 +77,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facademapping.impl.MappingImpl <em>Mapping</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.impl.MappingImpl
* @see org.eclipse.papyrus.facademapping.impl.FacademappingPackageImpl#getMapping()
* @generated
@@ -82,6 +88,7 @@ public interface FacademappingPackage extends EPackage {
* The feature id for the '<em><b>Uml Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -91,6 +98,7 @@ public interface FacademappingPackage extends EPackage {
* The feature id for the '<em><b>Specific Domain Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -100,6 +108,7 @@ public interface FacademappingPackage extends EPackage {
* The number of structural features of the '<em>Mapping</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -109,6 +118,7 @@ public interface FacademappingPackage extends EPackage {
* The number of operations of the '<em>Mapping</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -118,6 +128,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facademapping.impl.StereotypedMappingImpl <em>Stereotyped Mapping</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.impl.StereotypedMappingImpl
* @see org.eclipse.papyrus.facademapping.impl.FacademappingPackageImpl#getStereotypedMapping()
* @generated
@@ -128,6 +139,7 @@ public interface FacademappingPackage extends EPackage {
* The feature id for the '<em><b>Uml Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -137,6 +149,7 @@ public interface FacademappingPackage extends EPackage {
* The feature id for the '<em><b>Specific Domain Element</b></em>' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -146,6 +159,7 @@ public interface FacademappingPackage extends EPackage {
* The feature id for the '<em><b>Applied Stereotypes</b></em>' reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -155,6 +169,7 @@ public interface FacademappingPackage extends EPackage {
* The feature id for the '<em><b>Kind</b></em>' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -164,6 +179,7 @@ public interface FacademappingPackage extends EPackage {
* The number of structural features of the '<em>Stereotyped Mapping</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -173,6 +189,7 @@ public interface FacademappingPackage extends EPackage {
* The number of operations of the '<em>Stereotyped Mapping</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -182,6 +199,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facademapping.impl.FacadeMapppingImpl <em>Facade Mappping</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.impl.FacadeMapppingImpl
* @see org.eclipse.papyrus.facademapping.impl.FacademappingPackageImpl#getFacadeMappping()
* @generated
@@ -192,6 +210,7 @@ public interface FacademappingPackage extends EPackage {
* The feature id for the '<em><b>Mappings</b></em>' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -201,6 +220,7 @@ public interface FacademappingPackage extends EPackage {
* The number of structural features of the '<em>Facade Mappping</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -210,6 +230,7 @@ public interface FacademappingPackage extends EPackage {
* The number of operations of the '<em>Facade Mappping</em>' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
* @ordered
*/
@@ -219,6 +240,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object id for the '{@link org.eclipse.papyrus.facademapping.ExtensionDefinitionKind <em>Extension Definition Kind</em>}' enum.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.ExtensionDefinitionKind
* @see org.eclipse.papyrus.facademapping.impl.FacademappingPackageImpl#getExtensionDefinitionKind()
* @generated
@@ -230,6 +252,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facademapping.Mapping <em>Mapping</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Mapping</em>'.
* @see org.eclipse.papyrus.facademapping.Mapping
* @generated
@@ -240,6 +263,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the meta object for the reference '{@link org.eclipse.papyrus.facademapping.Mapping#getUmlElement <em>Uml Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference '<em>Uml Element</em>'.
* @see org.eclipse.papyrus.facademapping.Mapping#getUmlElement()
* @see #getMapping()
@@ -251,6 +275,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the meta object for the reference '{@link org.eclipse.papyrus.facademapping.Mapping#getSpecificDomainElement <em>Specific Domain Element</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference '<em>Specific Domain Element</em>'.
* @see org.eclipse.papyrus.facademapping.Mapping#getSpecificDomainElement()
* @see #getMapping()
@@ -262,6 +287,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facademapping.StereotypedMapping <em>Stereotyped Mapping</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Stereotyped Mapping</em>'.
* @see org.eclipse.papyrus.facademapping.StereotypedMapping
* @generated
@@ -272,6 +298,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the meta object for the reference list '{@link org.eclipse.papyrus.facademapping.StereotypedMapping#getAppliedStereotypes <em>Applied Stereotypes</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the reference list '<em>Applied Stereotypes</em>'.
* @see org.eclipse.papyrus.facademapping.StereotypedMapping#getAppliedStereotypes()
* @see #getStereotypedMapping()
@@ -283,6 +310,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the meta object for the attribute '{@link org.eclipse.papyrus.facademapping.StereotypedMapping#getKind <em>Kind</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the attribute '<em>Kind</em>'.
* @see org.eclipse.papyrus.facademapping.StereotypedMapping#getKind()
* @see #getStereotypedMapping()
@@ -294,6 +322,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the meta object for class '{@link org.eclipse.papyrus.facademapping.FacadeMappping <em>Facade Mappping</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for class '<em>Facade Mappping</em>'.
* @see org.eclipse.papyrus.facademapping.FacadeMappping
* @generated
@@ -304,6 +333,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the meta object for the containment reference list '{@link org.eclipse.papyrus.facademapping.FacadeMappping#getMappings <em>Mappings</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for the containment reference list '<em>Mappings</em>'.
* @see org.eclipse.papyrus.facademapping.FacadeMappping#getMappings()
* @see #getFacadeMappping()
@@ -315,6 +345,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the meta object for enum '{@link org.eclipse.papyrus.facademapping.ExtensionDefinitionKind <em>Extension Definition Kind</em>}'.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the meta object for enum '<em>Extension Definition Kind</em>'.
* @see org.eclipse.papyrus.facademapping.ExtensionDefinitionKind
* @generated
@@ -325,6 +356,7 @@ public interface FacademappingPackage extends EPackage {
* Returns the factory that creates the instances of the model.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the factory that creates the instances of the model.
* @generated
*/
@@ -334,13 +366,14 @@ public interface FacademappingPackage extends EPackage {
* <!-- begin-user-doc -->
* Defines literals for the meta objects that represent
* <ul>
- * <li>each class,</li>
- * <li>each feature of each class,</li>
- * <li>each operation of each class,</li>
- * <li>each enum,</li>
- * <li>and each data type</li>
+ * <li>each class,</li>
+ * <li>each feature of each class,</li>
+ * <li>each operation of each class,</li>
+ * <li>each enum,</li>
+ * <li>and each data type</li>
* </ul>
* <!-- end-user-doc -->
+ *
* @generated
*/
interface Literals {
@@ -348,6 +381,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facademapping.impl.MappingImpl <em>Mapping</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.impl.MappingImpl
* @see org.eclipse.papyrus.facademapping.impl.FacademappingPackageImpl#getMapping()
* @generated
@@ -358,6 +392,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object literal for the '<em><b>Uml Element</b></em>' reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference MAPPING__UML_ELEMENT = eINSTANCE.getMapping_UmlElement();
@@ -366,6 +401,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object literal for the '<em><b>Specific Domain Element</b></em>' reference feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference MAPPING__SPECIFIC_DOMAIN_ELEMENT = eINSTANCE.getMapping_SpecificDomainElement();
@@ -374,6 +410,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facademapping.impl.StereotypedMappingImpl <em>Stereotyped Mapping</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.impl.StereotypedMappingImpl
* @see org.eclipse.papyrus.facademapping.impl.FacademappingPackageImpl#getStereotypedMapping()
* @generated
@@ -384,6 +421,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object literal for the '<em><b>Applied Stereotypes</b></em>' reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference STEREOTYPED_MAPPING__APPLIED_STEREOTYPES = eINSTANCE.getStereotypedMapping_AppliedStereotypes();
@@ -392,6 +430,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object literal for the '<em><b>Kind</b></em>' attribute feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EAttribute STEREOTYPED_MAPPING__KIND = eINSTANCE.getStereotypedMapping_Kind();
@@ -400,6 +439,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facademapping.impl.FacadeMapppingImpl <em>Facade Mappping</em>}' class.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.impl.FacadeMapppingImpl
* @see org.eclipse.papyrus.facademapping.impl.FacademappingPackageImpl#getFacadeMappping()
* @generated
@@ -410,6 +450,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object literal for the '<em><b>Mappings</b></em>' containment reference list feature.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
EReference FACADE_MAPPPING__MAPPINGS = eINSTANCE.getFacadeMappping_Mappings();
@@ -418,6 +459,7 @@ public interface FacademappingPackage extends EPackage {
* The meta object literal for the '{@link org.eclipse.papyrus.facademapping.ExtensionDefinitionKind <em>Extension Definition Kind</em>}' enum.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.ExtensionDefinitionKind
* @see org.eclipse.papyrus.facademapping.impl.FacademappingPackageImpl#getExtensionDefinitionKind()
* @generated
@@ -426,4 +468,4 @@ public interface FacademappingPackage extends EPackage {
}
-} //FacademappingPackage
+} // FacademappingPackage
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/Mapping.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/Mapping.java
index 50dc8b688df..8f02ae0fe87 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/Mapping.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/Mapping.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,8 +23,8 @@ import org.eclipse.emf.ecore.EObject;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facademapping.Mapping#getUmlElement <em>Uml Element</em>}</li>
- * <li>{@link org.eclipse.papyrus.facademapping.Mapping#getSpecificDomainElement <em>Specific Domain Element</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.Mapping#getUmlElement <em>Uml Element</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.Mapping#getSpecificDomainElement <em>Specific Domain Element</em>}</li>
* </ul>
* </p>
*
@@ -37,10 +37,10 @@ public interface Mapping extends EObject {
* Returns the value of the '<em><b>Uml Element</b></em>' reference.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Uml Element</em>' reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Uml Element</em>' reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Uml Element</em>' reference.
* @see #setUmlElement(EObject)
* @see org.eclipse.papyrus.facademapping.FacademappingPackage#getMapping_UmlElement()
@@ -53,7 +53,9 @@ public interface Mapping extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facademapping.Mapping#getUmlElement <em>Uml Element</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Uml Element</em>' reference.
+ *
+ * @param value
+ * the new value of the '<em>Uml Element</em>' reference.
* @see #getUmlElement()
* @generated
*/
@@ -63,10 +65,10 @@ public interface Mapping extends EObject {
* Returns the value of the '<em><b>Specific Domain Element</b></em>' reference.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Specific Domain Element</em>' reference isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Specific Domain Element</em>' reference isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Specific Domain Element</em>' reference.
* @see #setSpecificDomainElement(EObject)
* @see org.eclipse.papyrus.facademapping.FacademappingPackage#getMapping_SpecificDomainElement()
@@ -79,7 +81,9 @@ public interface Mapping extends EObject {
* Sets the value of the '{@link org.eclipse.papyrus.facademapping.Mapping#getSpecificDomainElement <em>Specific Domain Element</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Specific Domain Element</em>' reference.
+ *
+ * @param value
+ * the new value of the '<em>Specific Domain Element</em>' reference.
* @see #getSpecificDomainElement()
* @generated
*/
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/StereotypedMapping.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/StereotypedMapping.java
index 293fc9fd2ca..1e90c1e0d4f 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/StereotypedMapping.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/StereotypedMapping.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -25,8 +25,8 @@ import org.eclipse.emf.ecore.EObject;
* <p>
* The following features are supported:
* <ul>
- * <li>{@link org.eclipse.papyrus.facademapping.StereotypedMapping#getAppliedStereotypes <em>Applied Stereotypes</em>}</li>
- * <li>{@link org.eclipse.papyrus.facademapping.StereotypedMapping#getKind <em>Kind</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.StereotypedMapping#getAppliedStereotypes <em>Applied Stereotypes</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.StereotypedMapping#getKind <em>Kind</em>}</li>
* </ul>
* </p>
*
@@ -40,10 +40,10 @@ public interface StereotypedMapping extends Mapping {
* The list contents are of type {@link org.eclipse.emf.ecore.EObject}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Applied Stereotypes</em>' reference list isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Applied Stereotypes</em>' reference list isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Applied Stereotypes</em>' reference list.
* @see org.eclipse.papyrus.facademapping.FacademappingPackage#getStereotypedMapping_AppliedStereotypes()
* @model required="true"
@@ -56,10 +56,10 @@ public interface StereotypedMapping extends Mapping {
* The literals are from the enumeration {@link org.eclipse.papyrus.facademapping.ExtensionDefinitionKind}.
* <!-- begin-user-doc -->
* <p>
- * If the meaning of the '<em>Kind</em>' attribute isn't clear,
- * there really should be more of a description here...
+ * If the meaning of the '<em>Kind</em>' attribute isn't clear, there really should be more of a description here...
* </p>
* <!-- end-user-doc -->
+ *
* @return the value of the '<em>Kind</em>' attribute.
* @see org.eclipse.papyrus.facademapping.ExtensionDefinitionKind
* @see #setKind(ExtensionDefinitionKind)
@@ -73,7 +73,9 @@ public interface StereotypedMapping extends Mapping {
* Sets the value of the '{@link org.eclipse.papyrus.facademapping.StereotypedMapping#getKind <em>Kind</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param value the new value of the '<em>Kind</em>' attribute.
+ *
+ * @param value
+ * the new value of the '<em>Kind</em>' attribute.
* @see org.eclipse.papyrus.facademapping.ExtensionDefinitionKind
* @see #getKind()
* @generated
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacadeMapppingImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacadeMapppingImpl.java
index a2c1c64665f..a9bee12a80d 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacadeMapppingImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacadeMapppingImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -38,7 +38,7 @@ import org.eclipse.papyrus.facademapping.Mapping;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facademapping.impl.FacadeMapppingImpl#getMappings <em>Mappings</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.impl.FacadeMapppingImpl#getMappings <em>Mappings</em>}</li>
* </ul>
* </p>
*
@@ -49,6 +49,7 @@ public class FacadeMapppingImpl extends MinimalEObjectImpl.Container implements
* The cached value of the '{@link #getMappings() <em>Mappings</em>}' containment reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getMappings()
* @generated
* @ordered
@@ -58,6 +59,7 @@ public class FacadeMapppingImpl extends MinimalEObjectImpl.Container implements
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacadeMapppingImpl() {
@@ -67,6 +69,7 @@ public class FacadeMapppingImpl extends MinimalEObjectImpl.Container implements
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -77,8 +80,10 @@ public class FacadeMapppingImpl extends MinimalEObjectImpl.Container implements
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<Mapping> getMappings() {
if (mappings == null) {
mappings = new EObjectContainmentEList<Mapping>(Mapping.class, this, FacademappingPackage.FACADE_MAPPPING__MAPPINGS);
@@ -89,13 +94,14 @@ public class FacadeMapppingImpl extends MinimalEObjectImpl.Container implements
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) {
switch (featureID) {
- case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
- return ((InternalEList<?>)getMappings()).basicRemove(otherEnd, msgs);
+ case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
+ return ((InternalEList<?>) getMappings()).basicRemove(otherEnd, msgs);
}
return super.eInverseRemove(otherEnd, featureID, msgs);
}
@@ -103,13 +109,14 @@ public class FacadeMapppingImpl extends MinimalEObjectImpl.Container implements
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
- return getMappings();
+ case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
+ return getMappings();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -117,16 +124,17 @@ public class FacadeMapppingImpl extends MinimalEObjectImpl.Container implements
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
- getMappings().clear();
- getMappings().addAll((Collection<? extends Mapping>)newValue);
- return;
+ case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
+ getMappings().clear();
+ getMappings().addAll((Collection<? extends Mapping>) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -134,14 +142,15 @@ public class FacadeMapppingImpl extends MinimalEObjectImpl.Container implements
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
- getMappings().clear();
- return;
+ case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
+ getMappings().clear();
+ return;
}
super.eUnset(featureID);
}
@@ -149,15 +158,16 @@ public class FacadeMapppingImpl extends MinimalEObjectImpl.Container implements
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
- return mappings != null && !mappings.isEmpty();
+ case FacademappingPackage.FACADE_MAPPPING__MAPPINGS:
+ return mappings != null && !mappings.isEmpty();
}
return super.eIsSet(featureID);
}
-} //FacadeMapppingImpl
+} // FacadeMapppingImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingFactoryImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingFactoryImpl.java
index fac2ff51410..911d457a5eb 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingFactoryImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingFactoryImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -28,6 +28,7 @@ import org.eclipse.papyrus.facademapping.*;
* <!-- begin-user-doc -->
* An implementation of the model <b>Factory</b>.
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacademappingFactoryImpl extends EFactoryImpl implements FacademappingFactory {
@@ -35,16 +36,16 @@ public class FacademappingFactoryImpl extends EFactoryImpl implements Facademapp
* Creates the default factory implementation.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public static FacademappingFactory init() {
try {
- FacademappingFactory theFacademappingFactory = (FacademappingFactory)EPackage.Registry.INSTANCE.getEFactory(FacademappingPackage.eNS_URI);
+ FacademappingFactory theFacademappingFactory = (FacademappingFactory) EPackage.Registry.INSTANCE.getEFactory(FacademappingPackage.eNS_URI);
if (theFacademappingFactory != null) {
return theFacademappingFactory;
}
- }
- catch (Exception exception) {
+ } catch (Exception exception) {
EcorePlugin.INSTANCE.log(exception);
}
return new FacademappingFactoryImpl();
@@ -54,6 +55,7 @@ public class FacademappingFactoryImpl extends EFactoryImpl implements Facademapp
* Creates an instance of the factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingFactoryImpl() {
@@ -63,54 +65,62 @@ public class FacademappingFactoryImpl extends EFactoryImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public EObject create(EClass eClass) {
switch (eClass.getClassifierID()) {
- case FacademappingPackage.MAPPING: return createMapping();
- case FacademappingPackage.STEREOTYPED_MAPPING: return createStereotypedMapping();
- case FacademappingPackage.FACADE_MAPPPING: return createFacadeMappping();
- default:
- throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
+ case FacademappingPackage.MAPPING:
+ return createMapping();
+ case FacademappingPackage.STEREOTYPED_MAPPING:
+ return createStereotypedMapping();
+ case FacademappingPackage.FACADE_MAPPPING:
+ return createFacadeMappping();
+ default:
+ throw new IllegalArgumentException("The class '" + eClass.getName() + "' is not a valid classifier");
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object createFromString(EDataType eDataType, String initialValue) {
switch (eDataType.getClassifierID()) {
- case FacademappingPackage.EXTENSION_DEFINITION_KIND:
- return createExtensionDefinitionKindFromString(eDataType, initialValue);
- default:
- throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
+ case FacademappingPackage.EXTENSION_DEFINITION_KIND:
+ return createExtensionDefinitionKindFromString(eDataType, initialValue);
+ default:
+ throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public String convertToString(EDataType eDataType, Object instanceValue) {
switch (eDataType.getClassifierID()) {
- case FacademappingPackage.EXTENSION_DEFINITION_KIND:
- return convertExtensionDefinitionKindToString(eDataType, instanceValue);
- default:
- throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
+ case FacademappingPackage.EXTENSION_DEFINITION_KIND:
+ return convertExtensionDefinitionKindToString(eDataType, instanceValue);
+ default:
+ throw new IllegalArgumentException("The datatype '" + eDataType.getName() + "' is not a valid classifier");
}
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public Mapping createMapping() {
MappingImpl mapping = new MappingImpl();
return mapping;
@@ -119,8 +129,10 @@ public class FacademappingFactoryImpl extends EFactoryImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public StereotypedMapping createStereotypedMapping() {
StereotypedMappingImpl stereotypedMapping = new StereotypedMappingImpl();
return stereotypedMapping;
@@ -129,8 +141,10 @@ public class FacademappingFactoryImpl extends EFactoryImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public FacadeMappping createFacadeMappping() {
FacadeMapppingImpl facadeMappping = new FacadeMapppingImpl();
return facadeMappping;
@@ -139,17 +153,21 @@ public class FacademappingFactoryImpl extends EFactoryImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public ExtensionDefinitionKind createExtensionDefinitionKindFromString(EDataType eDataType, String initialValue) {
ExtensionDefinitionKind result = ExtensionDefinitionKind.get(initialValue);
- if (result == null) throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'");
+ if (result == null) {
+ throw new IllegalArgumentException("The value '" + initialValue + "' is not a valid enumerator of '" + eDataType.getName() + "'");
+ }
return result;
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public String convertExtensionDefinitionKindToString(EDataType eDataType, Object instanceValue) {
@@ -159,15 +177,18 @@ public class FacademappingFactoryImpl extends EFactoryImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public FacademappingPackage getFacademappingPackage() {
- return (FacademappingPackage)getEPackage();
+ return (FacademappingPackage) getEPackage();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @deprecated
* @generated
*/
@@ -176,4 +197,4 @@ public class FacademappingFactoryImpl extends EFactoryImpl implements Facademapp
return FacademappingPackage.eINSTANCE;
}
-} //FacademappingFactoryImpl
+} // FacademappingFactoryImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingPackageImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingPackageImpl.java
index 4b9aadff35a..9894234d2b0 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingPackageImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/FacademappingPackageImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -32,12 +32,14 @@ import org.eclipse.papyrus.facademapping.StereotypedMapping;
* <!-- begin-user-doc -->
* An implementation of the model <b>Package</b>.
* <!-- end-user-doc -->
+ *
* @generated
*/
public class FacademappingPackageImpl extends EPackageImpl implements FacademappingPackage {
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass mappingEClass = null;
@@ -45,6 +47,7 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass stereotypedMappingEClass = null;
@@ -52,6 +55,7 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EClass facadeMapppingEClass = null;
@@ -59,20 +63,17 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private EEnum extensionDefinitionKindEEnum = null;
/**
- * Creates an instance of the model <b>Package</b>, registered with
- * {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
+ * Creates an instance of the model <b>Package</b>, registered with {@link org.eclipse.emf.ecore.EPackage.Registry EPackage.Registry} by the package
* package URI value.
- * <p>Note: the correct way to create the package is via the static
- * factory method {@link #init init()}, which also performs
- * initialization of the package, or returns the registered package,
- * if one already exists.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
+ * <p>
+ * Note: the correct way to create the package is via the static factory method {@link #init init()}, which also performs initialization of the package, or returns the registered package, if one already exists. <!-- begin-user-doc --> <!-- end-user-doc -->
+ *
* @see org.eclipse.emf.ecore.EPackage.Registry
* @see org.eclipse.papyrus.facademapping.FacademappingPackage#eNS_URI
* @see #init()
@@ -85,27 +86,30 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private static boolean isInited = false;
/**
* Creates, registers, and initializes the <b>Package</b> for this model, and for any others upon which it depends.
+ *
+ * <p>
+ * This method is used to initialize {@link FacademappingPackage#eINSTANCE} when that field is accessed. Clients should not invoke it directly. Instead, they should simply access that field to obtain the package. <!-- begin-user-doc --> <!-- end-user-doc
+ * -->
*
- * <p>This method is used to initialize {@link FacademappingPackage#eINSTANCE} when that field is accessed.
- * Clients should not invoke it directly. Instead, they should simply access that field to obtain the package.
- * <!-- begin-user-doc -->
- * <!-- end-user-doc -->
* @see #eNS_URI
* @see #createPackageContents()
* @see #initializePackageContents()
* @generated
*/
public static FacademappingPackage init() {
- if (isInited) return (FacademappingPackage)EPackage.Registry.INSTANCE.getEPackage(FacademappingPackage.eNS_URI);
+ if (isInited) {
+ return (FacademappingPackage) EPackage.Registry.INSTANCE.getEPackage(FacademappingPackage.eNS_URI);
+ }
// Obtain or create and register package
- FacademappingPackageImpl theFacademappingPackage = (FacademappingPackageImpl)(EPackage.Registry.INSTANCE.get(eNS_URI) instanceof FacademappingPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new FacademappingPackageImpl());
+ FacademappingPackageImpl theFacademappingPackage = (FacademappingPackageImpl) (EPackage.Registry.INSTANCE.get(eNS_URI) instanceof FacademappingPackageImpl ? EPackage.Registry.INSTANCE.get(eNS_URI) : new FacademappingPackageImpl());
isInited = true;
@@ -118,7 +122,7 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
// Mark meta-data to indicate it can't be changed
theFacademappingPackage.freeze();
-
+
// Update the registry and return the package
EPackage.Registry.INSTANCE.put(FacademappingPackage.eNS_URI, theFacademappingPackage);
return theFacademappingPackage;
@@ -127,8 +131,10 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getMapping() {
return mappingEClass;
}
@@ -136,26 +142,32 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getMapping_UmlElement() {
- return (EReference)mappingEClass.getEStructuralFeatures().get(0);
+ return (EReference) mappingEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getMapping_SpecificDomainElement() {
- return (EReference)mappingEClass.getEStructuralFeatures().get(1);
+ return (EReference) mappingEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getStereotypedMapping() {
return stereotypedMappingEClass;
}
@@ -163,26 +175,32 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getStereotypedMapping_AppliedStereotypes() {
- return (EReference)stereotypedMappingEClass.getEStructuralFeatures().get(0);
+ return (EReference) stereotypedMappingEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EAttribute getStereotypedMapping_Kind() {
- return (EAttribute)stereotypedMappingEClass.getEStructuralFeatures().get(1);
+ return (EAttribute) stereotypedMappingEClass.getEStructuralFeatures().get(1);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EClass getFacadeMappping() {
return facadeMapppingEClass;
}
@@ -190,17 +208,21 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EReference getFacadeMappping_Mappings() {
- return (EReference)facadeMapppingEClass.getEStructuralFeatures().get(0);
+ return (EReference) facadeMapppingEClass.getEStructuralFeatures().get(0);
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EEnum getExtensionDefinitionKind() {
return extensionDefinitionKindEEnum;
}
@@ -208,28 +230,34 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public FacademappingFactory getFacademappingFactory() {
- return (FacademappingFactory)getEFactoryInstance();
+ return (FacademappingFactory) getEFactoryInstance();
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private boolean isCreated = false;
/**
- * Creates the meta-model objects for the package. This method is
+ * Creates the meta-model objects for the package. This method is
* guarded to have no affect on any invocation but its first.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void createPackageContents() {
- if (isCreated) return;
+ if (isCreated) {
+ return;
+ }
isCreated = true;
// Create classes and their features
@@ -251,19 +279,23 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
private boolean isInitialized = false;
/**
- * Complete the initialization of the package and its meta-model. This
+ * Complete the initialization of the package and its meta-model. This
* method is guarded to have no affect on any invocation but its first.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public void initializePackageContents() {
- if (isInitialized) return;
+ if (isInitialized) {
+ return;
+ }
isInitialized = true;
// Initialize package
@@ -281,10 +313,12 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
// Initialize classes, features, and operations; add parameters
initEClass(mappingEClass, Mapping.class, "Mapping", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
initEReference(getMapping_UmlElement(), ecorePackage.getEObject(), null, "umlElement", null, 1, 1, Mapping.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
- initEReference(getMapping_SpecificDomainElement(), ecorePackage.getEObject(), null, "specificDomainElement", null, 1, 1, Mapping.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getMapping_SpecificDomainElement(), ecorePackage.getEObject(), null, "specificDomainElement", null, 1, 1, Mapping.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE,
+ !IS_DERIVED, IS_ORDERED);
initEClass(stereotypedMappingEClass, StereotypedMapping.class, "StereotypedMapping", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
- initEReference(getStereotypedMapping_AppliedStereotypes(), ecorePackage.getEObject(), null, "appliedStereotypes", null, 1, -1, StereotypedMapping.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
+ initEReference(getStereotypedMapping_AppliedStereotypes(), ecorePackage.getEObject(), null, "appliedStereotypes", null, 1, -1, StereotypedMapping.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE,
+ IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEAttribute(getStereotypedMapping_Kind(), this.getExtensionDefinitionKind(), "kind", null, 0, 1, StereotypedMapping.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED);
initEClass(facadeMapppingEClass, FacadeMappping.class, "FacadeMappping", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS);
@@ -301,4 +335,4 @@ public class FacademappingPackageImpl extends EPackageImpl implements Facademapp
createResource(eNS_URI);
}
-} //FacademappingPackageImpl
+} // FacademappingPackageImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/MappingImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/MappingImpl.java
index 2b04d97253e..2473bd0fe00 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/MappingImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/MappingImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -32,8 +32,8 @@ import org.eclipse.papyrus.facademapping.Mapping;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facademapping.impl.MappingImpl#getUmlElement <em>Uml Element</em>}</li>
- * <li>{@link org.eclipse.papyrus.facademapping.impl.MappingImpl#getSpecificDomainElement <em>Specific Domain Element</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.impl.MappingImpl#getUmlElement <em>Uml Element</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.impl.MappingImpl#getSpecificDomainElement <em>Specific Domain Element</em>}</li>
* </ul>
* </p>
*
@@ -44,6 +44,7 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
* The cached value of the '{@link #getUmlElement() <em>Uml Element</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getUmlElement()
* @generated
* @ordered
@@ -54,6 +55,7 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
* The cached value of the '{@link #getSpecificDomainElement() <em>Specific Domain Element</em>}' reference.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getSpecificDomainElement()
* @generated
* @ordered
@@ -63,6 +65,7 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected MappingImpl() {
@@ -72,6 +75,7 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -82,15 +86,18 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EObject getUmlElement() {
if (umlElement != null && umlElement.eIsProxy()) {
- InternalEObject oldUmlElement = (InternalEObject)umlElement;
+ InternalEObject oldUmlElement = (InternalEObject) umlElement;
umlElement = eResolveProxy(oldUmlElement);
if (umlElement != oldUmlElement) {
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.RESOLVE, FacademappingPackage.MAPPING__UML_ELEMENT, oldUmlElement, umlElement));
+ }
}
}
return umlElement;
@@ -99,6 +106,7 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public EObject basicGetUmlElement() {
@@ -108,27 +116,33 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setUmlElement(EObject newUmlElement) {
EObject oldUmlElement = umlElement;
umlElement = newUmlElement;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, FacademappingPackage.MAPPING__UML_ELEMENT, oldUmlElement, umlElement));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EObject getSpecificDomainElement() {
if (specificDomainElement != null && specificDomainElement.eIsProxy()) {
- InternalEObject oldSpecificDomainElement = (InternalEObject)specificDomainElement;
+ InternalEObject oldSpecificDomainElement = (InternalEObject) specificDomainElement;
specificDomainElement = eResolveProxy(oldSpecificDomainElement);
if (specificDomainElement != oldSpecificDomainElement) {
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.RESOLVE, FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT, oldSpecificDomainElement, specificDomainElement));
+ }
}
}
return specificDomainElement;
@@ -137,6 +151,7 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public EObject basicGetSpecificDomainElement() {
@@ -146,29 +161,37 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setSpecificDomainElement(EObject newSpecificDomainElement) {
EObject oldSpecificDomainElement = specificDomainElement;
specificDomainElement = newSpecificDomainElement;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT, oldSpecificDomainElement, specificDomainElement));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case FacademappingPackage.MAPPING__UML_ELEMENT:
- if (resolve) return getUmlElement();
- return basicGetUmlElement();
- case FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT:
- if (resolve) return getSpecificDomainElement();
- return basicGetSpecificDomainElement();
+ case FacademappingPackage.MAPPING__UML_ELEMENT:
+ if (resolve) {
+ return getUmlElement();
+ }
+ return basicGetUmlElement();
+ case FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT:
+ if (resolve) {
+ return getSpecificDomainElement();
+ }
+ return basicGetSpecificDomainElement();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -176,17 +199,18 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case FacademappingPackage.MAPPING__UML_ELEMENT:
- setUmlElement((EObject)newValue);
- return;
- case FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT:
- setSpecificDomainElement((EObject)newValue);
- return;
+ case FacademappingPackage.MAPPING__UML_ELEMENT:
+ setUmlElement((EObject) newValue);
+ return;
+ case FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT:
+ setSpecificDomainElement((EObject) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -194,17 +218,18 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case FacademappingPackage.MAPPING__UML_ELEMENT:
- setUmlElement((EObject)null);
- return;
- case FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT:
- setSpecificDomainElement((EObject)null);
- return;
+ case FacademappingPackage.MAPPING__UML_ELEMENT:
+ setUmlElement((EObject) null);
+ return;
+ case FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT:
+ setSpecificDomainElement((EObject) null);
+ return;
}
super.eUnset(featureID);
}
@@ -212,17 +237,18 @@ public class MappingImpl extends MinimalEObjectImpl.Container implements Mapping
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case FacademappingPackage.MAPPING__UML_ELEMENT:
- return umlElement != null;
- case FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT:
- return specificDomainElement != null;
+ case FacademappingPackage.MAPPING__UML_ELEMENT:
+ return umlElement != null;
+ case FacademappingPackage.MAPPING__SPECIFIC_DOMAIN_ELEMENT:
+ return specificDomainElement != null;
}
return super.eIsSet(featureID);
}
-} //MappingImpl
+} // MappingImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/StereotypedMappingImpl.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/StereotypedMappingImpl.java
index 91cf2fad01a..0d5ceae421d 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/StereotypedMappingImpl.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/impl/StereotypedMappingImpl.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -37,8 +37,8 @@ import org.eclipse.papyrus.facademapping.StereotypedMapping;
* <p>
* The following features are implemented:
* <ul>
- * <li>{@link org.eclipse.papyrus.facademapping.impl.StereotypedMappingImpl#getAppliedStereotypes <em>Applied Stereotypes</em>}</li>
- * <li>{@link org.eclipse.papyrus.facademapping.impl.StereotypedMappingImpl#getKind <em>Kind</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.impl.StereotypedMappingImpl#getAppliedStereotypes <em>Applied Stereotypes</em>}</li>
+ * <li>{@link org.eclipse.papyrus.facademapping.impl.StereotypedMappingImpl#getKind <em>Kind</em>}</li>
* </ul>
* </p>
*
@@ -49,6 +49,7 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
* The cached value of the '{@link #getAppliedStereotypes() <em>Applied Stereotypes</em>}' reference list.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getAppliedStereotypes()
* @generated
* @ordered
@@ -59,6 +60,7 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
* The default value of the '{@link #getKind() <em>Kind</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getKind()
* @generated
* @ordered
@@ -69,6 +71,7 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
* The cached value of the '{@link #getKind() <em>Kind</em>}' attribute.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @see #getKind()
* @generated
* @ordered
@@ -78,6 +81,7 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected StereotypedMappingImpl() {
@@ -87,6 +91,7 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
@@ -97,8 +102,10 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public EList<EObject> getAppliedStereotypes() {
if (appliedStereotypes == null) {
appliedStereotypes = new EObjectResolvingEList<EObject>(EObject.class, this, FacademappingPackage.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES);
@@ -109,8 +116,10 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public ExtensionDefinitionKind getKind() {
return kind;
}
@@ -118,27 +127,31 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
+ @Override
public void setKind(ExtensionDefinitionKind newKind) {
ExtensionDefinitionKind oldKind = kind;
kind = newKind == null ? KIND_EDEFAULT : newKind;
- if (eNotificationRequired())
+ if (eNotificationRequired()) {
eNotify(new ENotificationImpl(this, Notification.SET, FacademappingPackage.STEREOTYPED_MAPPING__KIND, oldKind, kind));
+ }
}
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public Object eGet(int featureID, boolean resolve, boolean coreType) {
switch (featureID) {
- case FacademappingPackage.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES:
- return getAppliedStereotypes();
- case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
- return getKind();
+ case FacademappingPackage.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES:
+ return getAppliedStereotypes();
+ case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
+ return getKind();
}
return super.eGet(featureID, resolve, coreType);
}
@@ -146,19 +159,20 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@SuppressWarnings("unchecked")
@Override
public void eSet(int featureID, Object newValue) {
switch (featureID) {
- case FacademappingPackage.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES:
- getAppliedStereotypes().clear();
- getAppliedStereotypes().addAll((Collection<? extends EObject>)newValue);
- return;
- case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
- setKind((ExtensionDefinitionKind)newValue);
- return;
+ case FacademappingPackage.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES:
+ getAppliedStereotypes().clear();
+ getAppliedStereotypes().addAll((Collection<? extends EObject>) newValue);
+ return;
+ case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
+ setKind((ExtensionDefinitionKind) newValue);
+ return;
}
super.eSet(featureID, newValue);
}
@@ -166,17 +180,18 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public void eUnset(int featureID) {
switch (featureID) {
- case FacademappingPackage.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES:
- getAppliedStereotypes().clear();
- return;
- case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
- setKind(KIND_EDEFAULT);
- return;
+ case FacademappingPackage.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES:
+ getAppliedStereotypes().clear();
+ return;
+ case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
+ setKind(KIND_EDEFAULT);
+ return;
}
super.eUnset(featureID);
}
@@ -184,15 +199,16 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
/**
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
@Override
public boolean eIsSet(int featureID) {
switch (featureID) {
- case FacademappingPackage.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES:
- return appliedStereotypes != null && !appliedStereotypes.isEmpty();
- case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
- return kind != KIND_EDEFAULT;
+ case FacademappingPackage.STEREOTYPED_MAPPING__APPLIED_STEREOTYPES:
+ return appliedStereotypes != null && !appliedStereotypes.isEmpty();
+ case FacademappingPackage.STEREOTYPED_MAPPING__KIND:
+ return kind != KIND_EDEFAULT;
}
return super.eIsSet(featureID);
}
@@ -200,11 +216,14 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
/**
* <!-- 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(" (kind: ");
@@ -213,4 +232,4 @@ public class StereotypedMappingImpl extends MappingImpl implements StereotypedMa
return result.toString();
}
-} //StereotypedMappingImpl
+} // StereotypedMappingImpl
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingAdapterFactory.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingAdapterFactory.java
index c7668725040..6341e3b371b 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingAdapterFactory.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingAdapterFactory.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -27,6 +27,7 @@ import org.eclipse.papyrus.facademapping.*;
* The <b>Adapter Factory</b> for the model.
* It provides an adapter <code>createXXX</code> method for each class of the model.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.FacademappingPackage
* @generated
*/
@@ -35,6 +36,7 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
* The cached model package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected static FacademappingPackage modelPackage;
@@ -43,6 +45,7 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
* Creates an instance of the adapter factory.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingAdapterFactory() {
@@ -56,6 +59,7 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
* <!-- begin-user-doc -->
* This implementation returns <code>true</code> if the object is either the model's package or is an instance object of the model.
* <!-- end-user-doc -->
+ *
* @return whether this factory is applicable for the type of the object.
* @generated
*/
@@ -65,7 +69,7 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
return true;
}
if (object instanceof EObject) {
- return ((EObject)object).eClass().getEPackage() == modelPackage;
+ return ((EObject) object).eClass().getEPackage() == modelPackage;
}
return false;
}
@@ -74,39 +78,45 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
* The switch that delegates to the <code>createXXX</code> methods.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected FacademappingSwitch<Adapter> modelSwitch =
- new FacademappingSwitch<Adapter>() {
- @Override
- public Adapter caseMapping(Mapping object) {
- return createMappingAdapter();
- }
- @Override
- public Adapter caseStereotypedMapping(StereotypedMapping object) {
- return createStereotypedMappingAdapter();
- }
- @Override
- public Adapter caseFacadeMappping(FacadeMappping object) {
- return createFacadeMapppingAdapter();
- }
- @Override
- public Adapter defaultCase(EObject object) {
- return createEObjectAdapter();
- }
- };
+ new FacademappingSwitch<Adapter>() {
+ @Override
+ public Adapter caseMapping(Mapping object) {
+ return createMappingAdapter();
+ }
+
+ @Override
+ public Adapter caseStereotypedMapping(StereotypedMapping object) {
+ return createStereotypedMappingAdapter();
+ }
+
+ @Override
+ public Adapter caseFacadeMappping(FacadeMappping object) {
+ return createFacadeMapppingAdapter();
+ }
+
+ @Override
+ public Adapter defaultCase(EObject object) {
+ return createEObjectAdapter();
+ }
+ };
/**
* Creates an adapter for the <code>target</code>.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
- * @param target the object to adapt.
+ *
+ * @param target
+ * the object to adapt.
* @return the adapter for the <code>target</code>.
* @generated
*/
@Override
public Adapter createAdapter(Notifier target) {
- return modelSwitch.doSwitch((EObject)target);
+ return modelSwitch.doSwitch((EObject) target);
}
@@ -116,6 +126,7 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facademapping.Mapping
* @generated
@@ -130,6 +141,7 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facademapping.StereotypedMapping
* @generated
@@ -144,6 +156,7 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
* This default implementation returns null so that we can easily ignore cases;
* it's useful to ignore a case when inheritance will catch all the cases anyway.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @see org.eclipse.papyrus.facademapping.FacadeMappping
* @generated
@@ -157,6 +170,7 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
* <!-- begin-user-doc -->
* This default implementation returns null.
* <!-- end-user-doc -->
+ *
* @return the new adapter.
* @generated
*/
@@ -164,4 +178,4 @@ public class FacademappingAdapterFactory extends AdapterFactoryImpl {
return null;
}
-} //FacademappingAdapterFactory
+} // FacademappingAdapterFactory
diff --git a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingSwitch.java b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingSwitch.java
index 4b9dc80c100..ceea045c209 100644
--- a/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingSwitch.java
+++ b/extraplugins/facade/org.eclipse.papyrus.facade/src/org/eclipse/papyrus/facademapping/util/FacademappingSwitch.java
@@ -1,7 +1,7 @@
/*****************************************************************************
* Copyright (c) 2013 CEA LIST.
*
- *
+ *
* 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
@@ -23,13 +23,13 @@ import org.eclipse.papyrus.facademapping.*;
/**
* <!-- begin-user-doc -->
* The <b>Switch</b> for the model's inheritance hierarchy.
- * It supports the call {@link #doSwitch(EObject) doSwitch(object)}
- * to invoke the <code>caseXXX</code> method for each class of the model,
+ * It supports the call {@link #doSwitch(EObject) doSwitch(object)} to invoke the <code>caseXXX</code> method for each class of the model,
* starting with the actual class of the object
* and proceeding up the inheritance hierarchy
* until a non-null result is returned,
* which is the result of the switch.
* <!-- end-user-doc -->
+ *
* @see org.eclipse.papyrus.facademapping.FacademappingPackage
* @generated
*/
@@ -38,6 +38,7 @@ public class FacademappingSwitch<T> extends Switch<T> {
* The cached model package
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
protected static FacademappingPackage modelPackage;
@@ -46,6 +47,7 @@ public class FacademappingSwitch<T> extends Switch<T> {
* Creates an instance of the switch.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @generated
*/
public FacademappingSwitch() {
@@ -58,6 +60,7 @@ public class FacademappingSwitch<T> extends Switch<T> {
* Checks whether this is a switch for the given package.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @parameter ePackage the package in question.
* @return whether this is a switch for the given package.
* @generated
@@ -71,32 +74,42 @@ public class FacademappingSwitch<T> extends Switch<T> {
* Calls <code>caseXXX</code> for each class of the model until one returns a non null result; it yields that result.
* <!-- begin-user-doc -->
* <!-- end-user-doc -->
+ *
* @return the first non-null result returned by a <code>caseXXX</code> call.
* @generated
*/
@Override
protected T doSwitch(int classifierID, EObject theEObject) {
switch (classifierID) {
- case FacademappingPackage.MAPPING: {
- Mapping mapping = (Mapping)theEObject;
- T result = caseMapping(mapping);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ case FacademappingPackage.MAPPING: {
+ Mapping mapping = (Mapping) theEObject;
+ T result = caseMapping(mapping);
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- case FacademappingPackage.STEREOTYPED_MAPPING: {
- StereotypedMapping stereotypedMapping = (StereotypedMapping)theEObject;
- T result = caseStereotypedMapping(stereotypedMapping);
- if (result == null) result = caseMapping(stereotypedMapping);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ return result;
+ }
+ case FacademappingPackage.STEREOTYPED_MAPPING: {
+ StereotypedMapping stereotypedMapping = (StereotypedMapping) theEObject;
+ T result = caseStereotypedMapping(stereotypedMapping);
+ if (result == null) {
+ result = caseMapping(stereotypedMapping);
}
- case FacademappingPackage.FACADE_MAPPPING: {
- FacadeMappping facadeMappping = (FacadeMappping)theEObject;
- T result = caseFacadeMappping(facadeMappping);
- if (result == null) result = defaultCase(theEObject);
- return result;
+ if (result == null) {
+ result = defaultCase(theEObject);
}
- default: return defaultCase(theEObject);
+ return result;
+ }
+ case FacademappingPackage.FACADE_MAPPPING: {
+ FacadeMappping facadeMappping = (FacadeMappping) theEObject;
+ T result = caseFacadeMappping(facadeMappping);
+ if (result == null) {
+ result = defaultCase(theEObject);
+ }
+ return result;
+ }
+ default:
+ return defaultCase(theEObject);
}
}
@@ -106,7 +119,9 @@ public class FacademappingSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Mapping</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -121,7 +136,9 @@ public class FacademappingSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Stereotyped Mapping</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -136,7 +153,9 @@ public class FacademappingSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>Facade Mappping</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject) doSwitch(EObject)
* @generated
@@ -151,7 +170,9 @@ public class FacademappingSwitch<T> extends Switch<T> {
* This implementation returns null;
* returning a non-null result will terminate the switch, but this is the last case anyway.
* <!-- end-user-doc -->
- * @param object the target of the switch.
+ *
+ * @param object
+ * the target of the switch.
* @return the result of interpreting the object as an instance of '<em>EObject</em>'.
* @see #doSwitch(org.eclipse.emf.ecore.EObject)
* @generated
@@ -161,4 +182,4 @@ public class FacademappingSwitch<T> extends Switch<T> {
return null;
}
-} //FacademappingSwitch
+} // FacademappingSwitch

Back to the top