Whitespace polishing: leading spaces->tabs; updated eclipse configuration to default to leading tabs for all bundles
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
#Fri Oct 24 14:55:27 EDT 2008
|
||||
#Thu Dec 18 06:34:11 PST 2008
|
||||
eclipse.preferences.version=1
|
||||
org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled
|
||||
org.eclipse.jdt.core.compiler.codegen.targetPlatform=1.6
|
||||
@@ -10,3 +10,259 @@ org.eclipse.jdt.core.compiler.debug.sourceFile=generate
|
||||
org.eclipse.jdt.core.compiler.problem.assertIdentifier=error
|
||||
org.eclipse.jdt.core.compiler.problem.enumIdentifier=error
|
||||
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=0
|
||||
org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0
|
||||
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=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=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=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=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_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_parameter=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=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=false
|
||||
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=tab
|
||||
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
|
||||
|
||||
@@ -0,0 +1,4 @@
|
||||
#Thu Dec 18 06:34:11 PST 2008
|
||||
eclipse.preferences.version=1
|
||||
formatter_profile=org.eclipse.jdt.ui.default.eclipse_profile
|
||||
formatter_settings_version=11
|
||||
@@ -36,35 +36,35 @@ import org.springframework.beans.factory.InitializingBean;
|
||||
*/
|
||||
public class CommonsLogFactoryBean implements FactoryBean<Log>, InitializingBean {
|
||||
|
||||
private Log log;
|
||||
private Log log;
|
||||
|
||||
|
||||
/**
|
||||
* The name of the log.
|
||||
* <p>This property is required.
|
||||
* @param logName the name of the log
|
||||
*/
|
||||
public void setLogName(String logName) {
|
||||
this.log = LogFactory.getLog(logName);
|
||||
}
|
||||
/**
|
||||
* The name of the log.
|
||||
* <p>This property is required.
|
||||
* @param logName the name of the log
|
||||
*/
|
||||
public void setLogName(String logName) {
|
||||
this.log = LogFactory.getLog(logName);
|
||||
}
|
||||
|
||||
|
||||
public void afterPropertiesSet() {
|
||||
if (this.log == null) {
|
||||
throw new IllegalArgumentException("'logName' is required");
|
||||
}
|
||||
}
|
||||
public void afterPropertiesSet() {
|
||||
if (this.log == null) {
|
||||
throw new IllegalArgumentException("'logName' is required");
|
||||
}
|
||||
}
|
||||
|
||||
public Log getObject() {
|
||||
return this.log;
|
||||
}
|
||||
public Log getObject() {
|
||||
return this.log;
|
||||
}
|
||||
|
||||
public Class<? extends Log> getObjectType() {
|
||||
return (this.log != null ? this.log.getClass() : Log.class);
|
||||
}
|
||||
public Class<? extends Log> getObjectType() {
|
||||
return (this.log != null ? this.log.getClass() : Log.class);
|
||||
}
|
||||
|
||||
public boolean isSingleton() {
|
||||
return true;
|
||||
}
|
||||
public boolean isSingleton() {
|
||||
return true;
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -92,7 +92,7 @@ import org.springframework.util.StringValueResolver;
|
||||
* @see PropertyOverrideConfigurer
|
||||
*/
|
||||
public class PropertyPlaceholderConfigurer extends PropertyResourceConfigurer
|
||||
implements BeanNameAware, BeanFactoryAware {
|
||||
implements BeanNameAware, BeanFactoryAware {
|
||||
|
||||
/** Default placeholder prefix: "${" */
|
||||
public static final String DEFAULT_PLACEHOLDER_PREFIX = "${";
|
||||
@@ -288,7 +288,7 @@ public class PropertyPlaceholderConfigurer extends PropertyResourceConfigurer
|
||||
* @see #resolvePlaceholder(String, java.util.Properties, int)
|
||||
*/
|
||||
protected String parseStringValue(String strVal, Properties props, Set<String> visitedPlaceholders)
|
||||
throws BeanDefinitionStoreException {
|
||||
throws BeanDefinitionStoreException {
|
||||
|
||||
StringBuilder buf = new StringBuilder(strVal);
|
||||
|
||||
|
||||
@@ -80,7 +80,7 @@ import org.springframework.util.StringUtils;
|
||||
* @see org.springframework.beans.factory.xml.XmlBeanDefinitionReader
|
||||
*/
|
||||
public class DefaultListableBeanFactory extends AbstractAutowireCapableBeanFactory
|
||||
implements ConfigurableListableBeanFactory, BeanDefinitionRegistry {
|
||||
implements ConfigurableListableBeanFactory, BeanDefinitionRegistry {
|
||||
|
||||
/** Whether to allow re-registration of a different definition with the same name */
|
||||
private boolean allowBeanDefinitionOverriding = true;
|
||||
|
||||
@@ -1311,7 +1311,7 @@ public class BeanWrapperTests extends TestCase {
|
||||
}
|
||||
|
||||
public void testSetNumberProperties() {
|
||||
NumberPropertyBean bean = new NumberPropertyBean();
|
||||
NumberPropertyBean bean = new NumberPropertyBean();
|
||||
BeanWrapper bw = new BeanWrapperImpl(bean);
|
||||
|
||||
String byteValue = " " + Byte.MAX_VALUE + " ";
|
||||
|
||||
@@ -1973,7 +1973,7 @@ public class DefaultListableBeanFactoryTests {
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
private void doTestFieldSettingWithInstantiationAwarePostProcessor(final boolean skipPropertyPopulation) {
|
||||
private void doTestFieldSettingWithInstantiationAwarePostProcessor(final boolean skipPropertyPopulation) {
|
||||
DefaultListableBeanFactory lbf = new DefaultListableBeanFactory();
|
||||
RootBeanDefinition bd = new RootBeanDefinition(TestBean.class);
|
||||
int ageSetByPropertyValue = 27;
|
||||
@@ -2008,7 +2008,7 @@ public class DefaultListableBeanFactoryTests {
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
@Test
|
||||
@Test
|
||||
public void testInitSecurityAwarePrototypeBean() {
|
||||
final DefaultListableBeanFactory lbf = new DefaultListableBeanFactory();
|
||||
RootBeanDefinition bd = new RootBeanDefinition(TestSecuredBean.class);
|
||||
@@ -2267,7 +2267,7 @@ public class DefaultListableBeanFactoryTests {
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
public Object convertIfNecessary(Object value, Class requiredType) {
|
||||
public Object convertIfNecessary(Object value, Class requiredType) {
|
||||
return convertIfNecessary(value, requiredType, null);
|
||||
}
|
||||
|
||||
|
||||
@@ -24,5 +24,5 @@ package org.springframework.beans.factory;
|
||||
*/
|
||||
class PackageLevelVisibleBean {
|
||||
|
||||
public static final String CONSTANT = "Wuby";
|
||||
}
|
||||
public static final String CONSTANT = "Wuby";
|
||||
}
|
||||
|
||||
@@ -53,9 +53,9 @@ import org.springframework.core.io.Resource;
|
||||
* @author Chris Beams
|
||||
*/
|
||||
public class PropertyResourceConfigurerTests {
|
||||
|
||||
|
||||
private DefaultListableBeanFactory factory;
|
||||
|
||||
|
||||
@Before
|
||||
public void setUp() {
|
||||
factory = new DefaultListableBeanFactory();
|
||||
@@ -67,15 +67,15 @@ public class PropertyResourceConfigurerTests {
|
||||
.genericBeanDefinition(TestBean.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("tb1", def1);
|
||||
|
||||
|
||||
BeanDefinition def2 = BeanDefinitionBuilder
|
||||
.genericBeanDefinition(TestBean.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("tb2", def2);
|
||||
|
||||
|
||||
PropertyOverrideConfigurer poc1;
|
||||
PropertyOverrideConfigurer poc2;
|
||||
|
||||
|
||||
{
|
||||
poc1 = new PropertyOverrideConfigurer();
|
||||
Properties props = new Properties();
|
||||
@@ -83,7 +83,7 @@ public class PropertyResourceConfigurerTests {
|
||||
props.setProperty("tb2.name", "test");
|
||||
poc1.setProperties(props);
|
||||
}
|
||||
|
||||
|
||||
{
|
||||
poc2 = new PropertyOverrideConfigurer();
|
||||
Properties props = new Properties();
|
||||
@@ -91,14 +91,14 @@ public class PropertyResourceConfigurerTests {
|
||||
props.setProperty("tb2.name", "test2");
|
||||
poc2.setProperties(props);
|
||||
}
|
||||
|
||||
|
||||
// emulate what happens when BFPPs are added to an application context: It's LIFO-based
|
||||
poc2.postProcessBeanFactory(factory);
|
||||
poc1.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb1 = (TestBean) factory.getBean("tb1");
|
||||
TestBean tb2 = (TestBean) factory.getBean("tb2");
|
||||
|
||||
|
||||
assertEquals(99, tb1.getAge());
|
||||
assertEquals(99, tb2.getAge());
|
||||
assertEquals(null, tb1.getName());
|
||||
@@ -111,7 +111,7 @@ public class PropertyResourceConfigurerTests {
|
||||
.genericBeanDefinition(IndexedTestBean.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("tb", def);
|
||||
|
||||
|
||||
PropertyOverrideConfigurer poc;
|
||||
poc = new PropertyOverrideConfigurer();
|
||||
Properties props = new Properties();
|
||||
@@ -119,7 +119,7 @@ public class PropertyResourceConfigurerTests {
|
||||
props.setProperty("tb.list[1].name", "test");
|
||||
poc.setProperties(props);
|
||||
poc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
IndexedTestBean tb = (IndexedTestBean) factory.getBean("tb");
|
||||
assertEquals(99, tb.getArray()[0].getAge());
|
||||
assertEquals("test", ((TestBean) tb.getList().get(1)).getName());
|
||||
@@ -131,7 +131,7 @@ public class PropertyResourceConfigurerTests {
|
||||
.genericBeanDefinition(IndexedTestBean.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("my.tb", def);
|
||||
|
||||
|
||||
PropertyOverrideConfigurer poc;
|
||||
poc = new PropertyOverrideConfigurer();
|
||||
Properties props = new Properties();
|
||||
@@ -140,7 +140,7 @@ public class PropertyResourceConfigurerTests {
|
||||
poc.setProperties(props);
|
||||
poc.setBeanNameSeparator("_");
|
||||
poc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
IndexedTestBean tb = (IndexedTestBean) factory.getBean("my.tb");
|
||||
assertEquals(99, tb.getArray()[0].getAge());
|
||||
assertEquals("test", ((TestBean) tb.getList().get(1)).getName());
|
||||
@@ -152,7 +152,7 @@ public class PropertyResourceConfigurerTests {
|
||||
.genericBeanDefinition(IndexedTestBean.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("tb", def);
|
||||
|
||||
|
||||
PropertyOverrideConfigurer poc;
|
||||
poc = new PropertyOverrideConfigurer();
|
||||
Properties props = new Properties();
|
||||
@@ -160,40 +160,40 @@ public class PropertyResourceConfigurerTests {
|
||||
props.setProperty("tb.map[key2.ext]", "test");
|
||||
poc.setProperties(props);
|
||||
poc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
IndexedTestBean tb = (IndexedTestBean) factory.getBean("tb");
|
||||
assertEquals("99", tb.getMap().get("key1"));
|
||||
assertEquals("test", tb.getMap().get("key2.ext"));
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
public void testPropertyOverrideConfigurerWithHeldProperties() {
|
||||
BeanDefinition def = BeanDefinitionBuilder
|
||||
.genericBeanDefinition(PropertiesHolder.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("tb", def);
|
||||
|
||||
|
||||
PropertyOverrideConfigurer poc;
|
||||
poc = new PropertyOverrideConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.setProperty("tb.heldProperties[mail.smtp.auth]", "true");
|
||||
poc.setProperties(props);
|
||||
poc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
PropertiesHolder tb = (PropertiesHolder) factory.getBean("tb");
|
||||
assertEquals("true", tb.getHeldProperties().getProperty("mail.smtp.auth"));
|
||||
}
|
||||
|
||||
|
||||
static class PropertiesHolder {
|
||||
private Properties props = new Properties();
|
||||
private Properties props = new Properties();
|
||||
|
||||
public Properties getHeldProperties() {
|
||||
return props;
|
||||
}
|
||||
public Properties getHeldProperties() {
|
||||
return props;
|
||||
}
|
||||
|
||||
public void setHeldProperties(Properties props) {
|
||||
this.props = props;
|
||||
}
|
||||
public void setHeldProperties(Properties props) {
|
||||
this.props = props;
|
||||
}
|
||||
}
|
||||
|
||||
@Test
|
||||
@@ -202,11 +202,11 @@ public class PropertyResourceConfigurerTests {
|
||||
.genericBeanDefinition(IndexedTestBean.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("tb", def);
|
||||
|
||||
|
||||
PropertyOverrideConfigurer poc = new PropertyOverrideConfigurer();
|
||||
poc.setLocation(new ClassPathResource("org/springframework/beans/factory/config/test.properties"));
|
||||
poc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
IndexedTestBean tb = (IndexedTestBean) factory.getBean("tb");
|
||||
assertEquals(99, tb.getArray()[0].getAge());
|
||||
assertEquals("test", ((TestBean) tb.getList().get(1)).getName());
|
||||
@@ -218,7 +218,7 @@ public class PropertyResourceConfigurerTests {
|
||||
.genericBeanDefinition(IndexedTestBean.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("tb", def);
|
||||
|
||||
|
||||
PropertyOverrideConfigurer poc = new PropertyOverrideConfigurer();
|
||||
poc.setLocations(new Resource[] {
|
||||
new ClassPathResource("org/springframework/beans/factory/config/test.properties"),
|
||||
@@ -227,7 +227,7 @@ public class PropertyResourceConfigurerTests {
|
||||
);
|
||||
poc.setIgnoreResourceNotFound(true);
|
||||
poc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
IndexedTestBean tb = (IndexedTestBean) factory.getBean("tb");
|
||||
assertEquals(99, tb.getArray()[0].getAge());
|
||||
assertEquals("test", ((TestBean) tb.getList().get(1)).getName());
|
||||
@@ -239,11 +239,11 @@ public class PropertyResourceConfigurerTests {
|
||||
.genericBeanDefinition(IndexedTestBean.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("tb", def);
|
||||
|
||||
|
||||
PropertyOverrideConfigurer poc = new PropertyOverrideConfigurer();
|
||||
poc.setLocation(new ClassPathResource("org/springframework/beans/factory/config/test-properties.xml"));
|
||||
poc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
IndexedTestBean tb = (IndexedTestBean) factory.getBean("tb");
|
||||
assertEquals(99, tb.getArray()[0].getAge());
|
||||
assertEquals("test", ((TestBean) tb.getList().get(1)).getName());
|
||||
@@ -255,14 +255,14 @@ public class PropertyResourceConfigurerTests {
|
||||
.genericBeanDefinition(IndexedTestBean.class)
|
||||
.getBeanDefinition();
|
||||
factory.registerBeanDefinition("tb", def);
|
||||
|
||||
|
||||
ConvertingOverrideConfigurer bfpp = new ConvertingOverrideConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.setProperty("tb.array[0].name", "99");
|
||||
props.setProperty("tb.list[1].name", "test");
|
||||
bfpp.setProperties(props);
|
||||
bfpp.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
IndexedTestBean tb = (IndexedTestBean) factory.getBean("tb");
|
||||
assertEquals("X99", tb.getArray()[0].getName());
|
||||
assertEquals("Xtest", ((TestBean) tb.getList().get(1)).getName());
|
||||
@@ -272,7 +272,7 @@ public class PropertyResourceConfigurerTests {
|
||||
public void testPropertyOverrideConfigurerWithInvalidKey() {
|
||||
factory.registerBeanDefinition("tb1", genericBeanDefinition(TestBean.class).getBeanDefinition());
|
||||
factory.registerBeanDefinition("tb2", genericBeanDefinition(TestBean.class).getBeanDefinition());
|
||||
|
||||
|
||||
{
|
||||
PropertyOverrideConfigurer poc = new PropertyOverrideConfigurer();
|
||||
poc.setIgnoreInvalidKeys(true);
|
||||
@@ -303,7 +303,7 @@ public class PropertyResourceConfigurerTests {
|
||||
public void testPropertyOverrideConfigurerWithIgnoreInvalidKeys() {
|
||||
factory.registerBeanDefinition("tb1", genericBeanDefinition(TestBean.class).getBeanDefinition());
|
||||
factory.registerBeanDefinition("tb2", genericBeanDefinition(TestBean.class).getBeanDefinition());
|
||||
|
||||
|
||||
{
|
||||
PropertyOverrideConfigurer poc = new PropertyOverrideConfigurer();
|
||||
Properties props = new Properties();
|
||||
@@ -323,7 +323,7 @@ public class PropertyResourceConfigurerTests {
|
||||
poc.setProperties(props);
|
||||
poc.postProcessBeanFactory(factory);
|
||||
}
|
||||
|
||||
|
||||
TestBean tb1 = (TestBean) factory.getBean("tb1");
|
||||
TestBean tb2 = (TestBean) factory.getBean("tb2");
|
||||
assertEquals(99, tb1.getAge());
|
||||
@@ -440,7 +440,7 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("touchy", "${os.name}").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
@@ -453,13 +453,13 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("touchy", "${os.name}").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.setProperty("os.name", "myos");
|
||||
ppc.setProperties(props);
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertEquals("myos", tb.getTouchy());
|
||||
}
|
||||
@@ -469,14 +469,14 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("touchy", "${os.name}").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.put("os.name", "myos");
|
||||
ppc.setProperties(props);
|
||||
ppc.setSystemPropertiesMode(PropertyPlaceholderConfigurer.SYSTEM_PROPERTIES_MODE_OVERRIDE);
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertEquals(System.getProperty("os.name"), tb.getTouchy());
|
||||
}
|
||||
@@ -486,10 +486,10 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("touchy", "${user.dir}").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
ppc.setSystemPropertiesMode(PropertyPlaceholderConfigurer.SYSTEM_PROPERTIES_MODE_NEVER);
|
||||
|
||||
|
||||
try {
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
fail("Should have thrown BeanDefinitionStoreException");
|
||||
@@ -505,9 +505,9 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("name", "${ref}").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
|
||||
|
||||
try {
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
fail("Should have thrown BeanDefinitionStoreException");
|
||||
@@ -523,11 +523,11 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("name", "${ref}").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
ppc.setIgnoreUnresolvablePlaceholders(true);
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertEquals("${ref}", tb.getName());
|
||||
}
|
||||
@@ -537,11 +537,11 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("name", "").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
ppc.setNullValue("");
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertNull(tb.getName());
|
||||
}
|
||||
@@ -551,14 +551,14 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("name", "${ref}").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
ppc.setNullValue("");
|
||||
Properties props = new Properties();
|
||||
props.put("ref", "");
|
||||
ppc.setProperties(props);
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertNull(tb.getName());
|
||||
}
|
||||
@@ -568,18 +568,18 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("name", "${my${key}key}").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.put("key", "new");
|
||||
props.put("mynewkey", "myname");
|
||||
ppc.setProperties(props);
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertEquals("myname", tb.getName());
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
public void testPropertyPlaceholderConfigurerWithCircularReference() {
|
||||
factory.registerBeanDefinition("tb",
|
||||
@@ -587,14 +587,14 @@ public class PropertyResourceConfigurerTests {
|
||||
.addPropertyValue("age", "${age}")
|
||||
.addPropertyValue("name", "name${var}")
|
||||
.getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.setProperty("age", "99");
|
||||
props.setProperty("var", "${m}");
|
||||
props.setProperty("m", "${var}");
|
||||
ppc.setProperties(props);
|
||||
|
||||
|
||||
try {
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
fail("Should have thrown BeanDefinitionStoreException");
|
||||
@@ -609,13 +609,13 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("touchy", "${test}").getBeanDefinition());
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.put("test", "mytest");
|
||||
ppc.setProperties(props);
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertEquals("mytest", tb.getTouchy());
|
||||
}
|
||||
@@ -648,10 +648,10 @@ public class PropertyResourceConfigurerTests {
|
||||
factory.registerBeanDefinition("tb",
|
||||
genericBeanDefinition(TestBean.class)
|
||||
.addPropertyValue("touchy", "${test}").getBeanDefinition());
|
||||
|
||||
|
||||
factory.registerAlias("tb", "${myAlias}");
|
||||
factory.registerAlias("${myTarget}", "alias2");
|
||||
|
||||
|
||||
PropertyPlaceholderConfigurer ppc = new PropertyPlaceholderConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.put("test", "mytest");
|
||||
@@ -659,7 +659,7 @@ public class PropertyResourceConfigurerTests {
|
||||
props.put("myTarget", "tb");
|
||||
ppc.setProperties(props);
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertEquals("mytest", tb.getTouchy());
|
||||
tb = (TestBean) factory.getBean("alias");
|
||||
@@ -676,7 +676,7 @@ public class PropertyResourceConfigurerTests {
|
||||
.addPropertyValue("age", "${myAge}")
|
||||
.addPropertyValue("touchy", "${myTouchy}")
|
||||
.getBeanDefinition());
|
||||
|
||||
|
||||
PreferencesPlaceholderConfigurer ppc = new PreferencesPlaceholderConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.put("myAge", "99");
|
||||
@@ -704,7 +704,7 @@ public class PropertyResourceConfigurerTests {
|
||||
.addPropertyValue("age", "${myAge}")
|
||||
.addPropertyValue("touchy", "${myTouchy}")
|
||||
.getBeanDefinition());
|
||||
|
||||
|
||||
PreferencesPlaceholderConfigurer ppc = new PreferencesPlaceholderConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.put("myAge", "99");
|
||||
@@ -716,7 +716,7 @@ public class PropertyResourceConfigurerTests {
|
||||
Preferences.userRoot().node("myUserPath").put("myTouchy", "myOtherTouchyValue");
|
||||
ppc.afterPropertiesSet();
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertEquals("myNameValue", tb.getName());
|
||||
assertEquals(99, tb.getAge());
|
||||
@@ -734,7 +734,7 @@ public class PropertyResourceConfigurerTests {
|
||||
.addPropertyValue("age", "${myAge}")
|
||||
.addPropertyValue("touchy", "${myotherpath/myTouchy}")
|
||||
.getBeanDefinition());
|
||||
|
||||
|
||||
PreferencesPlaceholderConfigurer ppc = new PreferencesPlaceholderConfigurer();
|
||||
Properties props = new Properties();
|
||||
props.put("myAge", "99");
|
||||
@@ -746,7 +746,7 @@ public class PropertyResourceConfigurerTests {
|
||||
Preferences.userRoot().node("myUserPath/myotherpath").put("myTouchy", "myOtherTouchyValue");
|
||||
ppc.afterPropertiesSet();
|
||||
ppc.postProcessBeanFactory(factory);
|
||||
|
||||
|
||||
TestBean tb = (TestBean) factory.getBean("tb");
|
||||
assertEquals("myNameValue", tb.getName());
|
||||
assertEquals(99, tb.getAge());
|
||||
|
||||
@@ -337,26 +337,26 @@ public class FactoryMethodTests {
|
||||
assertEquals("someuser", session.getProperty("mail.smtp.user"));
|
||||
assertEquals("somepw", session.getProperty("mail.smtp.password"));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
class MailSession {
|
||||
private Properties props;
|
||||
|
||||
private MailSession() {
|
||||
private MailSession() {
|
||||
}
|
||||
|
||||
|
||||
public void setProperties(Properties props) {
|
||||
this.props = props;
|
||||
this.props = props;
|
||||
}
|
||||
|
||||
public static MailSession getDefaultInstance(Properties props) {
|
||||
MailSession session = new MailSession();
|
||||
session.setProperties(props);
|
||||
return session;
|
||||
}
|
||||
|
||||
public Object getProperty(String key) {
|
||||
return props.get(key);
|
||||
}
|
||||
|
||||
public static MailSession getDefaultInstance(Properties props) {
|
||||
MailSession session = new MailSession();
|
||||
session.setProperties(props);
|
||||
return session;
|
||||
}
|
||||
|
||||
public Object getProperty(String key) {
|
||||
return props.get(key);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -31,7 +31,7 @@ import org.springframework.util.comparator.CompoundComparator;
|
||||
*/
|
||||
public class PropertyComparatorTests {
|
||||
|
||||
@Test
|
||||
@Test
|
||||
public void testPropertyComparator() {
|
||||
Dog dog = new Dog();
|
||||
dog.setNickName("mace");
|
||||
@@ -45,7 +45,7 @@ public class PropertyComparatorTests {
|
||||
assertTrue(c.compare(dog2, dog) < 0);
|
||||
}
|
||||
|
||||
@Test
|
||||
@Test
|
||||
public void testPropertyComparatorNulls() {
|
||||
Dog dog = new Dog();
|
||||
Dog dog2 = new Dog();
|
||||
@@ -53,8 +53,8 @@ public class PropertyComparatorTests {
|
||||
assertTrue(c.compare(dog, dog2) == 0);
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
@Test
|
||||
@SuppressWarnings("unchecked")
|
||||
@Test
|
||||
public void testCompoundComparator() {
|
||||
CompoundComparator<Dog> c = new CompoundComparator<Dog>();
|
||||
c.addComparator(new PropertyComparator("lastName", false, true));
|
||||
@@ -76,8 +76,8 @@ public class PropertyComparatorTests {
|
||||
assertTrue(c.compare(dog2, dog1) > 0);
|
||||
}
|
||||
|
||||
@SuppressWarnings("unchecked")
|
||||
@Test
|
||||
@SuppressWarnings("unchecked")
|
||||
@Test
|
||||
public void testCompoundComparatorInvert() {
|
||||
CompoundComparator<Dog> c = new CompoundComparator<Dog>();
|
||||
c.addComparator(new PropertyComparator("lastName", false, true));
|
||||
|
||||
Reference in New Issue
Block a user