diff --git a/.gitignore b/.gitignore index a648df837..aaa1fee14 100644 --- a/.gitignore +++ b/.gitignore @@ -5,8 +5,9 @@ _LOCAL/ /bin /*/bin **/.settings/* -!**/.settings/org.eclipse.core.resoures.prefs +!**/.settings/org.eclipse.core.resources.prefs !**/.settings/org.eclipse.jdt.core.prefs +!**/.settings/org.eclipse.jdt.ui.prefs !**/.settings/org.eclipse.pde.core.prefs .pydevproject .tycho-consumer-pom.xml diff --git a/.settings/org.eclipse.core.resources.prefs b/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.core.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.core.tests/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.core.tests/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.core.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.core.tests/.settings/org.eclipse.jdt.core.prefs index 42ea09faa..31d9c27e0 100644 --- a/org.eclipse.tm4e.core.tests/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.core.tests/.settings/org.eclipse.jdt.core.prefs @@ -1,14 +1,27 @@ eclipse.preferences.version=1 -org.eclipse.jdt.core.builder.annotationPath.allLocations=disabled +org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary= +org.eclipse.jdt.core.compiler.annotation.notowning=org.eclipse.jdt.annotation.NotOwning org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable org.eclipse.jdt.core.compiler.annotation.nullable.secondary= org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=disabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 @@ -18,6 +31,7 @@ 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=200 org.eclipse.jdt.core.compiler.problem.APILeak=warning org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning @@ -42,8 +56,10 @@ org.eclipse.jdt.core.compiler.problem.forbiddenReference=error org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=enabled org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompatibleOwningContract=warning org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.insufficientResourceAnalysis=warning org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled @@ -72,15 +88,15 @@ org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning -org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning -org.eclipse.jdt.core.compiler.problem.nullReference=warning -org.eclipse.jdt.core.compiler.problem.nullSpecViolation=warning -org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning +org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error +org.eclipse.jdt.core.compiler.problem.nullReference=error +org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error +org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=info org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning -org.eclipse.jdt.core.compiler.problem.potentialNullReference=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=error org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning @@ -92,7 +108,7 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled @@ -118,6 +134,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverridin org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedImport=warning org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning org.eclipse.jdt.core.compiler.problem.unusedLocal=warning org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning org.eclipse.jdt.core.compiler.problem.unusedParameter=warning @@ -130,6 +147,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -170,6 +188,7 @@ org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0 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_permitted_types_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_record_components=16 org.eclipse.jdt.core.formatter.alignment_for_relational_operator=0 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 @@ -206,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -232,6 +252,7 @@ org.eclipse.jdt.core.formatter.comment.indent_tag_description=false org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_between_different_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.javadoc_do_not_separate_block_tags=false org.eclipse.jdt.core.formatter.comment.line_length=140 org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true @@ -265,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -460,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -524,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.core.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.core.tests/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.core.tests/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.core/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.core/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.core/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.core/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.core/.settings/org.eclipse.jdt.core.prefs index 543db3986..75d9b0744 100644 --- a/org.eclipse.tm4e.core/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.core/.settings/org.eclipse.jdt.core.prefs @@ -1,7 +1,17 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault @@ -11,7 +21,7 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul org.eclipse.jdt.core.compiler.annotation.nullable.secondary= org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning -org.eclipse.jdt.core.compiler.annotation.resourceanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=enabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 @@ -21,6 +31,7 @@ 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=200 org.eclipse.jdt.core.compiler.problem.APILeak=warning org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning @@ -97,7 +108,7 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled @@ -123,6 +134,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverridin org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedImport=warning org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning org.eclipse.jdt.core.compiler.problem.unusedLocal=warning org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning org.eclipse.jdt.core.compiler.problem.unusedParameter=warning @@ -135,6 +147,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -175,6 +188,7 @@ org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0 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_permitted_types_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_record_components=16 org.eclipse.jdt.core.formatter.alignment_for_relational_operator=0 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 @@ -211,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -237,6 +252,7 @@ org.eclipse.jdt.core.formatter.comment.indent_tag_description=false org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_between_different_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.javadoc_do_not_separate_block_tags=false org.eclipse.jdt.core.formatter.comment.line_length=140 org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true @@ -270,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -465,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -529,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.core/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.core/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.core/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/grammar/LineTokenizer.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/grammar/LineTokenizer.java index def919d11..6f45fbff3 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/grammar/LineTokenizer.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/grammar/LineTokenizer.java @@ -193,9 +193,9 @@ private void scanNext() { // custom tm4e code - not from upstream (for TMPartitioner) // make sure origin grammar scope is present when external - AttributedScopeStack baseNames = castNonNull(stack.contentNameScopesList); + final AttributedScopeStack baseNames = castNonNull(stack.contentNameScopesList); final var nameScopesList = baseNames.pushAttributed(scopeName, grammar); - final String frameGrammarScope = (rule.grammarScope != null && !rule.grammarScope.equals(grammar.getScopeName())) + final String frameGrammarScope = rule.grammarScope != null && !rule.grammarScope.equals(grammar.getScopeName()) ? rule.grammarScope : stack.grammarScope; @@ -508,11 +508,11 @@ private void handleCaptures(final Grammar grammar, final OnigString lineText, fi final var scopeName = captureRule.getName(lineTextContent, captureIndices); // custom tm4e code - not from upstream (for TMPartitioner) - AttributedScopeStack baseNames = castNonNull(stack.contentNameScopesList); + final AttributedScopeStack baseNames = castNonNull(stack.contentNameScopesList); final var retokenizeRule = grammar.getRule(retokenizeCapturedWithRuleId); final var grammarScope = retokenizeRule.grammarScope; final var nameScopesList = baseNames.pushAttributed(scopeName, grammar); - final String frameGrammarScope = (grammarScope != null && !grammarScope.equals(grammar.getScopeName())) + final String frameGrammarScope = grammarScope != null && !grammarScope.equals(grammar.getScopeName()) ? grammarScope : stack.grammarScope; diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/grammar/raw/RawRule.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/grammar/raw/RawRule.java index 1ec7d64b1..33d8db628 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/grammar/raw/RawRule.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/grammar/raw/RawRule.java @@ -149,15 +149,11 @@ public RawRule setPatterns(final @Nullable Collection patterns) { @Override public boolean isApplyEndPatternLast() { final Object applyEndPatternLast = get(APPLY_END_PATTERN_LAST); - if (applyEndPatternLast == null) { - return false; - } - if (applyEndPatternLast instanceof final Boolean asBool) { - return asBool; - } - if (applyEndPatternLast instanceof final Integer asInt) { - return asInt == 1; - } - return false; + return switch (applyEndPatternLast) { + case null -> false; + case Boolean asBool -> asBool; + case Integer asInt -> asInt == 1; + default -> false; + }; } } diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/TMParserJSON.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/TMParserJSON.java index b7013e0c2..fb84b3d53 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/TMParserJSON.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/parser/TMParserJSON.java @@ -21,6 +21,7 @@ import java.util.stream.Collectors; import org.eclipse.jdt.annotation.NonNull; +import org.eclipse.jdt.annotation.NotOwning; import com.google.gson.Gson; @@ -50,14 +51,15 @@ private static String removeTrailingCommas(final String jsonString) { protected TMParserJSON() { } - protected Map loadRaw(final Reader source) { + protected Map loadRaw(final @NotOwning Reader source) { // GSON does not support trailing commas so we have to manually remove them -> maybe better switch to jackson json parser? + @SuppressWarnings("resource") final var jsonString = removeTrailingCommas(new BufferedReader(source).lines().collect(Collectors.joining("\n"))); return castNonNull(LOADER.fromJson(jsonString, Map.class)); } @Override - public final > T parse(final Reader source, final ObjectFactory factory) { + public final > T parse(final @NotOwning Reader source, final ObjectFactory factory) { final Map rawRoot = loadRaw(source); return transform(rawRoot, factory); } diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/registry/SyncRegistry.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/registry/SyncRegistry.java index 287a1b974..06c526c14 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/registry/SyncRegistry.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/registry/SyncRegistry.java @@ -60,9 +60,9 @@ public List getColorMap() { */ public void addGrammar(final IRawGrammar grammar, final @Nullable Collection injectionScopeNames) { this._rawGrammars.put(grammar.getScopeName(), grammar); - + // custom tm4e code, not from upstream: - // If an IRawGrammar is re-registered under the same scope name, + // If an IRawGrammar is re-registered under the same scope name, // clear any cached Grammar so it will be rebuilt with the new definition this._grammars.remove(grammar.getScopeName()); diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/rule/RuleFactory.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/rule/RuleFactory.java index 00b5fb5e3..88d1fbb9c 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/rule/RuleFactory.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/rule/RuleFactory.java @@ -225,17 +225,23 @@ private static CompilePatternsResult _compilePatterns(final @Nullable Collection } boolean skipRule = false; - if (rule instanceof final IncludeOnlyRule ior) { - if (ior.hasMissingPatterns && ior.patterns.length == 0) { - skipRule = true; + switch (rule) { + case IncludeOnlyRule ior -> { + if (ior.hasMissingPatterns && ior.patterns.length == 0) { + skipRule = true; + } + } + case BeginEndRule ber -> { + if (ber.hasMissingPatterns && ber.patterns.length == 0) { + skipRule = true; + } } - } else if (rule instanceof final BeginEndRule ber) { - if (ber.hasMissingPatterns && ber.patterns.length == 0) { - skipRule = true; + case BeginWhileRule bwr -> { + if (bwr.hasMissingPatterns && bwr.patterns.length == 0) { + skipRule = true; + } } - } else if (rule instanceof final BeginWhileRule bwr) { - if (bwr.hasMissingPatterns && bwr.patterns.length == 0) { - skipRule = true; + case null, default -> { } } diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/theme/ThemeTrieElement.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/theme/ThemeTrieElement.java index 89760668c..a77bb661b 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/theme/ThemeTrieElement.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/theme/ThemeTrieElement.java @@ -11,7 +11,7 @@ */ package org.eclipse.tm4e.core.internal.theme; -import static org.eclipse.tm4e.core.internal.utils.StringUtils.*; +import static org.eclipse.tm4e.core.internal.utils.StringUtils.strArrCmp; import java.util.ArrayList; import java.util.HashMap; diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/AbstractListeners.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/AbstractListeners.java index 1de6a7b31..524f4f007 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/AbstractListeners.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/AbstractListeners.java @@ -75,4 +75,4 @@ public boolean remove(final LISTENER listener) { public void removeAll() { listeners.clear(); } -} \ No newline at end of file +} diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/ObjectCloner.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/ObjectCloner.java index 924631012..e52ecb827 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/ObjectCloner.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/ObjectCloner.java @@ -42,28 +42,30 @@ public final class ObjectCloner { if (clone != null) return (T) clone; - if (obj instanceof final List list) { - final var listClone = shallowClone(list, () -> new ArrayList<>(list)); - clones.put(list, listClone); - listClone.replaceAll(v -> deepCloneNullable(v, clones)); - return (T) listClone; - } - - if (obj instanceof final Set set) { - final var setClone = (Set<@Nullable Object>) shallowClone(set, HashSet::new); - clones.put(set, setClone); - setClone.clear(); - for (final var e : set) { - setClone.add(deepCloneNullable(e, clones)); + switch (obj) { + case final List list -> { + final var listClone = shallowClone(list, () -> new ArrayList<>(list)); + clones.put(list, listClone); + listClone.replaceAll(v -> deepCloneNullable(v, clones)); + return (T) listClone; + } + case final Set set -> { + final var setClone = (Set<@Nullable Object>) shallowClone(set, HashSet::new); + clones.put(set, setClone); + setClone.clear(); + for (final var e : set) { + setClone.add(deepCloneNullable(e, clones)); + } + return (T) setClone; + } + case final Map map -> { + final var mapClone = shallowClone(map, () -> new HashMap<>(map)); + clones.put(map, mapClone); + mapClone.replaceAll((k, v) -> deepCloneNullable(v, clones)); + return (T) mapClone; + } + default -> { } - return (T) setClone; - } - - if (obj instanceof final Map map) { - final var mapClone = shallowClone(map, () -> new HashMap<>(map)); - clones.put(map, mapClone); - mapClone.replaceAll((k, v) -> deepCloneNullable(v, clones)); - return (T) mapClone; } if (obj.getClass().isArray()) { diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/ResourceUtils.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/ResourceUtils.java index 662fc689e..550630b91 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/ResourceUtils.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/ResourceUtils.java @@ -28,20 +28,21 @@ import java.util.jar.JarEntry; import org.eclipse.jdt.annotation.Nullable; +import org.eclipse.jdt.annotation.Owning; public final class ResourceUtils { /** * @throws FileNotFoundException if the resource isn't found on the classpath */ - public static BufferedReader getResourceReader(final Class clazz, final String resourceName) throws FileNotFoundException { + public static @Owning BufferedReader getResourceReader(final Class clazz, final String resourceName) throws FileNotFoundException { return getResourceReader(clazz, resourceName, null); } /** * @throws FileNotFoundException if the resource isn't found on the classpath */ - public static BufferedReader getResourceReader(final Class clazz, final String resourceName, + public static @Owning BufferedReader getResourceReader(final Class clazz, final String resourceName, final @Nullable Charset charset) throws FileNotFoundException { final InputStream is = clazz.getResourceAsStream(resourceName); if (is == null) diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/StringUtils.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/StringUtils.java index b43d783c2..1f770ac3f 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/StringUtils.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/internal/utils/StringUtils.java @@ -119,7 +119,7 @@ private static Pattern makeContainsRtl() { /** * Returns true if `str` contains any Unicode character that is classified as "R" or "AL". */ - public static boolean containsRTL(String str) { + public static boolean containsRTL(final String str) { Pattern p = CONTAINS_RTL; if (p == null) { p = CONTAINS_RTL = makeContainsRtl(); diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/model/TMTokenizationSupport.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/model/TMTokenizationSupport.java index e90b205b1..7d690f8ba 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/model/TMTokenizationSupport.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/model/TMTokenizationSupport.java @@ -99,7 +99,7 @@ public TokenizationResult tokenize(final String line, final String baseScope = _grammar.getScopeName(); final String preferredFromScopes = choosePreferredScope(token.scopes, baseScope); final String tokenGrammarScope = token.grammarScope == null - || (preferredFromScopes != null && !preferredFromScopes.equals(baseScope)) + || preferredFromScopes != null && !preferredFromScopes.equals(baseScope) ? preferredFromScopes : token.grammarScope; tmTokens.add(new TMToken(token.startIndex + offsetDelta, tokenType, token.scopes, tokenGrammarScope)); diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/registry/IGrammarSource.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/registry/IGrammarSource.java index 63c0aafcd..2cd9d6e39 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/registry/IGrammarSource.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/registry/IGrammarSource.java @@ -20,6 +20,7 @@ import java.nio.file.Path; import org.eclipse.jdt.annotation.Nullable; +import org.eclipse.jdt.annotation.Owning; import org.eclipse.tm4e.core.internal.utils.ResourceUtils; public interface IGrammarSource { @@ -53,7 +54,7 @@ static IGrammarSource fromFile(final Path file, final @Nullable ContentType cont final var contentType1 = contentType == null ? guessFileFormat(file.toString()) : contentType; return new IGrammarSource() { @Override - public Reader getReader() throws IOException { + public @Owning Reader getReader() throws IOException { return Files.newBufferedReader(file, charset == null ? StandardCharsets.UTF_8 : charset); } @@ -90,7 +91,7 @@ static IGrammarSource fromResource(final Class clazz, final String resourceNa final var contentType1 = contentType == null ? guessFileFormat(resourceName) : contentType; return new IGrammarSource() { @Override - public Reader getReader() throws IOException { + public @Owning Reader getReader() throws IOException { return ResourceUtils.getResourceReader(clazz, resourceName, charset); } @@ -128,7 +129,7 @@ static IGrammarSource fromString(final ContentType contentType, final String con final long modified = System.currentTimeMillis(); return new IGrammarSource() { @Override - public Reader getReader() { + public @Owning Reader getReader() { return new StringReader(content); } @@ -155,6 +156,7 @@ default ContentType getContentType() { URI getURI(); + @Owning Reader getReader() throws IOException; /** diff --git a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/registry/IThemeSource.java b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/registry/IThemeSource.java index 8a55a829d..2e24ba3a8 100644 --- a/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/registry/IThemeSource.java +++ b/org.eclipse.tm4e.core/src/main/java/org/eclipse/tm4e/core/registry/IThemeSource.java @@ -20,6 +20,7 @@ import java.nio.file.Path; import org.eclipse.jdt.annotation.Nullable; +import org.eclipse.jdt.annotation.Owning; import org.eclipse.tm4e.core.internal.utils.ResourceUtils; public interface IThemeSource { @@ -53,6 +54,7 @@ static IThemeSource fromFile(final Path file, final @Nullable ContentType conten final var contentType1 = contentType == null ? guessFileFormat(file.toString()) : contentType; return new IThemeSource() { @Override + @Owning public Reader getReader() throws IOException { return Files.newBufferedReader(file, charset == null ? StandardCharsets.UTF_8 : charset); } @@ -90,6 +92,7 @@ static IThemeSource fromResource(final Class clazz, final String resourceName final var contentType1 = contentType == null ? guessFileFormat(resourceName) : contentType; return new IThemeSource() { @Override + @Owning public Reader getReader() throws IOException { return ResourceUtils.getResourceReader(clazz, resourceName, charset); } @@ -151,6 +154,7 @@ default ContentType getContentType() { URI getURI(); + @Owning Reader getReader() throws IOException; long lastModified() throws IOException; diff --git a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/benchmark/BenchmarkRunner.java b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/benchmark/BenchmarkRunner.java index bae9a99d3..416478d05 100644 --- a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/benchmark/BenchmarkRunner.java +++ b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/benchmark/BenchmarkRunner.java @@ -75,7 +75,7 @@ private static void runRound(final String label, final int round, final int tota final var durationMS = System.currentTimeMillis() - startAt; final var durationMSPerIteration = durationMS / (float) iterations; - final var iterationsPerSecond = (iterations / (float) durationMS) * 1_000; + final var iterationsPerSecond = iterations / (float) durationMS * 1_000; if (measureHeapUsage) { final var heapBytesPerIteration = (startFreeMem - RUNTIME.freeMemory()) / (float) iterations; diff --git a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/grammar/tokenattrs/EncodedTokenAttributesTest.java b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/grammar/tokenattrs/EncodedTokenAttributesTest.java index bb23467cb..8f1f36cb7 100644 --- a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/grammar/tokenattrs/EncodedTokenAttributesTest.java +++ b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/grammar/tokenattrs/EncodedTokenAttributesTest.java @@ -33,9 +33,8 @@ @TestMethodOrder(MethodOrderer.OrderAnnotation.class) class EncodedTokenAttributesTest { - @SuppressWarnings("null") - private static void assertEquals(final int metadata, final int languageId, final int /*StandardTokenType*/ tokenType, - final boolean containsBalancedBrackets, final int /*FontStyle*/ fontStyle, final int foreground, final int background) { + private static void assertEquals(final int metadata, final int languageId, final int /*StandardTokenType*/ tokenType, + final boolean containsBalancedBrackets, final int /*FontStyle*/ fontStyle, final int foreground, final int background) { final var actual = "{\n" + "languageId: " + EncodedTokenAttributes.getLanguageId(metadata) + ",\n" + "tokenType: " + EncodedTokenAttributes.getTokenType(metadata) + ",\n" diff --git a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/oniguruma/OnigRegExpTest.java b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/oniguruma/OnigRegExpTest.java index b5475e8e8..f14d59f2f 100644 --- a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/oniguruma/OnigRegExpTest.java +++ b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/oniguruma/OnigRegExpTest.java @@ -16,7 +16,6 @@ class OnigRegExpTest { - @SuppressWarnings("null") private void assertOnigRegExpSearch(final String input, final @Nullable OnigResult result, final int startPosition, final boolean shouldMatch, final String... expectedGroups) { if (shouldMatch) { diff --git a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/parser/TMParserTest.java b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/parser/TMParserTest.java index ddd6ea712..5fee4a7da 100644 --- a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/parser/TMParserTest.java +++ b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/parser/TMParserTest.java @@ -233,7 +233,6 @@ private void assertParseablePatterns(final @Nullable Collection patter } @Test - @SuppressWarnings("null") void testLanguagePackGrammars() throws IOException { final var count = new AtomicInteger(); Files.walkFileTree(Paths.get("../org.eclipse.tm4e.language_pack"), new SimpleFileVisitor() { diff --git a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/theme/raw/RawThemeReaderTest.java b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/theme/raw/RawThemeReaderTest.java index 6f451bc43..404cc289c 100644 --- a/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/theme/raw/RawThemeReaderTest.java +++ b/org.eclipse.tm4e.core/src/test/java/org/eclipse/tm4e/core/internal/theme/raw/RawThemeReaderTest.java @@ -27,7 +27,6 @@ class RawThemeReaderTest { @Test - @SuppressWarnings("null") void testLoadingThemes() throws IOException { final var count = new AtomicInteger(); try (final var files = Files.list(Paths.get("../org.eclipse.tm4e.core.tests/src/main/resources/test-cases/themes"))) { diff --git a/org.eclipse.tm4e.feature/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.feature/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.feature/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.language_pack.feature/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.language_pack.feature/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.language_pack.feature/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.language_pack/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.language_pack/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.language_pack/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.jdt.core.prefs index 408daa7c8..31d9c27e0 100644 --- a/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.jdt.core.prefs @@ -1,12 +1,153 @@ eclipse.preferences.version=1 +org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error +org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info +org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull +org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= +org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault +org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary= +org.eclipse.jdt.core.compiler.annotation.notowning=org.eclipse.jdt.annotation.NotOwning +org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable +org.eclipse.jdt.core.compiler.annotation.nullable.secondary= +org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=disabled +org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled +org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 +org.eclipse.jdt.core.compiler.codegen.unusedLocal=preserve org.eclipse.jdt.core.compiler.compliance=21 +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=200 +org.eclipse.jdt.core.compiler.problem.APILeak=warning +org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info +org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning +org.eclipse.jdt.core.compiler.problem.assertIdentifier=error +org.eclipse.jdt.core.compiler.problem.autoboxing=ignore +org.eclipse.jdt.core.compiler.problem.comparingIdentical=warning +org.eclipse.jdt.core.compiler.problem.deadCode=warning +org.eclipse.jdt.core.compiler.problem.deprecation=warning +org.eclipse.jdt.core.compiler.problem.deprecationInDeprecatedCode=disabled +org.eclipse.jdt.core.compiler.problem.deprecationWhenOverridingDeprecatedMethod=disabled +org.eclipse.jdt.core.compiler.problem.discouragedReference=warning +org.eclipse.jdt.core.compiler.problem.emptyStatement=warning org.eclipse.jdt.core.compiler.problem.enablePreviewFeatures=disabled -org.eclipse.jdt.core.compiler.problem.forbiddenReference=warning +org.eclipse.jdt.core.compiler.problem.enumIdentifier=error +org.eclipse.jdt.core.compiler.problem.explicitlyClosedAutoCloseable=warning +org.eclipse.jdt.core.compiler.problem.fallthroughCase=info +org.eclipse.jdt.core.compiler.problem.fatalOptionalError=disabled +org.eclipse.jdt.core.compiler.problem.fieldHiding=info +org.eclipse.jdt.core.compiler.problem.finalParameterBound=warning +org.eclipse.jdt.core.compiler.problem.finallyBlockNotCompletingNormally=warning +org.eclipse.jdt.core.compiler.problem.forbiddenReference=error +org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning +org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=enabled +org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompatibleOwningContract=warning +org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning +org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.insufficientResourceAnalysis=warning +org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning +org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsNotVisibleRef=enabled +org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsVisibility=public +org.eclipse.jdt.core.compiler.problem.localVariableHiding=ignore +org.eclipse.jdt.core.compiler.problem.methodWithConstructorName=warning +org.eclipse.jdt.core.compiler.problem.missingDefaultCase=ignore +org.eclipse.jdt.core.compiler.problem.missingDeprecatedAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingEnumCaseDespiteDefault=disabled +org.eclipse.jdt.core.compiler.problem.missingHashCodeMethod=warning +org.eclipse.jdt.core.compiler.problem.missingJavadocComments=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocCommentsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingJavadocTagDescription=return_tag +org.eclipse.jdt.core.compiler.problem.missingJavadocTags=ignore +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsMethodTypeParameters=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsOverriding=disabled +org.eclipse.jdt.core.compiler.problem.missingJavadocTagsVisibility=public +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotation=warning +org.eclipse.jdt.core.compiler.problem.missingOverrideAnnotationForInterfaceMethodImplementation=enabled +org.eclipse.jdt.core.compiler.problem.missingSerialVersion=warning +org.eclipse.jdt.core.compiler.problem.missingSynchronizedOnInheritedMethod=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.nonnullParameterAnnotationDropped=warning +org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning +org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error +org.eclipse.jdt.core.compiler.problem.nullReference=error +org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error +org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=info +org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning +org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore +org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning +org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=error +org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning +org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning +org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning +org.eclipse.jdt.core.compiler.problem.redundantNullCheck=warning +org.eclipse.jdt.core.compiler.problem.redundantSpecificationOfTypeArguments=warning +org.eclipse.jdt.core.compiler.problem.redundantSuperinterface=warning +org.eclipse.jdt.core.compiler.problem.reportMethodCanBePotentiallyStatic=ignore +org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning -org.eclipse.jdt.core.compiler.processAnnotations=disabled +org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled +org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled +org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled +org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info +org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled +org.eclipse.jdt.core.compiler.problem.syntheticAccessEmulation=ignore +org.eclipse.jdt.core.compiler.problem.terminalDeprecation=warning +org.eclipse.jdt.core.compiler.problem.typeParameterHiding=warning +org.eclipse.jdt.core.compiler.problem.unavoidableGenericTypeProblems=disabled +org.eclipse.jdt.core.compiler.problem.uncheckedTypeOperation=warning +org.eclipse.jdt.core.compiler.problem.unclosedCloseable=warning +org.eclipse.jdt.core.compiler.problem.undocumentedEmptyBlock=ignore +org.eclipse.jdt.core.compiler.problem.unhandledWarningToken=warning +org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentType=warning +org.eclipse.jdt.core.compiler.problem.unlikelyCollectionMethodArgumentTypeStrict=enabled +org.eclipse.jdt.core.compiler.problem.unlikelyEqualsArgumentType=warning +org.eclipse.jdt.core.compiler.problem.unnecessaryElse=warning +org.eclipse.jdt.core.compiler.problem.unnecessaryTypeCheck=warning +org.eclipse.jdt.core.compiler.problem.unqualifiedFieldAccess=ignore +org.eclipse.jdt.core.compiler.problem.unstableAutoModuleName=warning +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownException=warning +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionExemptExceptionAndThrowable=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverriding=disabled +org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore +org.eclipse.jdt.core.compiler.problem.unusedImport=warning +org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning +org.eclipse.jdt.core.compiler.problem.unusedLocal=warning +org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning +org.eclipse.jdt.core.compiler.problem.unusedParameter=warning +org.eclipse.jdt.core.compiler.problem.unusedParameterIncludeDocCommentReference=enabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenImplementingAbstract=disabled +org.eclipse.jdt.core.compiler.problem.unusedParameterWhenOverridingConcrete=disabled +org.eclipse.jdt.core.compiler.problem.unusedPrivateMember=warning +org.eclipse.jdt.core.compiler.problem.unusedTypeParameter=ignore +org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning +org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -84,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -144,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -339,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -403,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.language_pack/updater/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.language_pack/updater/src/main/java/updater/AbstractSourceHandler.java b/org.eclipse.tm4e.language_pack/updater/src/main/java/updater/AbstractSourceHandler.java index 3075face5..076f40ce3 100644 --- a/org.eclipse.tm4e.language_pack/updater/src/main/java/updater/AbstractSourceHandler.java +++ b/org.eclipse.tm4e.language_pack/updater/src/main/java/updater/AbstractSourceHandler.java @@ -79,7 +79,7 @@ void downloadLangConfigurationJSONFile(final DownloadContext ctx, final String l if (isURL(langCfgPathOrURL)) { final var targetFile = ctx.targetDir.resolve(ctx.targetNamePrefix + ".language-configuration.json"); if (ctx.updateExistingFiles || !Files.exists(targetFile)) { - downloadFile(URI.create(langCfgPathOrURL).toURL(), targetFile); + downloadFile(URI.create(langCfgPathOrURL).toURL(), targetFile); } } else { final var targetFile = ctx.targetDir.resolve(ctx.targetNamePrefix + ".language-configuration.json"); diff --git a/org.eclipse.tm4e.language_pack/updater/src/main/java/updater/Updater.java b/org.eclipse.tm4e.language_pack/updater/src/main/java/updater/Updater.java index ebd5c34e2..99c9e80ac 100644 --- a/org.eclipse.tm4e.language_pack/updater/src/main/java/updater/Updater.java +++ b/org.eclipse.tm4e.language_pack/updater/src/main/java/updater/Updater.java @@ -286,24 +286,26 @@ private void downloadFiles(final String sourceIdToUpdate) throws IOException, In final Path sourceRepoDir = sourceReposCacheDir.resolve(sourceId); final var gitCheckoutState = gitSparseCheckout(sourceRepoDir, source.github); - if (source instanceof final Config.CustomSource src) { - final var extensionState = new State.ExtensionState(); - extensionState.github = gitCheckoutState; - state.extensions.put(sourceId, extensionState); - new CustomSourceHandler(sourceId, src, sourceRepoDir, syntaxesDir, extensionState).handle(); - } else if (source instanceof final Config.VSCodeSingleExtensionSource src) { - final var extensionState = new State.ExtensionState(); - extensionState.github = gitCheckoutState; - state.extensions.put(sourceId, extensionState); - - for (final String buildCommand : src.build) { - Sys.execVerbose(sourceRepoDir, (Sys.IS_WINDOWS ? "cmd /c " : "") + buildCommand); + switch (source) { + case final Config.CustomSource src -> { + final var extensionState = new State.ExtensionState(); + extensionState.github = gitCheckoutState; + state.extensions.put(sourceId, extensionState); + new CustomSourceHandler(sourceId, src, sourceRepoDir, syntaxesDir, extensionState).handle(); + } + case final Config.VSCodeSingleExtensionSource src -> { + final var extensionState = new State.ExtensionState(); + extensionState.github = gitCheckoutState; + state.extensions.put(sourceId, extensionState); + for (final String buildCommand : src.build) { + Sys.execVerbose(sourceRepoDir, (Sys.IS_WINDOWS ? "cmd /c " : "") + buildCommand); + } + new VSCodeSingleExtensionSourceHandler(sourceId, src, sourceRepoDir, syntaxesDir, extensionState).handle(); + } + case final Config.VSCodeMultiExtensionsSource src -> new VSCodeMultiExtensionsSourceHandler(sourceId, src, sourceRepoDir, + gitCheckoutState, syntaxesDir, state.extensions).handle(); + default -> { } - - new VSCodeSingleExtensionSourceHandler(sourceId, src, sourceRepoDir, syntaxesDir, extensionState).handle(); - } else if (source instanceof final Config.VSCodeMultiExtensionsSource src) { - new VSCodeMultiExtensionsSourceHandler(sourceId, src, sourceRepoDir, gitCheckoutState, syntaxesDir, state.extensions) - .handle(); } logInfo("Saving state to [" + stateFile + "]"); diff --git a/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.jdt.core.prefs index 42ea09faa..31d9c27e0 100644 --- a/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.jdt.core.prefs @@ -1,14 +1,27 @@ eclipse.preferences.version=1 -org.eclipse.jdt.core.builder.annotationPath.allLocations=disabled +org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary= +org.eclipse.jdt.core.compiler.annotation.notowning=org.eclipse.jdt.annotation.NotOwning org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable org.eclipse.jdt.core.compiler.annotation.nullable.secondary= org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=disabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 @@ -18,6 +31,7 @@ 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=200 org.eclipse.jdt.core.compiler.problem.APILeak=warning org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning @@ -42,8 +56,10 @@ org.eclipse.jdt.core.compiler.problem.forbiddenReference=error org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=enabled org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompatibleOwningContract=warning org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.insufficientResourceAnalysis=warning org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled @@ -72,15 +88,15 @@ org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning -org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning -org.eclipse.jdt.core.compiler.problem.nullReference=warning -org.eclipse.jdt.core.compiler.problem.nullSpecViolation=warning -org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning +org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error +org.eclipse.jdt.core.compiler.problem.nullReference=error +org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error +org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=info org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning -org.eclipse.jdt.core.compiler.problem.potentialNullReference=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=error org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning @@ -92,7 +108,7 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled @@ -118,6 +134,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverridin org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedImport=warning org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning org.eclipse.jdt.core.compiler.problem.unusedLocal=warning org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning org.eclipse.jdt.core.compiler.problem.unusedParameter=warning @@ -130,6 +147,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -170,6 +188,7 @@ org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0 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_permitted_types_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_record_components=16 org.eclipse.jdt.core.formatter.alignment_for_relational_operator=0 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 @@ -206,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -232,6 +252,7 @@ org.eclipse.jdt.core.formatter.comment.indent_tag_description=false org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_between_different_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.javadoc_do_not_separate_block_tags=false org.eclipse.jdt.core.formatter.comment.line_length=140 org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true @@ -265,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -460,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -524,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.languageconfiguration.tests/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.jdt.core.prefs index 543db3986..75d9b0744 100644 --- a/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.jdt.core.prefs @@ -1,7 +1,17 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault @@ -11,7 +21,7 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul org.eclipse.jdt.core.compiler.annotation.nullable.secondary= org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning -org.eclipse.jdt.core.compiler.annotation.resourceanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=enabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 @@ -21,6 +31,7 @@ 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=200 org.eclipse.jdt.core.compiler.problem.APILeak=warning org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning @@ -97,7 +108,7 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled @@ -123,6 +134,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverridin org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedImport=warning org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning org.eclipse.jdt.core.compiler.problem.unusedLocal=warning org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning org.eclipse.jdt.core.compiler.problem.unusedParameter=warning @@ -135,6 +147,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -175,6 +188,7 @@ org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0 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_permitted_types_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_record_components=16 org.eclipse.jdt.core.formatter.alignment_for_relational_operator=0 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 @@ -211,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -237,6 +252,7 @@ org.eclipse.jdt.core.formatter.comment.indent_tag_description=false org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_between_different_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.javadoc_do_not_separate_block_tags=false org.eclipse.jdt.core.formatter.comment.line_length=140 org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true @@ -270,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -465,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -529,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.languageconfiguration/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/LanguageConfigurationCharacterPairMatcher.java b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/LanguageConfigurationCharacterPairMatcher.java index 65b87c5c8..3da7f99dd 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/LanguageConfigurationCharacterPairMatcher.java +++ b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/LanguageConfigurationCharacterPairMatcher.java @@ -202,7 +202,7 @@ private DefaultCharacterPairMatcher getMatcher(final IDocument document) { if (hasQuotes) { quotes = new char[surroundingQuotes.size()]; for (int i = 0; i < surroundingQuotes.size(); i++) { - quotes[i] = surroundingQuotes.get(i).charValue(); + quotes[i] = surroundingQuotes.get(i); } } else { quotes = NO_QUOTES; @@ -366,8 +366,6 @@ private char getMatchingBracket(final char ch) { return null; } } catch (final BadLocationException e) { - // if token lookup fails, fall back to the original region - return region; } return region; } @@ -459,7 +457,7 @@ private char getMatchingBracket(final char ch) { for (int i = 0; i < tokens.size(); i++) { final TMToken token = tokens.get(i); final int tokenStart = token.startIndex; - final int tokenEnd = (i + 1 < tokens.size()) ? tokens.get(i + 1).startIndex : lineLength; + final int tokenEnd = i + 1 < tokens.size() ? tokens.get(i + 1).startIndex : lineLength; if (column < tokenStart || column >= tokenEnd) { continue; } @@ -498,8 +496,7 @@ private static int findMatchingQuoteForward(final ITMModel tmModel, final IDocum final int lineLength = document.getLineLength(line); final String lineText = document.get(lineOffset, lineLength); - for (int i = 0; i < tokens.size(); i++) { - final TMToken token = tokens.get(i); + for (final TMToken token : tokens) { final int tokenStartColumn = token.startIndex; final int tokenStartOffset = lineOffset + tokenStartColumn; @@ -633,7 +630,7 @@ private static boolean isInsideStringCommentOrCharacterToken(final ITMModel tmMo for (int i = 0; i < tokens.size(); i++) { final TMToken token = tokens.get(i); final int tokenStart = token.startIndex; - final int tokenEnd = (i + 1 < tokens.size()) ? tokens.get(i + 1).startIndex : lineLength; + final int tokenEnd = i + 1 < tokens.size() ? tokens.get(i + 1).startIndex : lineLength; if (column < tokenStart || column >= tokenEnd) { continue; } diff --git a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/expressions/HasFoldingRulesPropertyTester.java b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/expressions/HasFoldingRulesPropertyTester.java index 129f8cb19..651b13c56 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/expressions/HasFoldingRulesPropertyTester.java +++ b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/expressions/HasFoldingRulesPropertyTester.java @@ -30,14 +30,19 @@ public final class HasFoldingRulesPropertyTester extends PropertyTester { @Override public boolean test(final @Nullable Object receiver, final String property, final Object[] args, final @Nullable Object expectedValue) { - if (receiver instanceof final IFileEditorInput fileInput) - return hasFoldingConfiguration(ContentTypeHelper.findContentTypesByFileName(fileInput.getFile().getName())); - - if (receiver instanceof final IPathEditorInput pathInput) - return hasFoldingConfiguration(ContentTypeHelper.findContentTypesByFileName(castNonNull(pathInput.getPath().lastSegment()))); - - if (receiver instanceof final IFile file) - return hasFoldingConfiguration(ContentTypeHelper.findContentTypesByFileName(file.getName())); + switch (receiver) { + case IFileEditorInput fileInput -> { + return hasFoldingConfiguration(ContentTypeHelper.findContentTypesByFileName(fileInput.getFile().getName())); + } + case IPathEditorInput pathInput -> { + return hasFoldingConfiguration(ContentTypeHelper.findContentTypesByFileName(castNonNull(pathInput.getPath().lastSegment()))); + } + case IFile file -> { + return hasFoldingConfiguration(ContentTypeHelper.findContentTypesByFileName(file.getName())); + } + case null, default -> { + } + } final var editor = Adapters.adapt(receiver, ITextEditor.class); if (editor == null) diff --git a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/expressions/HasLanguageConfigurationPropertyTester.java b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/expressions/HasLanguageConfigurationPropertyTester.java index 9ddd663a9..9dc37b282 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/expressions/HasLanguageConfigurationPropertyTester.java +++ b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/expressions/HasLanguageConfigurationPropertyTester.java @@ -31,14 +31,19 @@ public final class HasLanguageConfigurationPropertyTester extends PropertyTester @Override public boolean test(final @Nullable Object receiver, final String property, final Object[] args, final @Nullable Object expectedValue) { - if (receiver instanceof final IFileEditorInput fileInput) - return hasLanguageConfiguration(ContentTypeHelper.findContentTypesByFileName(fileInput.getFile().getName())); - - if (receiver instanceof final IPathEditorInput pathInput) - return hasLanguageConfiguration(ContentTypeHelper.findContentTypesByFileName(castNonNull(pathInput.getPath().lastSegment()))); - - if (receiver instanceof final IFile file) - return hasLanguageConfiguration(ContentTypeHelper.findContentTypesByFileName(file.getName())); + switch (receiver) { + case IFileEditorInput fileInput -> { + return hasLanguageConfiguration(ContentTypeHelper.findContentTypesByFileName(fileInput.getFile().getName())); + } + case IPathEditorInput pathInput -> { + return hasLanguageConfiguration(ContentTypeHelper.findContentTypesByFileName(castNonNull(pathInput.getPath().lastSegment()))); + } + case IFile file -> { + return hasLanguageConfiguration(ContentTypeHelper.findContentTypesByFileName(file.getName())); + } + case null, default -> { + } + } final var editor = Adapters.adapt(receiver, ITextEditor.class); if (editor == null) diff --git a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/model/IndentationRules.java b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/model/IndentationRules.java index 84ae29038..cdbe0e283 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/model/IndentationRules.java +++ b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/model/IndentationRules.java @@ -55,4 +55,4 @@ public IndentationRules(final RegExPattern decreaseIndentPattern, final RegExPat this.indentNextLinePattern = indentNextLinePattern; this.unIndentedLinePattern = unIndentedLinePattern; } -} \ No newline at end of file +} diff --git a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/model/LanguageConfiguration.java b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/model/LanguageConfiguration.java index b58bcb231..c544d10a1 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/model/LanguageConfiguration.java +++ b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/model/LanguageConfiguration.java @@ -22,8 +22,7 @@ import java.util.Objects; import java.util.stream.Collectors; -import org.eclipse.jdt.annotation.NonNull; -import org.eclipse.jdt.annotation.NonNullByDefault; +import org.eclipse.jdt.annotation.NotOwning; import org.eclipse.jdt.annotation.Nullable; import org.eclipse.tm4e.languageconfiguration.LanguageConfigurationPlugin; import org.eclipse.tm4e.languageconfiguration.internal.model.EnterAction.IndentAction; @@ -68,9 +67,9 @@ private static String removeTrailingCommas(final String jsonString) { * @return an instance of {@link LanguageConfiguration} loaded from the VSCode language-configuration.json file * reader. */ - @NonNullByDefault({}) - public static @Nullable LanguageConfiguration load(final @NonNull Reader reader) { + public static @Nullable LanguageConfiguration load(final @NotOwning Reader reader) { // GSON does not support trailing commas so we have to manually remove them -> maybe better switch to jackson json parser? + @SuppressWarnings("resource") final var jsonString = removeTrailingCommas(new BufferedReader(reader).lines().collect(Collectors.joining("\n"))); final var gsonBuilder = new GsonBuilder() .registerTypeAdapter(String.class, (JsonDeserializer) (json, typeOfT, context) -> { diff --git a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/supports/IndentForEnterHelper.java b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/supports/IndentForEnterHelper.java index b6ab8334b..013e49c63 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/supports/IndentForEnterHelper.java +++ b/org.eclipse.tm4e.languageconfiguration/src/main/java/org/eclipse/tm4e/languageconfiguration/internal/supports/IndentForEnterHelper.java @@ -182,8 +182,8 @@ private static final class InheritedIndentation { final var previousLineContent = model.getLineContent(previousLineIndex); final int previousLineIndentMetadata = indentRulesSupport.getIndentMetadata(previousLineContent); - if (((previousLineIndentMetadata & (IndentConsts.INCREASE_MASK | IndentConsts.DECREASE_MASK)) == 0) - && ((previousLineIndentMetadata & IndentConsts.INDENT_NEXTLINE_MASK) != 0)) { + if ((previousLineIndentMetadata & (IndentConsts.INCREASE_MASK | IndentConsts.DECREASE_MASK)) == 0 + && (previousLineIndentMetadata & IndentConsts.INDENT_NEXTLINE_MASK) != 0) { int stopLineIndex = -1; for (int i = previousLineIndex - 1; i >= 0; i--) { if (indentRulesSupport.shouldIndentNextLine(model.getLineContent(i))) @@ -250,13 +250,8 @@ private static final class InheritedIndentation { final IndentRulesSupport indentRulesSupport, final OnEnterSupport onEnterSupport) throws BadLocationException { - final var virtualModel = new IVirtualModel() { - @Override - public String getLineContent(int lineIndex) throws BadLocationException { - return DocumentHelper.getLineText(doc, lineIndex, false); - } - }; - InheritedIndentation indent = getInheritIndentForLine(virtualModel, true, lineIndex, indentRulesSupport); + final var virtualModel = (IVirtualModel) lineIndex1 -> DocumentHelper.getLineText(doc, lineIndex1, false); + final InheritedIndentation indent = getInheritIndentForLine(virtualModel, true, lineIndex, indentRulesSupport); if (indent != null) { final String lineContent = virtualModel.getLineContent(lineIndex); @@ -351,15 +346,11 @@ public String getLineContent(int lineIndex) throws BadLocationException { final String beforeEnterResult = beforeEnterText; final String beforeEnterIndent = Strings.getLeadingWhitespace(beforeEnterText); - final var virtualModel = new IVirtualModel() { - - @Override - public String getLineContent(int theLineIndex) throws BadLocationException { - if (theLineIndex == lineIndex) { - return beforeEnterResult; - } - return DocumentHelper.getLineText(doc, theLineIndex, false); + final var virtualModel = (IVirtualModel) theLineIndex -> { + if (theLineIndex == lineIndex) { + return beforeEnterResult; } + return DocumentHelper.getLineText(doc, theLineIndex, false); }; //final String currentLineIndent = TextUtils.getIndentationAtPosition(doc, offset); diff --git a/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/model/ParsingTest.java b/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/model/ParsingTest.java index 16bf29d58..e114e3900 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/model/ParsingTest.java +++ b/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/model/ParsingTest.java @@ -142,7 +142,7 @@ void testIndentationRules() { }, }"""); - var indentationRules = languageConfiguration.getIndentationRules(); + final var indentationRules = languageConfiguration.getIndentationRules(); assert indentationRules != null; assertThat(indentationRules.increaseIndentPattern).hasToString("(^.*\\{[^}]*$)"); diff --git a/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/supports/OnEnterSupportTest.java b/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/supports/OnEnterSupportTest.java index 3d6e76ac2..35cbb4324 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/supports/OnEnterSupportTest.java +++ b/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/supports/OnEnterSupportTest.java @@ -129,7 +129,6 @@ void testIndentAction(final String previousLineText, final String beforeText, fi testIndentAction(previousLineText, beforeText, afterText, expectedIndentAction, expectedAppendText, 0); } - @SuppressWarnings("null") void testIndentAction(final String previousLineText, final String beforeText, final String afterText, final @Nullable IndentAction expectedIndentAction, final @Nullable String expectedAppendText, final int removeText) { diff --git a/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/utils/IndentationTest.java b/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/utils/IndentationTest.java index b833eb9bd..b8529dde7 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/utils/IndentationTest.java +++ b/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/utils/IndentationTest.java @@ -31,7 +31,7 @@ class IndentationTest { @Test void testNormalizeIndentation1() { - var cursorCfg = new CursorConfiguration(false, 4); + final var cursorCfg = new CursorConfiguration(false, 4); assertThat(cursorCfg.normalizeIndentation("\t")).isEqualTo("\t"); assertThat(cursorCfg.normalizeIndentation(" ")).isEqualTo("\t"); @@ -60,7 +60,7 @@ void testNormalizeIndentation1() { @Test void testNormalizeIndentation2() { - var cursorCfg = new CursorConfiguration(true, 4); + final var cursorCfg = new CursorConfiguration(true, 4); assertThat(cursorCfg.normalizeIndentation("\ta")).isEqualTo(" a"); assertThat(cursorCfg.normalizeIndentation(" a")).isEqualTo(" a"); diff --git a/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/utils/MockDocument.java b/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/utils/MockDocument.java index f305af794..65be43809 100644 --- a/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/utils/MockDocument.java +++ b/org.eclipse.tm4e.languageconfiguration/src/test/java/org/eclipse/tm4e/languageconfiguration/internal/utils/MockDocument.java @@ -35,7 +35,7 @@ */ public class MockDocument implements IDocument { - private String contentType; + private final String contentType; private String text; public MockDocument(final String contentType, final String text) { @@ -44,7 +44,7 @@ public MockDocument(final String contentType, final String text) { } public int getOffsetAfter(final String searchFor) { - var idx = text.indexOf(searchFor); + final var idx = text.indexOf(searchFor); if (idx > -1) return idx + searchFor.length(); return idx; @@ -55,62 +55,62 @@ public int getOffsetOf(final String searchFor) { } @Override - public void addDocumentListener(IDocumentListener listener) { + public void addDocumentListener(final IDocumentListener listener) { throw new UnsupportedOperationException(); } @Override - public void addDocumentPartitioningListener(IDocumentPartitioningListener listener) { + public void addDocumentPartitioningListener(final IDocumentPartitioningListener listener) { throw new UnsupportedOperationException(); } @Override - public void addPosition(Position position) { + public void addPosition(final Position position) { throw new UnsupportedOperationException(); } @Override - public void addPosition(String category, Position position) { + public void addPosition(final String category, final Position position) { throw new UnsupportedOperationException(); } @Override - public void addPositionCategory(String category) { + public void addPositionCategory(final String category) { throw new UnsupportedOperationException(); } @Override - public void addPositionUpdater(IPositionUpdater updater) { + public void addPositionUpdater(final IPositionUpdater updater) { throw new UnsupportedOperationException(); } @Override - public void addPrenotifiedDocumentListener(IDocumentListener documentAdapter) { + public void addPrenotifiedDocumentListener(final IDocumentListener documentAdapter) { throw new UnsupportedOperationException(); } @Override - public int computeIndexInCategory(String category, int offset) { + public int computeIndexInCategory(final String category, final int offset) { throw new UnsupportedOperationException(); } @Override - public int computeNumberOfLines(String text) { + public int computeNumberOfLines(final String text) { throw new UnsupportedOperationException(); } @Override - public ITypedRegion[] computePartitioning(int offset, int length) { + public ITypedRegion[] computePartitioning(final int offset, final int length) { throw new UnsupportedOperationException(); } @Override - public boolean containsPosition(String category, int offset, int length) { + public boolean containsPosition(final String category, final int offset, final int length) { throw new UnsupportedOperationException(); } @Override - public boolean containsPositionCategory(String category) { + public boolean containsPositionCategory(final String category) { throw new UnsupportedOperationException(); } @@ -123,7 +123,7 @@ public String get() { public String get(final int offset, final int length) throws BadLocationException { try { return this.text.substring(offset, offset + length); - } catch (IndexOutOfBoundsException ex) { + } catch (final IndexOutOfBoundsException ex) { throw new BadLocationException(ex.getMessage()); } } @@ -132,13 +132,13 @@ public String get(final int offset, final int length) throws BadLocationExceptio public char getChar(final int offset) throws BadLocationException { try { return this.text.charAt(offset); - } catch (IndexOutOfBoundsException ex) { + } catch (final IndexOutOfBoundsException ex) { throw new BadLocationException(ex.getMessage()); } } @Override - public String getContentType(int offset) { + public String getContentType(final int offset) { return contentType; } @@ -209,7 +209,7 @@ public int getLineOfOffset(final int offset) throws BadLocationException { try (var lineIndexReader = new LineNumberReader(new StringReader(text))) { lineIndexReader.skip(offset); return lineIndexReader.getLineNumber(); - } catch (IOException ex) { + } catch (final IOException ex) { throw new BadLocationException(ex.getMessage()); } } @@ -225,7 +225,7 @@ public int getNumberOfLines(final int offset, final int length) throws BadLocati } @Override - public ITypedRegion getPartition(int offset) { + public ITypedRegion getPartition(final int offset) { throw new UnsupportedOperationException(); } @@ -235,7 +235,7 @@ public String[] getPositionCategories() { } @Override - public Position[] getPositions(String category) { + public Position[] getPositions(final String category) { throw new UnsupportedOperationException(); } @@ -245,42 +245,42 @@ public IPositionUpdater[] getPositionUpdaters() { } @Override - public void insertPositionUpdater(IPositionUpdater updater, int index) { + public void insertPositionUpdater(final IPositionUpdater updater, final int index) { throw new UnsupportedOperationException(); } @Override - public void removeDocumentListener(IDocumentListener listener) { + public void removeDocumentListener(final IDocumentListener listener) { throw new UnsupportedOperationException(); } @Override - public void removeDocumentPartitioningListener(IDocumentPartitioningListener listener) { + public void removeDocumentPartitioningListener(final IDocumentPartitioningListener listener) { throw new UnsupportedOperationException(); } @Override - public void removePosition(Position position) { + public void removePosition(final Position position) { throw new UnsupportedOperationException(); } @Override - public void removePosition(String category, Position position) { + public void removePosition(final String category, final Position position) { throw new UnsupportedOperationException(); } @Override - public void removePositionCategory(String category) { + public void removePositionCategory(final String category) { throw new UnsupportedOperationException(); } @Override - public void removePositionUpdater(IPositionUpdater updater) { + public void removePositionUpdater(final IPositionUpdater updater) { throw new UnsupportedOperationException(); } @Override - public void removePrenotifiedDocumentListener(IDocumentListener documentAdapter) { + public void removePrenotifiedDocumentListener(final IDocumentListener documentAdapter) { throw new UnsupportedOperationException(); } @@ -288,13 +288,14 @@ public void removePrenotifiedDocumentListener(IDocumentListener documentAdapter) public void replace(final int offset, final int length, final String text) throws BadLocationException { try { this.text = new StringBuilder(this.text).replace(offset, offset + length, text).toString(); - } catch (IndexOutOfBoundsException ex) { + } catch (final IndexOutOfBoundsException ex) { throw new BadLocationException(ex.getMessage()); } } @Override - public int search(int startOffset, String findString, boolean forwardSearch, boolean caseSensitive, boolean wholeWord) { + public int search(final int startOffset, final String findString, final boolean forwardSearch, final boolean caseSensitive, + final boolean wholeWord) { throw new UnsupportedOperationException(); } @@ -304,7 +305,7 @@ public void set(final String text) { } @Override - public void setDocumentPartitioner(@Nullable IDocumentPartitioner partitioner) { + public void setDocumentPartitioner(@Nullable final IDocumentPartitioner partitioner) { throw new UnsupportedOperationException(); } diff --git a/org.eclipse.tm4e.markdown/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.markdown/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.markdown/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.markdown/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.markdown/.settings/org.eclipse.jdt.core.prefs index 543db3986..75d9b0744 100644 --- a/org.eclipse.tm4e.markdown/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.markdown/.settings/org.eclipse.jdt.core.prefs @@ -1,7 +1,17 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault @@ -11,7 +21,7 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul org.eclipse.jdt.core.compiler.annotation.nullable.secondary= org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning -org.eclipse.jdt.core.compiler.annotation.resourceanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=enabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 @@ -21,6 +31,7 @@ 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=200 org.eclipse.jdt.core.compiler.problem.APILeak=warning org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning @@ -97,7 +108,7 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled @@ -123,6 +134,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverridin org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedImport=warning org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning org.eclipse.jdt.core.compiler.problem.unusedLocal=warning org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning org.eclipse.jdt.core.compiler.problem.unusedParameter=warning @@ -135,6 +147,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -175,6 +188,7 @@ org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0 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_permitted_types_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_record_components=16 org.eclipse.jdt.core.formatter.alignment_for_relational_operator=0 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 @@ -211,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -237,6 +252,7 @@ org.eclipse.jdt.core.formatter.comment.indent_tag_description=false org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_between_different_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.javadoc_do_not_separate_block_tags=false org.eclipse.jdt.core.formatter.comment.line_length=140 org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true @@ -270,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -465,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -529,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.markdown/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.markdown/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.markdown/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/TMHTMLRenderer.java b/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/TMHTMLRenderer.java index 3eead7c75..5cea44470 100644 --- a/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/TMHTMLRenderer.java +++ b/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/TMHTMLRenderer.java @@ -84,15 +84,15 @@ private void emitNewLine() { tokenText = line.substring(offset); } - String className = "token"; + StringBuilder className = new StringBuilder("token"); final String safeType = token.type.replaceAll("[^a-z0-9\\-]", " "); if (!safeType.isEmpty()) { - className += ' ' + safeType; + className.append(' ').append(safeType); } html.append(""); html.append(Helpers.htmlEscape(tokenText)); html.append(""); diff --git a/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/marked/InlineLexer.java b/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/marked/InlineLexer.java index 16aafa44b..400f46f34 100644 --- a/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/marked/InlineLexer.java +++ b/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/marked/InlineLexer.java @@ -87,7 +87,6 @@ public void output(String src) { if ((cap = this.rules.text.exec(src)) != null) { src = src.substring(cap.group(0).length()); this.renderer.text(htmlEscape(this.smartypants(cap.group(0)))); - continue; } } } diff --git a/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/marked/Parser.java b/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/marked/Parser.java index f2000e8b6..0c635270c 100644 --- a/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/marked/Parser.java +++ b/org.eclipse.tm4e.markdown/src/main/java/org/eclipse/tm4e/markdown/marked/Parser.java @@ -60,6 +60,7 @@ private boolean next(final Tokens tokens) { /** * Parse Current Token */ + @SuppressWarnings("incomplete-switch") private void tok(final InlineLexer inline) { final var token = this.token; if (token == null) diff --git a/org.eclipse.tm4e.registry/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.registry/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.registry/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.registry/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.registry/.settings/org.eclipse.jdt.core.prefs index 543db3986..75d9b0744 100644 --- a/org.eclipse.tm4e.registry/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.registry/.settings/org.eclipse.jdt.core.prefs @@ -1,7 +1,17 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault @@ -11,7 +21,7 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul org.eclipse.jdt.core.compiler.annotation.nullable.secondary= org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning -org.eclipse.jdt.core.compiler.annotation.resourceanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=enabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 @@ -21,6 +31,7 @@ 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=200 org.eclipse.jdt.core.compiler.problem.APILeak=warning org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning @@ -97,7 +108,7 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled @@ -123,6 +134,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverridin org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedImport=warning org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning org.eclipse.jdt.core.compiler.problem.unusedLocal=warning org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning org.eclipse.jdt.core.compiler.problem.unusedParameter=warning @@ -135,6 +147,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -175,6 +188,7 @@ org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0 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_permitted_types_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_record_components=16 org.eclipse.jdt.core.formatter.alignment_for_relational_operator=0 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 @@ -211,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -237,6 +252,7 @@ org.eclipse.jdt.core.formatter.comment.indent_tag_description=false org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_between_different_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.javadoc_do_not_separate_block_tags=false org.eclipse.jdt.core.formatter.comment.line_length=140 org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true @@ -270,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -465,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -529,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.registry/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.registry/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.registry/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/ITMScope.java b/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/ITMScope.java index cc70e5a9f..2821c704a 100644 --- a/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/ITMScope.java +++ b/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/ITMScope.java @@ -23,7 +23,7 @@ public interface ITMScope { /** * @param scopeName fully qualified ("source.batchfile@com.example.myplugin") or unqualified scopeName ("source.batchfile") */ - static ITMScope parse(String scopeName) { + static ITMScope parse(final String scopeName) { return TMScope.parse(scopeName); } @@ -35,4 +35,4 @@ static ITMScope parse(String scopeName) { String getPluginId(); boolean isQualified(); -} \ No newline at end of file +} diff --git a/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/TMResource.java b/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/TMResource.java index c2aad4c0c..337f9cbd0 100644 --- a/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/TMResource.java +++ b/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/TMResource.java @@ -30,7 +30,7 @@ public abstract class TMResource implements ITMResource { private static final String PLATFORM_PLUGIN = "platform:/plugin/"; - private String path; + private final String path; private @Nullable String pluginId; /** diff --git a/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/internal/AbstractGrammarRegistryManager.java b/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/internal/AbstractGrammarRegistryManager.java index cea1d897a..e6497b5b8 100644 --- a/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/internal/AbstractGrammarRegistryManager.java +++ b/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/internal/AbstractGrammarRegistryManager.java @@ -29,6 +29,7 @@ import org.eclipse.core.runtime.content.IContentType; import org.eclipse.jdt.annotation.Nullable; +import org.eclipse.jdt.annotation.Owning; import org.eclipse.tm4e.core.grammar.IGrammar; import org.eclipse.tm4e.core.registry.IGrammarSource; import org.eclipse.tm4e.core.registry.IRegistryOptions; @@ -137,7 +138,7 @@ public URI getURI() { } @Override - public Reader getReader() throws IOException { + public @Owning Reader getReader() throws IOException { return new InputStreamReader(definition_.getInputStream(), StandardCharsets.UTF_8); } diff --git a/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/internal/PreferenceHelper.java b/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/internal/PreferenceHelper.java index ad966dfff..c1cf5e252 100644 --- a/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/internal/PreferenceHelper.java +++ b/org.eclipse.tm4e.registry/src/main/java/org/eclipse/tm4e/registry/internal/PreferenceHelper.java @@ -47,7 +47,7 @@ final class PreferenceHelper { }.getType()); } - static void saveGrammars(Collection definitions) throws BackingStoreException { + static void saveGrammars(final Collection definitions) throws BackingStoreException { // Save grammar definitions in the // "${workspace_loc}/metadata/.plugins/org.eclipse.core.runtime/.settings/org.eclipse.tm4e.registry.prefs" final var json = DEFAULT_GSON.toJson(definitions); diff --git a/org.eclipse.tm4e.repository/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.repository/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.repository/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.samples/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.samples/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.samples/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.samples/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.samples/.settings/org.eclipse.jdt.core.prefs index 42ea09faa..75d9b0744 100644 --- a/org.eclipse.tm4e.samples/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.samples/.settings/org.eclipse.jdt.core.prefs @@ -1,14 +1,27 @@ eclipse.preferences.version=1 -org.eclipse.jdt.core.builder.annotationPath.allLocations=disabled +org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary= +org.eclipse.jdt.core.compiler.annotation.notowning=org.eclipse.jdt.annotation.NotOwning org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable org.eclipse.jdt.core.compiler.annotation.nullable.secondary= -org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled +org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=enabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 @@ -18,6 +31,7 @@ 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=200 org.eclipse.jdt.core.compiler.problem.APILeak=warning org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning @@ -42,8 +56,10 @@ org.eclipse.jdt.core.compiler.problem.forbiddenReference=error org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=enabled org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompatibleOwningContract=warning org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.insufficientResourceAnalysis=warning org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled @@ -72,15 +88,15 @@ org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning -org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning -org.eclipse.jdt.core.compiler.problem.nullReference=warning -org.eclipse.jdt.core.compiler.problem.nullSpecViolation=warning -org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning +org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error +org.eclipse.jdt.core.compiler.problem.nullReference=error +org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error +org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=info org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning -org.eclipse.jdt.core.compiler.problem.potentialNullReference=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=error org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning @@ -92,7 +108,7 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled @@ -118,6 +134,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverridin org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedImport=warning org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning org.eclipse.jdt.core.compiler.problem.unusedLocal=warning org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning org.eclipse.jdt.core.compiler.problem.unusedParameter=warning @@ -130,6 +147,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -170,6 +188,7 @@ org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0 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_permitted_types_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_record_components=16 org.eclipse.jdt.core.formatter.alignment_for_relational_operator=0 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 @@ -206,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -232,6 +252,7 @@ org.eclipse.jdt.core.formatter.comment.indent_tag_description=false org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_between_different_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.javadoc_do_not_separate_block_tags=false org.eclipse.jdt.core.formatter.comment.line_length=140 org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true @@ -265,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -460,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -524,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.samples/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.samples/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.samples/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.jdt.core.prefs index 42ea09faa..31d9c27e0 100644 --- a/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.jdt.core.prefs @@ -1,14 +1,27 @@ eclipse.preferences.version=1 -org.eclipse.jdt.core.builder.annotationPath.allLocations=disabled +org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault org.eclipse.jdt.core.compiler.annotation.nonnullbydefault.secondary= +org.eclipse.jdt.core.compiler.annotation.notowning=org.eclipse.jdt.annotation.NotOwning org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nullable org.eclipse.jdt.core.compiler.annotation.nullable.secondary= org.eclipse.jdt.core.compiler.annotation.nullanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=disabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 @@ -18,6 +31,7 @@ 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=200 org.eclipse.jdt.core.compiler.problem.APILeak=warning org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning @@ -42,8 +56,10 @@ org.eclipse.jdt.core.compiler.problem.forbiddenReference=error org.eclipse.jdt.core.compiler.problem.hiddenCatchBlock=warning org.eclipse.jdt.core.compiler.problem.includeNullInfoFromAsserts=enabled org.eclipse.jdt.core.compiler.problem.incompatibleNonInheritedInterfaceMethod=warning +org.eclipse.jdt.core.compiler.problem.incompatibleOwningContract=warning org.eclipse.jdt.core.compiler.problem.incompleteEnumSwitch=warning org.eclipse.jdt.core.compiler.problem.indirectStaticAccess=ignore +org.eclipse.jdt.core.compiler.problem.insufficientResourceAnalysis=warning org.eclipse.jdt.core.compiler.problem.invalidJavadoc=warning org.eclipse.jdt.core.compiler.problem.invalidJavadocTags=enabled org.eclipse.jdt.core.compiler.problem.invalidJavadocTagsDeprecatedRef=enabled @@ -72,15 +88,15 @@ org.eclipse.jdt.core.compiler.problem.noImplicitStringConversion=warning org.eclipse.jdt.core.compiler.problem.nonExternalizedStringLiteral=ignore org.eclipse.jdt.core.compiler.problem.nonnullParameterAnnotationDropped=warning org.eclipse.jdt.core.compiler.problem.nonnullTypeVariableFromLegacyInvocation=warning -org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=warning -org.eclipse.jdt.core.compiler.problem.nullReference=warning -org.eclipse.jdt.core.compiler.problem.nullSpecViolation=warning -org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=warning +org.eclipse.jdt.core.compiler.problem.nullAnnotationInferenceConflict=error +org.eclipse.jdt.core.compiler.problem.nullReference=error +org.eclipse.jdt.core.compiler.problem.nullSpecViolation=error +org.eclipse.jdt.core.compiler.problem.nullUncheckedConversion=info org.eclipse.jdt.core.compiler.problem.overridingPackageDefaultMethod=warning org.eclipse.jdt.core.compiler.problem.parameterAssignment=ignore org.eclipse.jdt.core.compiler.problem.pessimisticNullAnalysisForFreeTypeVariables=warning org.eclipse.jdt.core.compiler.problem.possibleAccidentalBooleanAssignment=warning -org.eclipse.jdt.core.compiler.problem.potentialNullReference=warning +org.eclipse.jdt.core.compiler.problem.potentialNullReference=error org.eclipse.jdt.core.compiler.problem.potentiallyUnclosedCloseable=warning org.eclipse.jdt.core.compiler.problem.rawTypeReference=warning org.eclipse.jdt.core.compiler.problem.redundantNullAnnotation=warning @@ -92,7 +108,7 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled @@ -118,6 +134,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverridin org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedImport=warning org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning org.eclipse.jdt.core.compiler.problem.unusedLocal=warning org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning org.eclipse.jdt.core.compiler.problem.unusedParameter=warning @@ -130,6 +147,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -170,6 +188,7 @@ org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0 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_permitted_types_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_record_components=16 org.eclipse.jdt.core.formatter.alignment_for_relational_operator=0 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 @@ -206,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -232,6 +252,7 @@ org.eclipse.jdt.core.formatter.comment.indent_tag_description=false org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_between_different_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.javadoc_do_not_separate_block_tags=false org.eclipse.jdt.core.formatter.comment.line_length=140 org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true @@ -265,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -460,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -524,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.ui.tests/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.ui.tests/src/main/java/org/eclipse/tm4e/ui/tests/internal/utils/DocumentInputStreamTest.java b/org.eclipse.tm4e.ui.tests/src/main/java/org/eclipse/tm4e/ui/tests/internal/utils/DocumentInputStreamTest.java index 13765a215..9ccebe07c 100644 --- a/org.eclipse.tm4e.ui.tests/src/main/java/org/eclipse/tm4e/ui/tests/internal/utils/DocumentInputStreamTest.java +++ b/org.eclipse.tm4e.ui.tests/src/main/java/org/eclipse/tm4e/ui/tests/internal/utils/DocumentInputStreamTest.java @@ -50,7 +50,7 @@ public void setUp() throws CoreException { p.create(null); p.open(null); - IFile testFile = p.getFile("testfile"); + final IFile testFile = p.getFile("testfile"); testFile.create(new ByteArrayInputStream(TEST_UNICODE.getBytes()), true, null); final var editorInput = new FileEditorInput(testFile); documentProvider.connect(editorInput); diff --git a/org.eclipse.tm4e.ui.tests/src/main/java/org/eclipse/tm4e/ui/tests/support/command/Command.java b/org.eclipse.tm4e.ui.tests/src/main/java/org/eclipse/tm4e/ui/tests/support/command/Command.java index f0f0dcdf2..d6d44b6a8 100644 --- a/org.eclipse.tm4e.ui.tests/src/main/java/org/eclipse/tm4e/ui/tests/support/command/Command.java +++ b/org.eclipse.tm4e.ui.tests/src/main/java/org/eclipse/tm4e/ui/tests/support/command/Command.java @@ -26,7 +26,6 @@ public String getName() { return name; } - public void setStyleRanges(final String styleRanges) { this.styleRanges = styleRanges; } diff --git a/org.eclipse.tm4e.ui/.settings/org.eclipse.core.resources.prefs b/org.eclipse.tm4e.ui/.settings/org.eclipse.core.resources.prefs new file mode 100644 index 000000000..99f26c020 --- /dev/null +++ b/org.eclipse.tm4e.ui/.settings/org.eclipse.core.resources.prefs @@ -0,0 +1,2 @@ +eclipse.preferences.version=1 +encoding/=UTF-8 diff --git a/org.eclipse.tm4e.ui/.settings/org.eclipse.jdt.core.prefs b/org.eclipse.tm4e.ui/.settings/org.eclipse.jdt.core.prefs index 543db3986..75d9b0744 100644 --- a/org.eclipse.tm4e.ui/.settings/org.eclipse.jdt.core.prefs +++ b/org.eclipse.tm4e.ui/.settings/org.eclipse.jdt.core.prefs @@ -1,7 +1,17 @@ eclipse.preferences.version=1 org.eclipse.jdt.core.builder.annotationPath.allLocations=enabled +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.recreateModifiedClassFileInOutputFolder=ignore +org.eclipse.jdt.core.builder.resourceCopyExclusionFilter= +org.eclipse.jdt.core.circularClasspath=warning +org.eclipse.jdt.core.classpath.exclusionPatterns=enabled +org.eclipse.jdt.core.classpath.mainOnlyProjectHasTestOnlyDependency=error +org.eclipse.jdt.core.classpath.multipleOutputLocations=enabled +org.eclipse.jdt.core.classpath.outputOverlappingAnotherSource=error org.eclipse.jdt.core.compiler.annotation.inheritNullAnnotations=enabled -org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=ignore +org.eclipse.jdt.core.compiler.annotation.missingNonNullByDefaultAnnotation=info org.eclipse.jdt.core.compiler.annotation.nonnull=org.eclipse.jdt.annotation.NonNull org.eclipse.jdt.core.compiler.annotation.nonnull.secondary= org.eclipse.jdt.core.compiler.annotation.nonnullbydefault=org.eclipse.jdt.annotation.NonNullByDefault @@ -11,7 +21,7 @@ org.eclipse.jdt.core.compiler.annotation.nullable=org.eclipse.jdt.annotation.Nul org.eclipse.jdt.core.compiler.annotation.nullable.secondary= org.eclipse.jdt.core.compiler.annotation.nullanalysis=enabled org.eclipse.jdt.core.compiler.annotation.owning=org.eclipse.jdt.annotation.Owning -org.eclipse.jdt.core.compiler.annotation.resourceanalysis=disabled +org.eclipse.jdt.core.compiler.annotation.resourceanalysis=enabled org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode=enabled org.eclipse.jdt.core.compiler.codegen.methodParameters=generate org.eclipse.jdt.core.compiler.codegen.targetPlatform=21 @@ -21,6 +31,7 @@ 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=200 org.eclipse.jdt.core.compiler.problem.APILeak=warning org.eclipse.jdt.core.compiler.problem.annotatedTypeArgumentToUnannotated=info org.eclipse.jdt.core.compiler.problem.annotationSuperInterface=warning @@ -97,7 +108,7 @@ org.eclipse.jdt.core.compiler.problem.reportMethodCanBeStatic=ignore org.eclipse.jdt.core.compiler.problem.reportPreviewFeatures=warning org.eclipse.jdt.core.compiler.problem.specialParameterHidingField=disabled org.eclipse.jdt.core.compiler.problem.staticAccessReceiver=warning -org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=disabled +org.eclipse.jdt.core.compiler.problem.suppressOptionalErrors=enabled org.eclipse.jdt.core.compiler.problem.suppressWarnings=enabled org.eclipse.jdt.core.compiler.problem.suppressWarningsNotFullyAnalysed=info org.eclipse.jdt.core.compiler.problem.syntacticNullAnalysisForFields=enabled @@ -123,6 +134,7 @@ org.eclipse.jdt.core.compiler.problem.unusedDeclaredThrownExceptionWhenOverridin org.eclipse.jdt.core.compiler.problem.unusedExceptionParameter=ignore org.eclipse.jdt.core.compiler.problem.unusedImport=warning org.eclipse.jdt.core.compiler.problem.unusedLabel=warning +org.eclipse.jdt.core.compiler.problem.unusedLambdaParameter=warning org.eclipse.jdt.core.compiler.problem.unusedLocal=warning org.eclipse.jdt.core.compiler.problem.unusedObjectAllocation=warning org.eclipse.jdt.core.compiler.problem.unusedParameter=warning @@ -135,6 +147,7 @@ org.eclipse.jdt.core.compiler.problem.unusedWarningToken=warning org.eclipse.jdt.core.compiler.problem.varargsArgumentNeedCast=warning org.eclipse.jdt.core.compiler.release=enabled org.eclipse.jdt.core.compiler.source=21 +org.eclipse.jdt.core.formatter.align_arrows_in_switch_on_columns=false org.eclipse.jdt.core.formatter.align_assignment_statements_on_columns=false org.eclipse.jdt.core.formatter.align_fields_grouping_blank_lines=2147483647 org.eclipse.jdt.core.formatter.align_selector_in_method_invocation_on_expression_first_line=false @@ -175,6 +188,7 @@ org.eclipse.jdt.core.formatter.alignment_for_multiplicative_operator=16 org.eclipse.jdt.core.formatter.alignment_for_parameterized_type_references=0 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_permitted_types_in_type_declaration=16 org.eclipse.jdt.core.formatter.alignment_for_record_components=16 org.eclipse.jdt.core.formatter.alignment_for_relational_operator=0 org.eclipse.jdt.core.formatter.alignment_for_resources_in_try=80 @@ -211,6 +225,7 @@ org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end 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_block_in_case_after_arrow=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 @@ -237,6 +252,7 @@ org.eclipse.jdt.core.formatter.comment.indent_tag_description=false org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_between_different_tags=insert org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=do not insert +org.eclipse.jdt.core.formatter.comment.javadoc_do_not_separate_block_tags=false org.eclipse.jdt.core.formatter.comment.line_length=140 org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries=true org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries=true @@ -270,7 +286,7 @@ 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_after_type_annotation=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_at_end_of_file_if_missing=insert org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert @@ -465,6 +481,7 @@ org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_ 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_line_comments=false org.eclipse.jdt.core.formatter.join_lines_in_comments=false org.eclipse.jdt.core.formatter.join_wrapped_lines=false org.eclipse.jdt.core.formatter.keep_annotation_declaration_on_one_line=one_line_never @@ -529,4 +546,6 @@ org.eclipse.jdt.core.formatter.wrap_before_shift_operator=true org.eclipse.jdt.core.formatter.wrap_before_string_concatenation=true org.eclipse.jdt.core.formatter.wrap_before_switch_case_arrow_operator=false org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested=true +org.eclipse.jdt.core.incompatibleJDKLevel=warning +org.eclipse.jdt.core.incompleteClasspath=error org.eclipse.jdt.core.javaFormatter=org.eclipse.jdt.core.defaultJavaFormatter diff --git a/org.eclipse.tm4e.ui/.settings/org.eclipse.jdt.ui.prefs b/org.eclipse.tm4e.ui/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 000000000..eeb5121f7 --- /dev/null +++ b/org.eclipse.tm4e.ui/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,307 @@ +cleanup.add_all=true +cleanup.add_default_serial_version_id=true +cleanup.add_generated_serial_version_id=false +cleanup.add_missing_annotations=true +cleanup.add_missing_deprecated_annotations=true +cleanup.add_missing_methods=false +cleanup.add_missing_nls_tags=false +cleanup.add_missing_override_annotations=true +cleanup.add_missing_override_annotations_interface_methods=true +cleanup.add_serial_version_id=true +cleanup.also_simplify_lambda=true +cleanup.always_use_blocks=false +cleanup.always_use_parentheses_in_expressions=false +cleanup.always_use_this_for_non_static_field_access=false +cleanup.always_use_this_for_non_static_method_access=false +cleanup.array_with_curly=true +cleanup.arrays_fill=true +cleanup.bitwise_conditional_expression=false +cleanup.boolean_literal=true +cleanup.boolean_value_rather_than_comparison=true +cleanup.break_loop=true +cleanup.collection_cloning=true +cleanup.comparing_on_criteria=true +cleanup.comparison_statement=true +cleanup.controlflow_merge=false +cleanup.convert_functional_interfaces=true +cleanup.convert_to_enhanced_for_loop=true +cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +cleanup.convert_to_switch_expressions=true +cleanup.correct_indentation=true +cleanup.do_while_rather_than_while=false +cleanup.double_negation=true +cleanup.else_if=false +cleanup.embedded_if=false +cleanup.evaluate_nullable=true +cleanup.extract_increment=false +cleanup.format_source_code=true +cleanup.format_source_code_changes_only=false +cleanup.hash=false +cleanup.if_condition=true +cleanup.insert_inferred_type_arguments=false +cleanup.instanceof=true +cleanup.instanceof_keyword=true +cleanup.invert_equals=false +cleanup.join=true +cleanup.lazy_logical_operator=true +cleanup.make_local_variable_final=true +cleanup.make_parameters_final=true +cleanup.make_private_fields_final=true +cleanup.make_type_abstract_if_missing_method=false +cleanup.make_variable_declarations_final=true +cleanup.map_cloning=true +cleanup.merge_conditional_blocks=false +cleanup.multi_catch=true +cleanup.never_use_blocks=false +cleanup.never_use_parentheses_in_expressions=true +cleanup.no_string_creation=false +cleanup.no_super=true +cleanup.number_suffix=true +cleanup.objects_equals=false +cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +cleanup.operand_factorization=false +cleanup.organize_imports=true +cleanup.overridden_assignment=false +cleanup.overridden_assignment_move_decl=true +cleanup.plain_replacement=true +cleanup.precompile_regex=false +cleanup.primitive_comparison=true +cleanup.primitive_parsing=true +cleanup.primitive_rather_than_wrapper=true +cleanup.primitive_serialization=true +cleanup.pull_out_if_from_if_else=false +cleanup.pull_up_assignment=false +cleanup.push_down_negation=false +cleanup.qualify_static_field_accesses_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +cleanup.qualify_static_member_accesses_with_declaring_class=false +cleanup.qualify_static_method_accesses_with_declaring_class=false +cleanup.reduce_indentation=false +cleanup.redundant_comparator=true +cleanup.redundant_falling_through_block_end=true +cleanup.remove_private_constructors=false +cleanup.remove_redundant_modifiers=true +cleanup.remove_redundant_semicolons=true +cleanup.remove_redundant_type_arguments=true +cleanup.remove_trailing_whitespaces=true +cleanup.remove_trailing_whitespaces_all=true +cleanup.remove_trailing_whitespaces_ignore_empty=false +cleanup.remove_unnecessary_array_creation=true +cleanup.remove_unnecessary_casts=true +cleanup.remove_unnecessary_nls_tags=true +cleanup.remove_unnecessary_suppress_warnings=true +cleanup.remove_unused_imports=true +cleanup.remove_unused_local_variables=false +cleanup.remove_unused_method_parameters=false +cleanup.remove_unused_private_fields=false +cleanup.remove_unused_private_members=false +cleanup.remove_unused_private_methods=false +cleanup.remove_unused_private_types=false +cleanup.replace_deprecated_calls=false +cleanup.replace_deprecated_fields=false +cleanup.return_expression=false +cleanup.simplify_boolean_if_else=false +cleanup.simplify_lambda_expression_and_method_ref=true +cleanup.single_used_field=false +cleanup.sort_members=false +cleanup.sort_members_all=false +cleanup.standard_comparison=false +cleanup.static_inner_class=true +cleanup.strictly_equal_or_different=false +cleanup.stringbuffer_to_stringbuilder=true +cleanup.stringbuilder=true +cleanup.stringbuilder_for_local_vars=true +cleanup.stringconcat_stringbuffer_stringbuilder=false +cleanup.stringconcat_to_textblock=false +cleanup.substring=true +cleanup.switch=false +cleanup.switch_for_instanceof_pattern=true +cleanup.system_property=true +cleanup.system_property_boolean=true +cleanup.system_property_file_encoding=true +cleanup.system_property_file_separator=true +cleanup.system_property_javaspecversion=true +cleanup.system_property_javaversion=true +cleanup.system_property_line_separator=true +cleanup.system_property_path_separator=true +cleanup.ternary_operator=true +cleanup.try_with_resource=true +cleanup.unlooped_while=true +cleanup.unreachable_block=false +cleanup.use_anonymous_class_creation=false +cleanup.use_autoboxing=true +cleanup.use_blocks=false +cleanup.use_blocks_only_for_return_and_throw=true +cleanup.use_directly_map_method=true +cleanup.use_lambda=true +cleanup.use_parentheses_in_expressions=true +cleanup.use_string_is_blank=true +cleanup.use_this_for_non_static_field_access=false +cleanup.use_this_for_non_static_field_access_only_if_necessary=true +cleanup.use_this_for_non_static_method_access=false +cleanup.use_this_for_non_static_method_access_only_if_necessary=true +cleanup.use_unboxing=true +cleanup.use_var=false +cleanup.useless_continue=true +cleanup.useless_return=true +cleanup.valueof_rather_than_instantiation=true +cleanup_profile=_TM4E +cleanup_settings_version=2 +eclipse.preferences.version=1 +editor_save_participant_org.eclipse.jdt.ui.postsavelistener.cleanup=true +formatter_profile=_TM4E +formatter_settings_version=23 +org.eclipse.jdt.ui.ignorelowercasenames=true +org.eclipse.jdt.ui.importorder=java;javax;org;com; +org.eclipse.jdt.ui.ondemandthreshold=99 +org.eclipse.jdt.ui.staticondemandthreshold=2 +sp_cleanup.add_all=true +sp_cleanup.add_default_serial_version_id=true +sp_cleanup.add_generated_serial_version_id=false +sp_cleanup.add_missing_annotations=true +sp_cleanup.add_missing_deprecated_annotations=true +sp_cleanup.add_missing_methods=false +sp_cleanup.add_missing_nls_tags=false +sp_cleanup.add_missing_override_annotations=true +sp_cleanup.add_missing_override_annotations_interface_methods=true +sp_cleanup.add_serial_version_id=true +sp_cleanup.also_simplify_lambda=true +sp_cleanup.always_use_blocks=false +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.array_with_curly=true +sp_cleanup.arrays_fill=true +sp_cleanup.bitwise_conditional_expression=false +sp_cleanup.boolean_literal=true +sp_cleanup.boolean_value_rather_than_comparison=true +sp_cleanup.break_loop=true +sp_cleanup.collection_cloning=true +sp_cleanup.comparing_on_criteria=true +sp_cleanup.comparison_statement=true +sp_cleanup.controlflow_merge=false +sp_cleanup.convert_functional_interfaces=true +sp_cleanup.convert_to_enhanced_for_loop=true +sp_cleanup.convert_to_enhanced_for_loop_if_loop_var_used=true +sp_cleanup.convert_to_switch_expressions=true +sp_cleanup.correct_indentation=true +sp_cleanup.do_while_rather_than_while=false +sp_cleanup.double_negation=true +sp_cleanup.else_if=false +sp_cleanup.embedded_if=false +sp_cleanup.evaluate_nullable=true +sp_cleanup.extract_increment=false +sp_cleanup.format_source_code=true +sp_cleanup.format_source_code_changes_only=false +sp_cleanup.hash=false +sp_cleanup.if_condition=true +sp_cleanup.insert_inferred_type_arguments=false +sp_cleanup.instanceof=true +sp_cleanup.instanceof_keyword=true +sp_cleanup.invert_equals=false +sp_cleanup.join=true +sp_cleanup.lazy_logical_operator=true +sp_cleanup.make_local_variable_final=true +sp_cleanup.make_parameters_final=true +sp_cleanup.make_private_fields_final=true +sp_cleanup.make_type_abstract_if_missing_method=false +sp_cleanup.make_variable_declarations_final=true +sp_cleanup.map_cloning=true +sp_cleanup.merge_conditional_blocks=false +sp_cleanup.multi_catch=true +sp_cleanup.never_use_blocks=false +sp_cleanup.never_use_parentheses_in_expressions=true +sp_cleanup.no_string_creation=false +sp_cleanup.no_super=true +sp_cleanup.number_suffix=true +sp_cleanup.objects_equals=false +sp_cleanup.on_save_use_additional_actions=true +sp_cleanup.one_if_rather_than_duplicate_blocks_that_fall_through=false +sp_cleanup.operand_factorization=false +sp_cleanup.organize_imports=true +sp_cleanup.overridden_assignment=false +sp_cleanup.overridden_assignment_move_decl=true +sp_cleanup.plain_replacement=true +sp_cleanup.precompile_regex=false +sp_cleanup.primitive_comparison=true +sp_cleanup.primitive_parsing=true +sp_cleanup.primitive_rather_than_wrapper=true +sp_cleanup.primitive_serialization=true +sp_cleanup.pull_out_if_from_if_else=false +sp_cleanup.pull_up_assignment=false +sp_cleanup.push_down_negation=false +sp_cleanup.qualify_static_field_accesses_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_instances_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class=false +sp_cleanup.qualify_static_member_accesses_with_declaring_class=false +sp_cleanup.qualify_static_method_accesses_with_declaring_class=false +sp_cleanup.reduce_indentation=false +sp_cleanup.redundant_comparator=true +sp_cleanup.redundant_falling_through_block_end=true +sp_cleanup.remove_private_constructors=false +sp_cleanup.remove_redundant_modifiers=true +sp_cleanup.remove_redundant_semicolons=true +sp_cleanup.remove_redundant_type_arguments=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_array_creation=true +sp_cleanup.remove_unnecessary_casts=true +sp_cleanup.remove_unnecessary_nls_tags=true +sp_cleanup.remove_unnecessary_suppress_warnings=true +sp_cleanup.remove_unused_imports=true +sp_cleanup.remove_unused_local_variables=false +sp_cleanup.remove_unused_method_parameters=false +sp_cleanup.remove_unused_private_fields=false +sp_cleanup.remove_unused_private_members=false +sp_cleanup.remove_unused_private_methods=false +sp_cleanup.remove_unused_private_types=false +sp_cleanup.replace_deprecated_calls=false +sp_cleanup.replace_deprecated_fields=false +sp_cleanup.return_expression=false +sp_cleanup.simplify_boolean_if_else=false +sp_cleanup.simplify_lambda_expression_and_method_ref=true +sp_cleanup.single_used_field=false +sp_cleanup.sort_members=false +sp_cleanup.sort_members_all=false +sp_cleanup.standard_comparison=false +sp_cleanup.static_inner_class=true +sp_cleanup.strictly_equal_or_different=false +sp_cleanup.stringbuffer_to_stringbuilder=true +sp_cleanup.stringbuilder=true +sp_cleanup.stringbuilder_for_local_vars=true +sp_cleanup.stringconcat_stringbuffer_stringbuilder=false +sp_cleanup.stringconcat_to_textblock=false +sp_cleanup.substring=true +sp_cleanup.switch=false +sp_cleanup.switch_for_instanceof_pattern=true +sp_cleanup.system_property=true +sp_cleanup.system_property_boolean=true +sp_cleanup.system_property_file_encoding=true +sp_cleanup.system_property_file_separator=true +sp_cleanup.system_property_javaspecversion=true +sp_cleanup.system_property_javaversion=true +sp_cleanup.system_property_line_separator=true +sp_cleanup.system_property_path_separator=true +sp_cleanup.ternary_operator=true +sp_cleanup.try_with_resource=true +sp_cleanup.unlooped_while=true +sp_cleanup.unreachable_block=false +sp_cleanup.use_anonymous_class_creation=false +sp_cleanup.use_autoboxing=true +sp_cleanup.use_blocks=false +sp_cleanup.use_blocks_only_for_return_and_throw=true +sp_cleanup.use_directly_map_method=true +sp_cleanup.use_lambda=true +sp_cleanup.use_parentheses_in_expressions=true +sp_cleanup.use_string_is_blank=true +sp_cleanup.use_this_for_non_static_field_access=false +sp_cleanup.use_this_for_non_static_field_access_only_if_necessary=true +sp_cleanup.use_this_for_non_static_method_access=false +sp_cleanup.use_this_for_non_static_method_access_only_if_necessary=true +sp_cleanup.use_unboxing=true +sp_cleanup.use_var=false +sp_cleanup.useless_continue=true +sp_cleanup.useless_return=true +sp_cleanup.valueof_rather_than_instantiation=true diff --git a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/model/TMDocumentModel.java b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/model/TMDocumentModel.java index 97fa87686..4de3cd64f 100644 --- a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/model/TMDocumentModel.java +++ b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/model/TMDocumentModel.java @@ -58,12 +58,12 @@ public void documentChanged(final DocumentEvent event) { final var isFullLineInsert = DocumentHelper.getStartLineCharIndex(event) == 0 && event.getText().endsWith("\n"); - final var linesAdded = (isFullLineInsert ? 0 : 1) + (endLineIndexOfAddedText - startLineIndex); + final var linesAdded = (isFullLineInsert ? 0 : 1) + endLineIndexOfAddedText - startLineIndex; onLinesReplaced(startLineIndex, isFullLineInsert ? 0 : 1, linesAdded); break; } case REMOVE: { - onLinesReplaced(startLineIndex, 1 + (endLineIndexOfRemovedText - startLineIndex), 1); + onLinesReplaced(startLineIndex, 1 + endLineIndexOfRemovedText - startLineIndex, 1); break; } case REPLACE: { @@ -72,8 +72,8 @@ public void documentChanged(final DocumentEvent event) { && event.getText().endsWith("\n"); onLinesReplaced(startLineIndex, - (isFullLineInsert ? 0 : 1) + (endLineIndexOfRemovedText - startLineIndex), - (isFullLineInsert ? 0 : 1) + (endLineIndexOfAddedText - startLineIndex)); + (isFullLineInsert ? 0 : 1) + endLineIndexOfRemovedText - startLineIndex, + (isFullLineInsert ? 0 : 1) + endLineIndexOfAddedText - startLineIndex); break; } } diff --git a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/preferences/PreferenceHelper.java b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/preferences/PreferenceHelper.java index 17ba87ae3..c36a848d5 100644 --- a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/preferences/PreferenceHelper.java +++ b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/preferences/PreferenceHelper.java @@ -11,7 +11,7 @@ */ package org.eclipse.tm4e.ui.internal.preferences; -import static org.eclipse.tm4e.core.internal.utils.NullSafetyHelper.*; +import static org.eclipse.tm4e.core.internal.utils.NullSafetyHelper.castNonNull; import java.io.IOException; import java.util.Collection; @@ -115,7 +115,7 @@ public static boolean isTMTokenHoverEnabled() { return TMUIPlugin.getPreference(PreferenceConstants.TMTOKEN_HOVER_ENABLED, false); } - public static void saveTMTokenHoverEnabled(boolean isEnabled) throws BackingStoreException { + public static void saveTMTokenHoverEnabled(final boolean isEnabled) throws BackingStoreException { final var prefs = InstanceScope.INSTANCE.getNode(TMUIPlugin.PLUGIN_ID); prefs.putBoolean(PreferenceConstants.TMTOKEN_HOVER_ENABLED, isEnabled); prefs.flush(); diff --git a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/preferences/ThemePreferencePage.java b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/preferences/ThemePreferencePage.java index 7641ac48b..90749a678 100644 --- a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/preferences/ThemePreferencePage.java +++ b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/preferences/ThemePreferencePage.java @@ -13,7 +13,7 @@ *******************************************************************************/ package org.eclipse.tm4e.ui.internal.preferences; -import static org.eclipse.tm4e.core.internal.utils.NullSafetyHelper.*; +import static org.eclipse.tm4e.core.internal.utils.NullSafetyHelper.lateNonNull; import java.nio.file.Path; import java.util.stream.Stream; @@ -279,7 +279,7 @@ private void preview() { return; final var selection = grammarsCombo.getStructuredSelection(); - if (selection.getFirstElement() instanceof IGrammarDefinition definition) { + if (selection.getFirstElement() instanceof final IGrammarDefinition definition) { // Preview the grammar final IGrammar grammar = grammarManager.getGrammarForScope(definition.getScope()); themePreview.setTheme(theme); diff --git a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/themes/ThemeManager.java b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/themes/ThemeManager.java index 4484e3448..16c7020be 100644 --- a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/themes/ThemeManager.java +++ b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/themes/ThemeManager.java @@ -11,7 +11,7 @@ */ package org.eclipse.tm4e.ui.internal.themes; -import static org.eclipse.tm4e.core.internal.utils.NullSafetyHelper.*; +import static org.eclipse.tm4e.core.internal.utils.NullSafetyHelper.castNonNull; import java.util.Arrays; diff --git a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/ClassHelper.java b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/ClassHelper.java index 689f49c6b..22d97072e 100644 --- a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/ClassHelper.java +++ b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/ClassHelper.java @@ -27,7 +27,6 @@ public final class ClassHelper { try { return (T) f.get(object); } catch (final Exception e) { - return null; } } return null; diff --git a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/ContentTypeHelper.java b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/ContentTypeHelper.java index eeb1a6276..d7ca39060 100644 --- a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/ContentTypeHelper.java +++ b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/ContentTypeHelper.java @@ -33,6 +33,7 @@ import org.eclipse.core.runtime.ListenerList; import org.eclipse.core.runtime.content.IContentType; import org.eclipse.jdt.annotation.Nullable; +import org.eclipse.jdt.annotation.Owning; import org.eclipse.jface.text.IDocument; import org.eclipse.tm4e.ui.TMUIPlugin; import org.eclipse.ui.IEditorInput; @@ -142,7 +143,7 @@ public static IContentType[] findContentTypesByFileName(final String fileName) { * * @throws CoreException */ - private static InputStream getContents(final ITextFileBuffer buffer) throws CoreException { + private static @Owning InputStream getContents(final ITextFileBuffer buffer) throws CoreException { final IPath path = buffer.getLocation(); if (path != null) { if (path.isAbsolute()) { @@ -189,7 +190,6 @@ private static InputStream getContents(final ITextFileBuffer buffer) throws Core } } catch (final Exception ex) { TMUIPlugin.logTrace(ex); - return null; } } /*else { // TODO: manage other type of IEditorInput diff --git a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/GrammarUtils.java b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/GrammarUtils.java index 94793c20b..76b7c8599 100644 --- a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/GrammarUtils.java +++ b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/GrammarUtils.java @@ -45,7 +45,7 @@ public final class GrammarUtils { } return grammar; } - + private GrammarUtils() { } } diff --git a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/MarkerUtils.java b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/MarkerUtils.java index bedb4f846..7ff35bfff 100644 --- a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/MarkerUtils.java +++ b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/utils/MarkerUtils.java @@ -98,7 +98,7 @@ private static void updateTextMarkers(final ITMDocumentModel docModel, final int continue; } - final int lineNumber = lineNumberObj.intValue(); + final int lineNumber = lineNumberObj; if (lineNumber < startLineNumber) { continue; // this marker needs no update } diff --git a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/widgets/TableWithControlsWidget.java b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/widgets/TableWithControlsWidget.java index 9ffe96746..9939b3d1d 100644 --- a/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/widgets/TableWithControlsWidget.java +++ b/org.eclipse.tm4e.ui/src/main/java/org/eclipse/tm4e/ui/internal/widgets/TableWithControlsWidget.java @@ -59,7 +59,7 @@ protected TableWithControlsWidget(final Composite parent, final @Nullable String buttonsArea.setLayoutData(new GridData(GridData.VERTICAL_ALIGN_BEGINNING | GridData.FILL_VERTICAL)); createButtons(); if (buttonsArea.getChildren().length == 0) { - (castNonNull((GridLayout) parent.getLayout())).horizontalSpacing = 0; + castNonNull((GridLayout) parent.getLayout()).horizontalSpacing = 0; } } diff --git a/org.eclipse.tm4e.ui/src/test/java/org/eclipse/tm4e/ui/internal/model/TMDocumentModelTest.java b/org.eclipse.tm4e.ui/src/test/java/org/eclipse/tm4e/ui/internal/model/TMDocumentModelTest.java index a1acd873a..2a9b31358 100644 --- a/org.eclipse.tm4e.ui/src/test/java/org/eclipse/tm4e/ui/internal/model/TMDocumentModelTest.java +++ b/org.eclipse.tm4e.ui/src/test/java/org/eclipse/tm4e/ui/internal/model/TMDocumentModelTest.java @@ -13,6 +13,7 @@ import static org.assertj.core.api.Assertions.assertThat; import static org.eclipse.tm4e.core.registry.IGrammarSource.fromString; + import org.eclipse.jface.text.Document; import org.eclipse.tm4e.core.registry.IGrammarSource.ContentType; import org.eclipse.tm4e.core.registry.Registry;