Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorThomas Watson2016-01-20 14:40:43 +0000
committerThomas Watson2016-01-20 14:49:11 +0000
commita164762f16f7f5f8d02c5cec5b5eb73dfcf27873 (patch)
tree83002d5b310fc4842b1561a4d5f011fe450c0b22 /bundles
parent652bb5b7845d77af8ef390d99d4c974f1ec8db3e (diff)
downloadrt.equinox.bundles-a164762f16f7f5f8d02c5cec5b5eb73dfcf27873.tar.gz
rt.equinox.bundles-a164762f16f7f5f8d02c5cec5b5eb73dfcf27873.tar.xz
rt.equinox.bundles-a164762f16f7f5f8d02c5cec5b5eb73dfcf27873.zip
Bug 470000 - Remove (or reduce) dependency on aspectj bundles
Change-Id: Ibe5343cacf9cfb126ec8bab22cc9a414d6b28514 Signed-off-by: Thomas Watson <tjwatson@us.ibm.com>
Diffstat (limited to 'bundles')
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/.classpath7
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/.cvsignore1
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/.options1
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/.project34
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.core.resources.prefs3
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.core.runtime.prefs2
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.jdt.core.prefs371
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.jdt.ui.prefs114
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.pde.prefs22
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/META-INF/MANIFEST.MF21
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/META-INF/optional-p2.inf10
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/about.html28
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/build.properties19
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/forceQualifierUpdate.txt4
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/pom.xml47
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectAdmin.java180
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectConfiguration.java70
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingActivator.java64
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingService.java164
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingServiceFactory.java46
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingStarter.java108
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/AspectAdminImpl.java464
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/AspectResolver.java268
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/OSGiWeavingAdaptor.java285
-rw-r--r--bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/OSGiWeavingContext.java86
25 files changed, 0 insertions, 2419 deletions
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/.classpath b/bundles/org.eclipse.equinox.weaving.aspectj/.classpath
deleted file mode 100644
index a45409c4d..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/.classpath
+++ /dev/null
@@ -1,7 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<classpath>
- <classpathentry kind="con" path="org.eclipse.jdt.launching.JRE_CONTAINER/org.eclipse.jdt.internal.debug.ui.launcher.StandardVMType/JavaSE-1.6"/>
- <classpathentry kind="con" path="org.eclipse.pde.core.requiredPlugins"/>
- <classpathentry excluding="org/eclipse/osgi/aspectj/weavingService/WeavingServiceFactory.java" kind="src" path="src"/>
- <classpathentry kind="output" path="bin"/>
-</classpath>
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/.cvsignore b/bundles/org.eclipse.equinox.weaving.aspectj/.cvsignore
deleted file mode 100644
index ba077a403..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/.cvsignore
+++ /dev/null
@@ -1 +0,0 @@
-bin
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/.options b/bundles/org.eclipse.equinox.weaving.aspectj/.options
deleted file mode 100644
index a4c746efd..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/.options
+++ /dev/null
@@ -1 +0,0 @@
-org.aspectj.osgi.service.weaving/debug=false
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/.project b/bundles/org.eclipse.equinox.weaving.aspectj/.project
deleted file mode 100644
index 1b266ec34..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/.project
+++ /dev/null
@@ -1,34 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<projectDescription>
- <name>org.eclipse.equinox.weaving.aspectj</name>
- <comment></comment>
- <projects>
- </projects>
- <buildSpec>
- <buildCommand>
- <name>org.eclipse.jdt.core.javabuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.ManifestBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.SchemaBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- <buildCommand>
- <name>org.eclipse.pde.api.tools.apiAnalysisBuilder</name>
- <arguments>
- </arguments>
- </buildCommand>
- </buildSpec>
- <natures>
- <nature>org.eclipse.pde.PluginNature</nature>
- <nature>org.eclipse.jdt.core.javanature</nature>
- <nature>org.eclipse.pde.api.tools.apiAnalysisNature</nature>
- </natures>
-</projectDescription>
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.core.resources.prefs b/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.core.resources.prefs
deleted file mode 100644
index 074ef504d..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.core.resources.prefs
+++ /dev/null
@@ -1,3 +0,0 @@
-#Mon Aug 04 14:34:18 CEST 2008
-eclipse.preferences.version=1
-encoding/<project>=UTF-8
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.core.runtime.prefs b/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.core.runtime.prefs
deleted file mode 100644
index 5a0ad22d2..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.core.runtime.prefs
+++ /dev/null
@@ -1,2 +0,0 @@
-eclipse.preferences.version=1
-line.separator=\n
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.jdt.core.prefs b/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.jdt.core.prefs
deleted file mode 100644
index 5c6b0177e..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.jdt.core.prefs
+++ /dev/null
@@ -1,371 +0,0 @@
-eclipse.preferences.version=1
-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.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault
-org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable
-org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled
-org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
-org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
-org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve
-org.eclipse.jdt.core.compiler.compliance=1.6
-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.doc.comment.support=enabled
-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.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=enabled
-org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore
-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=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
-org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore
-org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
-org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore
-org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled
-org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=ignore
-org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=enabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=all_standard_tags
-org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
-org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=protected
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=disabled
-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=warning
-org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=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.possibleAccidentalBooleanAssignment=ignore
-org.eclipse.jdt.core.compiler.problem.potentialNullReference=ignore
-org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=ignore
-org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning
-org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
-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.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.syntacticNullAnalysisForFields=disabled
-org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
-org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
-org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled
-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.unnecessaryElse=ignore
-org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning
-org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
-org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning
-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.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=ignore
-org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning
-org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning
-org.eclipse.jdt.core.compiler.source=1.6
-org.eclipse.jdt.core.formatter.align_type_members_on_columns=false
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_assignment=0
-org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16
-org.eclipse.jdt.core.formatter.alignment_for_compact_if=16
-org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80
-org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0
-org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16
-org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16
-org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16
-org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16
-org.eclipse.jdt.core.formatter.blank_lines_after_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_after_package=1
-org.eclipse.jdt.core.formatter.blank_lines_before_field=1
-org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=1
-org.eclipse.jdt.core.formatter.blank_lines_before_imports=1
-org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1
-org.eclipse.jdt.core.formatter.blank_lines_before_method=1
-org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1
-org.eclipse.jdt.core.formatter.blank_lines_before_package=1
-org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1
-org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1
-org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line
-org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false
-org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false
-org.eclipse.jdt.core.formatter.comment.format_block_comments=true
-org.eclipse.jdt.core.formatter.comment.format_header=false
-org.eclipse.jdt.core.formatter.comment.format_html=true
-org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true
-org.eclipse.jdt.core.formatter.comment.format_line_comments=false
-org.eclipse.jdt.core.formatter.comment.format_source_code=true
-org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true
-org.eclipse.jdt.core.formatter.comment.indent_root_tags=true
-org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert
-org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert
-org.eclipse.jdt.core.formatter.comment.line_length=80
-org.eclipse.jdt.core.formatter.compact_else_if=true
-org.eclipse.jdt.core.formatter.continuation_indentation=2
-org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
-org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true
-org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true
-org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_empty_lines=false
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true
-org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true
-org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false
-org.eclipse.jdt.core.formatter.indentation.size=4
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
-org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert
-org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert
-org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert
-org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert
-org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert
-org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert
-org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert
-org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert
-org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert
-org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert
-org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert
-org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false
-org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=true
-org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
-org.eclipse.jdt.core.formatter.lineSplit=80
-org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false
-org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0
-org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1
-org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
-org.eclipse.jdt.core.formatter.tabulation.char=space
-org.eclipse.jdt.core.formatter.tabulation.size=4
-org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
-org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.jdt.ui.prefs b/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.jdt.ui.prefs
deleted file mode 100644
index 5423ee617..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.jdt.ui.prefs
+++ /dev/null
@@ -1,114 +0,0 @@
-#Mon Aug 04 14:34:18 CEST 2008
-cleanup.add_default_serial_version_id=false
-cleanup.add_generated_serial_version_id=true
-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_serial_version_id=true
-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_to_enhanced_for_loop=false
-cleanup.correct_indentation=false
-cleanup.format_source_code=true
-cleanup.format_source_code_changes_only=false
-cleanup.make_local_variable_final=true
-cleanup.make_parameters_final=true
-cleanup.make_private_fields_final=true
-cleanup.make_type_abstract_if_missing_method=false
-cleanup.make_variable_declarations_final=true
-cleanup.never_use_blocks=false
-cleanup.never_use_parentheses_in_expressions=true
-cleanup.organize_imports=true
-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_trailing_whitespaces=true
-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=true
-cleanup.sort_members_all=true
-cleanup.use_blocks=false
-cleanup.use_blocks_only_for_return_and_throw=false
-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=_defaultCleanUpProfile
-cleanup_settings_version=2
-eclipse.preferences.version=1
-editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
-formatter_profile=_defaultFormatterProfile
-formatter_settings_version=11
-org.eclipse.jdt.ui.ignorelowercasenames=true
-org.eclipse.jdt.ui.importorder=java;javax;com;de;net;org;
-org.eclipse.jdt.ui.javadoc=false
-org.eclipse.jdt.ui.ondemandthreshold=99
-org.eclipse.jdt.ui.staticondemandthreshold=99
-org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8"?><templates><template autoinsert\="true" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment">/**\n * @return the ${bare_field_name}\n */</template><template autoinsert\="true" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment">/**\n * @param ${param} the ${bare_field_name} to set\n */</template><template autoinsert\="true" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment">/**\n * ${tags}\n */</template><template autoinsert\="false" context\="filecomment_context" deleted\="false" description\="Comment for created Java files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.filecomment" name\="filecomment">/*******************************************************************************\n * Copyright (c) 2008 ${user} and others.\n * All rights reserved. This program and the accompanying materials \n * are made available under the terms of the Eclipse Public License v1.0\n * which accompanies this distribution, and is available at\n * http\://www.eclipse.org/legal/epl-v10.html.\n * \n * Contributors\:\n * ${user} - initial implementation\n ******************************************************************************/\n</template><template autoinsert\="false" context\="typecomment_context" deleted\="false" description\="Comment for created types" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.typecomment" name\="typecomment">/**\n * @author ${user}\n * ${tags}\n */</template><template autoinsert\="true" context\="fieldcomment_context" deleted\="false" description\="Comment for fields" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.fieldcomment" name\="fieldcomment">/**\n * \n */</template><template autoinsert\="true" context\="methodcomment_context" deleted\="false" description\="Comment for non-overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodcomment" name\="methodcomment">/**\n * ${tags}\n */</template><template autoinsert\="false" context\="overridecomment_context" deleted\="false" description\="Comment for overriding methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.overridecomment" name\="overridecomment">/**\n * ${see_to_overridden}\n */</template><template autoinsert\="true" context\="delegatecomment_context" deleted\="false" description\="Comment for delegate methods" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.delegatecomment" name\="delegatecomment">/**\n * ${tags}\n * ${see_to_target}\n */</template><template autoinsert\="false" context\="newtype_context" deleted\="false" description\="Newly created files" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.newtype" name\="newtype">${filecomment}\n\n${package_declaration}\n\n${typecomment}\n${type_declaration}</template><template autoinsert\="true" context\="classbody_context" deleted\="false" description\="Code in new class type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.classbody" name\="classbody">\n</template><template autoinsert\="true" context\="interfacebody_context" deleted\="false" description\="Code in new interface type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.interfacebody" name\="interfacebody">\n</template><template autoinsert\="true" context\="enumbody_context" deleted\="false" description\="Code in new enum type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.enumbody" name\="enumbody">\n</template><template autoinsert\="true" context\="annotationbody_context" deleted\="false" description\="Code in new annotation type bodies" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.annotationbody" name\="annotationbody">\n</template><template autoinsert\="true" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">// ${todo} Auto-generated catch block\n${exception_var}.printStackTrace();</template><template autoinsert\="true" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">// ${todo} Auto-generated method stub\n${body_statement}</template><template autoinsert\="false" context\="constructorbody_context" deleted\="false" description\="Code in created constructor stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorbody" name\="constructorbody">// ${todo} Auto-generated constructor stub\n${body_statement}</template><template autoinsert\="true" context\="getterbody_context" deleted\="false" description\="Code in created getters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.getterbody" name\="getterbody">return ${field};</template><template autoinsert\="true" context\="setterbody_context" deleted\="false" description\="Code in created setters" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.setterbody" name\="setterbody">${field} \= ${param};</template></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_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_to_enhanced_for_loop=false
-sp_cleanup.correct_indentation=false
-sp_cleanup.format_source_code=true
-sp_cleanup.format_source_code_changes_only=false
-sp_cleanup.make_local_variable_final=true
-sp_cleanup.make_parameters_final=true
-sp_cleanup.make_private_fields_final=true
-sp_cleanup.make_type_abstract_if_missing_method=false
-sp_cleanup.make_variable_declarations_final=true
-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_trailing_whitespaces=true
-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=true
-sp_cleanup.remove_unused_imports=true
-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=true
-sp_cleanup.sort_members_all=true
-sp_cleanup.use_blocks=false
-sp_cleanup.use_blocks_only_for_return_and_throw=false
-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/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.pde.prefs b/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.pde.prefs
deleted file mode 100644
index 21798cc6b..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/.settings/org.eclipse.pde.prefs
+++ /dev/null
@@ -1,22 +0,0 @@
-#Mon Aug 04 14:34:18 CEST 2008
-compilers.f.unresolved-features=1
-compilers.f.unresolved-plugins=1
-compilers.incompatible-environment=1
-compilers.p.build=1
-compilers.p.deprecated=1
-compilers.p.discouraged-class=1
-compilers.p.internal=1
-compilers.p.missing-packages=2
-compilers.p.no-required-att=0
-compilers.p.not-externalized-att=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/org.eclipse.equinox.weaving.aspectj/META-INF/MANIFEST.MF b/bundles/org.eclipse.equinox.weaving.aspectj/META-INF/MANIFEST.MF
deleted file mode 100644
index bef28b30e..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/META-INF/MANIFEST.MF
+++ /dev/null
@@ -1,21 +0,0 @@
-Manifest-Version: 1.0
-Bundle-ManifestVersion: 2
-Bundle-Name: WeavingService Plug-in
-Bundle-SymbolicName: org.eclipse.equinox.weaving.aspectj
-Bundle-Version: 1.0.400.qualifier
-Bundle-Vendor: Eclipse.org - Equinox
-Bundle-Activator: org.eclipse.equinox.weaving.aspectj.AspectJWeavingActivator
-Import-Package: org.aspectj.weaver;version="1.6.3";resolution:=optional,
- org.aspectj.weaver.bcel;version="1.6.3";resolution:=optional,
- org.aspectj.weaver.loadtime;version="1.6.3";resolution:=optional,
- org.aspectj.weaver.loadtime.definition;version="1.6.3";resolution:=optional,
- org.aspectj.weaver.tools;version="1.6.3";resolution:=optional,
- org.eclipse.equinox.service.weaving,
- org.eclipse.osgi.service.debug,
- org.eclipse.osgi.util;version="1.1.0",
- org.osgi.framework;version="[1.6, 2.0)",
- org.osgi.framework.namespace;version="1.1.0",
- org.osgi.framework.wiring;version="1.1.0"
-Bundle-RequiredExecutionEnvironment: JavaSE-1.6
-Export-Package: org.eclipse.equinox.weaving.aspectj;x-friends:="org.eclipse.equinox.weaving.tests",
- org.eclipse.equinox.weaving.aspectj.loadtime;x-friends:="org.eclipse.equinox.weaving.tests"
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/META-INF/optional-p2.inf b/bundles/org.eclipse.equinox.weaving.aspectj/META-INF/optional-p2.inf
deleted file mode 100644
index 43ce7ced1..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/META-INF/optional-p2.inf
+++ /dev/null
@@ -1,10 +0,0 @@
-instructions.configure = \
- setStartLevel(startLevel:4); \
- markStarted(started: true); \
- setProgramProperty(propName:org.aspectj.weaver.showWeaveInfo, propValue:true); \
- setProgramProperty(propName:org.aspectj.osgi.verbose, propValue:true); \
- setProgramProperty(propName:aj.weaving.verbose, propValue:true);
-instructions.unconfigure = \
- setProgramProperty(propName:org.aspectj.weaver.showWeaveInfo, propValue:); \
- setProgramProperty(propName:org.aspectj.osgi.verbose, propValue:); \
- setProgramProperty(propName:aj.weaving.verbose, propValue:);
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/about.html b/bundles/org.eclipse.equinox.weaving.aspectj/about.html
deleted file mode 100644
index 571b117e9..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/about.html
+++ /dev/null
@@ -1,28 +0,0 @@
-<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
- "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
-<html xmlns="http://www.w3.org/1999/xhtml">
-<head>
-<meta http-equiv="Content-Type" content="text/html; charset=ISO-8859-1"/>
-<title>About</title>
-</head>
-<body lang="EN-US">
-<h2>About This Content</h2>
-
-<p>May 24, 2012</p>
-<h3>License</h3>
-
-<p>The Eclipse Foundation makes available all content in this plug-in (&quot;Content&quot;). Unless otherwise
-indicated below, the Content is provided to you under the terms and conditions of the
-Eclipse Public License Version 1.0 (&quot;EPL&quot;). A copy of the EPL is available
-at <a href="http://www.eclipse.org/legal/epl-v10.html">http://www.eclipse.org/legal/epl-v10.html</a>.
-For purposes of the EPL, &quot;Program&quot; will mean the Content.</p>
-
-<p>If you did not receive this Content directly from the Eclipse Foundation, the Content is
-being redistributed by another party (&quot;Redistributor&quot;) and different terms and conditions may
-apply to your use of any object code in the Content. Check the Redistributor's license that was
-provided with the Content. If no such license exists, contact the Redistributor. Unless otherwise
-indicated below, the terms and conditions of the EPL still apply to any source code in the Content
-and such source code may be obtained at <a href="http://www.eclipse.org">http://www.eclipse.org</a>.</p>
-
-</body>
-</html> \ No newline at end of file
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/build.properties b/bundles/org.eclipse.equinox.weaving.aspectj/build.properties
deleted file mode 100644
index cc4b3bb70..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/build.properties
+++ /dev/null
@@ -1,19 +0,0 @@
-###############################################################################
-# Copyright (c) 2011 IBM Corporation and others.
-# All rights reserved. This program and the accompanying materials
-# are made available under the terms of the Eclipse Public License v1.0
-# which accompanies this distribution, and is available at
-# http://www.eclipse.org/legal/epl-v10.html
-#
-# Contributors:
-# IBM Corporation - initial API and implementation
-###############################################################################
-source.. = src/
-output.. = bin/
-bin.includes = META-INF/,\
- .,\
- .options,\
- about.html
-src.includes = src/,\
- about.html
-javacWarnings..=-raw,-unchecked
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/forceQualifierUpdate.txt b/bundles/org.eclipse.equinox.weaving.aspectj/forceQualifierUpdate.txt
deleted file mode 100644
index 77ab709a9..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/forceQualifierUpdate.txt
+++ /dev/null
@@ -1,4 +0,0 @@
-# To force a version qualifier update add the bug here
-Bug 403352 - Update all parent versions to match our build stream
- -- Force update for luna
-Bug 416896 - Some Equinox bundles need to be touched to get API descriptions back \ No newline at end of file
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/pom.xml b/bundles/org.eclipse.equinox.weaving.aspectj/pom.xml
deleted file mode 100644
index 4cea69b80..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/pom.xml
+++ /dev/null
@@ -1,47 +0,0 @@
-<?xml version="1.0" encoding="UTF-8"?>
-<!--
- Copyright (c) 2012 Eclipse Foundation.
- All rights reserved. This program and the accompanying materials
- are made available under the terms of the Eclipse Distribution License v1.0
- which accompanies this distribution, and is available at
- http://www.eclipse.org/org/documents/edl-v10.php
-
- Contributors:
- Igor Fedorenko - initial implementation
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/xsd/maven-4.0.0.xsd">
- <modelVersion>4.0.0</modelVersion>
- <parent>
- <artifactId>rt.equinox.bundles</artifactId>
- <groupId>org.eclipse.equinox.bundles</groupId>
- <version>4.6.0-SNAPSHOT</version>
- <relativePath>../../</relativePath>
- </parent>
- <groupId>org.eclipse.equinox</groupId>
- <artifactId>org.eclipse.equinox.weaving.aspectj</artifactId>
- <version>1.0.400-SNAPSHOT</version>
- <packaging>eclipse-plugin</packaging>
-
-
- <build>
- <plugins>
- <plugin>
- <groupId>org.eclipse.tycho</groupId>
- <artifactId>target-platform-configuration</artifactId>
- <configuration>
- <dependency-resolution>
- <extraRequirements>
- <!-- this guarantees proper reactor build order -->
- <requirement>
- <type>eclipse-plugin</type>
- <id>org.aspectj.weaver</id>
- <versionRange>0.0.0</versionRange>
- </requirement>
- </extraRequirements>
- </dependency-resolution>
- </configuration>
- </plugin>
- </plugins>
- </build>
-
-</project>
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectAdmin.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectAdmin.java
deleted file mode 100644
index bcc1d2fc8..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectAdmin.java
+++ /dev/null
@@ -1,180 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009 Martin Lippert and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Martin Lippert initial implementation
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj;
-
-import org.aspectj.weaver.loadtime.definition.Definition;
-import org.osgi.framework.Bundle;
-
-/**
- * The AspectAdmin gives you detailed information about bundles providing
- * aspects, which aspects are provided, which aspects are exported and the
- * defined aspect policies for exported packages.
- *
- * This service is used by the weaver to determine which aspects to weave into
- * which bundles. It can also be used to implement some basic management
- * features for the AspectJ-based weaving of Equinox Aspects.
- *
- * @author Martin Lippert
- */
-public interface AspectAdmin {
-
- /**
- * Header for aspect bundle manifest files to indicate whether a bundle is
- * readily compiled with AJDT, for example. This tells Equinox Aspects that
- * the bundle does not need to be woven if it refers to just its own
- * aspects.
- */
- public static final String AOP_BUNDLE_FINISHED_HEADER = "Eclipse-AspectBundle"; //$NON-NLS-1$
-
- /**
- * The value for the aspect bundle header to indicate that there is no
- * weaving necessary to finish the aspects of the bundle itself
- */
- public static final String AOP_BUNDLE_FINISHED_VALUE = "finished"; //$NON-NLS-1$
-
- /**
- * This is the default value for the location of the aop.xml file inside a
- * bundle
- */
- public static final String AOP_CONTEXT_DEFAULT_LOCATION = "META-INF/aop.xml"; //$NON-NLS-1$
-
- /**
- * The name of the header to determine where to look for the aop.xml files
- * inside a bundle Bundles can use this header to specify the location where
- * their aop.xml is located
- */
- public static final String AOP_CONTEXT_LOCATION_HEADER = "Eclipse-AspectContext"; //$NON-NLS-1$
-
- /**
- * directive for the policy to apply aspects from imported or required
- * bundles
- */
- public static final String ASPECT_APPLY_POLICY_DIRECTIVE = "apply-aspects"; //$NON-NLS-1$
-
- /**
- * apply policy is false in this case, do not apply aspects for weaving
- */
- public static final int ASPECT_APPLY_POLICY_FALSE = 2;
-
- /**
- * apply policy is not defined
- */
- public static final int ASPECT_APPLY_POLICY_NOT_DEFINED = 0;
-
- /**
- * apply policy is true, so apply aspects for weaving
- */
- public static final int ASPECT_APPLY_POLICY_TRUE = 1;
-
- /**
- * directive to declare the aspect policy. possible values are "opt-in" or
- * "opt-out"
- */
- public static final String ASPECT_POLICY_DIRECTIVE = "aspect-policy"; //$NON-NLS-1$
-
- /**
- * policy directive value to tell the weaver that clients have explicitly to
- * ask for those aspects to be applied
- */
- public static final String ASPECT_POLICY_DIRECTIVE_OPT_IN = "opt-in"; //$NON-NLS-1$
-
- /**
- * policy directive value to tell the weaver that clients will get those
- * aspects applied automatically unless they ask for not applying them
- */
- public static final String ASPECT_POLICY_DIRECTIVE_OPT_OUT = "opt-out"; //$NON-NLS-1$
-
- /**
- * This indicates that there is no aspects policy defined
- */
- public static final int ASPECT_POLICY_NOT_DEFINED = 0;
-
- /**
- * Policy to indicate that the aspects of this package should only be woven
- * if the importer explicitly asks for it
- */
- public static final int ASPECT_POLICY_OPT_IN = 1;
-
- /**
- * Policy to indicate that the aspects of this package should automatically
- * be woven if the importer does not prohibit it
- */
- public static final int ASPECT_POLICY_OPT_OUT = 2;
-
- /**
- * directive to declare the exported aspects. The values should list the
- * aspect class names without the package
- */
- public static final String ASPECTS_ATTRIBUTE = "aspects"; //$NON-NLS-1$
-
- /**
- * Returns the cached aspect definition for the given bundle, if the bundle
- * has an aspect definition
- *
- * @param bundle The bundle for which the aspect definition should be
- * returned
- * @return The parsed and cached aspect definition for the given bundle or
- * null, if the bundle doesn't contain an aspect definition
- */
- public Definition getAspectDefinition(final Bundle bundle);
-
- /**
- * Gives information on which aspect policy is defined for the given package
- * of the given bundle
- *
- * @param bundle The bundle which contains the aspects for the given package
- * @param packageName The name of the package that contains the aspects
- * @return OPT_IN_POLICY or OPT_OUT_POLICY (where OPT_OUT_POLICY is the
- * defailt case)
- */
- public int getAspectPolicy(Bundle bundle, String packageName);
-
- /**
- * Returns the definitions of aspects whose packages are exported and
- * therefore visible to the outside of the bundle.
- *
- * @param bundle The bundle for which the visible aspects should be
- * calculated
- * @return The definition for the exported aspects or null, if no aspect is
- * visible
- */
- public Definition getExportedAspectDefinitions(final Bundle bundle);
-
- /**
- * Calculates the set of aspects to be woven if the given imported package
- * is wired to the given bundle (with the given policy on applying aspects)
- *
- * @param bundle The bundle from which the given package is imported
- * @param packageName The name of the package that is imported
- * @param applyAspectsPolicy the policy for applying visible aspects for
- * weaving
- * @return The set of aspects that should be woven from the given imported
- * package
- */
- public Definition resolveImportedPackage(final Bundle bundle,
- String packageName, final int applyAspectsPolicy);
-
- /**
- * Calculates the set of aspects to be woven if the given bundle is declared
- * as a required bundle (with the given policy on applying aspects)
- *
- * @param bundle The bundle which is required and might export aspects that
- * should be woven
- * @param applyAspectsPolicy the policy for applying visible aspects for
- * weaving
- * @return The set of aspects that should be woven from the given required
- * bundle
- */
- public Definition resolveRequiredBundle(final Bundle bundle,
- final int applyAspectsPolicy);
-
-}
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectConfiguration.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectConfiguration.java
deleted file mode 100644
index 2fc91d783..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectConfiguration.java
+++ /dev/null
@@ -1,70 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009 Martin Lippert and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Martin Lippert initial implementation
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj;
-
-import java.util.Arrays;
-import java.util.List;
-
-import org.aspectj.weaver.loadtime.definition.Definition;
-import org.osgi.framework.Bundle;
-
-/**
- * An aspect configuration object describes for one specific bundle which
- * aspects from which other bundles are declared to be woven into the bundle.
- *
- * @author Martin Lippert
- */
-public class AspectConfiguration {
-
- private final Definition[] aspectDefinitions;
-
- private final Bundle bundle;
-
- private final String fingerprint;
-
- /**
- * Creates a new aspect configuration object for the given bundle.
- *
- * @param bundle The host bundle this configuration belongs to
- * @param aspectDefinitions The set of aspect definitions for the weaver
- * @param fingerprint The fingerprint of the defined aspects
- */
- public AspectConfiguration(final Bundle bundle,
- final Definition[] aspectDefinitions, final String fingerprint) {
- this.bundle = bundle;
- this.fingerprint = fingerprint;
- this.aspectDefinitions = aspectDefinitions;
- }
-
- /**
- * @return The set of aspect configurations to be used by the weaver
- */
- public List<Definition> getAspectDefinitions() {
- return Arrays.asList(aspectDefinitions);
- }
-
- /**
- * @return The host bundle this aspect configuration belongs to
- */
- public Bundle getBundle() {
- return bundle;
- }
-
- /**
- * @return A short version of the different aspects being woven into this
- * bundle to be used as unique identifier for aspect configurations
- */
- public String getFingerprint() {
- return fingerprint;
- }
-
-}
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingActivator.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingActivator.java
deleted file mode 100644
index 79bddb620..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingActivator.java
+++ /dev/null
@@ -1,64 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009 Martin Lippert and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Martin Lippert initial implementation
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj;
-
-import java.lang.reflect.Method;
-
-import org.osgi.framework.BundleActivator;
-import org.osgi.framework.BundleContext;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class AspectJWeavingActivator implements BundleActivator {
-
- private static final String CHECK_ASPECTJ_CLASS = "org.aspectj.weaver.loadtime.definition.Definition"; //$NON-NLS-1$
-
- private static final String REAL_ACTIVATOR_CLASS = "org.eclipse.equinox.weaving.aspectj.AspectJWeavingStarter"; //$NON-NLS-1$
-
- private Object starter; // to decouple the optional dependencies
-
- private Class<?> starterClass;
-
- /**
- * @see org.osgi.framework.BundleActivator#start(org.osgi.framework.BundleContext)
- */
- public void start(final BundleContext context) throws Exception {
- final ClassLoader loader = this.getClass().getClassLoader();
-
- try {
- final Class<?> aspectjClass = loader.loadClass(CHECK_ASPECTJ_CLASS);
- if (aspectjClass != null) {
- starterClass = loader.loadClass(REAL_ACTIVATOR_CLASS);
- starter = starterClass.newInstance();
-
- final Method startMethod = starterClass.getMethod("start",
- BundleContext.class);
- startMethod.invoke(starter, context);
- }
- } catch (final Exception e) {
- e.printStackTrace();
- }
- }
-
- /**
- * @see org.osgi.framework.BundleActivator#stop(org.osgi.framework.BundleContext)
- */
- public void stop(final BundleContext context) throws Exception {
- if (starter != null) {
- final Method stopMethod = starterClass.getMethod("stop",
- BundleContext.class);
- stopMethod.invoke(starter, context);
- }
- }
-
-}
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingService.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingService.java
deleted file mode 100644
index e7d72647b..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingService.java
+++ /dev/null
@@ -1,164 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006, 2009 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * David Knibb initial implementation
- * Matthew Webster Eclipse 3.2 changes
- * Heiko Seeberger AJDT 1.5.1 changes
- * Martin Lippert weaving context and adaptors reworked
- * Martin Lippert extracted weaving service factory
- * Martin Lippert advanced aspect resolving implemented
- * Martin Lippert caching of generated classes
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj;
-
-import java.io.IOException;
-import java.util.HashMap;
-import java.util.List;
-import java.util.Map;
-
-import org.aspectj.weaver.loadtime.definition.Definition;
-import org.eclipse.equinox.service.weaving.ISupplementerRegistry;
-import org.eclipse.equinox.service.weaving.IWeavingService;
-import org.eclipse.equinox.weaving.aspectj.loadtime.AspectResolver;
-import org.eclipse.equinox.weaving.aspectj.loadtime.OSGiWeavingAdaptor;
-import org.eclipse.equinox.weaving.aspectj.loadtime.OSGiWeavingContext;
-import org.osgi.framework.Bundle;
-import org.osgi.framework.wiring.BundleRevision;
-
-public class AspectJWeavingService implements IWeavingService {
-
- private List<Definition> aspectDefinitions;
-
- private BundleRevision bundleRevision;
-
- private boolean enabled;
-
- private String namespaceAddOn;
-
- private OSGiWeavingAdaptor weavingAdaptor;
-
- private OSGiWeavingContext weavingContext;
-
- public AspectJWeavingService() {
- if (AspectJWeavingStarter.DEBUG)
- System.out.println("- WeavingService.<init>");
- }
-
- public AspectJWeavingService(final ClassLoader loader, final Bundle bundle,
- final BundleRevision bundleRevision,
- final ISupplementerRegistry supplementerRegistry,
- final AspectAdmin aspectAdmin) {
- this.bundleRevision = bundleRevision;
-
- final AspectResolver aspectResolver = new AspectResolver(
- supplementerRegistry, aspectAdmin, AspectJWeavingStarter
- .getDefault().getContext());
- final AspectConfiguration aspectConfig = aspectResolver
- .resolveAspectsFor(bundle, bundleRevision);
- this.namespaceAddOn = aspectConfig.getFingerprint();
- this.aspectDefinitions = aspectConfig.getAspectDefinitions();
-
- this.enabled = this.aspectDefinitions.size() > 0;
- if (this.enabled) {
- this.weavingContext = new OSGiWeavingContext(loader,
- bundleRevision, aspectDefinitions);
- this.weavingAdaptor = new OSGiWeavingAdaptor(loader,
- weavingContext, namespaceAddOn.toString());
- } else {
- if (AspectJWeavingStarter.DEBUG) {
- System.err
- .println("[org.eclipse.equinox.weaving.aspectj] info not weaving bundle '"
- + bundle.getSymbolicName() + "'");
- }
- }
- }
-
- private void ensureAdaptorInit() {
- weavingAdaptor.initialize();
- }
-
- /**
- * @see org.eclipse.equinox.service.weaving.IWeavingService#flushGeneratedClasses(java.lang.ClassLoader)
- */
- public void flushGeneratedClasses(final ClassLoader loader) {
- if (enabled) {
- ensureAdaptorInit();
- weavingAdaptor.flushGeneratedClasses();
- }
- }
-
- /**
- * @see org.eclipse.equinox.service.weaving.IWeavingService#generatedClassesExistFor(java.lang.ClassLoader,
- * java.lang.String)
- */
- public boolean generatedClassesExistFor(final ClassLoader loader,
- final String className) {
- if (enabled) {
- ensureAdaptorInit();
- return weavingAdaptor.generatedClassesExistFor(className);
- } else {
- return false;
- }
- }
-
- /**
- * @see org.eclipse.equinox.service.weaving.IWeavingService#getGeneratedClassesFor(java.lang.String)
- */
- public Map<String, byte[]> getGeneratedClassesFor(final String className) {
- if (enabled) {
- ensureAdaptorInit();
- return weavingAdaptor.getGeneratedClassesFor(className);
- } else {
- return new HashMap<String, byte[]>();
- }
- }
-
- /**
- * @see org.eclipse.equinox.service.weaving.IWeavingService#getKey()
- */
- public String getKey() {
- if (AspectJWeavingStarter.DEBUG)
- System.out.println("> WeavingService.getKey() bundle="
- + bundleRevision.getSymbolicName());
-
- final String namespace = namespaceAddOn.toString();
-
- if (AspectJWeavingStarter.DEBUG)
- System.out.println("< WeavingService.getKey() key='" + namespace
- + "'");
-
- return namespace;
- }
-
- /**
- * @see org.eclipse.equinox.service.weaving.IWeavingService#preProcess(java.lang.String,
- * byte[], java.lang.ClassLoader)
- */
- public byte[] preProcess(final String name, final byte[] classbytes,
- final ClassLoader loader) throws IOException {
- if (enabled) {
- if (AspectJWeavingStarter.DEBUG)
- System.out.println("> WeavingService.preProcess() bundle="
- + bundleRevision.getSymbolicName() + ", name=" + name
- + ", bytes=" + classbytes.length);
- byte[] newBytes;
- ensureAdaptorInit();
-
- // Bug 215177: Adapt to updated (AJ 1.5.4) signature.
- newBytes = weavingAdaptor.weaveClass(name, classbytes, false);
- if (AspectJWeavingStarter.DEBUG)
- System.out.println("< WeavingService.preProcess() bytes="
- + newBytes.length);
- return newBytes;
- } else {
- return null;
- }
- }
-
-}
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingServiceFactory.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingServiceFactory.java
deleted file mode 100644
index 115095a91..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingServiceFactory.java
+++ /dev/null
@@ -1,46 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008, 2009 Martin Lippert and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Martin Lippert initial implementation
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj;
-
-import org.eclipse.equinox.service.weaving.ISupplementerRegistry;
-import org.eclipse.equinox.service.weaving.IWeavingService;
-import org.eclipse.equinox.service.weaving.IWeavingServiceFactory;
-import org.eclipse.equinox.weaving.aspectj.loadtime.AspectAdminImpl;
-import org.osgi.framework.Bundle;
-import org.osgi.framework.wiring.BundleRevision;
-
-/**
- * The factory to create AspectJ-based weavers.
- *
- * @author martinlippert
- */
-public class AspectJWeavingServiceFactory implements IWeavingServiceFactory {
-
- private final AspectAdminImpl aspectDefinitionRegistry;
-
- public AspectJWeavingServiceFactory(
- final AspectAdminImpl aspectDefinitionRegistry) {
- this.aspectDefinitionRegistry = aspectDefinitionRegistry;
- }
-
- /**
- * @see org.eclipse.equinox.service.weaving.IWeavingServiceFactory#createWeavingService(ClassLoader,
- * Bundle, BundleRevision, ISupplementerRegistry)
- */
- public IWeavingService createWeavingService(final ClassLoader loader,
- final Bundle bundle, final BundleRevision bundleRevision,
- final ISupplementerRegistry supplementerRegistry) {
- return new AspectJWeavingService(loader, bundle, bundleRevision,
- supplementerRegistry, aspectDefinitionRegistry);
- }
-
-}
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingStarter.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingStarter.java
deleted file mode 100644
index da995c281..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/AspectJWeavingStarter.java
+++ /dev/null
@@ -1,108 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006, 2013 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * David Knibb initial implementation
- * Matthew Webster Eclipse 3.2 changes
- * Martin Lippert extracted weaving service factory
- * Martin Lippert dependencies to AspectJ packages made optional
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj;
-
-import org.eclipse.equinox.service.weaving.IWeavingServiceFactory;
-import org.eclipse.equinox.weaving.aspectj.loadtime.AspectAdminImpl;
-import org.eclipse.osgi.service.debug.DebugOptions;
-import org.osgi.framework.BundleActivator;
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.ServiceReference;
-
-/**
- * The main plugin class to be used in the desktop.
- */
-public class AspectJWeavingStarter implements BundleActivator {
-
- public static boolean DEBUG;
-
- public static boolean verbose = Boolean
- .getBoolean("org.aspectj.osgi.verbose");
-
- //The shared instance.
- private static AspectJWeavingStarter plugin;
-
- private AspectAdminImpl aspectDefinitionRegistry;
-
- private BundleContext context;
-
- /**
- * The constructor.
- */
- public AspectJWeavingStarter() {
- plugin = this;
- }
-
- /**
- * Returns the shared instance.
- */
- public static AspectJWeavingStarter getDefault() {
- return plugin;
- }
-
- /**
- * @return The bundle context of the weaving service bundle or null, of
- * bundle is not started
- */
- public BundleContext getContext() {
- return this.context;
- }
-
- /**
- * This method is called upon plug-in activation
- */
- public void start(final BundleContext context) throws Exception {
- this.context = context;
-
- this.aspectDefinitionRegistry = new AspectAdminImpl();
- context.addBundleListener(this.aspectDefinitionRegistry);
- this.aspectDefinitionRegistry.initialize(context.getBundles());
-
- loadOptions(context);
- if (verbose)
- System.err
- .println("[org.eclipse.equinox.weaving.aspectj] info Starting AspectJ weaving service ...");
- final String serviceName = IWeavingServiceFactory.class.getName();
- final IWeavingServiceFactory weavingServiceFactory = new AspectJWeavingServiceFactory(
- aspectDefinitionRegistry);
- context.registerService(serviceName, weavingServiceFactory, null);
- }
-
- /**
- * This method is called when the plug-in is stopped
- */
- public void stop(final BundleContext context) throws Exception {
- this.context = null;
- plugin = null;
- }
-
- private void loadOptions(final BundleContext context) {
- // all this is only to get the application args
- DebugOptions service = null;
- final ServiceReference<DebugOptions> reference = context
- .getServiceReference(DebugOptions.class);
- if (reference != null)
- service = context.getService(reference);
- if (service == null) return;
- try {
- DEBUG = service.getBooleanOption(
- "org.aspectj.osgi.service.weaving/debug", false);
- } finally {
- // we have what we want - release the service
- context.ungetService(reference);
- }
- }
-
-}
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/AspectAdminImpl.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/AspectAdminImpl.java
deleted file mode 100644
index 5a04602d9..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/AspectAdminImpl.java
+++ /dev/null
@@ -1,464 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2008, 2009 Martin Lippert and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Martin Lippert initial implementation
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj.loadtime;
-
-import java.net.URL;
-import java.util.Dictionary;
-import java.util.HashMap;
-import java.util.HashSet;
-import java.util.Iterator;
-import java.util.LinkedHashSet;
-import java.util.List;
-import java.util.Map;
-import java.util.Set;
-import java.util.concurrent.ConcurrentHashMap;
-
-import org.aspectj.weaver.loadtime.definition.Definition;
-import org.aspectj.weaver.loadtime.definition.DocumentParser;
-import org.aspectj.weaver.loadtime.definition.Definition.ConcreteAspect;
-import org.eclipse.equinox.weaving.aspectj.AspectAdmin;
-import org.eclipse.osgi.util.ManifestElement;
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleEvent;
-import org.osgi.framework.Constants;
-import org.osgi.framework.SynchronousBundleListener;
-
-/**
- * The AspectAdmin takes care of resolving aspect definitions of resolved
- * bundles and provides information which bundle should be woven with which
- * aspects.
- *
- * The AspectAdmin takes the aop.xml files into account as well as the aspect
- * definitions in the bundle manifests.
- *
- * All the information parsing and resolving is done at bundle resolve time, the
- * removal from the cache is done at unresolved events. The initial state is
- * re-created by the initialize method.
- *
- * @author Martin Lippert
- */
-public class AspectAdminImpl implements AspectAdmin, SynchronousBundleListener {
-
- // remember all aspect definitions for the given bundle (regardless of the way they are declared)
- private final Map<Bundle, Definition> aspectDefinitions;
-
- // remember only the exported aspect definitions for the given bundle (regardless of the way they are declared)
- private final Map<Bundle, Definition> aspectDefinitionsExported;
-
- // remember the aspect policies per exported package per bundle
- private final Map<Bundle, Map<String, Integer>> aspectPolicies;
-
- /**
- * Create a registry to manage aspect definition files
- */
- public AspectAdminImpl() {
- this.aspectDefinitions = new ConcurrentHashMap<Bundle, Definition>();
- this.aspectDefinitionsExported = new ConcurrentHashMap<Bundle, Definition>();
- this.aspectPolicies = new ConcurrentHashMap<Bundle, Map<String, Integer>>();
- }
-
- /**
- * @see org.osgi.framework.BundleListener#bundleChanged(org.osgi.framework.BundleEvent)
- */
- public void bundleChanged(final BundleEvent event) {
- if (event.getType() == BundleEvent.RESOLVED) {
- bundleResolved(event.getBundle());
- } else if (event.getType() == BundleEvent.UNRESOLVED) {
- bundleUnresolved(event.getBundle());
- }
- }
-
- /**
- * Do the parsing when a bundle is resolved
- *
- * @param bundle The bundle that is resolved (should not be null)
- */
- public void bundleResolved(final Bundle bundle) {
- if (!this.aspectDefinitions.containsKey(bundle)
- && !this.aspectDefinitionsExported.containsKey(bundle)
- && !this.aspectPolicies.containsKey(bundle)) {
- parseDefinitions(bundle);
- }
- }
-
- /**
- * Remove the cached aspect definitions from the aspect definition registry
- *
- * @param bundle The bundle that got unresolved (should not be null)
- */
- public void bundleUnresolved(final Bundle bundle) {
- this.aspectDefinitions.remove(bundle);
- this.aspectDefinitionsExported.remove(bundle);
- this.aspectPolicies.remove(bundle);
- }
-
- /**
- * @see org.eclipse.equinox.weaving.aspectj.AspectAdmin#getAspectDefinition(org.osgi.framework.Bundle)
- */
- public Definition getAspectDefinition(final Bundle bundle) {
- return this.aspectDefinitions.get(bundle);
- }
-
- /**
- * @see org.eclipse.equinox.weaving.aspectj.AspectAdmin#getAspectPolicy(org.osgi.framework.Bundle,
- * java.lang.String)
- */
- public int getAspectPolicy(final Bundle bundle, final String packageName) {
- final Map<String, Integer> policies = this.aspectPolicies.get(bundle);
- if (policies != null) {
- final Integer policy = policies.get(packageName);
- if (policy != null) {
- return policy;
- }
- }
-
- return AspectAdmin.ASPECT_POLICY_NOT_DEFINED;
- }
-
- /**
- * Finds the location of the aspect definition within the given bundle. The
- * default location is "META-INF/aop.xml", but if the bundles manifest
- * contains an entry for "Eclipse-AspectContext", that value is used to
- * search for the aop.xml file.
- *
- * @param bundle The bundle for which to calculate the location of the
- * aspect definition file
- * @return The path to the aspect definition relately to the given bundle
- */
- public String getDefinitionLocation(final Bundle bundle) {
- String aopContextHeader = bundle.getHeaders("").get( //$NON-NLS-1$
- AOP_CONTEXT_LOCATION_HEADER);
- if (aopContextHeader != null) {
- aopContextHeader = aopContextHeader.trim();
- return aopContextHeader;
- }
-
- return AOP_CONTEXT_DEFAULT_LOCATION;
- }
-
- /**
- * @see org.eclipse.equinox.weaving.aspectj.AspectAdmin#getExportedAspectDefinitions(org.osgi.framework.Bundle)
- */
- public Definition getExportedAspectDefinitions(final Bundle bundle) {
- return this.aspectDefinitionsExported.get(bundle);
- }
-
- /**
- * Initialize the state of the aspect definition registry for the given
- * bundles. This should typically be called when the weaving service bundle
- * is started to set up the aspect definitions for all resolved bundles
- *
- * @param bundles All bundles that should be taken into account and searched
- * for aspect definitions
- *
- */
- public void initialize(final Bundle[] bundles) {
- for (final Bundle bundle : bundles) {
- final int state = bundle.getState();
- if (state != Bundle.INSTALLED && state != Bundle.UNINSTALLED) {
- parseDefinitions(bundle);
- }
- }
- }
-
- /**
- * @see org.eclipse.equinox.weaving.aspectj.AspectAdmin#resolveImportedPackage(org.osgi.framework.Bundle,
- * java.lang.String, int)
- */
- public Definition resolveImportedPackage(final Bundle bundle,
- final String packageName, final int applyAspectsPolicy) {
- if (AspectAdmin.ASPECT_APPLY_POLICY_TRUE == applyAspectsPolicy) {
- final Definition exportedAspectDefinitions = getExportedAspectDefinitions(bundle);
- final Definition result = new Definition();
- if (exportedAspectDefinitions != null) {
- final List<?> aspectClassNames = exportedAspectDefinitions
- .getAspectClassNames();
- for (final Iterator<?> iterator = aspectClassNames.iterator(); iterator
- .hasNext();) {
- final String aspectName = (String) iterator.next();
- final String aspectPackageName = getPackage(aspectName);
- if (aspectPackageName.equals(packageName)) {
- result.getAspectClassNames().add(aspectName);
- }
- }
-
- final Iterator<?> concreteAspects = exportedAspectDefinitions
- .getConcreteAspects().iterator();
- while (concreteAspects.hasNext()) {
- final Definition.ConcreteAspect concreteAspect = (ConcreteAspect) concreteAspects
- .next();
- if (concreteAspect.name != null
- && getPackage(concreteAspect.name).equals(
- packageName)) {
- result.getConcreteAspects().add(concreteAspect);
- }
- }
-
- if (exportedAspectDefinitions.getWeaverOptions().trim()
- .length() > 0) {
- result.appendWeaverOptions(exportedAspectDefinitions
- .getWeaverOptions());
- }
- }
- if (result.getAspectClassNames().size() > 0
- || result.getConcreteAspects().size() > 0
- || result.getWeaverOptions().length() > 0) {
- return result;
- } else {
- return null;
- }
- } else if (AspectAdmin.ASPECT_APPLY_POLICY_FALSE == applyAspectsPolicy) {
- return null;
- } else {
- final Definition exportedAspectDefinitions = getExportedAspectDefinitions(bundle);
- final Definition result = new Definition();
- if (exportedAspectDefinitions != null) {
- final List<?> aspectClassNames = exportedAspectDefinitions
- .getAspectClassNames();
- for (final Iterator<?> iterator = aspectClassNames.iterator(); iterator
- .hasNext();) {
- final String aspectName = (String) iterator.next();
- final String aspectPackageName = getPackage(aspectName);
- final int aspectPolicy = getAspectPolicy(bundle,
- aspectPackageName);
- if (aspectPackageName.equals(packageName)
- && (AspectAdmin.ASPECT_POLICY_NOT_DEFINED == aspectPolicy || AspectAdmin.ASPECT_POLICY_OPT_OUT == aspectPolicy)) {
- result.getAspectClassNames().add(aspectName);
- }
- }
-
- final Iterator<?> concreteAspects = exportedAspectDefinitions
- .getConcreteAspects().iterator();
- while (concreteAspects.hasNext()) {
- final Definition.ConcreteAspect concreteAspect = (ConcreteAspect) concreteAspects
- .next();
-
- final String aspectPackageName = getPackage(concreteAspect.name);
- final int aspectPolicy = getAspectPolicy(bundle,
- aspectPackageName);
-
- if (aspectPackageName.equals(packageName)
- && (AspectAdmin.ASPECT_POLICY_NOT_DEFINED == aspectPolicy || AspectAdmin.ASPECT_POLICY_OPT_OUT == aspectPolicy)) {
- result.getConcreteAspects().add(concreteAspect);
- }
- }
-
- if (exportedAspectDefinitions.getWeaverOptions().trim()
- .length() > 0) {
- result.appendWeaverOptions(exportedAspectDefinitions
- .getWeaverOptions());
- }
- }
-
- if (result.getAspectClassNames().size() > 0
- || result.getConcreteAspects().size() > 0
- || result.getWeaverOptions().length() > 0) {
- return result;
- } else {
- return null;
- }
- }
- }
-
- /**
- * @see org.eclipse.equinox.weaving.aspectj.AspectAdmin#resolveRequiredBundle(org.osgi.framework.Bundle,
- * int)
- */
- public Definition resolveRequiredBundle(final Bundle bundle,
- final int applyAspectsPolicy) {
- if (AspectAdmin.ASPECT_APPLY_POLICY_TRUE == applyAspectsPolicy) {
- return getExportedAspectDefinitions(bundle);
- } else if (AspectAdmin.ASPECT_APPLY_POLICY_FALSE == applyAspectsPolicy) {
- return null;
- } else {
- final Definition exportedAspectDefinitions = getExportedAspectDefinitions(bundle);
- final Definition result = new Definition();
-
- if (exportedAspectDefinitions != null) {
- final Iterator<?> aspects = exportedAspectDefinitions
- .getAspectClassNames().iterator();
- while (aspects.hasNext()) {
- final String aspect = (String) aspects.next();
- final String aspectPackage = getPackage(aspect);
- final int aspectPolicy = getAspectPolicy(bundle,
- aspectPackage);
-
- if (aspectPolicy == AspectAdmin.ASPECT_POLICY_NOT_DEFINED
- || aspectPolicy == AspectAdmin.ASPECT_POLICY_OPT_OUT) {
- result.getAspectClassNames().add(aspect);
- }
- }
-
- final Iterator<?> concreteAspects = exportedAspectDefinitions
- .getConcreteAspects().iterator();
- while (concreteAspects.hasNext()) {
- final Definition.ConcreteAspect concreteAspect = (Definition.ConcreteAspect) concreteAspects
- .next();
- final String aspectPackage = getPackage(concreteAspect.name);
- final int aspectPolicy = getAspectPolicy(bundle,
- aspectPackage);
-
- if (aspectPolicy == AspectAdmin.ASPECT_POLICY_NOT_DEFINED
- || aspectPolicy == AspectAdmin.ASPECT_POLICY_OPT_OUT) {
- result.getConcreteAspects().add(concreteAspect);
- }
- }
-
- if (exportedAspectDefinitions.getWeaverOptions().trim()
- .length() > 0) {
- result.appendWeaverOptions(exportedAspectDefinitions
- .getWeaverOptions());
- }
- }
-
- if (result.getAspectClassNames().size() > 0
- || result.getConcreteAspects().size() > 0
- || result.getWeaverOptions().length() > 0) {
- return result;
- } else {
- return null;
- }
- }
- }
-
- /**
- * Parse the aspect definition for the given bundle, if there is one.
- *
- * @param bundle The bundle for which the aspect definition should be parsed
- */
- protected void parseDefinitions(final Bundle bundle) {
- try {
- Definition allAspectsDefinition = null;
- final Set<String> exportedAspects = new LinkedHashSet<String>();
- final Set<Definition.ConcreteAspect> exportedConcreteAspects = new HashSet<Definition.ConcreteAspect>();
- final Map<String, Integer> policies = new HashMap<String, Integer>();
- final Set<String> exportedPackages = new HashSet<String>();
-
- // try to find aop.xml file
- final String aopXmlLocation = getDefinitionLocation(bundle);
- final URL aopXmlDef = bundle.getEntry(aopXmlLocation);
- if (aopXmlDef != null) {
- allAspectsDefinition = DocumentParser.parse(aopXmlDef);
- }
-
- // parse export package headers
- final Dictionary<?, ?> manifest = bundle.getHeaders(""); //$NON-NLS-1$
- final ManifestElement[] exports = ManifestElement.parseHeader(
- Constants.EXPORT_PACKAGE, (String) manifest
- .get(Constants.EXPORT_PACKAGE));
-
- for (int i = 0; exports != null && i < exports.length; i++) {
- final String packageName = exports[i].getValue();
- exportedPackages.add(packageName);
-
- // policies
- final String policy = exports[i]
- .getDirective(ASPECT_POLICY_DIRECTIVE);
- if (policy != null
- && policy.trim().toLowerCase().equals(
- ASPECT_POLICY_DIRECTIVE_OPT_OUT)) {
- policies
- .put(packageName, AspectAdmin.ASPECT_POLICY_OPT_OUT);
- }
- if (policy != null
- && policy.trim().toLowerCase().equals(
- ASPECT_POLICY_DIRECTIVE_OPT_IN)) {
- policies.put(packageName, AspectAdmin.ASPECT_POLICY_OPT_IN);
- }
-
- // aspects
- final String allaspects = exports[i]
- .getAttribute(ASPECTS_ATTRIBUTE);
- if (allaspects != null) {
- final String[] aspects = ManifestElement
- .getArrayFromList(allaspects);
- if (aspects != null) {
- for (int j = 0; j < aspects.length; j++) {
- exportedAspects.add(packageName + "." + aspects[j]); //$NON-NLS-1$
- }
- }
- }
- }
-
- // add aop.xml declared aspects to the list of exported aspects if their packages are exported
- if (allAspectsDefinition != null
- && allAspectsDefinition.getAspectClassNames() != null) {
- final Iterator<?> iterator = allAspectsDefinition
- .getAspectClassNames().iterator();
- while (iterator.hasNext()) {
- final String aspect = (String) iterator.next();
- final String packageName = getPackage(aspect);
- if (exportedPackages.contains(packageName)) {
- exportedAspects.add(aspect);
- }
- }
- }
-
- if (allAspectsDefinition != null
- && allAspectsDefinition.getConcreteAspects().size() > 0) {
- final Iterator<?> iterator = allAspectsDefinition
- .getConcreteAspects().iterator();
- while (iterator.hasNext()) {
- final Definition.ConcreteAspect concreteAspect = (Definition.ConcreteAspect) iterator
- .next();
- if (concreteAspect.name != null
- && exportedPackages
- .contains(getPackage(concreteAspect.name))) {
- exportedConcreteAspects.add(concreteAspect);
- }
- }
- }
-
- if (allAspectsDefinition != null) {
- this.aspectDefinitions.put(bundle, allAspectsDefinition);
- }
-
- if (exportedAspects.size() > 0
- || exportedConcreteAspects.size() > 0
- || (allAspectsDefinition != null && allAspectsDefinition
- .getWeaverOptions().length() > 0)) {
- final Definition exportedAspectsDefinition = new Definition();
- exportedAspectsDefinition.getAspectClassNames().addAll(
- exportedAspects);
- exportedAspectsDefinition.getConcreteAspects().addAll(
- exportedConcreteAspects);
-
- if (allAspectsDefinition != null
- && allAspectsDefinition.getWeaverOptions().trim()
- .length() > 0) {
- exportedAspectsDefinition
- .appendWeaverOptions(allAspectsDefinition
- .getWeaverOptions());
- }
-
- this.aspectDefinitionsExported.put(bundle,
- exportedAspectsDefinition);
- }
-
- if (policies.size() > 0) {
- this.aspectPolicies.put(bundle, policies);
- }
-
- } catch (final Exception e) {
- e.printStackTrace();
- }
- }
-
- private String getPackage(final String aspect) {
- final int index = aspect.lastIndexOf('.');
- if (index >= 0) {
- return aspect.substring(0, index);
- } else {
- return ""; //$NON-NLS-1$
- }
- }
-}
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/AspectResolver.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/AspectResolver.java
deleted file mode 100644
index 95a565b36..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/AspectResolver.java
+++ /dev/null
@@ -1,268 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2009, 2013 Martin Lippert and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * Martin Lippert initial implementation
- * Martin Lippert fragment handling fixed
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj.loadtime;
-
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-
-import org.aspectj.weaver.loadtime.definition.Definition;
-import org.eclipse.equinox.service.weaving.ISupplementerRegistry;
-import org.eclipse.equinox.service.weaving.Supplementer;
-import org.eclipse.equinox.weaving.aspectj.AspectAdmin;
-import org.eclipse.equinox.weaving.aspectj.AspectConfiguration;
-import org.eclipse.osgi.util.ManifestElement;
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.BundleException;
-import org.osgi.framework.Constants;
-import org.osgi.framework.Version;
-import org.osgi.framework.namespace.BundleNamespace;
-import org.osgi.framework.namespace.HostNamespace;
-import org.osgi.framework.namespace.PackageNamespace;
-import org.osgi.framework.wiring.BundleRevision;
-import org.osgi.framework.wiring.BundleWire;
-import org.osgi.framework.wiring.BundleWiring;
-
-/**
- * The aspect resolver is responsible for finding the right connections between
- * bundles and aspects. It calculates the set of aspects that should be woven
- * into a specific bundle, depending on the resolved wires of the bundle and the
- * aspects declared by the wired bundles.
- *
- * @author Martin Lippert
- */
-public class AspectResolver {
-
- private final AspectAdmin aspectAdmin;
-
- private final ISupplementerRegistry supplementerRegistry;
-
- private final BundleContext weavingBundleContext;
-
- /**
- * Creates a new instance of an aspect resolver for the given state. This
- * resolver can be used to resolve aspect configurations for bundles. It
- * does not carry any own state, it just uses the injected components to
- * retrieve the necessary informaton to determine which aspects to weave
- * into which bundles.
- *
- * @param state The state of the OSGi framework (contains wiring
- * information)
- * @param supplementerRegistry The supplementer registry
- * @param aspectAdmin The aspect admin, which tells us which bundle exports
- * which aspects
- * @param bundleContext The bundle context in which the aspect resolver is
- * used
- */
- public AspectResolver(final ISupplementerRegistry supplementerRegistry,
- final AspectAdmin aspectAdmin, final BundleContext bundleContext) {
- this.supplementerRegistry = supplementerRegistry;
- this.aspectAdmin = aspectAdmin;
- this.weavingBundleContext = bundleContext;
- }
-
- private int getApplyAspectsPolicy(final ManifestElement[] headers,
- final String manifestValue) {
- int result = AspectAdmin.ASPECT_APPLY_POLICY_NOT_DEFINED;
-
- if (headers != null) {
- for (int i = 0; i < headers.length; i++) {
- if (headers[i].getValue().equals(manifestValue)) {
- final String directive = headers[i]
- .getDirective(AspectAdmin.ASPECT_APPLY_POLICY_DIRECTIVE);
- if ("true".equals(directive)) { //$NON-NLS-1$
- result = AspectAdmin.ASPECT_APPLY_POLICY_TRUE;
- } else if ("false".equals(directive)) { //$NON-NLS-1$
- result = AspectAdmin.ASPECT_APPLY_POLICY_FALSE;
- }
- }
- }
- }
- return result;
- }
-
- private String getBundleVersion(final Bundle bundle) {
- return bundle.getVersion().toString();
- }
-
- /**
- * Resolve the aspects to be woven into the given bundle
- *
- * @param bundle The bundle in which the aspects should be woven into
- * @param bundlerevision The revision of the bundle to be woven into
- * @return The configuration of aspects what should be woven into the bundle
- */
- public AspectConfiguration resolveAspectsFor(final Bundle bundle,
- final BundleRevision bundleRevision) {
- final List<String> fingerprintElements = new ArrayList<String>();
-
- final List<Definition> definitions = resolveAspectsForBundle(
- fingerprintElements, bundle, bundleRevision);
-
- final Definition[] foundDefinitions = definitions
- .toArray(new Definition[definitions.size()]);
-
- Collections.sort(fingerprintElements);
- final StringBuilder fingerprint = new StringBuilder();
- final Iterator<String> iterator = fingerprintElements.iterator();
- while (iterator.hasNext()) {
- final String element = iterator.next();
- fingerprint.append(element);
- fingerprint.append(';');
- }
-
- return new AspectConfiguration(bundle, foundDefinitions,
- fingerprint.toString());
- }
-
- private List<Definition> resolveAspectsForBundle(
- final List<String> fingerprintElements, final Bundle bundle,
- final BundleRevision bundleRevision) {
- final List<Definition> result = new ArrayList<Definition>();
- final BundleWiring wiring = bundleRevision.getWiring();
-
- if (wiring != null && weavingBundleContext != null) {
-
- Definition aspects = null;
-
- // fragments
- for (final BundleWire hostWire : wiring
- .getProvidedWires(HostNamespace.HOST_NAMESPACE)) {
- final Bundle fragmentBundle = hostWire.getRequirer()
- .getBundle();
- if (fragmentBundle != null) {
- aspects = aspectAdmin.getAspectDefinition(fragmentBundle);
- if (aspects != null) {
- result.add(aspects);
- fingerprintElements.add(fragmentBundle
- .getSymbolicName()
- + ":" //$NON-NLS-1$
- + hostWire.getRequirer().getVersion()
- .toString());
- }
- }
- }
-
- // required bundles
- final List<BundleWire> requiredBundles = wiring
- .getRequiredWires(BundleNamespace.BUNDLE_NAMESPACE);
- ManifestElement[] requireHeaders = null;
- if (!requiredBundles.isEmpty()) {
- try {
- requireHeaders = ManifestElement
- .parseHeader(
- Constants.REQUIRE_BUNDLE,
- bundle.getHeaders("").get(Constants.REQUIRE_BUNDLE)); //$NON-NLS-1$
- } catch (final BundleException e) {
- }
- }
- for (final BundleWire requiredBundleWire : requiredBundles) {
- final Bundle requiredBundle = requiredBundleWire.getProvider()
- .getBundle();
- if (requiredBundle != null) {
- final int applyPolicy = getApplyAspectsPolicy(
- requireHeaders, requiredBundle.getSymbolicName());
-
- aspects = aspectAdmin.resolveRequiredBundle(requiredBundle,
- applyPolicy);
-
- if (aspects != null) {
- result.add(aspects);
- fingerprintElements.add(requiredBundle
- .getSymbolicName()
- + ":" //$NON-NLS-1$
- + requiredBundleWire.getProvider().getVersion()
- .toString());
- }
- }
- }
-
- // imported packages
- final List<BundleWire> importedPackages = wiring
- .getRequiredWires(PackageNamespace.PACKAGE_NAMESPACE);
- ManifestElement[] importHeaders = null;
- if (!importedPackages.isEmpty()) {
- try {
- importHeaders = ManifestElement
- .parseHeader(
- Constants.IMPORT_PACKAGE,
- bundle.getHeaders("").get(Constants.IMPORT_PACKAGE)); //$NON-NLS-1$
- } catch (final BundleException e) {
- }
- }
- for (final BundleWire importPackageWire : importedPackages) {
- final Bundle exportingBundle = importPackageWire.getProvider()
- .getBundle();
- if (exportingBundle != null) {
- final String importedPackage = (String) importPackageWire
- .getCapability().getAttributes()
- .get(PackageNamespace.PACKAGE_NAMESPACE);
-
- final int applyPolicy = getApplyAspectsPolicy(
- importHeaders, importedPackage);
-
- aspects = aspectAdmin.resolveImportedPackage(
- exportingBundle, importedPackage, applyPolicy);
-
- if (aspects != null) {
- result.add(aspects);
- final Object v = importPackageWire
- .getCapability()
- .getAttributes()
- .get(PackageNamespace.CAPABILITY_VERSION_ATTRIBUTE);
- final String version = v == null ? Version.emptyVersion
- .toString() : v.toString();
- fingerprintElements.add(importedPackage + ":" //$NON-NLS-1$
- + version);
- }
- }
- }
-
- // supplementers
- final Supplementer[] supplementers = this.supplementerRegistry
- .getSupplementers(bundleRevision.getBundle().getBundleId());
-
- for (int i = 0; i < supplementers.length; i++) {
- aspects = aspectAdmin
- .getExportedAspectDefinitions(supplementers[i]
- .getSupplementerBundle());
- if (aspects != null) {
- result.add(aspects);
- fingerprintElements.add(supplementers[i].getSymbolicName()
- + ":" //$NON-NLS-1$
- + getBundleVersion(supplementers[i]
- .getSupplementerBundle()));
- }
- }
-
- // this bundle
- aspects = aspectAdmin.getAspectDefinition(bundle);
- if (aspects != null) {
- final String finishedValue = bundle.getHeaders("").get( //$NON-NLS-1$
- AspectAdmin.AOP_BUNDLE_FINISHED_HEADER);
- if (finishedValue == null
- || !AspectAdmin.AOP_BUNDLE_FINISHED_VALUE
- .equals(finishedValue)) {
- result.add(aspects);
- fingerprintElements.add(bundle.getSymbolicName() + ":" //$NON-NLS-1$
- + bundleRevision.getVersion().toString());
- }
- }
- }
-
- return result;
- }
-
-}
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/OSGiWeavingAdaptor.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/OSGiWeavingAdaptor.java
deleted file mode 100644
index b335b1563..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/OSGiWeavingAdaptor.java
+++ /dev/null
@@ -1,285 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006, 2013 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * David Knibb initial implementation
- * Matthew Webster Eclipse 3.2 changes
- * Heiko Seeberger AJDT 1.5.1 changes
- * Martin Lippert minor changes and bugfixes
- * Martin Lippert reworked
- * Martin Lippert caching of generated classes
- * Martin Lippert added locking for weaving
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj.loadtime;
-
-import java.io.IOException;
-import java.lang.reflect.InvocationTargetException;
-import java.lang.reflect.Method;
-import java.util.HashMap;
-import java.util.Iterator;
-import java.util.Map;
-import java.util.concurrent.ConcurrentLinkedQueue;
-
-import org.aspectj.weaver.IUnwovenClassFile;
-import org.aspectj.weaver.bcel.BcelWeakClassLoaderReference;
-import org.aspectj.weaver.loadtime.ClassLoaderWeavingAdaptor;
-import org.aspectj.weaver.tools.GeneratedClassHandler;
-import org.aspectj.weaver.tools.Trace;
-import org.aspectj.weaver.tools.TraceFactory;
-import org.eclipse.equinox.weaving.aspectj.AspectJWeavingStarter;
-
-/**
- * The weaving adaptor for AspectJs load-time weaving API that deals with the
- * OSGi specifics for load-time weaving
- */
-public class OSGiWeavingAdaptor extends ClassLoaderWeavingAdaptor {
-
- /**
- * internal class to collect generated classes (produced by the weaving) to
- * define then after the weaving itself
- */
- class GeneratedClass {
-
- private final byte[] bytes;
-
- private final String name;
-
- public GeneratedClass(final String name, final byte[] bytes) {
- this.name = name;
- this.bytes = bytes;
- }
-
- public byte[] getBytes() {
- return bytes;
- }
-
- public String getName() {
- return name;
- }
- }
-
- /**
- * generated class handler to collect generated classes (produced by the
- * weaving) to define then after the weaving itself
- */
- class OSGiGeneratedClassHandler implements GeneratedClassHandler {
-
- private final ConcurrentLinkedQueue<GeneratedClass> classesToBeDefined;
-
- private final BcelWeakClassLoaderReference loaderRef;
-
- public OSGiGeneratedClassHandler(final ClassLoader loader) {
- loaderRef = new BcelWeakClassLoaderReference(loader);
- classesToBeDefined = new ConcurrentLinkedQueue<GeneratedClass>();
- }
-
- /**
- * Callback when we need to define a generated class in the JVM (version
- * for older AspectJ versions)
- */
- public void acceptClass(final String name, final byte[] bytes) {
- try {
- if (shouldDump(name.replace('/', '.'), false)) {
- dump(name, bytes, false);
- }
- } catch (final Throwable throwable) {
- throwable.printStackTrace();
- }
- classesToBeDefined.offer(new GeneratedClass(name, bytes));
- }
-
- /**
- * Callback when we need to define a generated class in the JVM (version
- * for newer AspectJ versions, but we can ignore the originalBytes here)
- */
- public void acceptClass(final String name, final byte[] originalBytes,
- final byte[] weavedBytes) {
- acceptClass(name, weavedBytes);
- }
-
- public void defineGeneratedClasses() {
- while (!classesToBeDefined.isEmpty()) {
- final GeneratedClass generatedClass = classesToBeDefined.poll();
- if (generatedClass != null) {
- defineClass(loaderRef.getClassLoader(),
- generatedClass.getName(), generatedClass.getBytes());
- } else {
- break;
- }
- }
- }
-
- }
-
- private static Trace trace = TraceFactory.getTraceFactory().getTrace(
- ClassLoaderWeavingAdaptor.class);
-
- private final ClassLoader classLoader;
-
- private Method defineClassMethod;
-
- private boolean initialized;
-
- private final Object initializeLock = new Object();
-
- private final String namespace;
-
- private final OSGiWeavingContext weavingContext;
-
- /**
- * The OSGi weaving adaptor provides a bridge to the AspectJ weaving adaptor
- * implementation for general classloaders. This weaving adaptor exists per
- * bundle that should be woven.
- *
- * @param loader The classloader of the bundle to be woven
- * @param context The bridge to the weaving context
- * @param namespace The namespace of this adaptor, some kind of unique ID
- * for this weaver
- */
- public OSGiWeavingAdaptor(final ClassLoader loader,
- final OSGiWeavingContext context, final String namespace) {
- super();
- this.classLoader = loader;
- this.weavingContext = context;
- this.namespace = namespace;
- }
-
- private void defineClass(final ClassLoader loader, final String name,
- final byte[] bytes) {
- if (trace.isTraceEnabled()) {
- trace.enter("defineClass", this,
- new Object[] { loader, name, bytes });
- }
- Object clazz = null;
- debug("generating class '" + name + "'");
-
- try {
- if (defineClassMethod == null) {
- defineClassMethod = ClassLoader.class.getDeclaredMethod(
- "defineClass",
- new Class[] { String.class, bytes.getClass(),
- int.class, int.class });
- }
- defineClassMethod.setAccessible(true);
- clazz = defineClassMethod.invoke(loader, new Object[] { name,
- bytes, new Integer(0), new Integer(bytes.length) });
- } catch (final InvocationTargetException e) {
- if (e.getTargetException() instanceof LinkageError) {
- warn("define generated class failed", e.getTargetException());
- // is already defined (happens for X$ajcMightHaveAspect interfaces since aspects are reweaved)
- // TODO maw I don't think this is OK and
- } else {
- warn("define generated class failed", e.getTargetException());
- }
- } catch (final Exception e) {
- warn("define generated class failed", e);
- }
-
- if (trace.isTraceEnabled()) {
- trace.exit("defineClass", clazz);
- }
- }
-
- /**
- * In some situations the weaving creates new classes on the fly that are
- * not part of the original bundle. This is the case when the weaver needs
- * to create closure-like constructs for the woven code.
- *
- * This method returns a map of the generated classes (name -> bytecode) and
- * flushes the internal cache afterwards to avoid memory damage over time.
- *
- * @param className The name of the class for which additional classes might
- * got generated
- * @return the map of generated class names and bytecodes for those
- * generated classes
- */
- public Map<String, byte[]> getGeneratedClassesFor(final String className) {
- final Map<?, ?> generated = this.generatedClasses;
- final Map<String, byte[]> result = new HashMap<String, byte[]>();
-
- final Iterator<?> generatedClassNames = generated.keySet().iterator();
- while (generatedClassNames.hasNext()) {
- final String name = (String) generatedClassNames.next();
- final IUnwovenClassFile unwovenClass = (IUnwovenClassFile) generated
- .get(name);
-
- if (!className.equals(name)) {
- result.put(name, unwovenClass.getBytes());
- }
- }
-
- flushGeneratedClasses();
- return result;
- }
-
- /**
- * @see org.aspectj.weaver.loadtime.ClassLoaderWeavingAdaptor#getNamespace()
- */
- @Override
- public String getNamespace() {
- return namespace;
- }
-
- /**
- * initialize the weaving adaptor
- */
- public void initialize() {
- synchronized (initializeLock) {
- if (!initialized) {
- super.initialize(classLoader, weavingContext);
- this.generatedClassHandler = new OSGiGeneratedClassHandler(
- classLoader);
- initialized = true;
-
- if (AspectJWeavingStarter.verbose) {
- if (isEnabled()) {
- System.err
- .println("[org.eclipse.equinox.weaving.aspectj] info weaving bundle '"
- + weavingContext.getClassLoaderName()
- + "'");
- } else {
- System.err
- .println("[org.eclipse.equinox.weaving.aspectj] info not weaving bundle '"
- + weavingContext.getClassLoaderName()
- + "'");
- }
- }
- }
- }
-
- }
-
- /**
- * @see org.aspectj.weaver.tools.WeavingAdaptor#weaveClass(java.lang.String,
- * byte[], boolean)
- */
- @Override
- public byte[] weaveClass(final String name, byte[] bytes,
- final boolean mustWeave) throws IOException {
-
- /* Avoid recursion during adaptor initialization */
- synchronized (initializeLock) {
- if (!initialized) {
- super.initialize(classLoader, weavingContext);
- this.generatedClassHandler = new OSGiGeneratedClassHandler(
- classLoader);
- initialized = true;
- }
- }
-
- synchronized (this) {
- bytes = super.weaveClass(name, bytes, mustWeave);
- }
-
- ((OSGiGeneratedClassHandler) this.generatedClassHandler)
- .defineGeneratedClasses();
-
- return bytes;
- }
-
-}
diff --git a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/OSGiWeavingContext.java b/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/OSGiWeavingContext.java
deleted file mode 100644
index 804c75493..000000000
--- a/bundles/org.eclipse.equinox.weaving.aspectj/src/org/eclipse/equinox/weaving/aspectj/loadtime/OSGiWeavingContext.java
+++ /dev/null
@@ -1,86 +0,0 @@
-/*******************************************************************************
- * Copyright (c) 2006, 2013 IBM Corporation and others.
- * All rights reserved. This program and the accompanying materials
- * are made available under the terms of the Eclipse Public License v1.0
- * which accompanies this distribution, and is available at
- * http://www.eclipse.org/legal/epl-v10.html
- *
- * Contributors:
- * David Knibb initial implementation
- * Matthew Webster Eclipse 3.2 changes
- * Martin Lippert reworked
- *******************************************************************************/
-
-package org.eclipse.equinox.weaving.aspectj.loadtime;
-
-import java.net.URL;
-import java.util.List;
-
-import org.aspectj.weaver.loadtime.DefaultWeavingContext;
-import org.aspectj.weaver.loadtime.definition.Definition;
-import org.aspectj.weaver.tools.WeavingAdaptor;
-import org.eclipse.equinox.weaving.aspectj.AspectJWeavingStarter;
-import org.osgi.framework.wiring.BundleRevision;
-
-/**
- * The weaving context for AspectJs load-time weaving API that deals with the
- * OSGi specifics for load-time weaving
- */
-public class OSGiWeavingContext extends DefaultWeavingContext {
-
- private final List<Definition> aspectDefinitions;
-
- private final BundleRevision bundleRevision;
-
- public OSGiWeavingContext(final ClassLoader loader,
- final BundleRevision bundleRevision,
- final List<Definition> aspectDefinitions) {
- super(loader);
- this.bundleRevision = bundleRevision;
- this.aspectDefinitions = aspectDefinitions;
- if (AspectJWeavingStarter.DEBUG)
- System.out.println("- WeavingContext.WeavingContext() locader="
- + loader + ", bundle=" + bundleRevision.getSymbolicName());
- }
-
- /**
- * @see org.aspectj.weaver.loadtime.DefaultWeavingContext#getClassLoaderName()
- */
- @Override
- public String getClassLoaderName() {
- return bundleRevision.getSymbolicName();
- }
-
- /**
- * @see org.aspectj.weaver.loadtime.DefaultWeavingContext#getDefinitions(java.lang.ClassLoader,
- * org.aspectj.weaver.tools.WeavingAdaptor)
- */
- @Override
- public List<Definition> getDefinitions(final ClassLoader loader,
- final WeavingAdaptor adaptor) {
- return aspectDefinitions;
- }
-
- /**
- * @see org.aspectj.weaver.loadtime.DefaultWeavingContext#getFile(java.net.URL)
- */
- @Override
- public String getFile(final URL url) {
- return getBundleIdFromURL(url) + url.getFile();
- }
-
- /**
- * @see org.aspectj.weaver.loadtime.DefaultWeavingContext#getId()
- */
- @Override
- public String getId() {
- return bundleRevision.getSymbolicName();
- }
-
- @Override
- public String toString() {
- return getClass().getName() + "[" + bundleRevision.getSymbolicName()
- + "]";
- }
-
-}

Back to the top