diff --git a/bundles/ru.arsysop.loft.cast.cgm.ecore/model/cgm.ecore b/bundles/ru.arsysop.loft.cast.cgm.ecore/model/cgm.ecore index 05d3da5..00fad89 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.ecore/model/cgm.ecore +++ b/bundles/ru.arsysop.loft.cast.cgm.ecore/model/cgm.ecore @@ -2,15 +2,18 @@ - + - - + eType="#//Options" containment="true"/> + + + defaultValueLiteral=""/> diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/.classpath b/bundles/ru.arsysop.loft.cast.cgm.edit/.classpath new file mode 100644 index 0000000..8dd013a --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/.classpath @@ -0,0 +1,8 @@ + + + + + + + + diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/.project b/bundles/ru.arsysop.loft.cast.cgm.edit/.project new file mode 100644 index 0000000..30bbcd0 --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/.project @@ -0,0 +1,28 @@ + + + ru.arsysop.loft.cast.cgm.edit + + + + + + org.eclipse.jdt.core.javabuilder + + + + + org.eclipse.pde.ManifestBuilder + + + + + org.eclipse.pde.SchemaBuilder + + + + + + org.eclipse.jdt.core.javanature + org.eclipse.pde.PluginNature + + diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.jdt.core.prefs b/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000..aaf10d0 --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,118 @@ +eclipse.preferences.version=1 +org.eclipse.jdt.core.builder.annotationPath.allLocations=disabled +org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=disabled +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull +org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= +org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault +org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary= +org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable +org.eclipse.jdt.core.compiler.annotation.nullable.secondary= +org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.methodParameters=do not generate +org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.8 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve +org.eclipse.jdt.core.compiler.compliance=1.8 +org.eclipse.jdt.core.compiler.debug.lineNumber=generate +org.eclipse.jdt.core.compiler.debug.localVariable=generate +org.eclipse.jdt.core.compiler.debug.sourceFile=generate +org.eclipse.jdt.core.compiler.problem.APILeak=warning +org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info +org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.autoboxing=ignore +org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning +org.eclipse.jdt.core.compiler.problem.deadCode=warning +org.eclipse.jdt.core.compiler.problem.deprecation=warning +org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled +org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled +org.eclipse.jdt.core.compiler.problem.discouragedReference=warning +org.eclipse.jdt.core.compiler.problem.emptyStatement=ignore +org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=ignore +org.eclipse.jdt.core.compiler.problem.fallthroughCase=warning +org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled +org.eclipse.jdt.core.compiler.problem.fieldHiding=warning +org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning +org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning +org.eclipse.jdt.core.compiler.problem.forbiddenReference=error +org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning +org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=disabled +org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning +org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.localVariableHiding=warning +org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning +org.eclipse.jdt.core.compiler.problem.missingDefaultCase=warning +org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled +org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=warning +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled +org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning +org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=ignore +org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning +org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning +org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=error +org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning +org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning +org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error +org.eclipse.jdt.core.compiler.problem.nullReference=warning +org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error +org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning +org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning +org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore +org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning +org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=warning +org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning +org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning +org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning +org.eclipse.jdt.core.compiler.problem.redundantNullCheck=warning +org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=ignore +org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore +org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore +org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore +org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning +org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled +org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled +org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info +org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=disabled +org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore +org.eclipse.jdt.core.compiler.problem.terminalDeprecation=warning +org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning +org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=enabled +org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning +org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning +org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore +org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning +org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentType=warning +org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentTypeStrict=disabled +org.eclipse.jdt.core.compiler.problem.unlikelyEqualsArgumentType=info +org.eclipse.jdt.core.compiler.problem.unnecessaryElse=ignore +org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning +org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore +org.eclipse.jdt.core.compiler.problem.unstableAutoModuleName=warning +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled +org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore +org.eclipse.jdt.core.compiler.problem.unusedImport=warning +org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLocal=warning +org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameter=ignore +org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled +org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning +org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=warning +org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning +org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning +org.eclipse.jdt.core.compiler.release=enabled +org.eclipse.jdt.core.compiler.source=1.8 diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.jdt.ui.prefs b/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 0000000..15649cf --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,123 @@ +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=false +cleanup.always_use_blocks=true +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.convert_functional_interfaces=false +cleanup.convert_to_enhanced_for_loop=false +cleanup.correct_indentation=false +cleanup.format_source_code=false +cleanup.format_source_code_changes_only=false +cleanup.insert_inferred_type_arguments=false +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=false +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=false +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.organize_imports=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +cleanup.qualify_static_member_accesses_with_declaring_class=true +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.remove_private_constructors=true +cleanup.remove_redundant_modifiers=false +cleanup.remove_redundant_semicolons=false +cleanup.remove_redundant_type_arguments=false +cleanup.remove_trailing_whitespaces=false +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_private_fields=true +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=true +cleanup.remove_unused_private_types=true +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.use_anonymous_class_creation=false +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=false +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=false +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup_profile=org.eclipse.jdt.ui.default.eclipse_clean_up_profile +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_settings_version=16 +org.eclipse.jdt.ui.text.custom_code_templates= +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=false +sp_cleanup.always_use_blocks=true +sp_cleanup.always_use_parentheses_in_expressions=false +sp_cleanup.always_use_this_for_non_static_field_access=false +sp_cleanup.always_use_this_for_non_static_method_access=false +sp_cleanup.convert_functional_interfaces=false +sp_cleanup.convert_to_enhanced_for_loop=false +sp_cleanup.correct_indentation=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=false +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=false +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.organize_imports=true +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.remove_private_constructors=true +sp_cleanup.remove_redundant_modifiers=false +sp_cleanup.remove_redundant_semicolons=false +sp_cleanup.remove_redundant_type_arguments=false +sp_cleanup.remove_trailing_whitespaces=false +sp_cleanup.remove_trailing_whitespaces_all=true +sp_cleanup.remove_trailing_whitespaces_ignore_empty=false +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=false +sp_cleanup.remove_unused_imports=false +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_private_fields=true +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=true +sp_cleanup.remove_unused_private_types=true +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=false +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=false +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.pde.ds.annotations.prefs b/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.pde.ds.annotations.prefs new file mode 100644 index 0000000..73a356b --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.pde.ds.annotations.prefs @@ -0,0 +1,8 @@ +classpath=true +dsVersion=V1_3 +eclipse.preferences.version=1 +enabled=true +generateBundleActivationPolicyLazy=true +path=OSGI-INF +validationErrorLevel=error +validationErrorLevel.missingImplicitUnbindMethod=error diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.pde.prefs b/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.pde.prefs new file mode 100644 index 0000000..47bd5bd --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/.settings/org.eclipse.pde.prefs @@ -0,0 +1,34 @@ +compilers.f.unresolved-features=1 +compilers.f.unresolved-plugins=1 +compilers.incompatible-environment=1 +compilers.p.build=1 +compilers.p.build.bin.includes=1 +compilers.p.build.encodings=2 +compilers.p.build.java.compiler=2 +compilers.p.build.java.compliance=1 +compilers.p.build.missing.output=2 +compilers.p.build.output.library=1 +compilers.p.build.source.library=1 +compilers.p.build.src.includes=1 +compilers.p.deprecated=1 +compilers.p.discouraged-class=1 +compilers.p.internal=1 +compilers.p.missing-packages=2 +compilers.p.missing-version-export-package=2 +compilers.p.missing-version-import-package=2 +compilers.p.missing-version-require-bundle=1 +compilers.p.no-required-att=0 +compilers.p.no.automatic.module=1 +compilers.p.not-externalized-att=0 +compilers.p.service.component.without.lazyactivation=1 +compilers.p.unknown-attribute=1 +compilers.p.unknown-class=1 +compilers.p.unknown-element=1 +compilers.p.unknown-identifier=1 +compilers.p.unknown-resource=1 +compilers.p.unresolved-ex-points=0 +compilers.p.unresolved-import=0 +compilers.s.create-docs=false +compilers.s.doc-folder=doc +compilers.s.open-tags=1 +eclipse.preferences.version=1 diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/META-INF/MANIFEST.MF b/bundles/ru.arsysop.loft.cast.cgm.edit/META-INF/MANIFEST.MF new file mode 100644 index 0000000..5cb35c0 --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/META-INF/MANIFEST.MF @@ -0,0 +1,18 @@ +Manifest-Version: 1.0 +Automatic-Module-Name: ru.arsysop.loft.cast.cgm.edit +Bundle-ManifestVersion: 2 +Bundle-Name: %pluginName +Bundle-SymbolicName: ru.arsysop.loft.cast.cgm.edit;singleton:=true +Bundle-Version: 0.1.0.qualifier +Bundle-ClassPath: . +Bundle-Activator: ru.arsysop.loft.cast.cgm.edit.CgmEditPlugin$Implementation +Bundle-Vendor: %providerName +Bundle-Localization: plugin +Bundle-RequiredExecutionEnvironment: JavaSE-1.8 +Export-Package: ru.arsysop.loft.cast.cgm.edit, + ru.arsysop.loft.cast.cgm.edit.providers +Require-Bundle: org.eclipse.core.runtime;bundle-version="0.0.0", + org.eclipse.emf.ecore.edit;bundle-version="0.0.0", + ru.arsysop.loft.cast.cgm.model;bundle-version="0.1.0";visibility:=reexport, + org.eclipse.emf.edit;visibility:=reexport +Bundle-ActivationPolicy: lazy diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/build.properties b/bundles/ru.arsysop.loft.cast.cgm.edit/build.properties new file mode 100644 index 0000000..f303efd --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/build.properties @@ -0,0 +1,31 @@ +# +############################################################################### +# Copyright (c) 2022 ArSysOp. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 +# +# Contributors: +# ArSysOp - initial API and implementation +############################################################################### + +bin.includes = .,\ + icons/,\ + META-INF/,\ + plugin.xml,\ + plugin.properties +jars.compile.order = . +source.. = src-gen/,\ + src/ +output.. = bin/ diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/icons/full/obj16/.gitkeep b/bundles/ru.arsysop.loft.cast.cgm.edit/icons/full/obj16/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/plugin.properties b/bundles/ru.arsysop.loft.cast.cgm.edit/plugin.properties new file mode 100644 index 0000000..0b833b2 --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/plugin.properties @@ -0,0 +1,101 @@ +############################################################################### +# Copyright (c) 2022 ArSysOp. +# +# Licensed under the Apache License, Version 2.0 (the "License"); +# you may not use this file except in compliance with the License. +# You may obtain a copy of the License at +# +# http://www.apache.org/licenses/LICENSE-2.0 +# +# Unless required by applicable law or agreed to in writing, software +# distributed under the License is distributed on an "AS IS" BASIS, +# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. +# See the License for the specific language governing permissions and +# limitations under the License. +# +# SPDX-License-Identifier: Apache-2.0 +# +# Contributors: +# ArSysOp - initial API and implementation +############################################################################### + +pluginName = ArSysOp LOFT CAST Decl Edit Support +providerName = ArSysOp +Bundle-Name = ArSysOp LOFT CAST Decl Edit Support +Bundle-Vendor = ArSysOp +Bundle-Copyright = Copyright (c) 2022 ArSysOp.\n\ +\n\ +Licensed under the Apache License, Version 2.0 (the "License");\n\ +you may not use this file except in compliance with the License.\n\ +You may obtain a copy of the License at\n\ + http://www.apache.org/licenses/LICENSE-2.0\n\ +Unless required by applicable law or agreed to in writing, software\n\ +distributed under the License is distributed on an "AS IS" BASIS,\n\ +WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n\ +See the License for the specific language governing permissions and\n\ +limitations under the License.\n\ +\n\ +SPDX-License-Identifier: Apache-2.0\n\ +\n +_UI_CreateChild_text = {0} +_UI_CreateChild_text2 = {1} {0} +_UI_CreateChild_text3 = {1} +_UI_CreateChild_tooltip = Create New {0} Under {1} Feature +_UI_CreateChild_description = Create a new child of type {0} for the {1} feature of the selected {2}. +_UI_CreateSibling_description = Create a new sibling of type {0} for the selected {2}, under the {1} feature of their parent. + _UI_PropertyDescriptor_description = The {0} of the {1} + _UI_Synopsis_type = Synopsis +_UI_DefinitionSynopsis_type = Definition Synopsis +_UI_Namespace_type = Namespace +_UI_FunctionDecl_type = Function Decl +_UI_ClassDecl_type = Class Decl +_UI_EnumDecl_type = Enum Decl +_UI_StructDecl_type = Struct Decl +_UI_UnionDecl_type = Union Decl +_UI_FieldDecl_type = Field Decl +_UI_VarDecl_type = Var Decl +_UI_TypedefDecl_type = Typedef Decl +_UI_ParmDecl_type = Parm Decl +_UI_FunctionTemplate_type = Function Template +_UI_ClassTemplate_type = Class Template +_UI_CXXMethod_type = CXX Method +_UI_Constructor_type = Constructor +_UI_Destructor_type = Destructor +_UI_TemplateTypeParameter_type = Template Type Parameter +_UI_Unknown_type = Object + _UI_Unknown_datatype= Value + _UI_Synopsis_name_feature = Name +_UI_Synopsis_part_feature = Part +_UI_Synopsis_definitions_feature = Definitions +_UI_DefinitionSynopsis_id_feature = Id +_UI_DefinitionSynopsis_name_feature = Name +_UI_FunctionDecl_signature_feature = Signature +_UI_FunctionDecl_parameters_feature = Parameters +_UI_ClassDecl_fields_feature = Fields +_UI_ClassDecl_destructor_feature = Destructor +_UI_ClassDecl_constructors_feature = Constructors +_UI_ClassDecl_cxxmethod_feature = Cxxmethod +_UI_ClassTemplate_templatetypeparameter_feature = Templatetypeparameter +_UI_Unknown_feature = Unspecified + +_UI_NamedDecl_type = Named Decl +_UI_TranslationUnitDecl_type = Translation Unit Decl +_UI_NamespaceDecl_type = Namespace Decl +_UI_ClassTemplateDecl_type = Class Template Decl +_UI_NamedDecl_id_feature = Id +_UI_NamedDecl_name_feature = Name +_UI_TranslationUnitDecl_declarations_feature = Declarations +_UI_NamespaceDecl_declarations_feature = Declarations +_UI_ClassTemplateDecl_methods_feature = Methods +_UI_CxxMethodTemplateDecl_type = Cxx Method Template Decl +_UI_CxxMethodTemplateDecl_classTemplate_feature = Class Template +_UI_CompilationSession_type = Compilation Session +_UI_Tool_type = Tool +_UI_Options_type = Options +_UI_Index_type = Index +_UI_CallTree_type = Call Tree +_UI_CompilationSession_tool_feature = Tool +_UI_CompilationSession_options_feature = Options +_UI_CompilationSession_index_feature = Index +_UI_CompilationSession_calls_feature = Calls +_UI_Tool_type_feature = Type diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/plugin.xml b/bundles/ru.arsysop.loft.cast.cgm.edit/plugin.xml new file mode 100644 index 0000000..65810c2 --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/plugin.xml @@ -0,0 +1,64 @@ + + + + + + + + + + + + + + + + + diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/CgmEditPlugin.java b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/CgmEditPlugin.java new file mode 100644 index 0000000..fcd7492 --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/CgmEditPlugin.java @@ -0,0 +1,106 @@ +/** + * Copyright (c) 2022 ArSysOp + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * SPDX-License-Identifier: Apache-2.0 + * Contributors: + * ArSysOp - initial API and implementation + * + */ +package ru.arsysop.loft.cast.cgm.edit; + +import org.eclipse.emf.common.EMFPlugin; + +import org.eclipse.emf.common.util.ResourceLocator; + +/** + * This is the central singleton for the Cgm edit plugin. + * + * + * @generated + */ +public final class CgmEditPlugin extends EMFPlugin { + /** + * Keep track of the singleton. + * + * + * @generated + */ + public static final CgmEditPlugin INSTANCE = new CgmEditPlugin(); + + /** + * Keep track of the singleton. + * + * + * @generated + */ + private static Implementation plugin; + + /** + * Create the instance. + * + * + * @generated + */ + public CgmEditPlugin() { + super + (new ResourceLocator [] { + }); + } + + /** + * Returns the singleton instance of the Eclipse plugin. + * + * + * @return the singleton instance. + * @generated + */ + @Override + public ResourceLocator getPluginResourceLocator() { + return plugin; + } + + /** + * Returns the singleton instance of the Eclipse plugin. + * + * + * @return the singleton instance. + * @generated + */ + public static Implementation getPlugin() { + return plugin; + } + + /** + * The actual implementation of the Eclipse Plugin. + * + * + * @generated + */ + public static class Implementation extends EclipsePlugin { + /** + * Creates an instance. + * + * + * @generated + */ + public Implementation() { + super(); + + // Remember the static instance. + // + plugin = this; + } + } + +} diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/CallTreeItemProvider.java b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/CallTreeItemProvider.java new file mode 100644 index 0000000..5416d6d --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/CallTreeItemProvider.java @@ -0,0 +1,207 @@ +/** + * Copyright (c) 2022 ArSysOp + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * SPDX-License-Identifier: Apache-2.0 + * Contributors: + * ArSysOp - initial API and implementation + * + */ +package ru.arsysop.loft.cast.cgm.edit.providers; + + +import java.util.Collection; +import java.util.List; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.ecore.provider.EcoreEditPlugin; +import org.eclipse.emf.edit.provider.IChildCreationExtender; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IItemStyledLabelProvider; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemProviderAdapter; +import org.eclipse.emf.edit.provider.StyledString; + +/** + * This is the item provider adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.CallTree} object. + * + * + * @generated + */ +public class CallTreeItemProvider + extends ItemProviderAdapter + implements + IEditingDomainItemProvider, + IStructuredItemContentProvider, + ITreeItemContentProvider, + IItemLabelProvider, + IItemPropertySource, + ITableItemLabelProvider, + ITableItemColorProvider, + ITableItemFontProvider, + IItemColorProvider, + IItemFontProvider, + IItemStyledLabelProvider { + /** + * This constructs an instance from a factory and a notifier. + * + * + * @generated + */ + public CallTreeItemProvider(AdapterFactory adapterFactory) { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * + * + * @generated + */ + @Override + public List getPropertyDescriptors(Object object) { + if (itemPropertyDescriptors == null) { + super.getPropertyDescriptors(object); + + } + return itemPropertyDescriptors; + } + + /** + * + * + * @generated + */ + @Override + public boolean hasChildren(Object object) { + return hasChildren(object, true); + } + + /** + * @generated NOT + */ + @Override + public Object getImage(Object object) { + return overlayImage(object, EcoreEditPlugin.INSTANCE.getImage("full/obj16/EObject")); //$NON-NLS-1$ + } + + /** + * This returns getImage(object) for the column index 0 or super.getImage(object) otherwise. + * + * + * @see #getText(Object) + * @see #getColumnText(Object, int) + * @generated + */ + @Override + public Object getColumnImage(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getImage(object) : super.getImage(object); + } + + /** + * + * + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() { + return true; + } + + /** + * This returns the label text for the adapted class. + * + * + * @generated + */ + @Override + public String getText(Object object) { + return ((StyledString)getStyledText(object)).getString(); + } + + /** + * This returns getText(object) for the column index 0 or super.getText(object) otherwise. + * + * + * @see #getImage(Object) + * @see #getColumnImage(Object, int) + * @generated + */ + @Override + public String getColumnText(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getText(object) : super.getText(object); + } + + /** + * This returns the label styled text for the adapted class. + * + * + * @generated + */ + @Override + public Object getStyledText(Object object) { + return new StyledString(getString("_UI_CallTree_type")); //$NON-NLS-1$ + } + + /** + * 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}. + * + * + * @generated + */ + @Override + public void notifyChanged(Notification notification) { + updateChildren(notification); + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * + * + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + + /** + * Return the resource locator for this item provider's resources. + * + * + * @generated + */ + @Override + public ResourceLocator getResourceLocator() { + return ((IChildCreationExtender)adapterFactory).getResourceLocator(); + } + +} diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/CgmItemProviderAdapterFactory.java b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/CgmItemProviderAdapterFactory.java new file mode 100644 index 0000000..4037eb6 --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/CgmItemProviderAdapterFactory.java @@ -0,0 +1,376 @@ +/** + * Copyright (c) 2022 ArSysOp + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * SPDX-License-Identifier: Apache-2.0 + * Contributors: + * ArSysOp - initial API and implementation + * + */ +package ru.arsysop.loft.cast.cgm.edit.providers; + +import java.util.ArrayList; +import java.util.Collection; +import java.util.List; + +import org.eclipse.emf.common.notify.Adapter; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.Notifier; + +import org.eclipse.emf.common.util.ResourceLocator; + +import org.eclipse.emf.edit.domain.EditingDomain; + +import org.eclipse.emf.edit.provider.ChangeNotifier; +import org.eclipse.emf.edit.provider.ChildCreationExtenderManager; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.ComposedAdapterFactory; +import org.eclipse.emf.edit.provider.IChangeNotifier; +import org.eclipse.emf.edit.provider.IChildCreationExtender; +import org.eclipse.emf.edit.provider.IDisposable; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IItemStyledLabelProvider; +import org.eclipse.emf.edit.provider.INotifyChangedListener; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; + +import ru.arsysop.loft.cast.cgm.edit.CgmEditPlugin; + +import ru.arsysop.loft.cast.cgm.model.meta.CgmPackage; + +import ru.arsysop.loft.cast.cgm.model.util.CgmAdapterFactory; + +/** + * This is the factory that is used to provide the interfaces needed to support Viewers. + * The adapters generated by this factory convert EMF adapter notifications into calls to {@link #fireNotifyChanged fireNotifyChanged}. + * The adapters also support Eclipse property sheets. + * Note that most of the adapters are shared among multiple instances. + * + * + * @generated + */ +public class CgmItemProviderAdapterFactory extends CgmAdapterFactory implements ComposeableAdapterFactory, IChangeNotifier, IDisposable, IChildCreationExtender { + /** + * This keeps track of the root adapter factory that delegates to this adapter factory. + * + * + * @generated + */ + protected ComposedAdapterFactory parentAdapterFactory; + + /** + * This is used to implement {@link org.eclipse.emf.edit.provider.IChangeNotifier}. + * + * + * @generated + */ + protected IChangeNotifier changeNotifier = new ChangeNotifier(); + + /** + * This helps manage the child creation extenders. + * + * + * @generated + */ + protected ChildCreationExtenderManager childCreationExtenderManager = new ChildCreationExtenderManager(CgmEditPlugin.INSTANCE, CgmPackage.eNS_URI); + + /** + * This keeps track of all the supported types checked by {@link #isFactoryForType isFactoryForType}. + * + * + * @generated + */ + protected Collection supportedTypes = new ArrayList(); + + /** + * This constructs an instance. + * + * + * @generated + */ + public CgmItemProviderAdapterFactory() { + supportedTypes.add(IEditingDomainItemProvider.class); + supportedTypes.add(IStructuredItemContentProvider.class); + supportedTypes.add(ITreeItemContentProvider.class); + supportedTypes.add(IItemLabelProvider.class); + supportedTypes.add(IItemPropertySource.class); + supportedTypes.add(ITableItemLabelProvider.class); + supportedTypes.add(ITableItemColorProvider.class); + supportedTypes.add(ITableItemFontProvider.class); + supportedTypes.add(IItemColorProvider.class); + supportedTypes.add(IItemFontProvider.class); + supportedTypes.add(IItemStyledLabelProvider.class); + } + + /** + * This keeps track of the one adapter used for all {@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession} instances. + * + * + * @generated + */ + protected CompilationSessionItemProvider compilationSessionItemProvider; + + /** + * This creates an adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession}. + * + * + * @generated + */ + @Override + public Adapter createCompilationSessionAdapter() { + if (compilationSessionItemProvider == null) { + compilationSessionItemProvider = new CompilationSessionItemProvider(this); + } + + return compilationSessionItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link ru.arsysop.loft.cast.cgm.model.api.Tool} instances. + * + * + * @generated + */ + protected ToolItemProvider toolItemProvider; + + /** + * This creates an adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.Tool}. + * + * + * @generated + */ + @Override + public Adapter createToolAdapter() { + if (toolItemProvider == null) { + toolItemProvider = new ToolItemProvider(this); + } + + return toolItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link ru.arsysop.loft.cast.cgm.model.api.Options} instances. + * + * + * @generated + */ + protected OptionsItemProvider optionsItemProvider; + + /** + * This creates an adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.Options}. + * + * + * @generated + */ + @Override + public Adapter createOptionsAdapter() { + if (optionsItemProvider == null) { + optionsItemProvider = new OptionsItemProvider(this); + } + + return optionsItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link ru.arsysop.loft.cast.cgm.model.api.Index} instances. + * + * + * @generated + */ + protected IndexItemProvider indexItemProvider; + + /** + * This creates an adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.Index}. + * + * + * @generated + */ + @Override + public Adapter createIndexAdapter() { + if (indexItemProvider == null) { + indexItemProvider = new IndexItemProvider(this); + } + + return indexItemProvider; + } + + /** + * This keeps track of the one adapter used for all {@link ru.arsysop.loft.cast.cgm.model.api.CallTree} instances. + * + * + * @generated + */ + protected CallTreeItemProvider callTreeItemProvider; + + /** + * This creates an adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.CallTree}. + * + * + * @generated + */ + @Override + public Adapter createCallTreeAdapter() { + if (callTreeItemProvider == null) { + callTreeItemProvider = new CallTreeItemProvider(this); + } + + return callTreeItemProvider; + } + + /** + * This returns the root adapter factory that contains this factory. + * + * + * @generated + */ + @Override + public ComposeableAdapterFactory getRootAdapterFactory() { + return parentAdapterFactory == null ? this : parentAdapterFactory.getRootAdapterFactory(); + } + + /** + * This sets the composed adapter factory that contains this factory. + * + * + * @generated + */ + @Override + public void setParentAdapterFactory(ComposedAdapterFactory parentAdapterFactory) { + this.parentAdapterFactory = parentAdapterFactory; + } + + /** + * + * + * @generated + */ + @Override + public boolean isFactoryForType(Object type) { + return supportedTypes.contains(type) || super.isFactoryForType(type); + } + + /** + * This implementation substitutes the factory itself as the key for the adapter. + * + * + * @generated + */ + @Override + public Adapter adapt(Notifier notifier, Object type) { + return super.adapt(notifier, this); + } + + /** + * + * + * @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))) { + return adapter; + } + } + + return null; + } + + /** + * + * + * @generated + */ + public List getChildCreationExtenders() { + return childCreationExtenderManager.getChildCreationExtenders(); + } + + /** + * + * + * @generated + */ + public Collection getNewChildDescriptors(Object object, EditingDomain editingDomain) { + return childCreationExtenderManager.getNewChildDescriptors(object, editingDomain); + } + + /** + * + * + * @generated + */ + public ResourceLocator getResourceLocator() { + return childCreationExtenderManager; + } + + /** + * This adds a listener. + * + * + * @generated + */ + @Override + public void addListener(INotifyChangedListener notifyChangedListener) { + changeNotifier.addListener(notifyChangedListener); + } + + /** + * This removes a listener. + * + * + * @generated + */ + @Override + public void removeListener(INotifyChangedListener notifyChangedListener) { + changeNotifier.removeListener(notifyChangedListener); + } + + /** + * This delegates to {@link #changeNotifier} and to {@link #parentAdapterFactory}. + * + * + * @generated + */ + @Override + public void fireNotifyChanged(Notification notification) { + changeNotifier.fireNotifyChanged(notification); + + if (parentAdapterFactory != null) { + parentAdapterFactory.fireNotifyChanged(notification); + } + } + + /** + * This disposes all of the item providers created by this factory. + * + * + * @generated + */ + @Override + public void dispose() { + if (compilationSessionItemProvider != null) compilationSessionItemProvider.dispose(); + if (toolItemProvider != null) toolItemProvider.dispose(); + if (optionsItemProvider != null) optionsItemProvider.dispose(); + if (indexItemProvider != null) indexItemProvider.dispose(); + if (callTreeItemProvider != null) callTreeItemProvider.dispose(); + } + +} diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/CompilationSessionItemProvider.java b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/CompilationSessionItemProvider.java new file mode 100644 index 0000000..9ef322a --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/CompilationSessionItemProvider.java @@ -0,0 +1,277 @@ +/** + * Copyright (c) 2022 ArSysOp + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * SPDX-License-Identifier: Apache-2.0 + * Contributors: + * ArSysOp - initial API and implementation + * + */ +package ru.arsysop.loft.cast.cgm.edit.providers; + + +import java.util.Collection; +import java.util.List; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.ecore.EStructuralFeature; +import org.eclipse.emf.ecore.provider.EcoreEditPlugin; +import org.eclipse.emf.edit.provider.IChildCreationExtender; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IItemStyledLabelProvider; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemProviderAdapter; +import org.eclipse.emf.edit.provider.StyledString; + +import org.eclipse.emf.edit.provider.ViewerNotification; +import ru.arsysop.loft.cast.cgm.model.api.CompilationSession; +import ru.arsysop.loft.cast.cgm.model.meta.CgmFactory; +import ru.arsysop.loft.cast.cgm.model.meta.CgmPackage; + +/** + * This is the item provider adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession} object. + * + * + * @generated + */ +public class CompilationSessionItemProvider + extends ItemProviderAdapter + implements + IEditingDomainItemProvider, + IStructuredItemContentProvider, + ITreeItemContentProvider, + IItemLabelProvider, + IItemPropertySource, + ITableItemLabelProvider, + ITableItemColorProvider, + ITableItemFontProvider, + IItemColorProvider, + IItemFontProvider, + IItemStyledLabelProvider { + /** + * This constructs an instance from a factory and a notifier. + * + * + * @generated + */ + public CompilationSessionItemProvider(AdapterFactory adapterFactory) { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * + * + * @generated + */ + @Override + public List getPropertyDescriptors(Object object) { + if (itemPropertyDescriptors == null) { + super.getPropertyDescriptors(object); + + } + return itemPropertyDescriptors; + } + + /** + * 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}. + * + * + * @generated + */ + @Override + public Collection getChildrenFeatures(Object object) { + if (childrenFeatures == null) { + super.getChildrenFeatures(object); + childrenFeatures.add(CgmPackage.eINSTANCE.getCompilationSession_Tool()); + childrenFeatures.add(CgmPackage.eINSTANCE.getCompilationSession_Options()); + childrenFeatures.add(CgmPackage.eINSTANCE.getCompilationSession_Index()); + childrenFeatures.add(CgmPackage.eINSTANCE.getCompilationSession_Calls()); + } + return childrenFeatures; + } + + /** + * + * + * @generated + */ + @Override + protected EStructuralFeature getChildFeature(Object object, Object child) { + // Check the type of the specified child object and return the proper feature to use for + // adding (see {@link AddCommand}) it as a child. + + return super.getChildFeature(object, child); + } + + /** + * + * + * @generated + */ + @Override + public boolean hasChildren(Object object) { + return hasChildren(object, true); + } + + /** + * @generated NOT + */ + @Override + public Object getImage(Object object) { + return overlayImage(object, EcoreEditPlugin.INSTANCE.getImage("full/obj16/EObject")); //$NON-NLS-1$ + } + + /** + * This returns getImage(object) for the column index 0 or super.getImage(object) otherwise. + * + * + * @see #getText(Object) + * @see #getColumnText(Object, int) + * @generated + */ + @Override + public Object getColumnImage(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getImage(object) : super.getImage(object); + } + + /** + * + * + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() { + return true; + } + + /** + * This returns the label text for the adapted class. + * + * + * @generated + */ + @Override + public String getText(Object object) { + return ((StyledString)getStyledText(object)).getString(); + } + + /** + * This returns getText(object) for the column index 0 or super.getText(object) otherwise. + * + * + * @see #getImage(Object) + * @see #getColumnImage(Object, int) + * @generated + */ + @Override + public String getColumnText(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getText(object) : super.getText(object); + } + + /** + * This returns the label styled text for the adapted class. + * + * + * @generated + */ + @Override + public Object getStyledText(Object object) { + return new StyledString(getString("_UI_CompilationSession_type")); //$NON-NLS-1$ + } + + /** + * 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}. + * + * + * @generated + */ + @Override + public void notifyChanged(Notification notification) { + updateChildren(notification); + + switch (notification.getFeatureID(CompilationSession.class)) { + case CgmPackage.COMPILATION_SESSION__TOOL: + case CgmPackage.COMPILATION_SESSION__OPTIONS: + case CgmPackage.COMPILATION_SESSION__INDEX: + case CgmPackage.COMPILATION_SESSION__CALLS: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), true, false)); + return; + default: + super.notifyChanged(notification); + return; + } + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * + * + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { + super.collectNewChildDescriptors(newChildDescriptors, object); + + newChildDescriptors.add + (createChildParameter + (CgmPackage.eINSTANCE.getCompilationSession_Tool(), + CgmFactory.eINSTANCE.createTool())); + + newChildDescriptors.add + (createChildParameter + (CgmPackage.eINSTANCE.getCompilationSession_Options(), + CgmFactory.eINSTANCE.createOptions())); + + newChildDescriptors.add + (createChildParameter + (CgmPackage.eINSTANCE.getCompilationSession_Index(), + CgmFactory.eINSTANCE.createIndex())); + + newChildDescriptors.add + (createChildParameter + (CgmPackage.eINSTANCE.getCompilationSession_Calls(), + CgmFactory.eINSTANCE.createCallTree())); + } + + /** + * Return the resource locator for this item provider's resources. + * + * + * @generated + */ + @Override + public ResourceLocator getResourceLocator() { + return ((IChildCreationExtender)adapterFactory).getResourceLocator(); + } + +} diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/IndexItemProvider.java b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/IndexItemProvider.java new file mode 100644 index 0000000..dbc5333 --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/IndexItemProvider.java @@ -0,0 +1,207 @@ +/** + * Copyright (c) 2022 ArSysOp + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * SPDX-License-Identifier: Apache-2.0 + * Contributors: + * ArSysOp - initial API and implementation + * + */ +package ru.arsysop.loft.cast.cgm.edit.providers; + + +import java.util.Collection; +import java.util.List; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.ecore.provider.EcoreEditPlugin; +import org.eclipse.emf.edit.provider.IChildCreationExtender; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IItemStyledLabelProvider; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemProviderAdapter; +import org.eclipse.emf.edit.provider.StyledString; + +/** + * This is the item provider adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.Index} object. + * + * + * @generated + */ +public class IndexItemProvider + extends ItemProviderAdapter + implements + IEditingDomainItemProvider, + IStructuredItemContentProvider, + ITreeItemContentProvider, + IItemLabelProvider, + IItemPropertySource, + ITableItemLabelProvider, + ITableItemColorProvider, + ITableItemFontProvider, + IItemColorProvider, + IItemFontProvider, + IItemStyledLabelProvider { + /** + * This constructs an instance from a factory and a notifier. + * + * + * @generated + */ + public IndexItemProvider(AdapterFactory adapterFactory) { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * + * + * @generated + */ + @Override + public List getPropertyDescriptors(Object object) { + if (itemPropertyDescriptors == null) { + super.getPropertyDescriptors(object); + + } + return itemPropertyDescriptors; + } + + /** + * + * + * @generated + */ + @Override + public boolean hasChildren(Object object) { + return hasChildren(object, true); + } + + /** + * @generated NOT + */ + @Override + public Object getImage(Object object) { + return overlayImage(object, EcoreEditPlugin.INSTANCE.getImage("full/obj16/EObject")); //$NON-NLS-1$ + } + + /** + * This returns getImage(object) for the column index 0 or super.getImage(object) otherwise. + * + * + * @see #getText(Object) + * @see #getColumnText(Object, int) + * @generated + */ + @Override + public Object getColumnImage(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getImage(object) : super.getImage(object); + } + + /** + * + * + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() { + return true; + } + + /** + * This returns the label text for the adapted class. + * + * + * @generated + */ + @Override + public String getText(Object object) { + return ((StyledString)getStyledText(object)).getString(); + } + + /** + * This returns getText(object) for the column index 0 or super.getText(object) otherwise. + * + * + * @see #getImage(Object) + * @see #getColumnImage(Object, int) + * @generated + */ + @Override + public String getColumnText(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getText(object) : super.getText(object); + } + + /** + * This returns the label styled text for the adapted class. + * + * + * @generated + */ + @Override + public Object getStyledText(Object object) { + return new StyledString(getString("_UI_Index_type")); //$NON-NLS-1$ + } + + /** + * 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}. + * + * + * @generated + */ + @Override + public void notifyChanged(Notification notification) { + updateChildren(notification); + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * + * + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + + /** + * Return the resource locator for this item provider's resources. + * + * + * @generated + */ + @Override + public ResourceLocator getResourceLocator() { + return ((IChildCreationExtender)adapterFactory).getResourceLocator(); + } + +} diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/OptionsItemProvider.java b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/OptionsItemProvider.java new file mode 100644 index 0000000..af4f9fe --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/OptionsItemProvider.java @@ -0,0 +1,207 @@ +/** + * Copyright (c) 2022 ArSysOp + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * SPDX-License-Identifier: Apache-2.0 + * Contributors: + * ArSysOp - initial API and implementation + * + */ +package ru.arsysop.loft.cast.cgm.edit.providers; + + +import java.util.Collection; +import java.util.List; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.ecore.provider.EcoreEditPlugin; +import org.eclipse.emf.edit.provider.IChildCreationExtender; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IItemStyledLabelProvider; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemProviderAdapter; +import org.eclipse.emf.edit.provider.StyledString; + +/** + * This is the item provider adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.Options} object. + * + * + * @generated + */ +public class OptionsItemProvider + extends ItemProviderAdapter + implements + IEditingDomainItemProvider, + IStructuredItemContentProvider, + ITreeItemContentProvider, + IItemLabelProvider, + IItemPropertySource, + ITableItemLabelProvider, + ITableItemColorProvider, + ITableItemFontProvider, + IItemColorProvider, + IItemFontProvider, + IItemStyledLabelProvider { + /** + * This constructs an instance from a factory and a notifier. + * + * + * @generated + */ + public OptionsItemProvider(AdapterFactory adapterFactory) { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * + * + * @generated + */ + @Override + public List getPropertyDescriptors(Object object) { + if (itemPropertyDescriptors == null) { + super.getPropertyDescriptors(object); + + } + return itemPropertyDescriptors; + } + + /** + * + * + * @generated + */ + @Override + public boolean hasChildren(Object object) { + return hasChildren(object, true); + } + + /** + * @generated NOT + */ + @Override + public Object getImage(Object object) { + return overlayImage(object, EcoreEditPlugin.INSTANCE.getImage("full/obj16/EObject")); //$NON-NLS-1$ + } + + /** + * This returns getImage(object) for the column index 0 or super.getImage(object) otherwise. + * + * + * @see #getText(Object) + * @see #getColumnText(Object, int) + * @generated + */ + @Override + public Object getColumnImage(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getImage(object) : super.getImage(object); + } + + /** + * + * + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() { + return true; + } + + /** + * This returns the label text for the adapted class. + * + * + * @generated + */ + @Override + public String getText(Object object) { + return ((StyledString)getStyledText(object)).getString(); + } + + /** + * This returns getText(object) for the column index 0 or super.getText(object) otherwise. + * + * + * @see #getImage(Object) + * @see #getColumnImage(Object, int) + * @generated + */ + @Override + public String getColumnText(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getText(object) : super.getText(object); + } + + /** + * This returns the label styled text for the adapted class. + * + * + * @generated + */ + @Override + public Object getStyledText(Object object) { + return new StyledString(getString("_UI_Options_type")); //$NON-NLS-1$ + } + + /** + * 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}. + * + * + * @generated + */ + @Override + public void notifyChanged(Notification notification) { + updateChildren(notification); + super.notifyChanged(notification); + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * + * + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + + /** + * Return the resource locator for this item provider's resources. + * + * + * @generated + */ + @Override + public ResourceLocator getResourceLocator() { + return ((IChildCreationExtender)adapterFactory).getResourceLocator(); + } + +} diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/ToolItemProvider.java b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/ToolItemProvider.java new file mode 100644 index 0000000..297ce98 --- /dev/null +++ b/bundles/ru.arsysop.loft.cast.cgm.edit/src-gen/ru/arsysop/loft/cast/cgm/edit/providers/ToolItemProvider.java @@ -0,0 +1,251 @@ +/** + * Copyright (c) 2022 ArSysOp + * + * Licensed under the Apache License, Version 2.0 (the "License"); + * you may not use this file except in compliance with the License. + * You may obtain a copy of the License at + * + * http://www.apache.org/licenses/LICENSE-2.0 + * + * Unless required by applicable law or agreed to in writing, software + * distributed under the License is distributed on an "AS IS" BASIS, + * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. + * See the License for the specific language governing permissions and + * limitations under the License. + * SPDX-License-Identifier: Apache-2.0 + * Contributors: + * ArSysOp - initial API and implementation + * + */ +package ru.arsysop.loft.cast.cgm.edit.providers; + + +import java.util.Collection; +import java.util.List; + +import org.eclipse.emf.common.notify.AdapterFactory; +import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.util.ResourceLocator; +import org.eclipse.emf.ecore.provider.EcoreEditPlugin; +import org.eclipse.emf.edit.provider.ComposeableAdapterFactory; +import org.eclipse.emf.edit.provider.IChildCreationExtender; +import org.eclipse.emf.edit.provider.IEditingDomainItemProvider; +import org.eclipse.emf.edit.provider.IItemColorProvider; +import org.eclipse.emf.edit.provider.IItemFontProvider; +import org.eclipse.emf.edit.provider.IItemLabelProvider; +import org.eclipse.emf.edit.provider.IItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.IItemPropertySource; +import org.eclipse.emf.edit.provider.IItemStyledLabelProvider; +import org.eclipse.emf.edit.provider.IStructuredItemContentProvider; +import org.eclipse.emf.edit.provider.ITableItemColorProvider; +import org.eclipse.emf.edit.provider.ITableItemFontProvider; +import org.eclipse.emf.edit.provider.ITableItemLabelProvider; +import org.eclipse.emf.edit.provider.ITreeItemContentProvider; +import org.eclipse.emf.edit.provider.ItemPropertyDescriptor; +import org.eclipse.emf.edit.provider.ItemProviderAdapter; +import org.eclipse.emf.edit.provider.StyledString; +import org.eclipse.emf.edit.provider.ViewerNotification; + +import ru.arsysop.loft.cast.cgm.model.api.Tool; +import ru.arsysop.loft.cast.cgm.model.meta.CgmPackage; + +/** + * This is the item provider adapter for a {@link ru.arsysop.loft.cast.cgm.model.api.Tool} object. + * + * + * @generated + */ +public class ToolItemProvider + extends ItemProviderAdapter + implements + IEditingDomainItemProvider, + IStructuredItemContentProvider, + ITreeItemContentProvider, + IItemLabelProvider, + IItemPropertySource, + ITableItemLabelProvider, + ITableItemColorProvider, + ITableItemFontProvider, + IItemColorProvider, + IItemFontProvider, + IItemStyledLabelProvider { + /** + * This constructs an instance from a factory and a notifier. + * + * + * @generated + */ + public ToolItemProvider(AdapterFactory adapterFactory) { + super(adapterFactory); + } + + /** + * This returns the property descriptors for the adapted class. + * + * + * @generated + */ + @Override + public List getPropertyDescriptors(Object object) { + if (itemPropertyDescriptors == null) { + super.getPropertyDescriptors(object); + + addTypePropertyDescriptor(object); + } + return itemPropertyDescriptors; + } + + /** + * This adds a property descriptor for the Type feature. + * + * + * @generated + */ + protected void addTypePropertyDescriptor(Object object) { + itemPropertyDescriptors.add + (createItemPropertyDescriptor + (((ComposeableAdapterFactory)adapterFactory).getRootAdapterFactory(), + getResourceLocator(), + getString("_UI_Tool_type_feature"), //$NON-NLS-1$ + getString("_UI_PropertyDescriptor_description", "_UI_Tool_type_feature", "_UI_Tool_type"), //$NON-NLS-1$ //$NON-NLS-2$ //$NON-NLS-3$ + CgmPackage.eINSTANCE.getTool_Type(), + true, + false, + false, + ItemPropertyDescriptor.GENERIC_VALUE_IMAGE, + null, + null)); + } + + /** + * + * + * @generated + */ + @Override + public boolean hasChildren(Object object) { + return hasChildren(object, true); + } + + /** + * @generated NOT + */ + @Override + public Object getImage(Object object) { + return overlayImage(object, EcoreEditPlugin.INSTANCE.getImage("full/obj16/EObject")); //$NON-NLS-1$ + } + + /** + * This returns getImage(object) for the column index 0 or super.getImage(object) otherwise. + * + * + * @see #getText(Object) + * @see #getColumnText(Object, int) + * @generated + */ + @Override + public Object getColumnImage(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getImage(object) : super.getImage(object); + } + + /** + * + * + * @generated + */ + @Override + protected boolean shouldComposeCreationImage() { + return true; + } + + /** + * This returns the label text for the adapted class. + * + * + * @generated + */ + @Override + public String getText(Object object) { + return ((StyledString)getStyledText(object)).getString(); + } + + /** + * This returns getText(object) for the column index 0 or super.getText(object) otherwise. + * + * + * @see #getImage(Object) + * @see #getColumnImage(Object, int) + * @generated + */ + @Override + public String getColumnText(Object object, int columnIndex) { + // TODO: implement this method to return appropriate information for each column. + // Ensure that you remove @generated or mark it @generated NOT + return columnIndex == 0 ? getText(object) : super.getText(object); + } + + /** + * This returns the label styled text for the adapted class. + * + * + * @generated + */ + @Override + public Object getStyledText(Object object) { + String label = ((Tool)object).getType(); + StyledString styledLabel = new StyledString(); + if (label == null || label.length() == 0) { + styledLabel.append(getString("_UI_Tool_type"), StyledString.Style.QUALIFIER_STYLER); //$NON-NLS-1$ + } else { + styledLabel.append(getString("_UI_Tool_type"), StyledString.Style.QUALIFIER_STYLER).append(" " + label); //$NON-NLS-1$ //$NON-NLS-2$ + } + return styledLabel; + } + + /** + * 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}. + * + * + * @generated + */ + @Override + public void notifyChanged(Notification notification) { + updateChildren(notification); + + switch (notification.getFeatureID(Tool.class)) { + case CgmPackage.TOOL__TYPE: + fireNotifyChanged(new ViewerNotification(notification, notification.getNotifier(), false, true)); + return; + default: + super.notifyChanged(notification); + return; + } + } + + /** + * This adds {@link org.eclipse.emf.edit.command.CommandParameter}s describing the children + * that can be created under this object. + * + * + * @generated + */ + @Override + protected void collectNewChildDescriptors(Collection newChildDescriptors, Object object) { + super.collectNewChildDescriptors(newChildDescriptors, object); + } + + /** + * Return the resource locator for this item provider's resources. + * + * + * @generated + */ + @Override + public ResourceLocator getResourceLocator() { + return ((IChildCreationExtender)adapterFactory).getResourceLocator(); + } + +} diff --git a/bundles/ru.arsysop.loft.cast.cgm.edit/src/.gitkeep b/bundles/ru.arsysop.loft.cast.cgm.edit/src/.gitkeep new file mode 100644 index 0000000..e69de29 diff --git a/bundles/ru.arsysop.loft.cast.cgm.model/META-INF/MANIFEST.MF b/bundles/ru.arsysop.loft.cast.cgm.model/META-INF/MANIFEST.MF index 111c028..1c54cd0 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.model/META-INF/MANIFEST.MF +++ b/bundles/ru.arsysop.loft.cast.cgm.model/META-INF/MANIFEST.MF @@ -17,3 +17,4 @@ Require-Bundle: org.eclipse.core.runtime;bundle-version="0.0.0", org.eclipse.emf.ecore.xmi;bundle-version="0.0.0";visibility:=reexport, org.emfjson.jackson;bundle-version="1.3.0" Bundle-ActivationPolicy: lazy +Import-Package: com.fasterxml.jackson.databind diff --git a/bundles/ru.arsysop.loft.cast.cgm.model/model/cgm.genmodel b/bundles/ru.arsysop.loft.cast.cgm.model/model/cgm.genmodel index f93f1f1..79bf4f7 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.model/model/cgm.genmodel +++ b/bundles/ru.arsysop.loft.cast.cgm.model/model/cgm.genmodel @@ -9,25 +9,28 @@ importerID="org.eclipse.emf.importer.ecore" complianceLevel="8.0" copyrightFields="false" editPluginID="ru.arsysop.loft.cast.cgm.edit" editorPluginID="ru.arsysop.loft.cast.cgm.editor" optimizedHasChildren="true" tableProviders="true" colorProviders="true" fontProviders="true" - operationReflection="true" runtimePlatform="RCP" importOrganizing="true" styleProviders="true" - findAction="true"> + operationReflection="true" importOrganizing="true" styleProviders="true" findAction="true"> ../../ru.arsysop.loft.cast.cgm.ecore/model/cgm.ecore - - - - - + + + + + - + - - - + + + diff --git a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/api/CompilationSession.java b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/api/CompilationSession.java index ce3e2e0..0303aee 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/api/CompilationSession.java +++ b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/api/CompilationSession.java @@ -42,88 +42,88 @@ */ public interface CompilationSession extends EObject { /** - * Returns the value of the 'Tool' reference. + * Returns the value of the 'Tool' containment reference. * * - * @return the value of the 'Tool' reference. + * @return the value of the 'Tool' containment reference. * @see #setTool(Tool) * @see ru.arsysop.loft.cast.cgm.model.meta.CgmPackage#getCompilationSession_Tool() - * @model required="true" + * @model containment="true" required="true" * @generated */ Tool getTool(); /** - * Sets the value of the '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getTool Tool}' reference. + * Sets the value of the '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getTool Tool}' containment reference. * * - * @param value the new value of the 'Tool' reference. + * @param value the new value of the 'Tool' containment reference. * @see #getTool() * @generated */ void setTool(Tool value); /** - * Returns the value of the 'Options' reference. + * Returns the value of the 'Options' containment reference. * * - * @return the value of the 'Options' reference. + * @return the value of the 'Options' containment reference. * @see #setOptions(Options) * @see ru.arsysop.loft.cast.cgm.model.meta.CgmPackage#getCompilationSession_Options() - * @model required="true" + * @model containment="true" required="true" * @generated */ Options getOptions(); /** - * Sets the value of the '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getOptions Options}' reference. + * Sets the value of the '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getOptions Options}' containment reference. * * - * @param value the new value of the 'Options' reference. + * @param value the new value of the 'Options' containment reference. * @see #getOptions() * @generated */ void setOptions(Options value); /** - * Returns the value of the 'Index' reference. + * Returns the value of the 'Index' containment reference. * * - * @return the value of the 'Index' reference. + * @return the value of the 'Index' containment reference. * @see #setIndex(Index) * @see ru.arsysop.loft.cast.cgm.model.meta.CgmPackage#getCompilationSession_Index() - * @model required="true" + * @model containment="true" required="true" * @generated */ Index getIndex(); /** - * Sets the value of the '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getIndex Index}' reference. + * Sets the value of the '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getIndex Index}' containment reference. * * - * @param value the new value of the 'Index' reference. + * @param value the new value of the 'Index' containment reference. * @see #getIndex() * @generated */ void setIndex(Index value); /** - * Returns the value of the 'Calls' reference. + * Returns the value of the 'Calls' containment reference. * * - * @return the value of the 'Calls' reference. + * @return the value of the 'Calls' containment reference. * @see #setCalls(CallTree) * @see ru.arsysop.loft.cast.cgm.model.meta.CgmPackage#getCompilationSession_Calls() - * @model + * @model containment="true" * @generated */ CallTree getCalls(); /** - * Sets the value of the '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getCalls Calls}' reference. + * Sets the value of the '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getCalls Calls}' containment reference. * * - * @param value the new value of the 'Calls' reference. + * @param value the new value of the 'Calls' containment reference. * @see #getCalls() * @generated */ diff --git a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/api/Tool.java b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/api/Tool.java index f23d1f9..5b64fd5 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/api/Tool.java +++ b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/api/Tool.java @@ -40,13 +40,13 @@ public interface Tool extends EObject { /** * Returns the value of the 'Type' attribute. - * The default value is "clang". + * The default value is "". * * * @return the value of the 'Type' attribute. * @see #setType(String) * @see ru.arsysop.loft.cast.cgm.model.meta.CgmPackage#getTool_Type() - * @model default="clang" required="true" + * @model default="" required="true" * @generated */ String getType(); diff --git a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/CgmPackageImpl.java b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/CgmPackageImpl.java index d65269f..8dc402b 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/CgmPackageImpl.java +++ b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/CgmPackageImpl.java @@ -314,13 +314,13 @@ public void initializePackageContents() { // Initialize classes, features, and operations; add parameters initEClass(compilationSessionEClass, CompilationSession.class, "CompilationSession", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ - initEReference(getCompilationSession_Tool(), this.getTool(), null, "tool", null, 1, 1, CompilationSession.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ - initEReference(getCompilationSession_Options(), this.getOptions(), null, "options", null, 1, 1, CompilationSession.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ - initEReference(getCompilationSession_Index(), this.getIndex(), null, "index", null, 1, 1, CompilationSession.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ - initEReference(getCompilationSession_Calls(), this.getCallTree(), null, "calls", null, 0, 1, CompilationSession.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_COMPOSITE, IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEReference(getCompilationSession_Tool(), this.getTool(), null, "tool", null, 1, 1, CompilationSession.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEReference(getCompilationSession_Options(), this.getOptions(), null, "options", null, 1, 1, CompilationSession.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEReference(getCompilationSession_Index(), this.getIndex(), null, "index", null, 1, 1, CompilationSession.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ + initEReference(getCompilationSession_Calls(), this.getCallTree(), null, "calls", null, 0, 1, CompilationSession.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, IS_COMPOSITE, !IS_RESOLVE_PROXIES, !IS_UNSETTABLE, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ initEClass(toolEClass, Tool.class, "Tool", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ - initEAttribute(getTool_Type(), ecorePackage.getEString(), "type", "clang", 1, 1, Tool.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ //$NON-NLS-2$ + initEAttribute(getTool_Type(), ecorePackage.getEString(), "type", "", 1, 1, Tool.class, !IS_TRANSIENT, !IS_VOLATILE, IS_CHANGEABLE, !IS_UNSETTABLE, !IS_ID, IS_UNIQUE, !IS_DERIVED, IS_ORDERED); //$NON-NLS-1$ //$NON-NLS-2$ initEClass(optionsEClass, Options.class, "Options", !IS_ABSTRACT, !IS_INTERFACE, IS_GENERATED_INSTANCE_CLASS); //$NON-NLS-1$ diff --git a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/CompilationSessionImpl.java b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/CompilationSessionImpl.java index 1f9412e..0731948 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/CompilationSessionImpl.java +++ b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/CompilationSessionImpl.java @@ -21,6 +21,7 @@ import org.eclipse.emf.common.notify.Notification; +import org.eclipse.emf.common.notify.NotificationChain; import org.eclipse.emf.ecore.EClass; import org.eclipse.emf.ecore.InternalEObject; @@ -53,7 +54,7 @@ */ public class CompilationSessionImpl extends MinimalEObjectImpl.Container implements CompilationSession { /** - * The cached value of the '{@link #getTool() Tool}' reference. + * The cached value of the '{@link #getTool() Tool}' containment reference. * * * @see #getTool() @@ -63,7 +64,7 @@ public class CompilationSessionImpl extends MinimalEObjectImpl.Container impleme protected Tool tool; /** - * The cached value of the '{@link #getOptions() Options}' reference. + * The cached value of the '{@link #getOptions() Options}' containment reference. * * * @see #getOptions() @@ -73,7 +74,7 @@ public class CompilationSessionImpl extends MinimalEObjectImpl.Container impleme protected Options options; /** - * The cached value of the '{@link #getIndex() Index}' reference. + * The cached value of the '{@link #getIndex() Index}' containment reference. * * * @see #getIndex() @@ -83,7 +84,7 @@ public class CompilationSessionImpl extends MinimalEObjectImpl.Container impleme protected Index index; /** - * The cached value of the '{@link #getCalls() Calls}' reference. + * The cached value of the '{@link #getCalls() Calls}' containment reference. * * * @see #getCalls() @@ -118,14 +119,6 @@ protected EClass eStaticClass() { */ @Override public Tool getTool() { - if (tool != null && tool.eIsProxy()) { - InternalEObject oldTool = (InternalEObject)tool; - tool = (Tool)eResolveProxy(oldTool); - if (tool != oldTool) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, CgmPackage.COMPILATION_SESSION__TOOL, oldTool, tool)); - } - } return tool; } @@ -134,8 +127,14 @@ public Tool getTool() { * * @generated */ - public Tool basicGetTool() { - return tool; + public NotificationChain basicSetTool(Tool newTool, NotificationChain msgs) { + Tool oldTool = tool; + tool = newTool; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__TOOL, oldTool, newTool); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; } /** @@ -145,10 +144,17 @@ public Tool basicGetTool() { */ @Override public void setTool(Tool newTool) { - Tool oldTool = tool; - tool = newTool; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__TOOL, oldTool, tool)); + if (newTool != tool) { + NotificationChain msgs = null; + if (tool != null) + msgs = ((InternalEObject)tool).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - CgmPackage.COMPILATION_SESSION__TOOL, null, msgs); + if (newTool != null) + msgs = ((InternalEObject)newTool).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - CgmPackage.COMPILATION_SESSION__TOOL, null, msgs); + msgs = basicSetTool(newTool, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__TOOL, newTool, newTool)); } /** @@ -158,14 +164,6 @@ public void setTool(Tool newTool) { */ @Override public Options getOptions() { - if (options != null && options.eIsProxy()) { - InternalEObject oldOptions = (InternalEObject)options; - options = (Options)eResolveProxy(oldOptions); - if (options != oldOptions) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, CgmPackage.COMPILATION_SESSION__OPTIONS, oldOptions, options)); - } - } return options; } @@ -174,8 +172,14 @@ public Options getOptions() { * * @generated */ - public Options basicGetOptions() { - return options; + public NotificationChain basicSetOptions(Options newOptions, NotificationChain msgs) { + Options oldOptions = options; + options = newOptions; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__OPTIONS, oldOptions, newOptions); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; } /** @@ -185,10 +189,17 @@ public Options basicGetOptions() { */ @Override public void setOptions(Options newOptions) { - Options oldOptions = options; - options = newOptions; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__OPTIONS, oldOptions, options)); + if (newOptions != options) { + NotificationChain msgs = null; + if (options != null) + msgs = ((InternalEObject)options).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - CgmPackage.COMPILATION_SESSION__OPTIONS, null, msgs); + if (newOptions != null) + msgs = ((InternalEObject)newOptions).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - CgmPackage.COMPILATION_SESSION__OPTIONS, null, msgs); + msgs = basicSetOptions(newOptions, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__OPTIONS, newOptions, newOptions)); } /** @@ -198,14 +209,6 @@ public void setOptions(Options newOptions) { */ @Override public Index getIndex() { - if (index != null && index.eIsProxy()) { - InternalEObject oldIndex = (InternalEObject)index; - index = (Index)eResolveProxy(oldIndex); - if (index != oldIndex) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, CgmPackage.COMPILATION_SESSION__INDEX, oldIndex, index)); - } - } return index; } @@ -214,8 +217,14 @@ public Index getIndex() { * * @generated */ - public Index basicGetIndex() { - return index; + public NotificationChain basicSetIndex(Index newIndex, NotificationChain msgs) { + Index oldIndex = index; + index = newIndex; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__INDEX, oldIndex, newIndex); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; } /** @@ -225,10 +234,17 @@ public Index basicGetIndex() { */ @Override public void setIndex(Index newIndex) { - Index oldIndex = index; - index = newIndex; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__INDEX, oldIndex, index)); + if (newIndex != index) { + NotificationChain msgs = null; + if (index != null) + msgs = ((InternalEObject)index).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - CgmPackage.COMPILATION_SESSION__INDEX, null, msgs); + if (newIndex != null) + msgs = ((InternalEObject)newIndex).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - CgmPackage.COMPILATION_SESSION__INDEX, null, msgs); + msgs = basicSetIndex(newIndex, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__INDEX, newIndex, newIndex)); } /** @@ -238,14 +254,6 @@ public void setIndex(Index newIndex) { */ @Override public CallTree getCalls() { - if (calls != null && calls.eIsProxy()) { - InternalEObject oldCalls = (InternalEObject)calls; - calls = (CallTree)eResolveProxy(oldCalls); - if (calls != oldCalls) { - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.RESOLVE, CgmPackage.COMPILATION_SESSION__CALLS, oldCalls, calls)); - } - } return calls; } @@ -254,8 +262,14 @@ public CallTree getCalls() { * * @generated */ - public CallTree basicGetCalls() { - return calls; + public NotificationChain basicSetCalls(CallTree newCalls, NotificationChain msgs) { + CallTree oldCalls = calls; + calls = newCalls; + if (eNotificationRequired()) { + ENotificationImpl notification = new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__CALLS, oldCalls, newCalls); + if (msgs == null) msgs = notification; else msgs.add(notification); + } + return msgs; } /** @@ -265,10 +279,38 @@ public CallTree basicGetCalls() { */ @Override public void setCalls(CallTree newCalls) { - CallTree oldCalls = calls; - calls = newCalls; - if (eNotificationRequired()) - eNotify(new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__CALLS, oldCalls, calls)); + if (newCalls != calls) { + NotificationChain msgs = null; + if (calls != null) + msgs = ((InternalEObject)calls).eInverseRemove(this, EOPPOSITE_FEATURE_BASE - CgmPackage.COMPILATION_SESSION__CALLS, null, msgs); + if (newCalls != null) + msgs = ((InternalEObject)newCalls).eInverseAdd(this, EOPPOSITE_FEATURE_BASE - CgmPackage.COMPILATION_SESSION__CALLS, null, msgs); + msgs = basicSetCalls(newCalls, msgs); + if (msgs != null) msgs.dispatch(); + } + else if (eNotificationRequired()) + eNotify(new ENotificationImpl(this, Notification.SET, CgmPackage.COMPILATION_SESSION__CALLS, newCalls, newCalls)); + } + + /** + * + * + * @generated + */ + @Override + public NotificationChain eInverseRemove(InternalEObject otherEnd, int featureID, NotificationChain msgs) { + switch (featureID) { + case CgmPackage.COMPILATION_SESSION__TOOL: + return basicSetTool(null, msgs); + case CgmPackage.COMPILATION_SESSION__OPTIONS: + return basicSetOptions(null, msgs); + case CgmPackage.COMPILATION_SESSION__INDEX: + return basicSetIndex(null, msgs); + case CgmPackage.COMPILATION_SESSION__CALLS: + return basicSetCalls(null, msgs); + default: + return super.eInverseRemove(otherEnd, featureID, msgs); + } } /** @@ -280,17 +322,13 @@ public void setCalls(CallTree newCalls) { public Object eGet(int featureID, boolean resolve, boolean coreType) { switch (featureID) { case CgmPackage.COMPILATION_SESSION__TOOL: - if (resolve) return getTool(); - return basicGetTool(); + return getTool(); case CgmPackage.COMPILATION_SESSION__OPTIONS: - if (resolve) return getOptions(); - return basicGetOptions(); + return getOptions(); case CgmPackage.COMPILATION_SESSION__INDEX: - if (resolve) return getIndex(); - return basicGetIndex(); + return getIndex(); case CgmPackage.COMPILATION_SESSION__CALLS: - if (resolve) return getCalls(); - return basicGetCalls(); + return getCalls(); default: return super.eGet(featureID, resolve, coreType); } diff --git a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/ToolImpl.java b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/ToolImpl.java index 9386fd3..38e51ae 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/ToolImpl.java +++ b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/impl/ToolImpl.java @@ -52,7 +52,7 @@ public class ToolImpl extends MinimalEObjectImpl.Container implements Tool { * @generated * @ordered */ - protected static final String TYPE_EDEFAULT = "clang"; //$NON-NLS-1$ + protected static final String TYPE_EDEFAULT = ""; //$NON-NLS-1$ /** * The cached value of the '{@link #getType() Type}' attribute. diff --git a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/meta/CgmPackage.java b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/meta/CgmPackage.java index 51dac9f..af68fd3 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/meta/CgmPackage.java +++ b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/meta/CgmPackage.java @@ -84,7 +84,7 @@ public interface CgmPackage extends EPackage { int COMPILATION_SESSION = 0; /** - * The feature id for the 'Tool' reference. + * The feature id for the 'Tool' containment reference. * * * @generated @@ -93,7 +93,7 @@ public interface CgmPackage extends EPackage { int COMPILATION_SESSION__TOOL = 0; /** - * The feature id for the 'Options' reference. + * The feature id for the 'Options' containment reference. * * * @generated @@ -102,7 +102,7 @@ public interface CgmPackage extends EPackage { int COMPILATION_SESSION__OPTIONS = 1; /** - * The feature id for the 'Index' reference. + * The feature id for the 'Index' containment reference. * * * @generated @@ -111,7 +111,7 @@ public interface CgmPackage extends EPackage { int COMPILATION_SESSION__INDEX = 2; /** - * The feature id for the 'Calls' reference. + * The feature id for the 'Calls' containment reference. * * * @generated @@ -270,10 +270,10 @@ public interface CgmPackage extends EPackage { EClass getCompilationSession(); /** - * Returns the meta object for the reference '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getTool Tool}'. + * Returns the meta object for the containment reference '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getTool Tool}'. * * - * @return the meta object for the reference 'Tool'. + * @return the meta object for the containment reference 'Tool'. * @see ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getTool() * @see #getCompilationSession() * @generated @@ -281,10 +281,10 @@ public interface CgmPackage extends EPackage { EReference getCompilationSession_Tool(); /** - * Returns the meta object for the reference '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getOptions Options}'. + * Returns the meta object for the containment reference '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getOptions Options}'. * * - * @return the meta object for the reference 'Options'. + * @return the meta object for the containment reference 'Options'. * @see ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getOptions() * @see #getCompilationSession() * @generated @@ -292,10 +292,10 @@ public interface CgmPackage extends EPackage { EReference getCompilationSession_Options(); /** - * Returns the meta object for the reference '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getIndex Index}'. + * Returns the meta object for the containment reference '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getIndex Index}'. * * - * @return the meta object for the reference 'Index'. + * @return the meta object for the containment reference 'Index'. * @see ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getIndex() * @see #getCompilationSession() * @generated @@ -303,10 +303,10 @@ public interface CgmPackage extends EPackage { EReference getCompilationSession_Index(); /** - * Returns the meta object for the reference '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getCalls Calls}'. + * Returns the meta object for the containment reference '{@link ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getCalls Calls}'. * * - * @return the meta object for the reference 'Calls'. + * @return the meta object for the containment reference 'Calls'. * @see ru.arsysop.loft.cast.cgm.model.api.CompilationSession#getCalls() * @see #getCompilationSession() * @generated diff --git a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/util/CgmResourceFactoryImpl.java b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/util/CgmResourceFactoryImpl.java index 86848cc..416bf47 100644 --- a/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/util/CgmResourceFactoryImpl.java +++ b/bundles/ru.arsysop.loft.cast.cgm.model/src-gen/ru/arsysop/loft/cast/cgm/model/util/CgmResourceFactoryImpl.java @@ -21,6 +21,7 @@ import org.eclipse.emf.common.util.URI; import org.eclipse.emf.ecore.resource.Resource; +import org.emfjson.jackson.resource.JsonResource; import org.emfjson.jackson.resource.JsonResourceFactory; /** @@ -45,11 +46,12 @@ public CgmResourceFactoryImpl() { * Creates an instance of the resource. * * - * @generated + * @generated NOT */ @Override public Resource createResource(URI uri) { - Resource result = new CgmResourceImpl(uri); + JsonResource result = new CgmResourceImpl(uri); + result.setObjectMapper(getMapper()); return result; } diff --git a/features/ru.arsysop.loft.cast.cgm.feature/feature.xml b/features/ru.arsysop.loft.cast.cgm.feature/feature.xml index cd22b2b..1cd0198 100644 --- a/features/ru.arsysop.loft.cast.cgm.feature/feature.xml +++ b/features/ru.arsysop.loft.cast.cgm.feature/feature.xml @@ -61,12 +61,10 @@ version="0.0.0" unpack="false"/> - diff --git a/releng/ru.arsysop.loft.cast.aggregator/pom.xml b/releng/ru.arsysop.loft.cast.aggregator/pom.xml index 0a3bef9..9716ffd 100644 --- a/releng/ru.arsysop.loft.cast.aggregator/pom.xml +++ b/releng/ru.arsysop.loft.cast.aggregator/pom.xml @@ -43,9 +43,7 @@ ..\..\bundles\ru.arsysop.loft.cast.cgm ..\..\bundles\ru.arsysop.loft.cast.cgm.ecore ..\..\bundles\ru.arsysop.loft.cast.cgm.model - ..\..\features\ru.arsysop.loft.cast.cgm.feature ..\..\bundles\ru.arsysop.loft.cast diff --git a/releng/ru.arsysop.loft.cast.target/ru.arsysop.loft.cast.target.target b/releng/ru.arsysop.loft.cast.target/ru.arsysop.loft.cast.target.target index b33dabb..19a088a 100644 --- a/releng/ru.arsysop.loft.cast.target/ru.arsysop.loft.cast.target.target +++ b/releng/ru.arsysop.loft.cast.target/ru.arsysop.loft.cast.target.target @@ -79,10 +79,26 @@ - - + + com.fasterxml.jackson.core + jackson-annotations + 2.11.4 + jar + + + com.fasterxml.jackson.core + jackson-core + 2.11.4 + jar + + + com.fasterxml.jackson.core + jackson-databind + 2.11.4 + jar + org.emfjson emfjson-jackson