You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@wicket.apache.org by iv...@apache.org on 2012/09/11 07:44:52 UTC
[5/7] git commit: brought over wicket-cdi and examples
brought over wicket-cdi and examples
Project: http://git-wip-us.apache.org/repos/asf/wicket/repo
Commit: http://git-wip-us.apache.org/repos/asf/wicket/commit/aae3a99c
Tree: http://git-wip-us.apache.org/repos/asf/wicket/tree/aae3a99c
Diff: http://git-wip-us.apache.org/repos/asf/wicket/diff/aae3a99c
Branch: refs/heads/master
Commit: aae3a99c2e453713504e65eaa537e08ffb28b446
Parents: 44d92f7
Author: Igor Vaynberg <ig...@gmail.com>
Authored: Mon Sep 10 15:01:01 2012 -0700
Committer: Igor Vaynberg <ig...@gmail.com>
Committed: Mon Sep 10 15:01:01 2012 -0700
----------------------------------------------------------------------
pom.xml | 7 +
wicket-cdi/.amateras | 12 +
.../.settings/org.eclipse.core.resources.prefs | 11 +
wicket-cdi/.settings/org.eclipse.jdt.core.prefs | 379 +++++++++++++++
wicket-cdi/.settings/org.eclipse.jdt.ui.prefs | 67 +++
wicket-cdi/.settings/org.eclipse.m2e.core.prefs | 5 +
wicket-cdi/.settings/org.eclipse.pde.core.prefs | 3 +
wicket-cdi/pom.xml | 57 +++
.../org/apache/wicket/cdi/AbstractInjector.java | 45 ++
.../org/apache/wicket/cdi/BehaviorInjector.java | 45 ++
.../org/apache/wicket/cdi/CdiConfiguration.java | 196 ++++++++
.../java/org/apache/wicket/cdi/CdiContainer.java | 167 +++++++
.../org/apache/wicket/cdi/CdiShutdownCleaner.java | 59 +++
.../org/apache/wicket/cdi/ComponentInjector.java | 46 ++
.../wicket/cdi/ConversationExpiredException.java | 51 ++
.../wicket/cdi/ConversationExpiryChecker.java | 72 +++
.../apache/wicket/cdi/ConversationIdMetaKey.java | 24 +
.../apache/wicket/cdi/ConversationPropagation.java | 78 +++
.../apache/wicket/cdi/ConversationPropagator.java | 342 +++++++++++++
.../java/org/apache/wicket/cdi/DetachEvent.java | 28 ++
.../org/apache/wicket/cdi/DetachEventEmitter.java | 78 +++
.../wicket/cdi/ICdiAwareRequestCycleListener.java | 39 ++
.../wicket/cdi/IConversationPropagation.java | 51 ++
.../apache/wicket/cdi/INonContextualManager.java | 55 +++
.../java/org/apache/wicket/cdi/NonContextual.java | 154 ++++++
.../apache/wicket/cdi/NonContextualManager.java | 78 +++
.../org/apache/wicket/cdi/SessionInjector.java | 46 ++
.../apache/wicket/cdi/ApacheLicenceHeaderTest.java | 41 ++
.../.settings/org.eclipse.m2e.core.prefs | 4 +
wicket-examples/pom.xml | 66 +++
.../wicket/examples/cdi/ApplicationCounter.java | 37 ++
.../apache/wicket/examples/cdi/CdiApplication.java | 48 ++
.../apache/wicket/examples/cdi/CdiExamplePage.html | 18 +
.../apache/wicket/examples/cdi/CdiExamplePage.java | 24 +
.../apache/wicket/examples/cdi/CdiHomePage.html | 16 +
.../apache/wicket/examples/cdi/CdiHomePage.java | 25 +
.../wicket/examples/cdi/ConversationCounter.java | 37 ++
.../wicket/examples/cdi/ConversationPage1.html | 20 +
.../wicket/examples/cdi/ConversationPage1.java | 59 +++
.../wicket/examples/cdi/ConversationPage2.html | 22 +
.../wicket/examples/cdi/ConversationPage2.java | 46 ++
.../wicket/examples/cdi/ConversationPage3.html | 13 +
.../wicket/examples/cdi/ConversationPage3.java | 33 ++
.../org/apache/wicket/examples/cdi/Counter.java | 35 ++
.../apache/wicket/examples/cdi/InjectionPage.html | 16 +
.../apache/wicket/examples/cdi/InjectionPage.java | 43 ++
.../apache/wicket/examples/homepage/HomePage.html | 1 +
wicket-examples/src/main/webapp/WEB-INF/web.xml | 23 +-
48 files changed, 2821 insertions(+), 1 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index f876512..4f22b24 100644
--- a/pom.xml
+++ b/pom.xml
@@ -44,6 +44,7 @@
<module>wicket-devutils</module>
<module>wicket-extensions</module>
<module>wicket-ioc</module>
+ <module>wicket-cdi</module>
<module>wicket-spring</module>
<module>wicket-velocity</module>
<module>wicket-auth-roles</module>
@@ -211,6 +212,12 @@
</dependency>
<dependency>
<groupId>org.apache.wicket</groupId>
+ <artifactId>wicket-cdi</artifactId>
+ <version>6.0-SNAPSHOT</version>
+ <type>jar</type>
+ </dependency>
+ <dependency>
+ <groupId>org.apache.wicket</groupId>
<artifactId>wicket-devutils</artifactId>
<version>6.0-SNAPSHOT</version>
<type>jar</type>
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/.amateras
----------------------------------------------------------------------
diff --git a/wicket-cdi/.amateras b/wicket-cdi/.amateras
new file mode 100755
index 0000000..a0cfe55
--- /dev/null
+++ b/wicket-cdi/.amateras
@@ -0,0 +1,12 @@
+#EclipseHTMLEditor configuration file
+#Sun Feb 21 21:11:11 PST 2010
+validateDTD=false
+javaScriptCompleters=
+useDTD=false
+validateJSP=false
+validateXML=false
+validateJS=false
+removeMarkers=true
+root=/
+validateHTML=false
+javaScripts=
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/.settings/org.eclipse.core.resources.prefs
----------------------------------------------------------------------
diff --git a/wicket-cdi/.settings/org.eclipse.core.resources.prefs b/wicket-cdi/.settings/org.eclipse.core.resources.prefs
new file mode 100644
index 0000000..eb4e8cf
--- /dev/null
+++ b/wicket-cdi/.settings/org.eclipse.core.resources.prefs
@@ -0,0 +1,11 @@
+#Mon Oct 10 10:40:56 EEST 2011
+eclipse.preferences.version=1
+encoding//.deprecations/DEPRECATE_wicket.markup.html.form.FormComponent.inputAsStringArray().xml=utf-8
+encoding//.deprecations/DEPRECATE_wicket.markup.html.list.ListView.setOptimizeItemRemoval(boolean).xml=utf-8
+encoding//.deprecations/DEPRECATE_wicket.markup.html.tree.Tree$TreePathsListView.getOptimizeItemRemoval().xml=utf-8
+encoding//src/java/wicket/Application_bg.properties=UTF-8
+encoding//src/main/java=UTF-8
+encoding//src/main/resources=UTF-8
+encoding//src/test/java=UTF-8
+encoding/<project>=UTF-8
+instance/org.eclipse.core.net/org.eclipse.core.net.hasMigrated=true
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/.settings/org.eclipse.jdt.core.prefs
----------------------------------------------------------------------
diff --git a/wicket-cdi/.settings/org.eclipse.jdt.core.prefs b/wicket-cdi/.settings/org.eclipse.jdt.core.prefs
new file mode 100644
index 0000000..3ce87ac
--- /dev/null
+++ b/wicket-cdi/.settings/org.eclipse.jdt.core.prefs
@@ -0,0 +1,379 @@
+eclipse.preferences.version=1
+encoding//src/main/java=UTF-8
+encoding//src/main/resources=UTF-8
+encoding//src/test/java=UTF-8
+instance/org.eclipse.core.net/org.eclipse.core.net.hasMigrated=true
+org.eclipse.jdt.core.builder.cleanOutputFolder=clean
+org.eclipse.jdt.core.builder.duplicateResourceTask=warning
+org.eclipse.jdt.core.builder.invalidClasspath=abort
+org.eclipse.jdt.core.builder.resourceCopyExclusionFilter=*.launch
+org.eclipse.jdt.core.circularClasspath=error
+org.eclipse.jdt.core.classpath.exclusionPatterns=enabled
+org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled
+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.maxProblemPerUnit=100
+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.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.fallthroughCase=ignore
+org.eclipse.jdt.core.compiler.problem.fatalOptionalError=enabled
+org.eclipse.jdt.core.compiler.problem.fieldHiding=ignore
+org.eclipse.jdt.core.compiler.problem.finalParameterBound=ignore
+org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning
+org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning
+org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning
+org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning
+org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=ignore
+org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore
+org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled
+org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=private
+org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore
+org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning
+org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=ignore
+org.eclipse.jdt.core.compiler.problem.missingJavadocComments=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public
+org.eclipse.jdt.core.compiler.problem.missingJavadocTags=warning
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=private
+org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=ignore
+org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning
+org.eclipse.jdt.core.compiler.problem.noEffectAssignment=warning
+org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning
+org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore
+org.eclipse.jdt.core.compiler.problem.nullReference=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.rawTypeReference=warning
+org.eclipse.jdt.core.compiler.problem.redundantNullCheck=ignore
+org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=ignore
+org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled
+org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning
+org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled
+org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore
+org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning
+org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=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=ignore
+org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore
+org.eclipse.jdt.core.compiler.problem.unsafeTypeOperation=warning
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=ignore
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled
+org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled
+org.eclipse.jdt.core.compiler.problem.unusedImport=warning
+org.eclipse.jdt.core.compiler.problem.unusedLabel=warning
+org.eclipse.jdt.core.compiler.problem.unusedLocal=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=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_annotation=0
+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=16
+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_method_declaration=0
+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_resources_in_try=80
+org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=80
+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=64
+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.alignment_for_union_type_in_multicatch=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=0
+org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
+org.eclipse.jdt.core.formatter.blank_lines_before_imports=0
+org.eclipse.jdt.core.formatter.blank_lines_before_member_type=0
+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=0
+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=next_line
+org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line
+org.eclipse.jdt.core.formatter.brace_position_for_block=next_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=next_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=next_line
+org.eclipse.jdt.core.formatter.brace_position_for_switch=next_line
+org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=next_line
+org.eclipse.jdt.core.formatter.comment.clear_blank_lines=false
+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_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=true
+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=insert
+org.eclipse.jdt.core.formatter.comment.line_length=100
+org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true
+org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true
+org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments=false
+org.eclipse.jdt.core.formatter.compact_else_if=true
+org.eclipse.jdt.core.formatter.continuation_indentation=1
+org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2
+org.eclipse.jdt.core.formatter.disabling_tag=@formatter\:off
+org.eclipse.jdt.core.formatter.enabling_tag=@formatter\:on
+org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false
+org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column=true
+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=true
+org.eclipse.jdt.core.formatter.indentation.size=4
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation=insert
+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_member=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=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type=insert
+org.eclipse.jdt.core.formatter.insert_new_line_after_label=do not 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=do not insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=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=insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=insert
+org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=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=do not 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_try=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_semicolon_in_try_resources=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_try=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=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert
+org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=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=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_try=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_semicolon_in_try_resources=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=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.join_lines_in_comments=true
+org.eclipse.jdt.core.formatter.join_wrapped_lines=true
+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=false
+org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false
+org.eclipse.jdt.core.formatter.lineSplit=100
+org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=true
+org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=true
+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=2
+org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true
+org.eclipse.jdt.core.formatter.tabulation.char=tab
+org.eclipse.jdt.core.formatter.tabulation.size=4
+org.eclipse.jdt.core.formatter.use_on_off_tags=true
+org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false
+org.eclipse.jdt.core.formatter.wrap_before_binary_operator=false
+org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch=true
+org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true
+org.eclipse.jdt.core.incompatibleJDKLevel=ignore
+org.eclipse.jdt.core.incompleteClasspath=error
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/.settings/org.eclipse.jdt.ui.prefs
----------------------------------------------------------------------
diff --git a/wicket-cdi/.settings/org.eclipse.jdt.ui.prefs b/wicket-cdi/.settings/org.eclipse.jdt.ui.prefs
new file mode 100644
index 0000000..b0868f5
--- /dev/null
+++ b/wicket-cdi/.settings/org.eclipse.jdt.ui.prefs
@@ -0,0 +1,67 @@
+comment_clear_blank_lines=false
+comment_format_comments=true
+comment_format_header=true
+comment_format_html=true
+comment_format_source_code=true
+comment_indent_parameter_description=true
+comment_indent_root_tags=true
+comment_line_length=80
+comment_new_line_for_parameter=true
+comment_separate_root_tags=true
+eclipse.preferences.version=1
+editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true
+formatter_profile=_Wicket
+formatter_settings_version=12
+instance/org.eclipse.core.net/org.eclipse.core.net.hasMigrated=true
+org.eclipse.jdt.ui.text.custom_code_templates=<?xml version\="1.0" encoding\="UTF-8" standalone\="no"?><templates><template autoinsert\="false" context\="gettercomment_context" deleted\="false" description\="Comment for getter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.gettercomment" name\="gettercomment">/**\r\n * Gets ${bare_field_name}.\r\n * @return ${bare_field_name}\r\n */</template><template autoinsert\="false" context\="settercomment_context" deleted\="false" description\="Comment for setter method" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.settercomment" name\="settercomment">/**\r\n * Sets ${bare_field_name}.\r\n * @param ${param} ${bare_field_name}\r\n */</template><template autoinsert\="false" context\="constructorcomment_context" deleted\="false" description\="Comment for created constructors" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.constructorcomment" name\="constructorcomment">/**\r\n * Construct.\r\n * ${tag
s}\r\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"/><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">/**\r\n * @author ${user}\r\n * ${tags}\r\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">/**\r\n * \r\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">/**\r\n * ${tags}\r\n */</templat
e><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">/**\r\n * ${see_to_overridden}\r\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">/*\r\n * Licensed to the Apache Software Foundation (ASF) under one or more\r\n * contributor license agreements. See the NOTICE file distributed with\r\n * this work for additional information regarding copyright ownership.\r\n * The ASF licenses this file to You under the Apache License, Version 2.0\r\n * (the "License"); you may not use this file except in compliance with\r\n * the License. You may obtain a copy of the License at\r\n *\r\n * http\://www.apache.org/licenses/LICENSE-2.0\r\n *\r\n * Unless require
d by applicable law or agreed to in writing, software\r\n * distributed under the License is distributed on an "AS IS" BASIS,\r\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\r\n * See the License for the specific language governing permissions and\r\n * limitations under the License.\r\n */\r\n${filecomment}\r\n${package_declaration}\r\n\r\n${typecomment}\r\n${type_declaration}</template><template autoinsert\="false" context\="catchblock_context" deleted\="false" description\="Code in new catch blocks" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.catchblock" name\="catchblock">throw new RuntimeException(${exception_var});</template><template autoinsert\="false" context\="methodbody_context" deleted\="false" description\="Code in created method stubs" enabled\="true" id\="org.eclipse.jdt.ui.text.codetemplates.methodbody" name\="methodbody">${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">${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><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">\r\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">\r\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">\r\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">\r\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">/**\r\n * ${tags}\r\n * ${see_to_target}\r\n */</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=false
+sp_cleanup.make_parameters_final=false
+sp_cleanup.make_private_fields_final=true
+sp_cleanup.make_type_abstract_if_missing_method=false
+sp_cleanup.make_variable_declarations_final=false
+sp_cleanup.never_use_blocks=false
+sp_cleanup.never_use_parentheses_in_expressions=true
+sp_cleanup.on_save_use_additional_actions=true
+sp_cleanup.organize_imports=true
+sp_cleanup.qualify_static_field_accesses_with_declaring_class=false
+sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=true
+sp_cleanup.qualify_static_member_accesses_with_declaring_class=true
+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=false
+sp_cleanup.sort_members_all=false
+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=true
+sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true
+sp_cleanup.use_this_for_non_static_method_access=true
+sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/.settings/org.eclipse.m2e.core.prefs
----------------------------------------------------------------------
diff --git a/wicket-cdi/.settings/org.eclipse.m2e.core.prefs b/wicket-cdi/.settings/org.eclipse.m2e.core.prefs
new file mode 100644
index 0000000..17d5ee05
--- /dev/null
+++ b/wicket-cdi/.settings/org.eclipse.m2e.core.prefs
@@ -0,0 +1,5 @@
+#Mon Sep 19 12:01:07 PDT 2011
+activeProfiles=
+eclipse.preferences.version=1
+resolveWorkspaceProjects=true
+version=1
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/.settings/org.eclipse.pde.core.prefs
----------------------------------------------------------------------
diff --git a/wicket-cdi/.settings/org.eclipse.pde.core.prefs b/wicket-cdi/.settings/org.eclipse.pde.core.prefs
new file mode 100644
index 0000000..1eb6077
--- /dev/null
+++ b/wicket-cdi/.settings/org.eclipse.pde.core.prefs
@@ -0,0 +1,3 @@
+#Mon Sep 19 12:02:51 PDT 2011
+BUNDLE_ROOT_PATH=target/classes
+eclipse.preferences.version=1
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/pom.xml
----------------------------------------------------------------------
diff --git a/wicket-cdi/pom.xml b/wicket-cdi/pom.xml
new file mode 100644
index 0000000..2ec438b
--- /dev/null
+++ b/wicket-cdi/pom.xml
@@ -0,0 +1,57 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+ Licensed to the Apache Software Foundation (ASF) under one or more
+ contributor license agreements. See the NOTICE file distributed with
+ this work for additional information regarding copyright ownership.
+ The ASF licenses this file to You under the Apache License, Version 2.0
+ (the "License"); you may not use this file except in compliance with
+ the License. You may obtain a copy of the License at
+
+ http://www.apache.org/licenses/LICENSE-2.0
+
+ Unless required by applicable law or agreed to in writing, software
+ distributed under the License is distributed on an "AS IS" BASIS,
+ WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ See the License for the specific language governing permissions and
+ limitations under the License.
+-->
+<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/maven-v4_0_0.xsd">
+ <modelVersion>4.0.0</modelVersion>
+ <parent>
+ <groupId>org.apache.wicket</groupId>
+ <artifactId>wicket-parent</artifactId>
+ <version>6.0-SNAPSHOT</version>
+ <relativePath>../pom.xml</relativePath>
+ </parent>
+ <artifactId>wicket-cdi</artifactId>
+ <packaging>jar</packaging>
+ <name>Wicket CDI Integration</name>
+ <description>
+ Provides integration between Wicket and CDI containers. Enables injection of
+ components and behaviors, as well as other non-contextual object instances.
+ Also enables propagation of conversations between wicket artifacts such as pages
+ and resources.
+ </description>
+ <dependencies>
+ <dependency>
+ <groupId>org.apache.wicket</groupId>
+ <artifactId>wicket-core</artifactId>
+ </dependency>
+ <dependency>
+ <groupId>javax.enterprise</groupId>
+ <artifactId>cdi-api</artifactId>
+ <version>1.0-SP4</version>
+ </dependency>
+ <dependency>
+ <groupId>org.jboss.seam.conversation</groupId>
+ <artifactId>seam-conversation-spi</artifactId>
+ <version>3.0.0.Final</version>
+ </dependency>
+ <dependency>
+ <groupId>junit</groupId>
+ <artifactId>junit</artifactId>
+ <scope>test</scope>
+ </dependency>
+ </dependencies>
+</project>
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/AbstractInjector.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/AbstractInjector.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/AbstractInjector.java
new file mode 100644
index 0000000..b77aa6e
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/AbstractInjector.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import org.apache.wicket.util.lang.Args;
+
+/**
+ * Base class for injectors
+ *
+ * @author igor
+ */
+class AbstractInjector
+{
+ private final CdiContainer container;
+
+ public AbstractInjector(CdiContainer container)
+ {
+ Args.notNull(container, "container");
+ this.container = container;
+ }
+
+ protected <T> void postConstruct(T instance)
+ {
+ container.getNonContextualManager().postConstruct(instance);
+ }
+
+ protected <T> void inject(T instance)
+ {
+ container.getNonContextualManager().inject(instance);
+ }
+}
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/BehaviorInjector.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/BehaviorInjector.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/BehaviorInjector.java
new file mode 100644
index 0000000..0ba6219
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/BehaviorInjector.java
@@ -0,0 +1,45 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import org.apache.wicket.IBehaviorInstantiationListener;
+import org.apache.wicket.behavior.Behavior;
+
+/**
+ * Injects components with CDI dependencies
+ *
+ * @author igor
+ *
+ */
+class BehaviorInjector extends AbstractInjector implements IBehaviorInstantiationListener
+{
+ /**
+ * Constructor
+ *
+ * @param container
+ */
+ public BehaviorInjector(CdiContainer container)
+ {
+ super(container);
+ }
+
+ @Override
+ public void onInstantiation(Behavior behavior)
+ {
+ inject(behavior);
+ }
+}
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiConfiguration.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiConfiguration.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiConfiguration.java
new file mode 100644
index 0000000..6a2bce6
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiConfiguration.java
@@ -0,0 +1,196 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import javax.enterprise.inject.spi.BeanManager;
+
+import org.apache.wicket.Application;
+import org.apache.wicket.request.cycle.RequestCycleListenerCollection;
+import org.apache.wicket.util.lang.Args;
+import org.jboss.seam.conversation.spi.SeamConversationContextFactory;
+
+/**
+ * Configures Weld integration
+ *
+ * @author igor
+ *
+ */
+public class CdiConfiguration
+{
+ private BeanManager beanManager;
+ private IConversationPropagation propagation = ConversationPropagation.NONBOOKMARKABLE;
+ private INonContextualManager nonContextualManager;
+
+ private boolean injectComponents = true;
+ private boolean injectApplication = true;
+ private boolean injectSession = true;
+ private boolean injectBehaviors = true;
+
+
+ /**
+ * Constructor
+ *
+ * @param beanManager
+ */
+ public CdiConfiguration(BeanManager beanManager)
+ {
+ Args.notNull(beanManager, "beanManager");
+
+ this.beanManager = beanManager;
+ nonContextualManager = new NonContextualManager(beanManager);
+ }
+
+ /**
+ * Gets the configured bean manager
+ *
+ * @return bean manager or {@code null} if none
+ */
+ public BeanManager getBeanManager()
+ {
+ return beanManager;
+ }
+
+ public IConversationPropagation getPropagation()
+ {
+ return propagation;
+ }
+
+ public CdiConfiguration setPropagation(IConversationPropagation propagation)
+ {
+ this.propagation = propagation;
+ return this;
+ }
+
+ public INonContextualManager getNonContextualManager()
+ {
+ return nonContextualManager;
+ }
+
+ public CdiConfiguration setNonContextualManager(INonContextualManager nonContextualManager)
+ {
+ this.nonContextualManager = nonContextualManager;
+ return this;
+ }
+
+ public boolean isInjectComponents()
+ {
+ return injectComponents;
+ }
+
+ public CdiConfiguration setInjectComponents(boolean injectComponents)
+ {
+ this.injectComponents = injectComponents;
+ return this;
+ }
+
+ public boolean isInjectApplication()
+ {
+ return injectApplication;
+ }
+
+ public CdiConfiguration setInjectApplication(boolean injectApplication)
+ {
+ this.injectApplication = injectApplication;
+ return this;
+ }
+
+ public boolean isInjectSession()
+ {
+ return injectSession;
+ }
+
+ public CdiConfiguration setInjectSession(boolean injectSession)
+ {
+ this.injectSession = injectSession;
+ return this;
+ }
+
+ public boolean isInjectBehaviors()
+ {
+ return injectBehaviors;
+ }
+
+ public CdiConfiguration setInjectBehaviors(boolean injectBehaviors)
+ {
+ this.injectBehaviors = injectBehaviors;
+ return this;
+ }
+
+ /**
+ * Configures the specified application
+ *
+ * @param application
+ * @return
+ */
+ public CdiContainer configure(Application application)
+ {
+ if (beanManager == null)
+ {
+ throw new IllegalStateException(
+ "Configuration does not have a BeanManager instance configured");
+ }
+
+ CdiContainer container = new CdiContainer(beanManager, nonContextualManager);
+ container.bind(application);
+
+ RequestCycleListenerCollection listeners = new RequestCycleListenerCollection();
+ application.getRequestCycleListeners().add(listeners);
+
+ // enable conversation propagation
+ if (getPropagation() != ConversationPropagation.NONE)
+ {
+ listeners.add(new ConversationPropagator(application, container, getPropagation()));
+ application.getComponentPreOnBeforeRenderListeners().add(
+ new ConversationExpiryChecker(container));
+ SeamConversationContextFactory.setDisableNoopInstance(true);
+ }
+
+ // enable detach event
+ listeners.add(new DetachEventEmitter(container));
+
+ // inject application instance
+ if (isInjectApplication())
+ {
+ container.getNonContextualManager().postConstruct(application);
+ }
+
+ // enable injection of various framework components
+
+ if (isInjectSession())
+ {
+ application.getSessionListeners().add(new SessionInjector(container));
+ }
+
+ if (isInjectComponents())
+ {
+ application.getComponentInstantiationListeners().add(new ComponentInjector(container));
+ }
+
+ if (isInjectBehaviors())
+ {
+ application.getBehaviorInstantiationListeners().add(new BehaviorInjector(container));
+ }
+
+ // enable cleanup
+
+ application.getApplicationListeners().add(
+ new CdiShutdownCleaner(beanManager, isInjectApplication()));
+
+ return container;
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiContainer.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiContainer.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiContainer.java
new file mode 100644
index 0000000..3a5cc96
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiContainer.java
@@ -0,0 +1,167 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import javax.enterprise.inject.spi.BeanManager;
+import javax.servlet.http.HttpServletRequest;
+
+import org.apache.wicket.Application;
+import org.apache.wicket.MetaDataKey;
+import org.apache.wicket.Page;
+import org.apache.wicket.request.cycle.RequestCycle;
+import org.apache.wicket.util.lang.Args;
+import org.jboss.seam.conversation.spi.SeamConversationContext;
+import org.jboss.seam.conversation.spi.SeamConversationContextFactory;
+
+/**
+ * Provides access to CDI features from inside a Wicket request
+ *
+ * @author igor
+ *
+ */
+public class CdiContainer
+{
+ private static final MetaDataKey<CdiContainer> CONTEXT_KEY = new MetaDataKey<CdiContainer>()
+ {
+ private static final long serialVersionUID = 1L;
+ };
+
+ protected final BeanManager beanManager;
+ private final SeamConversationContext<HttpServletRequest> conversationContext;
+ private final INonContextualManager nonContextualManager;
+
+ /**
+ * Constructor
+ *
+ * @param beanManager
+ * bean manager
+ */
+ public CdiContainer(BeanManager beanManager, INonContextualManager nonContextualManager)
+ {
+ Args.notNull(beanManager, "beanManager");
+ Args.notNull(nonContextualManager, "nonContextualManager");
+
+ this.beanManager = beanManager;
+ this.nonContextualManager = nonContextualManager;
+
+ conversationContext = SeamConversationContextFactory.getContext(HttpServletRequest.class);
+ if (conversationContext == null)
+ {
+ throw new IllegalStateException(
+ "Could not resolve conversation context manager. Make sure a Seam-Conversation module for your CDI container implementation is included in your dependencies.");
+ }
+ }
+
+ public INonContextualManager getNonContextualManager()
+ {
+ return nonContextualManager;
+ }
+
+ /**
+ * Deactivates conversational context
+ *
+ * @param cycle
+ */
+ public void deactivateConversationalContext(RequestCycle cycle)
+ {
+ conversationContext.deactivate();
+ conversationContext.dissociate(getRequest(cycle));
+ }
+
+ /**
+ * Activates the conversational context and starts the conversation with the specified cid
+ *
+ * @param cycle
+ * @param cid
+ */
+ public void activateConversationalContext(RequestCycle cycle, String cid)
+ {
+ conversationContext.associate(getRequest(cycle));
+ conversationContext.activate(cid);
+ }
+
+ private HttpServletRequest getRequest(RequestCycle cycle)
+ {
+ return (HttpServletRequest)cycle.getRequest().getContainerRequest();
+ }
+
+ /**
+ * Retrieves a conversation id, if any, that is associated with a {@link Page} instance
+ *
+ * @param page
+ * page instance
+ * @return conversation id, if any
+ */
+ public String getConversationMarker(Page page)
+ {
+ return page.getMetaData(ConversationIdMetaKey.INSTANCE);
+ }
+
+ /**
+ * Removes conversation marker from the page instance which prevents the conversation from
+ * propagating to the page. This method should usually be called from page's {@code onDetach()}
+ * method.
+ *
+ * @param page
+ */
+ public void removeConversationMarker(Page page)
+ {
+ Args.notNull(page, "page");
+
+ page.setMetaData(ConversationIdMetaKey.INSTANCE, null);
+ page.getPageParameters().remove(ConversationPropagator.CID);
+ }
+
+ /**
+ * Binds this container instance to the {@link Application}, making it possible to retrieve it
+ * later
+ *
+ * @param application
+ */
+ protected void bind(Application application)
+ {
+ application.setMetaData(CONTEXT_KEY, this);
+ }
+
+ /**
+ * Retrieves container instance stored in the application
+ *
+ * @param application
+ * @return container instance or {@code null} if none
+ */
+ public static final CdiContainer get(Application application)
+ {
+ CdiContainer ctx = application.getMetaData(CONTEXT_KEY);
+ if (ctx == null)
+ {
+ throw new IllegalStateException("No CDI Context bound to application");
+ }
+ return ctx;
+ }
+
+ /**
+ * Retrieves container instance stored in the current thread's application
+ *
+ * @return container instance or {@code null} if none
+ */
+ public static final CdiContainer get()
+ {
+ return get(Application.get());
+ }
+
+
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiShutdownCleaner.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiShutdownCleaner.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiShutdownCleaner.java
new file mode 100644
index 0000000..5cb8a6e
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/CdiShutdownCleaner.java
@@ -0,0 +1,59 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import javax.enterprise.inject.spi.BeanManager;
+
+import org.apache.wicket.Application;
+import org.apache.wicket.IApplicationListener;
+import org.apache.wicket.util.lang.Args;
+
+/**
+ * Listens to application shutdown and cleans up
+ *
+ * @author igor
+ */
+class CdiShutdownCleaner implements IApplicationListener
+{
+ private final BeanManager beanManager;
+ private final boolean preDestroyApplication;
+
+ public CdiShutdownCleaner(BeanManager beanManager, boolean preDestroyApplication)
+ {
+ Args.notNull(beanManager, "beanManager");
+
+ this.beanManager = beanManager;
+ this.preDestroyApplication = preDestroyApplication;
+ }
+
+ @Override
+ public void onAfterInitialized(Application application)
+ {
+ // noop
+ }
+
+ @Override
+ public void onBeforeDestroyed(Application application)
+ {
+ if (preDestroyApplication)
+ {
+ NonContextual.of(application.getClass(), beanManager).preDestroy(application);
+ }
+ NonContextual.undeploy(beanManager);
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/ComponentInjector.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/ComponentInjector.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ComponentInjector.java
new file mode 100644
index 0000000..bc302ef
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ComponentInjector.java
@@ -0,0 +1,46 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import org.apache.wicket.Component;
+import org.apache.wicket.application.IComponentInstantiationListener;
+
+/**
+ * Injects components with CDI dependencies
+ *
+ * @author igor
+ *
+ */
+class ComponentInjector extends AbstractInjector implements IComponentInstantiationListener
+{
+ /**
+ * Constructor
+ *
+ * @param container
+ */
+ public ComponentInjector(CdiContainer container)
+ {
+ super(container);
+ }
+
+ @Override
+ public void onInstantiation(Component component)
+ {
+ inject(component);
+ }
+
+}
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationExpiredException.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationExpiredException.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationExpiredException.java
new file mode 100644
index 0000000..7993ae4
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationExpiredException.java
@@ -0,0 +1,51 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import org.apache.wicket.Page;
+import org.apache.wicket.request.IRequestHandler;
+
+public class ConversationExpiredException extends RuntimeException
+{
+ private String cid;
+ private Page page;
+ private IRequestHandler handler;
+
+ public ConversationExpiredException(Throwable cause, String cid, Page page,
+ IRequestHandler handler)
+ {
+ super(cause);
+ this.cid = cid;
+ this.page = page;
+ this.handler = handler;
+ }
+
+ public String getCid()
+ {
+ return cid;
+ }
+
+ public Page getPage()
+ {
+ return page;
+ }
+
+ public IRequestHandler getHandler()
+ {
+ return handler;
+ }
+}
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationExpiryChecker.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationExpiryChecker.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationExpiryChecker.java
new file mode 100644
index 0000000..d58b417
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationExpiryChecker.java
@@ -0,0 +1,72 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import javax.enterprise.context.Conversation;
+import javax.inject.Inject;
+
+import org.apache.wicket.Component;
+import org.apache.wicket.Page;
+import org.apache.wicket.ajax.AjaxRequestTarget;
+import org.apache.wicket.application.IComponentOnBeforeRenderListener;
+import org.apache.wicket.request.cycle.RequestCycle;
+import org.apache.wicket.util.lang.Objects;
+import org.slf4j.Logger;
+import org.slf4j.LoggerFactory;
+
+/**
+ * Checks for conversation expiration during page render and throws a
+ * {@link ConversationExpiredException} when an expired conversation is detected.
+ *
+ * For example a link that calls {@link Conversation#end()} but does not redirect to a
+ * non-conversation-dependent page will be caught by this listener.
+ *
+ * @author igor
+ *
+ */
+public class ConversationExpiryChecker implements IComponentOnBeforeRenderListener
+{
+ private static final Logger logger = LoggerFactory.getLogger(ConversationExpiryChecker.class);
+
+ @Inject
+ private Conversation conversation;
+
+ private final CdiContainer container;
+
+ public ConversationExpiryChecker(CdiContainer container)
+ {
+ this.container = container;
+
+ container.getNonContextualManager().inject(this);
+ }
+
+ @Override
+ public void onBeforeRender(Component component)
+ {
+ if (component instanceof Page || RequestCycle.get().find(AjaxRequestTarget.class) != null)
+ {
+ Page page = component.getPage();
+ String cid = container.getConversationMarker(page);
+ if (cid != null && !Objects.isEqual(conversation.getId(), cid))
+ {
+ logger.info("Conversation {} has expired for {}", cid, page);
+ throw new ConversationExpiredException(null, cid, page, RequestCycle.get()
+ .getActiveRequestHandler());
+ }
+ }
+ }
+}
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationIdMetaKey.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationIdMetaKey.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationIdMetaKey.java
new file mode 100644
index 0000000..94cc70f
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationIdMetaKey.java
@@ -0,0 +1,24 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import org.apache.wicket.MetaDataKey;
+
+final class ConversationIdMetaKey extends MetaDataKey<String>
+{
+ static final ConversationIdMetaKey INSTANCE = new ConversationIdMetaKey();
+}
\ No newline at end of file
http://git-wip-us.apache.org/repos/asf/wicket/blob/aae3a99c/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationPropagation.java
----------------------------------------------------------------------
diff --git a/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationPropagation.java b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationPropagation.java
new file mode 100644
index 0000000..e70ff9c
--- /dev/null
+++ b/wicket-cdi/src/main/java/org/apache/wicket/cdi/ConversationPropagation.java
@@ -0,0 +1,78 @@
+/*
+ * Licensed to the Apache Software Foundation (ASF) under one or more
+ * contributor license agreements. See the NOTICE file distributed with
+ * this work for additional information regarding copyright ownership.
+ * The ASF licenses this file to You under the Apache License, Version 2.0
+ * (the "License"); you may not use this file except in compliance with
+ * the License. You may obtain a copy of the License at
+ *
+ * http://www.apache.org/licenses/LICENSE-2.0
+ *
+ * Unless required by applicable law or agreed to in writing, software
+ * distributed under the License is distributed on an "AS IS" BASIS,
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
+ * See the License for the specific language governing permissions and
+ * limitations under the License.
+ */
+package org.apache.wicket.cdi;
+
+import javax.enterprise.context.ConversationScoped;
+
+import org.apache.wicket.Page;
+import org.apache.wicket.request.IRequestHandler;
+
+/**
+ * Various modes of propagating persistent conversations across requests.
+ *
+ * @see ConversationScoped
+ *
+ * @author igor
+ */
+public enum ConversationPropagation implements IConversationPropagation {
+ /** No conversational propagation takes place */
+ NONE {
+ @Override
+ public boolean propagatesViaPage(Page page, IRequestHandler handler)
+ {
+ return false;
+ }
+
+ @Override
+ public boolean propagatesViaParameters(IRequestHandler handler)
+ {
+ return false;
+ }
+ },
+ /**
+ * Pesistent conversations are propagated between non-bookmarkable pages only
+ */
+ NONBOOKMARKABLE {
+ @Override
+ public boolean propagatesViaPage(Page page, IRequestHandler handler)
+ {
+ return true;
+ }
+
+ @Override
+ public boolean propagatesViaParameters(IRequestHandler handler)
+ {
+ return false;
+ }
+ },
+ /**
+ * Persistent conversations are propagated between bookmarkable and non-bookmarkable pages
+ */
+ ALL {
+ @Override
+ public boolean propagatesViaPage(Page page, IRequestHandler handler)
+ {
+ return true;
+ }
+
+ @Override
+ public boolean propagatesViaParameters(IRequestHandler handler)
+ {
+ return true;
+ }
+ };
+}