Reformatting and cleaning up code (step 2/2)
This commit is contained in:
parent
95b9121a77
commit
cb75d15dd1
78 changed files with 1807 additions and 1460 deletions
56
cleanup.xml
Normal file
56
cleanup.xml
Normal file
|
@ -0,0 +1,56 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<profiles version="2">
|
||||
<profile kind="CleanUpProfile" name="ROME" version="2">
|
||||
<setting id="cleanup.remove_unused_private_fields" value="true"/>
|
||||
<setting id="cleanup.always_use_parentheses_in_expressions" value="false"/>
|
||||
<setting id="cleanup.never_use_blocks" value="false"/>
|
||||
<setting id="cleanup.remove_unused_private_methods" value="true"/>
|
||||
<setting id="cleanup.add_missing_deprecated_annotations" value="true"/>
|
||||
<setting id="cleanup.convert_to_enhanced_for_loop" value="true"/>
|
||||
<setting id="cleanup.remove_unnecessary_nls_tags" value="true"/>
|
||||
<setting id="cleanup.sort_members" value="false"/>
|
||||
<setting id="cleanup.remove_unused_local_variables" value="false"/>
|
||||
<setting id="cleanup.never_use_parentheses_in_expressions" value="true"/>
|
||||
<setting id="cleanup.remove_unused_private_members" value="false"/>
|
||||
<setting id="cleanup.remove_unnecessary_casts" value="true"/>
|
||||
<setting id="cleanup.make_parameters_final" value="true"/>
|
||||
<setting id="cleanup.use_this_for_non_static_field_access" value="true"/>
|
||||
<setting id="cleanup.remove_private_constructors" value="true"/>
|
||||
<setting id="cleanup.use_blocks" value="true"/>
|
||||
<setting id="cleanup.always_use_this_for_non_static_method_access" value="false"/>
|
||||
<setting id="cleanup.remove_trailing_whitespaces_all" value="true"/>
|
||||
<setting id="cleanup.always_use_this_for_non_static_field_access" value="false"/>
|
||||
<setting id="cleanup.use_this_for_non_static_field_access_only_if_necessary" value="true"/>
|
||||
<setting id="cleanup.add_default_serial_version_id" value="true"/>
|
||||
<setting id="cleanup.make_type_abstract_if_missing_method" value="false"/>
|
||||
<setting id="cleanup.qualify_static_member_accesses_through_subtypes_with_declaring_class" value="true"/>
|
||||
<setting id="cleanup.make_variable_declarations_final" value="true"/>
|
||||
<setting id="cleanup.add_missing_nls_tags" value="false"/>
|
||||
<setting id="cleanup.format_source_code" value="true"/>
|
||||
<setting id="cleanup.qualify_static_method_accesses_with_declaring_class" value="false"/>
|
||||
<setting id="cleanup.add_missing_override_annotations" value="true"/>
|
||||
<setting id="cleanup.remove_unused_private_types" value="true"/>
|
||||
<setting id="cleanup.add_missing_methods" value="false"/>
|
||||
<setting id="cleanup.make_local_variable_final" value="true"/>
|
||||
<setting id="cleanup.correct_indentation" value="true"/>
|
||||
<setting id="cleanup.add_missing_override_annotations_interface_methods" value="true"/>
|
||||
<setting id="cleanup.remove_unused_imports" value="true"/>
|
||||
<setting id="cleanup.remove_trailing_whitespaces_ignore_empty" value="false"/>
|
||||
<setting id="cleanup.make_private_fields_final" value="true"/>
|
||||
<setting id="cleanup.add_generated_serial_version_id" value="false"/>
|
||||
<setting id="cleanup.organize_imports" value="true"/>
|
||||
<setting id="cleanup.remove_trailing_whitespaces" value="true"/>
|
||||
<setting id="cleanup.sort_members_all" value="false"/>
|
||||
<setting id="cleanup.use_blocks_only_for_return_and_throw" value="false"/>
|
||||
<setting id="cleanup.add_missing_annotations" value="true"/>
|
||||
<setting id="cleanup.use_parentheses_in_expressions" value="true"/>
|
||||
<setting id="cleanup.qualify_static_field_accesses_with_declaring_class" value="false"/>
|
||||
<setting id="cleanup.use_this_for_non_static_method_access_only_if_necessary" value="true"/>
|
||||
<setting id="cleanup.use_this_for_non_static_method_access" value="true"/>
|
||||
<setting id="cleanup.qualify_static_member_accesses_through_instances_with_declaring_class" value="true"/>
|
||||
<setting id="cleanup.add_serial_version_id" value="false"/>
|
||||
<setting id="cleanup.format_source_code_changes_only" value="false"/>
|
||||
<setting id="cleanup.qualify_static_member_accesses_with_declaring_class" value="true"/>
|
||||
<setting id="cleanup.always_use_blocks" value="true"/>
|
||||
</profile>
|
||||
</profiles>
|
291
formatter.xml
Normal file
291
formatter.xml
Normal file
|
@ -0,0 +1,291 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<profiles version="12">
|
||||
<profile kind="CodeFormatterProfile" name="ROME" version="12">
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.disabling_tag" value="@formatter:off"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.new_lines_at_block_boundaries" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_field" value="0"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.use_on_off_tags" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_ellipsis" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_multiple_fields" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_conditional_expression" value="80"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_binary_operator" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_array_initializer" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_after_package" value="1"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.continuation_indentation" value="2"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk" value="1"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_binary_operator" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_package" value="0"/>
|
||||
<setting id="org.eclipse.jdt.core.compiler.source" value="1.7"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.format_line_comments" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.join_wrapped_lines" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_member_type" value="1"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.align_type_members_on_columns" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_unary_operator" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.indent_parameter_description" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.lineSplit" value="160"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration" value="0"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_method" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indentation.size" value="4"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.enabling_tag" value="@formatter:on"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_assignment" value="0"/>
|
||||
<setting id="org.eclipse.jdt.core.compiler.problem.assertIdentifier" value="error"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.tabulation.char" value="space"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_try_resources" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_statements_compare_to_body" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_method" value="1"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.wrap_outer_expressions_when_nested" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_method_declaration" value="0"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_try" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_switch" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_try" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.preserve_white_space_between_code_and_line_comments" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.compiler.problem.enumIdentifier" value="error"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_ellipsis" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_block" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_method_declaration" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.compact_else_if" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.wrap_before_or_operator_multicatch" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.format_line_comment_starting_on_first_column" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_field" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.indent_root_tags" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_enum_constant" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_union_type_in_multicatch" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.tabulation.size" value="4"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_empty_lines" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_block_in_case" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve" value="1"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.compiler.compliance" value="1.7"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer" value="2"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_unary_operator" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_binary_expression" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_type" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.compiler.codegen.inlineJsrBytecode" value="enabled"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_try" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_label" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.format_javadoc_comments" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.line_length" value="80"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_package" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_between_import_groups" value="1"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_semicolon" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body" value="0"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.wrap_before_binary_operator" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations" value="1"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_statements_compare_to_block" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.join_lines_in_comments" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_compact_if" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_before_imports" value="1"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.format_html" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.format_source_code" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration" value="16"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.compiler.codegen.targetPlatform" value="1.7"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_resources_in_try" value="80"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_arguments_in_annotation" value="0"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.format_header" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.format_block_comments" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.alignment_for_enum_constants" value="0"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.brace_position_for_type_declaration" value="end_of_line"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.comment.new_lines_at_javadoc_boundaries" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.blank_lines_after_imports" value="1"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header" value="true"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for" value="insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_try_resources" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments" value="do not insert"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column" value="false"/>
|
||||
<setting id="org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line" value="false"/>
|
||||
</profile>
|
||||
</profiles>
|
|
@ -43,11 +43,11 @@ import com.sun.syndication.feed.module.impl.ModuleUtils;
|
|||
*
|
||||
*/
|
||||
public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _feedType;
|
||||
private String _encoding;
|
||||
private List<Module> _modules;
|
||||
private List<Element> _foreignMarkup;
|
||||
private final ObjectBean objBean;
|
||||
private String feedType;
|
||||
private String encoding;
|
||||
private List<Module> modules;
|
||||
private List<Element> foreignMarkup;
|
||||
|
||||
/**
|
||||
* Default constructor, for bean cloning purposes only.
|
||||
|
@ -55,7 +55,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
protected WireFeed() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -67,7 +67,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
protected WireFeed(final String type) {
|
||||
this();
|
||||
this._feedType = type;
|
||||
feedType = type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -81,7 +81,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -104,7 +104,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
// can't use foreign markup in equals, due to JDOM equals impl
|
||||
final List<Element> fm = getForeignMarkup();
|
||||
setForeignMarkup(((WireFeed) other).getForeignMarkup());
|
||||
final boolean ret = this._objBean.equals(other);
|
||||
final boolean ret = objBean.equals(other);
|
||||
// restore foreign markup
|
||||
setForeignMarkup(fm);
|
||||
return ret;
|
||||
|
@ -121,7 +121,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -133,7 +133,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -145,7 +145,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setFeedType(final String feedType) {
|
||||
this._feedType = feedType;
|
||||
this.feedType = feedType;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -154,7 +154,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
* @return the type of the feed.
|
||||
*/
|
||||
public String getFeedType() {
|
||||
return this._feedType;
|
||||
return feedType;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -168,7 +168,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public String getEncoding() {
|
||||
return this._encoding;
|
||||
return encoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -182,7 +182,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setEncoding(final String encoding) {
|
||||
this._encoding = encoding;
|
||||
this.encoding = encoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -195,7 +195,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public List<Module> getModules() {
|
||||
return this._modules == null ? (this._modules = new ArrayList<Module>()) : this._modules;
|
||||
return modules == null ? (modules = new ArrayList<Module>()) : modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -208,7 +208,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public void setModules(final List<Module> modules) {
|
||||
this._modules = modules;
|
||||
this.modules = modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -220,7 +220,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public Module getModule(final String uri) {
|
||||
return ModuleUtils.getModule(this._modules, uri);
|
||||
return ModuleUtils.getModule(modules, uri);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -231,7 +231,7 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public List<Element> getForeignMarkup() {
|
||||
return this._foreignMarkup == null ? (this._foreignMarkup = new ArrayList<Element>()) : this._foreignMarkup;
|
||||
return foreignMarkup == null ? (foreignMarkup = new ArrayList<Element>()) : foreignMarkup;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -242,6 +242,6 @@ public abstract class WireFeed implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setForeignMarkup(final List<Element> foreignMarkup) {
|
||||
this._foreignMarkup = foreignMarkup;
|
||||
this.foreignMarkup = foreignMarkup;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,12 +28,12 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*/
|
||||
public class Category implements Cloneable, Serializable {
|
||||
|
||||
private final ObjectBean _objBean;
|
||||
private final ObjectBean objBean;
|
||||
|
||||
private String _term;
|
||||
private String _scheme;
|
||||
private String _schemeResolved;
|
||||
private String _label;
|
||||
private String term;
|
||||
private String scheme;
|
||||
private String schemeResolved;
|
||||
private String label;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -41,7 +41,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Category() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -55,7 +55,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -72,7 +72,7 @@ public class Category implements Cloneable, Serializable {
|
|||
if (!(other instanceof Category)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -86,7 +86,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -98,7 +98,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -108,7 +108,7 @@ public class Category implements Cloneable, Serializable {
|
|||
* @return Label for category.
|
||||
*/
|
||||
public String getLabel() {
|
||||
return this._label;
|
||||
return label;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -118,7 +118,7 @@ public class Category implements Cloneable, Serializable {
|
|||
* @param label Label for category.
|
||||
*/
|
||||
public void setLabel(final String label) {
|
||||
this._label = label;
|
||||
this.label = label;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -128,7 +128,7 @@ public class Category implements Cloneable, Serializable {
|
|||
* @return Scheme URI for category.
|
||||
*/
|
||||
public String getScheme() {
|
||||
return this._scheme;
|
||||
return scheme;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -138,15 +138,15 @@ public class Category implements Cloneable, Serializable {
|
|||
* @param scheme Scheme URI for category.
|
||||
*/
|
||||
public void setScheme(final String scheme) {
|
||||
this._scheme = scheme;
|
||||
this.scheme = scheme;
|
||||
}
|
||||
|
||||
public void setSchemeResolved(final String schemeResolved) {
|
||||
this._schemeResolved = schemeResolved;
|
||||
this.schemeResolved = schemeResolved;
|
||||
}
|
||||
|
||||
public String getSchemeResolved() {
|
||||
return this._schemeResolved != null ? this._schemeResolved : this._scheme;
|
||||
return schemeResolved != null ? schemeResolved : scheme;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -156,7 +156,7 @@ public class Category implements Cloneable, Serializable {
|
|||
* @return Term for category.
|
||||
*/
|
||||
public String getTerm() {
|
||||
return this._term;
|
||||
return term;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -166,6 +166,6 @@ public class Category implements Cloneable, Serializable {
|
|||
* @param term Term for category.
|
||||
*/
|
||||
public void setTerm(final String term) {
|
||||
this._term = term;
|
||||
this.term = term;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -31,11 +31,11 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*/
|
||||
public class Content implements Cloneable, Serializable {
|
||||
|
||||
private final ObjectBean _objBean;
|
||||
private final ObjectBean objBean;
|
||||
|
||||
private String _type;
|
||||
private String _value;
|
||||
private String _src;
|
||||
private String type;
|
||||
private String value;
|
||||
private String src;
|
||||
|
||||
/** @since Atom 1.0 */
|
||||
public static final String TEXT = "text";
|
||||
|
@ -55,7 +55,7 @@ public class Content implements Cloneable, Serializable {
|
|||
/** Atom 0.3 only */
|
||||
public static final String ESCAPED = "escaped";
|
||||
|
||||
private String _mode;
|
||||
private String mode;
|
||||
private static final Set<String> MODES = new HashSet<String>();
|
||||
static {
|
||||
MODES.add(XML);
|
||||
|
@ -69,7 +69,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Content() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -83,7 +83,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -100,7 +100,7 @@ public class Content implements Cloneable, Serializable {
|
|||
if (!(other instanceof Content)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -114,7 +114,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -126,7 +126,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -138,7 +138,7 @@ public class Content implements Cloneable, Serializable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -150,7 +150,7 @@ public class Content implements Cloneable, Serializable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setType(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -162,7 +162,7 @@ public class Content implements Cloneable, Serializable {
|
|||
* @return the content mode, <b>null</b> if none.
|
||||
*/
|
||||
public String getMode() {
|
||||
return this._mode;
|
||||
return mode;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -178,7 +178,7 @@ public class Content implements Cloneable, Serializable {
|
|||
if (mode == null || !MODES.contains(mode)) {
|
||||
throw new IllegalArgumentException("Invalid mode [" + mode + "]");
|
||||
}
|
||||
this._mode = mode;
|
||||
this.mode = mode;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -191,7 +191,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getValue() {
|
||||
return this._value;
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -204,7 +204,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setValue(final String value) {
|
||||
this._value = value;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -215,7 +215,7 @@ public class Content implements Cloneable, Serializable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getSrc() {
|
||||
return this._src;
|
||||
return src;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -226,6 +226,6 @@ public class Content implements Cloneable, Serializable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setSrc(final String src) {
|
||||
this._src = src;
|
||||
this.src = src;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -36,24 +36,24 @@ import com.sun.syndication.feed.module.impl.ModuleUtils;
|
|||
* @author Dave Johnson (updated for Atom 1.0)
|
||||
*/
|
||||
public class Entry implements Cloneable, Serializable, Extendable {
|
||||
private Content _summary;
|
||||
private Content _title;
|
||||
private Date _created; // Atom 0.3 only
|
||||
private Date _published; // AKA issued
|
||||
private Date _updated; // AKA modified
|
||||
private Feed _source;
|
||||
private List<Link> _alternateLinks;
|
||||
private List<Person> _authors;
|
||||
private List<Category> _categories;
|
||||
private List<Content> _contents;
|
||||
private List<Person> _contributors;
|
||||
private List<Element> _foreignMarkup;
|
||||
private List<Module> _modules;
|
||||
private List<Link> _otherLinks;
|
||||
private final ObjectBean _objBean;
|
||||
private String _id;
|
||||
private String _rights;
|
||||
private String _xmlBase;
|
||||
private Content summary;
|
||||
private Content title;
|
||||
private Date created; // Atom 0.3 only
|
||||
private Date published; // AKA issued
|
||||
private Date updated; // AKA modified
|
||||
private Feed source;
|
||||
private List<Link> alternateLinks;
|
||||
private List<Person> authors;
|
||||
private List<Category> categories;
|
||||
private List<Content> contents;
|
||||
private List<Person> contributors;
|
||||
private List<Element> foreignMarkup;
|
||||
private List<Module> modules;
|
||||
private List<Link> otherLinks;
|
||||
private final ObjectBean objBean;
|
||||
private String id;
|
||||
private String rights;
|
||||
private String xmlBase;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -61,7 +61,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Entry() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -72,7 +72,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* links to set, an empty list or <b>null</b> if none.
|
||||
*/
|
||||
public void setAlternateLinks(final List<Link> alternateLinks) {
|
||||
this._alternateLinks = alternateLinks;
|
||||
this.alternateLinks = alternateLinks;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -83,7 +83,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* list if none.
|
||||
*/
|
||||
public List<Link> getAlternateLinks() {
|
||||
return this._alternateLinks == null ? (this._alternateLinks = new ArrayList<Link>()) : this._alternateLinks;
|
||||
return alternateLinks == null ? (alternateLinks = new ArrayList<Link>()) : alternateLinks;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -94,7 +94,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setAuthors(final List<Person> authors) {
|
||||
this._authors = authors;
|
||||
this.authors = authors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -105,7 +105,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public List<Person> getAuthors() {
|
||||
return this._authors == null ? (this._authors = new ArrayList<Person>()) : this._authors;
|
||||
return authors == null ? (authors = new ArrayList<Person>()) : authors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -116,7 +116,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setCategories(final List<Category> categories) {
|
||||
this._categories = categories;
|
||||
this.categories = categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -127,7 +127,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public List<Category> getCategories() {
|
||||
return this._categories == null ? (this._categories = new ArrayList<Category>()) : this._categories;
|
||||
return categories == null ? (categories = new ArrayList<Category>()) : categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -138,7 +138,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* set, an empty list or <b>null</b> if none.
|
||||
*/
|
||||
public void setContents(final List<Content> contents) {
|
||||
this._contents = contents;
|
||||
this.contents = contents;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -149,7 +149,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* if none.
|
||||
*/
|
||||
public List<Content> getContents() {
|
||||
return this._contents == null ? (this._contents = new ArrayList<Content>()) : this._contents;
|
||||
return contents == null ? (contents = new ArrayList<Content>()) : contents;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -161,7 +161,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setContributors(final List<Person> contributors) {
|
||||
this._contributors = contributors;
|
||||
this.contributors = contributors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -173,7 +173,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public List<Person> getContributors() {
|
||||
return this._contributors == null ? (this._contributors = new ArrayList<Person>()) : this._contributors;
|
||||
return contributors == null ? (contributors = new ArrayList<Person>()) : contributors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -183,7 +183,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @param created the entry created date, <b>null</b> if none.
|
||||
*/
|
||||
public void setCreated(final Date created) {
|
||||
this._created = new Date(created.getTime());
|
||||
this.created = new Date(created.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -193,7 +193,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @return the entry created date, <b>null</b> if none.
|
||||
*/
|
||||
public Date getCreated() {
|
||||
return this._created == null ? null : new Date(this._created.getTime());
|
||||
return created == null ? null : new Date(created.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -204,7 +204,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setForeignMarkup(final List<Element> foreignMarkup) {
|
||||
this._foreignMarkup = foreignMarkup;
|
||||
this.foreignMarkup = foreignMarkup;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -215,7 +215,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public List<Element> getForeignMarkup() {
|
||||
return this._foreignMarkup == null ? (this._foreignMarkup = new ArrayList<Element>()) : this._foreignMarkup;
|
||||
return foreignMarkup == null ? (foreignMarkup = new ArrayList<Element>()) : foreignMarkup;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -226,7 +226,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setId(final String id) {
|
||||
this._id = id;
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -237,7 +237,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public String getId() {
|
||||
return this._id;
|
||||
return id;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -248,7 +248,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @param issued the entry issued date, <b>null</b> if none.
|
||||
*/
|
||||
public void setIssued(final Date issued) {
|
||||
this._published = issued == null ? null : new Date(issued.getTime());
|
||||
published = issued == null ? null : new Date(issued.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -259,7 +259,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @return the entry issued date, <b>null</b> if none.
|
||||
*/
|
||||
public Date getIssued() {
|
||||
return this._published == null ? null : new Date(this._published.getTime());
|
||||
return published == null ? null : new Date(published.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -290,7 +290,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @param modified the entry modified date, <b>null</b> if none.
|
||||
*/
|
||||
public void setModified(final Date modified) {
|
||||
this._updated = modified == null ? null : new Date(modified.getTime());
|
||||
updated = modified == null ? null : new Date(modified.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -301,7 +301,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @return the entry modified date, <b>null</b> if none.
|
||||
*/
|
||||
public Date getModified() {
|
||||
return this._updated == null ? null : new Date(this._updated.getTime());
|
||||
return updated == null ? null : new Date(updated.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -313,7 +313,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public Module getModule(final String uri) {
|
||||
return ModuleUtils.getModule(this._modules, uri);
|
||||
return ModuleUtils.getModule(modules, uri);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -326,7 +326,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public void setModules(final List<Module> modules) {
|
||||
this._modules = modules;
|
||||
this.modules = modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -339,7 +339,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public List<Module> getModules() {
|
||||
return this._modules == null ? (this._modules = new ArrayList<Module>()) : this._modules;
|
||||
return modules == null ? (modules = new ArrayList<Module>()) : modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -350,7 +350,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* links to set, an empty list or <b>null</b> if none.
|
||||
*/
|
||||
public void setOtherLinks(final List<Link> otherLinks) {
|
||||
this._otherLinks = otherLinks;
|
||||
this.otherLinks = otherLinks;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -361,7 +361,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* set, an empty list if none.
|
||||
*/
|
||||
public List<Link> getOtherLinks() {
|
||||
return this._otherLinks == null ? (this._otherLinks = new ArrayList<Link>()) : this._otherLinks;
|
||||
return otherLinks == null ? (otherLinks = new ArrayList<Link>()) : otherLinks;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -372,7 +372,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setPublished(final Date published) {
|
||||
this._published = published == null ? null : new Date(published.getTime());
|
||||
this.published = published == null ? null : new Date(published.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -383,7 +383,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public Date getPublished() {
|
||||
return this._published == null ? null : new Date(this._published.getTime());
|
||||
return published == null ? null : new Date(published.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -394,7 +394,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setRights(final String rights) {
|
||||
this._rights = rights;
|
||||
this.rights = rights;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -405,7 +405,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getRights() {
|
||||
return this._rights;
|
||||
return rights;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -415,7 +415,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @param source The source to set.
|
||||
*/
|
||||
public void setSource(final Feed source) {
|
||||
this._source = source;
|
||||
this.source = source;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -425,7 +425,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @return Returns the source.
|
||||
*/
|
||||
public Feed getSource() {
|
||||
return this._source;
|
||||
return source;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -436,7 +436,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setSummary(final Content summary) {
|
||||
this._summary = summary;
|
||||
this.summary = summary;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -447,7 +447,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Content getSummary() {
|
||||
return this._summary;
|
||||
return summary;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -458,11 +458,11 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setTitle(final String title) {
|
||||
if (this._title == null) {
|
||||
this._title = new Content();
|
||||
if (this.title == null) {
|
||||
this.title = new Content();
|
||||
}
|
||||
|
||||
this._title.setValue(title);
|
||||
this.title.setValue(title);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -473,8 +473,8 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public String getTitle() {
|
||||
if (this._title != null) {
|
||||
return this._title.getValue();
|
||||
if (title != null) {
|
||||
return title.getValue();
|
||||
}
|
||||
|
||||
return null;
|
||||
|
@ -488,7 +488,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setTitleEx(final Content title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -499,7 +499,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Content getTitleEx() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -510,7 +510,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setUpdated(final Date updated) {
|
||||
this._updated = updated == null ? null : new Date(updated.getTime());
|
||||
this.updated = updated == null ? null : new Date(updated.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -521,7 +521,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public Date getUpdated() {
|
||||
return this._updated == null ? null : new Date(this._updated.getTime());
|
||||
return updated == null ? null : new Date(updated.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -532,7 +532,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setXmlBase(final String xmlBase) {
|
||||
this._xmlBase = xmlBase;
|
||||
this.xmlBase = xmlBase;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -543,7 +543,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getXmlBase() {
|
||||
return this._xmlBase;
|
||||
return xmlBase;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -557,7 +557,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -581,7 +581,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
final List<Element> fm = getForeignMarkup();
|
||||
setForeignMarkup(((Entry) other).getForeignMarkup());
|
||||
|
||||
final boolean ret = this._objBean.equals(other);
|
||||
final boolean ret = objBean.equals(other);
|
||||
// restore foreign markup
|
||||
setForeignMarkup(fm);
|
||||
|
||||
|
@ -599,7 +599,7 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -611,11 +611,11 @@ public class Entry implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
public Link findRelatedLink(final String relation) {
|
||||
for (final Link l : this._otherLinks) {
|
||||
for (final Link l : otherLinks) {
|
||||
if (relation.equals(l.getRel())) {
|
||||
return l;
|
||||
}
|
||||
|
|
|
@ -35,26 +35,26 @@ import com.sun.syndication.feed.module.impl.ModuleUtils;
|
|||
*/
|
||||
public class Feed extends WireFeed {
|
||||
|
||||
private String _xmlBase;
|
||||
private List<Category> _categories;
|
||||
private List<Person> _authors;
|
||||
private List<Person> _contributors;
|
||||
private Generator _generator;
|
||||
private String _icon;
|
||||
private String _id;
|
||||
private String _logo;
|
||||
private String _rights; // AKA copyright
|
||||
private Content _subtitle; // AKA tagline
|
||||
private Content _title;
|
||||
private Date _updated; // AKA modified
|
||||
private List<Link> _alternateLinks;
|
||||
private List<Link> _otherLinks;
|
||||
private List<Entry> _entries;
|
||||
private String xmlBase;
|
||||
private List<Category> categories;
|
||||
private List<Person> authors;
|
||||
private List<Person> contributors;
|
||||
private Generator generator;
|
||||
private String icon;
|
||||
private String id;
|
||||
private String logo;
|
||||
private String rights; // AKA copyright
|
||||
private Content subtitle; // AKA tagline
|
||||
private Content title;
|
||||
private Date updated; // AKA modified
|
||||
private List<Link> alternateLinks;
|
||||
private List<Link> otherLinks;
|
||||
private List<Entry> entries;
|
||||
|
||||
private List<Module> _modules;
|
||||
private List<Module> modules;
|
||||
|
||||
private Content _info; // Atom 0.3 only
|
||||
private String _language; // Atom 0.3 only
|
||||
private Content info; // Atom 0.3 only
|
||||
private String language; // Atom 0.3 only
|
||||
|
||||
/**
|
||||
* Default constructor, for bean cloning purposes only.
|
||||
|
@ -83,7 +83,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getLanguage() {
|
||||
return this._language;
|
||||
return language;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -94,7 +94,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setLanguage(final String language) {
|
||||
this._language = language;
|
||||
this.language = language;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -105,8 +105,8 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getTitle() {
|
||||
if (this._title != null) {
|
||||
return this._title.getValue();
|
||||
if (title != null) {
|
||||
return title.getValue();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
@ -119,10 +119,10 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setTitle(final String title) {
|
||||
if (this._title == null) {
|
||||
this._title = new Content();
|
||||
if (this.title == null) {
|
||||
this.title = new Content();
|
||||
}
|
||||
this._title.setValue(title);
|
||||
this.title.setValue(title);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -133,7 +133,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public Content getTitleEx() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -144,7 +144,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setTitleEx(final Content title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -155,7 +155,7 @@ public class Feed extends WireFeed {
|
|||
* list if none.
|
||||
*/
|
||||
public List<Link> getAlternateLinks() {
|
||||
return this._alternateLinks == null ? (this._alternateLinks = new ArrayList<Link>()) : this._alternateLinks;
|
||||
return alternateLinks == null ? (alternateLinks = new ArrayList<Link>()) : alternateLinks;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -166,7 +166,7 @@ public class Feed extends WireFeed {
|
|||
* links to set, an empty list or <b>null</b> if none.
|
||||
*/
|
||||
public void setAlternateLinks(final List<Link> alternateLinks) {
|
||||
this._alternateLinks = alternateLinks;
|
||||
this.alternateLinks = alternateLinks;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -177,7 +177,7 @@ public class Feed extends WireFeed {
|
|||
* ones), an empty list if none.
|
||||
*/
|
||||
public List<Link> getOtherLinks() {
|
||||
return this._otherLinks == null ? (this._otherLinks = new ArrayList<Link>()) : this._otherLinks;
|
||||
return otherLinks == null ? (otherLinks = new ArrayList<Link>()) : otherLinks;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -189,7 +189,7 @@ public class Feed extends WireFeed {
|
|||
* none.
|
||||
*/
|
||||
public void setOtherLinks(final List<Link> otherLinks) {
|
||||
this._otherLinks = otherLinks;
|
||||
this.otherLinks = otherLinks;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -200,7 +200,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public List<Person> getAuthors() {
|
||||
return this._authors == null ? (this._authors = new ArrayList<Person>()) : this._authors;
|
||||
return authors == null ? (authors = new ArrayList<Person>()) : authors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -211,7 +211,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setAuthors(final List<Person> authors) {
|
||||
this._authors = authors;
|
||||
this.authors = authors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -223,7 +223,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public List<Person> getContributors() {
|
||||
return this._contributors == null ? (this._contributors = new ArrayList<Person>()) : this._contributors;
|
||||
return contributors == null ? (contributors = new ArrayList<Person>()) : contributors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -235,7 +235,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setContributors(final List<Person> contributors) {
|
||||
this._contributors = contributors;
|
||||
this.contributors = contributors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -245,7 +245,7 @@ public class Feed extends WireFeed {
|
|||
* @return the feed tag line, <b>null</b> if none.
|
||||
*/
|
||||
public Content getTagline() {
|
||||
return this._subtitle;
|
||||
return subtitle;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -256,7 +256,7 @@ public class Feed extends WireFeed {
|
|||
* @param tagline the feed tagline to set, <b>null</b> if none.
|
||||
*/
|
||||
public void setTagline(final Content tagline) {
|
||||
this._subtitle = tagline;
|
||||
subtitle = tagline;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -267,7 +267,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getId() {
|
||||
return this._id;
|
||||
return id;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -278,7 +278,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setId(final String id) {
|
||||
this._id = id;
|
||||
this.id = id;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -289,7 +289,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public Generator getGenerator() {
|
||||
return this._generator;
|
||||
return generator;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -300,7 +300,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setGenerator(final Generator generator) {
|
||||
this._generator = generator;
|
||||
this.generator = generator;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -310,7 +310,7 @@ public class Feed extends WireFeed {
|
|||
* @return the feed copyright, <b>null</b> if none.
|
||||
*/
|
||||
public String getCopyright() {
|
||||
return this._rights;
|
||||
return rights;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -321,7 +321,7 @@ public class Feed extends WireFeed {
|
|||
* @param copyright the feed copyright to set, <b>null</b> if none.
|
||||
*/
|
||||
public void setCopyright(final String copyright) {
|
||||
this._rights = copyright;
|
||||
rights = copyright;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -331,7 +331,7 @@ public class Feed extends WireFeed {
|
|||
* @return the feed info, <b>null</b> if none.
|
||||
*/
|
||||
public Content getInfo() {
|
||||
return this._info;
|
||||
return info;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -341,7 +341,7 @@ public class Feed extends WireFeed {
|
|||
* @param info the feed info to set, <b>null</b> if none.
|
||||
*/
|
||||
public void setInfo(final Content info) {
|
||||
this._info = info;
|
||||
this.info = info;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -351,7 +351,7 @@ public class Feed extends WireFeed {
|
|||
* @return the feed modified date, <b>null</b> if none.
|
||||
*/
|
||||
public Date getModified() {
|
||||
return this._updated;
|
||||
return updated;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -362,7 +362,7 @@ public class Feed extends WireFeed {
|
|||
* @param modified the feed modified date to set, <b>null</b> if none.
|
||||
*/
|
||||
public void setModified(final Date modified) {
|
||||
this._updated = modified;
|
||||
updated = modified;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -374,7 +374,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public List<Entry> getEntries() {
|
||||
return this._entries == null ? (this._entries = new ArrayList<Entry>()) : this._entries;
|
||||
return entries == null ? (entries = new ArrayList<Entry>()) : entries;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -386,7 +386,7 @@ public class Feed extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setEntries(final List<Entry> entries) {
|
||||
this._entries = entries;
|
||||
this.entries = entries;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -399,7 +399,7 @@ public class Feed extends WireFeed {
|
|||
*/
|
||||
@Override
|
||||
public List<Module> getModules() {
|
||||
return this._modules == null ? (this._modules = new ArrayList<Module>()) : this._modules;
|
||||
return modules == null ? (modules = new ArrayList<Module>()) : modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -412,7 +412,7 @@ public class Feed extends WireFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setModules(final List<Module> modules) {
|
||||
this._modules = modules;
|
||||
this.modules = modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -424,7 +424,7 @@ public class Feed extends WireFeed {
|
|||
*/
|
||||
@Override
|
||||
public Module getModule(final String uri) {
|
||||
return ModuleUtils.getModule(this._modules, uri);
|
||||
return ModuleUtils.getModule(modules, uri);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -435,7 +435,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public List<Category> getCategories() {
|
||||
return this._categories == null ? (this._categories = new ArrayList<Category>()) : this._categories;
|
||||
return categories == null ? (categories = new ArrayList<Category>()) : categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -446,7 +446,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setCategories(final List<Category> categories) {
|
||||
this._categories = categories;
|
||||
this.categories = categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -457,7 +457,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getIcon() {
|
||||
return this._icon;
|
||||
return icon;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -468,7 +468,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setIcon(final String icon) {
|
||||
this._icon = icon;
|
||||
this.icon = icon;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -479,7 +479,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getLogo() {
|
||||
return this._logo;
|
||||
return logo;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -490,7 +490,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setLogo(final String logo) {
|
||||
this._logo = logo;
|
||||
this.logo = logo;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -501,7 +501,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getRights() {
|
||||
return this._rights;
|
||||
return rights;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -512,7 +512,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setRights(final String rights) {
|
||||
this._rights = rights;
|
||||
this.rights = rights;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -523,7 +523,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public Content getSubtitle() {
|
||||
return this._subtitle;
|
||||
return subtitle;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -534,7 +534,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setSubtitle(final Content subtitle) {
|
||||
this._subtitle = subtitle;
|
||||
this.subtitle = subtitle;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -545,7 +545,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public Date getUpdated() {
|
||||
return this._updated;
|
||||
return updated;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -556,7 +556,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setUpdated(final Date updated) {
|
||||
this._updated = updated;
|
||||
this.updated = updated;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -567,7 +567,7 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getXmlBase() {
|
||||
return this._xmlBase;
|
||||
return xmlBase;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -578,6 +578,6 @@ public class Feed extends WireFeed {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setXmlBase(final String xmlBase) {
|
||||
this._xmlBase = xmlBase;
|
||||
this.xmlBase = xmlBase;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -28,10 +28,10 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class Generator implements Cloneable, Serializable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _url;
|
||||
private String _version;
|
||||
private String _value;
|
||||
private final ObjectBean objBean;
|
||||
private String url;
|
||||
private String version;
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -39,7 +39,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Generator() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -53,7 +53,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -70,7 +70,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
if (!(other instanceof Generator)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -84,7 +84,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -96,7 +96,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -107,7 +107,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getUrl() {
|
||||
return this._url;
|
||||
return url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -118,7 +118,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setUrl(final String url) {
|
||||
this._url = url;
|
||||
this.url = url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -129,7 +129,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getVersion() {
|
||||
return this._version;
|
||||
return version;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -140,7 +140,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setVersion(final String version) {
|
||||
this._version = version;
|
||||
this.version = version;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -151,7 +151,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getValue() {
|
||||
return this._value;
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -162,7 +162,7 @@ public class Generator implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setValue(final String value) {
|
||||
this._value = value;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -29,15 +29,15 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*/
|
||||
public class Link implements Cloneable, Serializable {
|
||||
|
||||
private final ObjectBean _objBean;
|
||||
private final ObjectBean objBean;
|
||||
|
||||
private String _href;
|
||||
private String _hrefResolved;
|
||||
private String _rel = "alternate";
|
||||
private String _type;
|
||||
private String _hreflang;
|
||||
private String _title;
|
||||
private long _length;
|
||||
private String href;
|
||||
private String hrefResolved;
|
||||
private String rel = "alternate";
|
||||
private String type;
|
||||
private String hreflang;
|
||||
private String title;
|
||||
private long length;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -45,7 +45,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Link() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -59,7 +59,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -73,7 +73,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public boolean equals(final Object other) {
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -87,7 +87,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -99,7 +99,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -110,7 +110,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getRel() {
|
||||
return this._rel;
|
||||
return rel;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -122,7 +122,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*/
|
||||
public void setRel(final String rel) {
|
||||
// TODO add check, ask P@ about the check
|
||||
this._rel = rel;
|
||||
this.rel = rel;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -133,7 +133,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -144,7 +144,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setType(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -155,7 +155,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getHref() {
|
||||
return this._href;
|
||||
return href;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -166,15 +166,15 @@ public class Link implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setHref(final String href) {
|
||||
this._href = href;
|
||||
this.href = href;
|
||||
}
|
||||
|
||||
public void setHrefResolved(final String hrefResolved) {
|
||||
this._hrefResolved = hrefResolved;
|
||||
this.hrefResolved = hrefResolved;
|
||||
}
|
||||
|
||||
public String getHrefResolved() {
|
||||
return this._hrefResolved != null ? this._hrefResolved : this._href;
|
||||
return hrefResolved != null ? hrefResolved : href;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -185,7 +185,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getTitle() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -196,7 +196,7 @@ public class Link implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setTitle(final String title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -207,7 +207,7 @@ public class Link implements Cloneable, Serializable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getHreflang() {
|
||||
return this._hreflang;
|
||||
return hreflang;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -218,7 +218,7 @@ public class Link implements Cloneable, Serializable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setHreflang(final String hreflang) {
|
||||
this._hreflang = hreflang;
|
||||
this.hreflang = hreflang;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -228,7 +228,7 @@ public class Link implements Cloneable, Serializable {
|
|||
* @return Returns the length.
|
||||
*/
|
||||
public long getLength() {
|
||||
return this._length;
|
||||
return length;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -238,6 +238,6 @@ public class Link implements Cloneable, Serializable {
|
|||
* @param length The length to set.
|
||||
*/
|
||||
public void setLength(final long length) {
|
||||
this._length = length;
|
||||
this.length = length;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -34,13 +34,13 @@ import com.sun.syndication.feed.module.impl.ModuleUtils;
|
|||
*/
|
||||
public class Person implements Cloneable, Serializable, Extendable {
|
||||
|
||||
private final ObjectBean _objBean;
|
||||
private final ObjectBean objBean;
|
||||
|
||||
private String _name;
|
||||
private String _uri; // since Atom 1.0 (was called url)
|
||||
private String _uriResolved;
|
||||
private String _email;
|
||||
private List<Module> _modules;
|
||||
private String name;
|
||||
private String uri; // since Atom 1.0 (was called url)
|
||||
private String uriResolved;
|
||||
private String email;
|
||||
private List<Module> modules;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -48,7 +48,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Person() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -62,7 +62,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -76,7 +76,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public boolean equals(final Object other) {
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -90,7 +90,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -102,7 +102,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -113,7 +113,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public String getName() {
|
||||
return this._name;
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -124,7 +124,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setName(final String name) {
|
||||
this._name = name;
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -134,7 +134,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
* @return the person URL, <b>null</b> if none.
|
||||
*/
|
||||
public String getUrl() {
|
||||
return this._uri;
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -144,15 +144,15 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
* @param url the person URL, <b>null</b> if none.
|
||||
*/
|
||||
public void setUrl(final String url) {
|
||||
this._uri = url;
|
||||
uri = url;
|
||||
}
|
||||
|
||||
public void setUriResolved(final String uriResolved) {
|
||||
this._uriResolved = uriResolved;
|
||||
this.uriResolved = uriResolved;
|
||||
}
|
||||
|
||||
public String getUriResolved(final String resolveURI) {
|
||||
return this._uriResolved != null ? this._uriResolved : this._uri;
|
||||
return uriResolved != null ? uriResolved : uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -163,7 +163,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public String getEmail() {
|
||||
return this._email;
|
||||
return email;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -174,7 +174,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setEmail(final String email) {
|
||||
this._email = email;
|
||||
this.email = email;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -185,7 +185,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public String getUri() {
|
||||
return this._uri;
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -196,7 +196,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
* @since Atom 1.0
|
||||
*/
|
||||
public void setUri(final String uri) {
|
||||
this._uri = uri;
|
||||
this.uri = uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -209,7 +209,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public List<Module> getModules() {
|
||||
return this._modules == null ? (this._modules = new ArrayList<Module>()) : this._modules;
|
||||
return modules == null ? (modules = new ArrayList<Module>()) : modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -222,7 +222,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public void setModules(final List<Module> modules) {
|
||||
this._modules = modules;
|
||||
this.modules = modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -234,7 +234,7 @@ public class Person implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public Module getModule(final String uri) {
|
||||
return ModuleUtils.getModule(this._modules, uri);
|
||||
return ModuleUtils.getModule(modules, uri);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -41,13 +41,13 @@ import java.util.Set;
|
|||
*/
|
||||
public class BeanIntrospector {
|
||||
|
||||
private static final Map _introspected = new HashMap();
|
||||
private static final Map introspected = new HashMap();
|
||||
|
||||
public static synchronized PropertyDescriptor[] getPropertyDescriptors(final Class klass) throws IntrospectionException {
|
||||
PropertyDescriptor[] descriptors = (PropertyDescriptor[]) _introspected.get(klass);
|
||||
PropertyDescriptor[] descriptors = (PropertyDescriptor[]) introspected.get(klass);
|
||||
if (descriptors == null) {
|
||||
descriptors = getPDs(klass);
|
||||
_introspected.put(klass, descriptors);
|
||||
introspected.put(klass, descriptors);
|
||||
}
|
||||
return descriptors;
|
||||
}
|
||||
|
|
|
@ -45,8 +45,8 @@ public class CloneableBean implements Serializable, Cloneable {
|
|||
private static final Class[] NO_PARAMS_DEF = new Class[0];
|
||||
private static final Object[] NO_PARAMS = new Object[0];
|
||||
|
||||
private final Object _obj;
|
||||
private Set _ignoreProperties;
|
||||
private final Object obj;
|
||||
private Set ignoreProperties;
|
||||
|
||||
/**
|
||||
* Default constructor.
|
||||
|
@ -56,7 +56,7 @@ public class CloneableBean implements Serializable, Cloneable {
|
|||
*
|
||||
*/
|
||||
protected CloneableBean() {
|
||||
this._obj = this;
|
||||
obj = this;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -66,14 +66,14 @@ public class CloneableBean implements Serializable, Cloneable {
|
|||
* <p>
|
||||
* <code>
|
||||
* public class Foo implements Cloneable {
|
||||
* private CloneableBean _cloneableBean;
|
||||
* private CloneableBean cloneableBean;
|
||||
*
|
||||
* public Foo() {
|
||||
* _cloneableBean = new CloneableBean(this);
|
||||
* cloneableBean = new CloneableBean(this);
|
||||
* }
|
||||
*
|
||||
* public Object clone() throws CloneNotSupportedException {
|
||||
* return _cloneableBean.beanClone();
|
||||
* return cloneableBean.beanClone();
|
||||
* }
|
||||
*
|
||||
* }
|
||||
|
@ -104,8 +104,8 @@ public class CloneableBean implements Serializable, Cloneable {
|
|||
*
|
||||
*/
|
||||
public CloneableBean(final Object obj, final Set ignoreProperties) {
|
||||
this._obj = obj;
|
||||
this._ignoreProperties = ignoreProperties != null ? ignoreProperties : Collections.EMPTY_SET;
|
||||
this.obj = obj;
|
||||
this.ignoreProperties = ignoreProperties != null ? ignoreProperties : Collections.EMPTY_SET;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -142,8 +142,8 @@ public class CloneableBean implements Serializable, Cloneable {
|
|||
public Object beanClone() throws CloneNotSupportedException {
|
||||
Object clonedBean;
|
||||
try {
|
||||
clonedBean = this._obj.getClass().newInstance();
|
||||
final PropertyDescriptor[] pds = BeanIntrospector.getPropertyDescriptors(this._obj.getClass());
|
||||
clonedBean = obj.getClass().newInstance();
|
||||
final PropertyDescriptor[] pds = BeanIntrospector.getPropertyDescriptors(obj.getClass());
|
||||
if (pds != null) {
|
||||
for (int i = 0; i < pds.length; i++) {
|
||||
final Method pReadMethod = pds[i].getReadMethod();
|
||||
|
@ -154,7 +154,7 @@ public class CloneableBean implements Serializable, Cloneable {
|
|||
// and
|
||||
// setter
|
||||
// methods
|
||||
!this._ignoreProperties.contains(pds[i].getName()) && // is
|
||||
!ignoreProperties.contains(pds[i].getName()) && // is
|
||||
// not
|
||||
// in
|
||||
// the
|
||||
|
@ -173,7 +173,7 @@ public class CloneableBean implements Serializable, Cloneable {
|
|||
// that
|
||||
// take
|
||||
// parameters
|
||||
Object value = pReadMethod.invoke(this._obj, NO_PARAMS);
|
||||
Object value = pReadMethod.invoke(obj, NO_PARAMS);
|
||||
if (value != null) {
|
||||
value = doClone(value);
|
||||
pWriteMethod.invoke(clonedBean, new Object[] { value });
|
||||
|
@ -186,7 +186,7 @@ public class CloneableBean implements Serializable, Cloneable {
|
|||
} catch (final Exception ex) {
|
||||
System.out.println(ex);
|
||||
ex.printStackTrace(System.out);
|
||||
throw new CloneNotSupportedException("Cannot clone a " + this._obj.getClass() + " object");
|
||||
throw new CloneNotSupportedException("Cannot clone a " + obj.getClass() + " object");
|
||||
}
|
||||
return clonedBean;
|
||||
}
|
||||
|
|
|
@ -36,19 +36,19 @@ import com.sun.syndication.feed.CopyFrom;
|
|||
public class CopyFromHelper {
|
||||
private static final Object[] NO_PARAMS = new Object[0];
|
||||
|
||||
private final Class _beanInterfaceClass;
|
||||
private final Map _baseInterfaceMap; // ENTRIES(propertyName,interface.class)
|
||||
private final Map _baseImplMap; // ENTRIES(interface.class,implementation.class)
|
||||
private final Class beanInterfaceClass;
|
||||
private final Map baseInterfaceMap; // ENTRIES(propertyName,interface.class)
|
||||
private final Map baseImplMap; // ENTRIES(interface.class,implementation.class)
|
||||
|
||||
public CopyFromHelper(final Class beanInterfaceClass, final Map basePropInterfaceMap, final Map basePropClassImplMap) {
|
||||
this._beanInterfaceClass = beanInterfaceClass;
|
||||
this._baseInterfaceMap = basePropInterfaceMap;
|
||||
this._baseImplMap = basePropClassImplMap;
|
||||
this.beanInterfaceClass = beanInterfaceClass;
|
||||
baseInterfaceMap = basePropInterfaceMap;
|
||||
baseImplMap = basePropClassImplMap;
|
||||
}
|
||||
|
||||
public void copy(final Object target, final Object source) {
|
||||
try {
|
||||
final PropertyDescriptor[] pds = BeanIntrospector.getPropertyDescriptors(this._beanInterfaceClass);
|
||||
final PropertyDescriptor[] pds = BeanIntrospector.getPropertyDescriptors(beanInterfaceClass);
|
||||
if (pds != null) {
|
||||
for (final PropertyDescriptor pd : pds) {
|
||||
final String propertyName = pd.getName();
|
||||
|
@ -70,7 +70,7 @@ public class CopyFromHelper {
|
|||
// that
|
||||
// take
|
||||
// parameters
|
||||
this._baseInterfaceMap.containsKey(propertyName)) { // only
|
||||
baseInterfaceMap.containsKey(propertyName)) { // only
|
||||
// copies
|
||||
// properties
|
||||
// defined
|
||||
|
@ -78,7 +78,7 @@ public class CopyFromHelper {
|
|||
// copyFrom-able
|
||||
Object value = pReadMethod.invoke(source, NO_PARAMS);
|
||||
if (value != null) {
|
||||
final Class baseInterface = (Class) this._baseInterfaceMap.get(propertyName);
|
||||
final Class baseInterface = (Class) baseInterfaceMap.get(propertyName);
|
||||
value = doCopy(value, baseInterface);
|
||||
pWriteMethod.invoke(target, new Object[] { value });
|
||||
}
|
||||
|
@ -91,10 +91,10 @@ public class CopyFromHelper {
|
|||
}
|
||||
|
||||
private CopyFrom createInstance(final Class interfaceClass) throws Exception {
|
||||
if (this._baseImplMap.get(interfaceClass) == null) {
|
||||
if (baseImplMap.get(interfaceClass) == null) {
|
||||
return null;
|
||||
} else {
|
||||
return (CopyFrom) ((Class) this._baseImplMap.get(interfaceClass)).newInstance();
|
||||
return (CopyFrom) ((Class) baseImplMap.get(interfaceClass)).newInstance();
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -40,8 +40,8 @@ public class EqualsBean implements Serializable {
|
|||
|
||||
private static final Object[] NO_PARAMS = new Object[0];
|
||||
|
||||
private final Class _beanClass;
|
||||
private final Object _obj;
|
||||
private final Class beanClass;
|
||||
private final Object obj;
|
||||
|
||||
/**
|
||||
* Default constructor.
|
||||
|
@ -53,8 +53,8 @@ public class EqualsBean implements Serializable {
|
|||
*
|
||||
*/
|
||||
protected EqualsBean(final Class beanClass) {
|
||||
this._beanClass = beanClass;
|
||||
this._obj = this;
|
||||
this.beanClass = beanClass;
|
||||
obj = this;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -64,18 +64,18 @@ public class EqualsBean implements Serializable {
|
|||
* <p>
|
||||
* <code>
|
||||
* public class Foo implements FooI {
|
||||
* private EqualsBean _equalsBean;
|
||||
* private EqualsBean equalsBean;
|
||||
*
|
||||
* public Foo() {
|
||||
* _equalsBean = new EqualsBean(FooI.class);
|
||||
* equalsBean = new EqualsBean(FooI.class);
|
||||
* }
|
||||
*
|
||||
* public boolean equals(Object obj) {
|
||||
* return _equalsBean.beanEquals(obj);
|
||||
* return equalsBean.beanEquals(obj);
|
||||
* }
|
||||
*
|
||||
* public int hashCode() {
|
||||
* return _equalsBean.beanHashCode();
|
||||
* return equalsBean.beanHashCode();
|
||||
* }
|
||||
*
|
||||
* }
|
||||
|
@ -90,8 +90,8 @@ public class EqualsBean implements Serializable {
|
|||
if (!beanClass.isInstance(obj)) {
|
||||
throw new IllegalArgumentException(obj.getClass() + " is not instance of " + beanClass);
|
||||
}
|
||||
this._beanClass = beanClass;
|
||||
this._obj = obj;
|
||||
this.beanClass = beanClass;
|
||||
this.obj = obj;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -127,7 +127,7 @@ public class EqualsBean implements Serializable {
|
|||
*
|
||||
*/
|
||||
public boolean beanEquals(final Object obj) {
|
||||
final Object bean1 = this._obj;
|
||||
final Object bean1 = this.obj;
|
||||
final Object bean2 = obj;
|
||||
boolean eq;
|
||||
if (bean1 == null && bean2 == null) {
|
||||
|
@ -135,12 +135,12 @@ public class EqualsBean implements Serializable {
|
|||
} else if (bean1 == null || bean2 == null) {
|
||||
eq = false;
|
||||
} else {
|
||||
if (!this._beanClass.isInstance(bean2)) {
|
||||
if (!beanClass.isInstance(bean2)) {
|
||||
eq = false;
|
||||
} else {
|
||||
eq = true;
|
||||
try {
|
||||
final PropertyDescriptor[] pds = BeanIntrospector.getPropertyDescriptors(this._beanClass);
|
||||
final PropertyDescriptor[] pds = BeanIntrospector.getPropertyDescriptors(beanClass);
|
||||
if (pds != null) {
|
||||
for (int i = 0; eq && i < pds.length; i++) {
|
||||
final Method pReadMethod = pds[i].getReadMethod();
|
||||
|
@ -208,7 +208,7 @@ public class EqualsBean implements Serializable {
|
|||
*
|
||||
*/
|
||||
public int beanHashCode() {
|
||||
return this._obj.toString().hashCode();
|
||||
return obj.toString().hashCode();
|
||||
}
|
||||
|
||||
private boolean doEquals(final Object obj1, final Object obj2) {
|
||||
|
|
|
@ -43,9 +43,9 @@ import java.util.Set;
|
|||
*
|
||||
*/
|
||||
public class ObjectBean implements Serializable, Cloneable {
|
||||
private final EqualsBean _equalsBean;
|
||||
private final ToStringBean _toStringBean;
|
||||
private final CloneableBean _cloneableBean;
|
||||
private final EqualsBean equalsBean;
|
||||
private final ToStringBean toStringBean;
|
||||
private final CloneableBean cloneableBean;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
|
@ -75,9 +75,9 @@ public class ObjectBean implements Serializable, Cloneable {
|
|||
*
|
||||
*/
|
||||
public ObjectBean(final Class beanClass, final Object obj, final Set ignoreProperties) {
|
||||
this._equalsBean = new EqualsBean(beanClass, obj);
|
||||
this._toStringBean = new ToStringBean(beanClass, obj);
|
||||
this._cloneableBean = new CloneableBean(obj, ignoreProperties);
|
||||
equalsBean = new EqualsBean(beanClass, obj);
|
||||
toStringBean = new ToStringBean(beanClass, obj);
|
||||
cloneableBean = new CloneableBean(obj, ignoreProperties);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -91,7 +91,7 @@ public class ObjectBean implements Serializable, Cloneable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._cloneableBean.beanClone();
|
||||
return cloneableBean.beanClone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -105,7 +105,7 @@ public class ObjectBean implements Serializable, Cloneable {
|
|||
*/
|
||||
@Override
|
||||
public boolean equals(final Object other) {
|
||||
return this._equalsBean.beanEquals(other);
|
||||
return equalsBean.beanEquals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -119,7 +119,7 @@ public class ObjectBean implements Serializable, Cloneable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._equalsBean.beanHashCode();
|
||||
return equalsBean.beanHashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -131,7 +131,7 @@ public class ObjectBean implements Serializable, Cloneable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._toStringBean.toString();
|
||||
return toStringBean.toString();
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -51,8 +51,8 @@ public class ToStringBean implements Serializable {
|
|||
|
||||
private static final Object[] NO_PARAMS = new Object[0];
|
||||
|
||||
private final Class _beanClass;
|
||||
private final Object _obj;
|
||||
private final Class beanClass;
|
||||
private final Object obj;
|
||||
|
||||
/**
|
||||
* Default constructor.
|
||||
|
@ -65,8 +65,8 @@ public class ToStringBean implements Serializable {
|
|||
*
|
||||
*/
|
||||
protected ToStringBean(final Class beanClass) {
|
||||
this._beanClass = beanClass;
|
||||
this._obj = this;
|
||||
this.beanClass = beanClass;
|
||||
obj = this;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -96,8 +96,8 @@ public class ToStringBean implements Serializable {
|
|||
*
|
||||
*/
|
||||
public ToStringBean(final Class beanClass, final Object obj) {
|
||||
this._beanClass = beanClass;
|
||||
this._obj = obj;
|
||||
this.beanClass = beanClass;
|
||||
this.obj = obj;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -115,7 +115,7 @@ public class ToStringBean implements Serializable {
|
|||
final String[] tsInfo = (String[]) (stack.isEmpty() ? null : stack.peek());
|
||||
String prefix;
|
||||
if (tsInfo == null) {
|
||||
final String className = this._obj.getClass().getName();
|
||||
final String className = obj.getClass().getName();
|
||||
prefix = className.substring(className.lastIndexOf(".") + 1);
|
||||
} else {
|
||||
prefix = tsInfo[0];
|
||||
|
@ -135,7 +135,7 @@ public class ToStringBean implements Serializable {
|
|||
private String toString(final String prefix) {
|
||||
final StringBuffer sb = new StringBuffer(128);
|
||||
try {
|
||||
final PropertyDescriptor[] pds = BeanIntrospector.getPropertyDescriptors(this._beanClass);
|
||||
final PropertyDescriptor[] pds = BeanIntrospector.getPropertyDescriptors(beanClass);
|
||||
if (pds != null) {
|
||||
for (final PropertyDescriptor pd : pds) {
|
||||
final String pName = pd.getName();
|
||||
|
@ -151,13 +151,13 @@ public class ToStringBean implements Serializable {
|
|||
// that
|
||||
// take
|
||||
// parameters
|
||||
final Object value = pReadMethod.invoke(this._obj, NO_PARAMS);
|
||||
final Object value = pReadMethod.invoke(obj, NO_PARAMS);
|
||||
printProperty(sb, prefix + "." + pName, value);
|
||||
}
|
||||
}
|
||||
}
|
||||
} catch (final Exception ex) {
|
||||
sb.append("\n\nEXCEPTION: Could not complete " + this._obj.getClass() + ".toString(): " + ex.getMessage() + "\n");
|
||||
sb.append("\n\nEXCEPTION: Could not complete " + obj.getClass() + ".toString(): " + ex.getMessage() + "\n");
|
||||
}
|
||||
return sb.toString();
|
||||
}
|
||||
|
|
|
@ -39,22 +39,22 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class DCModuleImpl extends ModuleImpl implements DCModule {
|
||||
private final ObjectBean _objBean;
|
||||
private List<String> _title;
|
||||
private List<String> _creator;
|
||||
private List<DCSubject> _subject;
|
||||
private List<String> _description;
|
||||
private List<String> _publisher;
|
||||
private List<String> _contributors;
|
||||
private List<Date> _date;
|
||||
private List<String> _type;
|
||||
private List<String> _format;
|
||||
private List<String> _identifier;
|
||||
private List<String> _source;
|
||||
private List<String> _language;
|
||||
private List<String> _relation;
|
||||
private List<String> _coverage;
|
||||
private List<String> _rights;
|
||||
private final ObjectBean objBean;
|
||||
private List<String> title;
|
||||
private List<String> creator;
|
||||
private List<DCSubject> subject;
|
||||
private List<String> description;
|
||||
private List<String> publisher;
|
||||
private List<String> contributors;
|
||||
private List<Date> date;
|
||||
private List<String> type;
|
||||
private List<String> format;
|
||||
private List<String> identifier;
|
||||
private List<String> source;
|
||||
private List<String> language;
|
||||
private List<String> relation;
|
||||
private List<String> coverage;
|
||||
private List<String> rights;
|
||||
|
||||
/**
|
||||
* Properties to be ignored when cloning.
|
||||
|
@ -95,7 +95,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
public DCModuleImpl() {
|
||||
super(DCModule.class, URI);
|
||||
this._objBean = new ObjectBean(DCModule.class, this, CONVENIENCE_PROPERTIES);
|
||||
objBean = new ObjectBean(DCModule.class, this, CONVENIENCE_PROPERTIES);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -108,7 +108,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getTitles() {
|
||||
return this._title == null ? (this._title = new ArrayList<String>()) : this._title;
|
||||
return title == null ? (title = new ArrayList<String>()) : title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -121,7 +121,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setTitles(final List<String> titles) {
|
||||
this._title = titles;
|
||||
title = titles;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -133,7 +133,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getTitle() {
|
||||
return this._title != null && this._title.size() > 0 ? (String) this._title.get(0) : null;
|
||||
return title != null && title.size() > 0 ? (String) title.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -146,8 +146,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setTitle(final String title) {
|
||||
this._title = new ArrayList<String>();
|
||||
this._title.add(title);
|
||||
this.title = new ArrayList<String>();
|
||||
this.title.add(title);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -160,7 +160,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getCreators() {
|
||||
return this._creator == null ? (this._creator = new ArrayList<String>()) : this._creator;
|
||||
return creator == null ? (creator = new ArrayList<String>()) : creator;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -173,7 +173,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setCreators(final List<String> creators) {
|
||||
this._creator = creators;
|
||||
creator = creators;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -185,7 +185,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getCreator() {
|
||||
return this._creator != null && this._creator.size() > 0 ? (String) this._creator.get(0) : null;
|
||||
return creator != null && creator.size() > 0 ? (String) creator.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -198,8 +198,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setCreator(final String creator) {
|
||||
this._creator = new ArrayList<String>();
|
||||
this._creator.add(creator);
|
||||
this.creator = new ArrayList<String>();
|
||||
this.creator.add(creator);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -212,7 +212,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<DCSubject> getSubjects() {
|
||||
return this._subject == null ? (this._subject = new ArrayList<DCSubject>()) : this._subject;
|
||||
return subject == null ? (subject = new ArrayList<DCSubject>()) : subject;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -225,7 +225,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setSubjects(final List<DCSubject> subjects) {
|
||||
this._subject = subjects;
|
||||
subject = subjects;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -237,7 +237,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public DCSubject getSubject() {
|
||||
return this._subject != null && this._subject.size() > 0 ? (DCSubject) this._subject.get(0) : null;
|
||||
return subject != null && subject.size() > 0 ? (DCSubject) subject.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -250,8 +250,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setSubject(final DCSubject subject) {
|
||||
this._subject = new ArrayList<DCSubject>();
|
||||
this._subject.add(subject);
|
||||
this.subject = new ArrayList<DCSubject>();
|
||||
this.subject.add(subject);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -264,7 +264,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getDescriptions() {
|
||||
return this._description == null ? (this._description = new ArrayList<String>()) : this._description;
|
||||
return description == null ? (description = new ArrayList<String>()) : description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -277,7 +277,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setDescriptions(final List<String> descriptions) {
|
||||
this._description = descriptions;
|
||||
description = descriptions;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -289,7 +289,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getDescription() {
|
||||
return this._description != null && this._description.size() > 0 ? (String) this._description.get(0) : null;
|
||||
return description != null && description.size() > 0 ? (String) description.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -303,8 +303,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setDescription(final String description) {
|
||||
this._description = new ArrayList<String>();
|
||||
this._description.add(description);
|
||||
this.description = new ArrayList<String>();
|
||||
this.description.add(description);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -317,7 +317,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getPublishers() {
|
||||
return this._publisher == null ? (this._publisher = new ArrayList<String>()) : this._publisher;
|
||||
return publisher == null ? (publisher = new ArrayList<String>()) : publisher;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -330,7 +330,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setPublishers(final List<String> publishers) {
|
||||
this._publisher = publishers;
|
||||
publisher = publishers;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -342,7 +342,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getPublisher() {
|
||||
return this._publisher != null && this._publisher.size() > 0 ? (String) this._publisher.get(0) : null;
|
||||
return publisher != null && publisher.size() > 0 ? (String) publisher.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -356,8 +356,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setPublisher(final String publisher) {
|
||||
this._publisher = new ArrayList<String>();
|
||||
this._publisher.add(publisher);
|
||||
this.publisher = new ArrayList<String>();
|
||||
this.publisher.add(publisher);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -370,7 +370,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getContributors() {
|
||||
return this._contributors == null ? (this._contributors = new ArrayList<String>()) : this._contributors;
|
||||
return contributors == null ? (contributors = new ArrayList<String>()) : contributors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -383,7 +383,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setContributors(final List<String> contributors) {
|
||||
this._contributors = contributors;
|
||||
this.contributors = contributors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -395,7 +395,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getContributor() {
|
||||
return this._contributors != null && this._contributors.size() > 0 ? (String) this._contributors.get(0) : null;
|
||||
return contributors != null && contributors.size() > 0 ? (String) contributors.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -409,8 +409,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setContributor(final String contributor) {
|
||||
this._contributors = new ArrayList<String>();
|
||||
this._contributors.add(contributor);
|
||||
contributors = new ArrayList<String>();
|
||||
contributors.add(contributor);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -423,7 +423,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<Date> getDates() {
|
||||
return this._date == null ? (this._date = new ArrayList<Date>()) : this._date;
|
||||
return date == null ? (date = new ArrayList<Date>()) : date;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -436,7 +436,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setDates(final List<Date> dates) {
|
||||
this._date = dates;
|
||||
date = dates;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -448,7 +448,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public Date getDate() {
|
||||
return this._date != null && this._date.size() > 0 ? (Date) this._date.get(0) : null;
|
||||
return date != null && date.size() > 0 ? (Date) date.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -461,8 +461,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setDate(final Date date) {
|
||||
this._date = new ArrayList<Date>();
|
||||
this._date.add(date);
|
||||
this.date = new ArrayList<Date>();
|
||||
this.date.add(date);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -475,7 +475,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getTypes() {
|
||||
return this._type == null ? (this._type = new ArrayList<String>()) : this._type;
|
||||
return type == null ? (type = new ArrayList<String>()) : type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -488,7 +488,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setTypes(final List<String> types) {
|
||||
this._type = types;
|
||||
type = types;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -500,7 +500,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getType() {
|
||||
return this._type != null && this._type.size() > 0 ? (String) this._type.get(0) : null;
|
||||
return type != null && type.size() > 0 ? (String) type.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -513,8 +513,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setType(final String type) {
|
||||
this._type = new ArrayList<String>();
|
||||
this._type.add(type);
|
||||
this.type = new ArrayList<String>();
|
||||
this.type.add(type);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -527,7 +527,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getFormats() {
|
||||
return this._format == null ? (this._format = new ArrayList<String>()) : this._format;
|
||||
return format == null ? (format = new ArrayList<String>()) : format;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -540,7 +540,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setFormats(final List<String> formats) {
|
||||
this._format = formats;
|
||||
format = formats;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -552,7 +552,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getFormat() {
|
||||
return this._format != null && this._format.size() > 0 ? (String) this._format.get(0) : null;
|
||||
return format != null && format.size() > 0 ? (String) format.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -565,8 +565,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setFormat(final String format) {
|
||||
this._format = new ArrayList<String>();
|
||||
this._format.add(format);
|
||||
this.format = new ArrayList<String>();
|
||||
this.format.add(format);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -579,7 +579,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getIdentifiers() {
|
||||
return this._identifier == null ? (this._identifier = new ArrayList<String>()) : this._identifier;
|
||||
return identifier == null ? (identifier = new ArrayList<String>()) : identifier;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -592,7 +592,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setIdentifiers(final List<String> identifiers) {
|
||||
this._identifier = identifiers;
|
||||
identifier = identifiers;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -604,7 +604,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getIdentifier() {
|
||||
return this._identifier != null && this._identifier.size() > 0 ? (String) this._identifier.get(0) : null;
|
||||
return identifier != null && identifier.size() > 0 ? (String) identifier.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -618,8 +618,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setIdentifier(final String identifier) {
|
||||
this._identifier = new ArrayList<String>();
|
||||
this._identifier.add(identifier);
|
||||
this.identifier = new ArrayList<String>();
|
||||
this.identifier.add(identifier);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -632,7 +632,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getSources() {
|
||||
return this._source == null ? (this._source = new ArrayList<String>()) : this._source;
|
||||
return source == null ? (source = new ArrayList<String>()) : source;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -645,7 +645,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setSources(final List<String> sources) {
|
||||
this._source = sources;
|
||||
source = sources;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -657,7 +657,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getSource() {
|
||||
return this._source != null && this._source.size() > 0 ? (String) this._source.get(0) : null;
|
||||
return source != null && source.size() > 0 ? (String) source.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -670,8 +670,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setSource(final String source) {
|
||||
this._source = new ArrayList<String>();
|
||||
this._source.add(source);
|
||||
this.source = new ArrayList<String>();
|
||||
this.source.add(source);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -684,7 +684,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getLanguages() {
|
||||
return this._language == null ? (this._language = new ArrayList<String>()) : this._language;
|
||||
return language == null ? (language = new ArrayList<String>()) : language;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -697,7 +697,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setLanguages(final List<String> languages) {
|
||||
this._language = languages;
|
||||
language = languages;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -709,7 +709,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getLanguage() {
|
||||
return this._language != null && this._language.size() > 0 ? (String) this._language.get(0) : null;
|
||||
return language != null && language.size() > 0 ? (String) language.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -723,8 +723,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setLanguage(final String language) {
|
||||
this._language = new ArrayList<String>();
|
||||
this._language.add(language);
|
||||
this.language = new ArrayList<String>();
|
||||
this.language.add(language);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -737,7 +737,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getRelations() {
|
||||
return this._relation == null ? (this._relation = new ArrayList<String>()) : this._relation;
|
||||
return relation == null ? (relation = new ArrayList<String>()) : relation;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -750,7 +750,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setRelations(final List<String> relations) {
|
||||
this._relation = relations;
|
||||
relation = relations;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -762,7 +762,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getRelation() {
|
||||
return this._relation != null && this._relation.size() > 0 ? (String) this._relation.get(0) : null;
|
||||
return relation != null && relation.size() > 0 ? (String) relation.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -776,8 +776,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setRelation(final String relation) {
|
||||
this._relation = new ArrayList<String>();
|
||||
this._relation.add(relation);
|
||||
this.relation = new ArrayList<String>();
|
||||
this.relation.add(relation);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -790,7 +790,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getCoverages() {
|
||||
return this._coverage == null ? (this._coverage = new ArrayList<String>()) : this._coverage;
|
||||
return coverage == null ? (coverage = new ArrayList<String>()) : coverage;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -803,7 +803,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setCoverages(final List<String> coverages) {
|
||||
this._coverage = coverages;
|
||||
coverage = coverages;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -815,7 +815,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getCoverage() {
|
||||
return this._coverage != null && this._coverage.size() > 0 ? (String) this._coverage.get(0) : null;
|
||||
return coverage != null && coverage.size() > 0 ? (String) coverage.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -829,8 +829,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setCoverage(final String coverage) {
|
||||
this._coverage = new ArrayList<String>();
|
||||
this._coverage.add(coverage);
|
||||
this.coverage = new ArrayList<String>();
|
||||
this.coverage.add(coverage);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -843,7 +843,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public List<String> getRightsList() {
|
||||
return this._rights == null ? (this._rights = new ArrayList<String>()) : this._rights;
|
||||
return rights == null ? (rights = new ArrayList<String>()) : rights;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -856,7 +856,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setRightsList(final List<String> rights) {
|
||||
this._rights = rights;
|
||||
this.rights = rights;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -868,7 +868,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public String getRights() {
|
||||
return this._rights != null && this._rights.size() > 0 ? (String) this._rights.get(0) : null;
|
||||
return rights != null && rights.size() > 0 ? (String) rights.get(0) : null;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -881,8 +881,8 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public void setRights(final String rights) {
|
||||
this._rights = new ArrayList<String>();
|
||||
this._rights.add(rights);
|
||||
this.rights = new ArrayList<String>();
|
||||
this.rights.add(rights);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -896,7 +896,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public final Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -910,7 +910,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public final boolean equals(final Object other) {
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -924,7 +924,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public final int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -936,7 +936,7 @@ public class DCModuleImpl extends ModuleImpl implements DCModule {
|
|||
*/
|
||||
@Override
|
||||
public final String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -35,9 +35,9 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
||||
private final ObjectBean _objBean;
|
||||
private String _taxonomyUri;
|
||||
private String _value;
|
||||
private final ObjectBean objBean;
|
||||
private String taxonomyUri;
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -45,7 +45,7 @@ public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
|||
*
|
||||
*/
|
||||
public DCSubjectImpl() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -59,7 +59,7 @@ public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -76,7 +76,7 @@ public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
|||
if (!(other instanceof DCSubjectImpl)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -90,7 +90,7 @@ public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -102,7 +102,7 @@ public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -114,7 +114,7 @@ public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
|||
*/
|
||||
@Override
|
||||
public String getTaxonomyUri() {
|
||||
return this._taxonomyUri;
|
||||
return taxonomyUri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -127,7 +127,7 @@ public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
|||
*/
|
||||
@Override
|
||||
public void setTaxonomyUri(final String taxonomyUri) {
|
||||
this._taxonomyUri = taxonomyUri;
|
||||
this.taxonomyUri = taxonomyUri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -139,7 +139,7 @@ public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
|||
*/
|
||||
@Override
|
||||
public String getValue() {
|
||||
return this._value;
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -151,7 +151,7 @@ public class DCSubjectImpl implements Cloneable, Serializable, DCSubject {
|
|||
*/
|
||||
@Override
|
||||
public void setValue(final String value) {
|
||||
this._value = value;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -29,8 +29,8 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public abstract class ModuleImpl implements Cloneable, Serializable, Module {
|
||||
private final ObjectBean _objBean;
|
||||
private final String _uri;
|
||||
private final ObjectBean objBean;
|
||||
private final String uri;
|
||||
|
||||
/**
|
||||
* Constructor.
|
||||
|
@ -40,8 +40,8 @@ public abstract class ModuleImpl implements Cloneable, Serializable, Module {
|
|||
*
|
||||
*/
|
||||
protected ModuleImpl(final Class beanClass, final String uri) {
|
||||
this._objBean = new ObjectBean(beanClass, this);
|
||||
this._uri = uri;
|
||||
objBean = new ObjectBean(beanClass, this);
|
||||
this.uri = uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -55,7 +55,7 @@ public abstract class ModuleImpl implements Cloneable, Serializable, Module {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -72,7 +72,7 @@ public abstract class ModuleImpl implements Cloneable, Serializable, Module {
|
|||
if (!(other instanceof ModuleImpl)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -86,7 +86,7 @@ public abstract class ModuleImpl implements Cloneable, Serializable, Module {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -98,7 +98,7 @@ public abstract class ModuleImpl implements Cloneable, Serializable, Module {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -110,7 +110,7 @@ public abstract class ModuleImpl implements Cloneable, Serializable, Module {
|
|||
*/
|
||||
@Override
|
||||
public String getUri() {
|
||||
return this._uri;
|
||||
return uri;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -47,9 +47,9 @@ public class SyModuleImpl extends ModuleImpl implements SyModule {
|
|||
PERIODS.add(YEARLY);
|
||||
}
|
||||
|
||||
private String _updatePeriod;
|
||||
private int _updateFrequency;
|
||||
private Date _updateBase;
|
||||
private String updatePeriod;
|
||||
private int updateFrequency;
|
||||
private Date updateBase;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -69,7 +69,7 @@ public class SyModuleImpl extends ModuleImpl implements SyModule {
|
|||
*/
|
||||
@Override
|
||||
public String getUpdatePeriod() {
|
||||
return this._updatePeriod;
|
||||
return updatePeriod;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -85,7 +85,7 @@ public class SyModuleImpl extends ModuleImpl implements SyModule {
|
|||
if (!PERIODS.contains(updatePeriod)) {
|
||||
throw new IllegalArgumentException("Invalid period [" + updatePeriod + "]");
|
||||
}
|
||||
this._updatePeriod = updatePeriod;
|
||||
this.updatePeriod = updatePeriod;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -97,7 +97,7 @@ public class SyModuleImpl extends ModuleImpl implements SyModule {
|
|||
*/
|
||||
@Override
|
||||
public int getUpdateFrequency() {
|
||||
return this._updateFrequency;
|
||||
return updateFrequency;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -110,7 +110,7 @@ public class SyModuleImpl extends ModuleImpl implements SyModule {
|
|||
*/
|
||||
@Override
|
||||
public void setUpdateFrequency(final int updateFrequency) {
|
||||
this._updateFrequency = updateFrequency;
|
||||
this.updateFrequency = updateFrequency;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -122,7 +122,7 @@ public class SyModuleImpl extends ModuleImpl implements SyModule {
|
|||
*/
|
||||
@Override
|
||||
public Date getUpdateBase() {
|
||||
return new Date(this._updateBase.getTime());
|
||||
return new Date(updateBase.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -135,7 +135,7 @@ public class SyModuleImpl extends ModuleImpl implements SyModule {
|
|||
*/
|
||||
@Override
|
||||
public void setUpdateBase(final Date updateBase) {
|
||||
this._updateBase = new Date(updateBase.getTime());
|
||||
this.updateBase = new Date(updateBase.getTime());
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -29,9 +29,9 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class Category implements Cloneable, Serializable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _domain;
|
||||
private String _value;
|
||||
private final ObjectBean objBean;
|
||||
private String domain;
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -39,7 +39,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Category() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -53,7 +53,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -70,7 +70,7 @@ public class Category implements Cloneable, Serializable {
|
|||
if (!(other instanceof Category)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -84,7 +84,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -96,7 +96,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -107,7 +107,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getDomain() {
|
||||
return this._domain;
|
||||
return domain;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -118,7 +118,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setDomain(final String domain) {
|
||||
this._domain = domain;
|
||||
this.domain = domain;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -129,7 +129,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getValue() {
|
||||
return this._value;
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -140,7 +140,7 @@ public class Category implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setValue(final String value) {
|
||||
this._value = value;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -61,28 +61,28 @@ public class Channel extends WireFeed {
|
|||
DAYS = Collections.unmodifiableSet(days);
|
||||
}
|
||||
|
||||
private String _title;
|
||||
private String _description;
|
||||
private String _link;
|
||||
private String _uri;
|
||||
private Image _image;
|
||||
private List<Item> _items;
|
||||
private TextInput _textInput;
|
||||
private String _language;
|
||||
private String _rating;
|
||||
private String _copyright;
|
||||
private Date _pubDate;
|
||||
private Date _lastBuildDate;
|
||||
private String _docs;
|
||||
private String _managingEditor;
|
||||
private String _webMaster;
|
||||
private List<Integer> _skipHours;
|
||||
private List<String> _skipDays;
|
||||
private Cloud _cloud;
|
||||
private List<Category> _categories;
|
||||
private String _generator;
|
||||
private int _ttl = -1;
|
||||
private List<Module> _modules;
|
||||
private String title;
|
||||
private String description;
|
||||
private String link;
|
||||
private String uri;
|
||||
private Image image;
|
||||
private List<Item> items;
|
||||
private TextInput textInput;
|
||||
private String language;
|
||||
private String rating;
|
||||
private String copyright;
|
||||
private Date pubDate;
|
||||
private Date lastBuildDate;
|
||||
private String docs;
|
||||
private String managingEditor;
|
||||
private String webMaster;
|
||||
private List<Integer> skipHours;
|
||||
private List<String> skipDays;
|
||||
private Cloud cloud;
|
||||
private List<Category> categories;
|
||||
private String generator;
|
||||
private int ttl = -1;
|
||||
private List<Module> modules;
|
||||
|
||||
/**
|
||||
* Default constructor, for bean cloning purposes only.
|
||||
|
@ -111,7 +111,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getTitle() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -122,7 +122,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setTitle(final String title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -133,7 +133,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getDescription() {
|
||||
return this._description;
|
||||
return description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -144,7 +144,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setDescription(final String description) {
|
||||
this._description = description;
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -155,7 +155,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getLink() {
|
||||
return this._link;
|
||||
return link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -166,7 +166,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setLink(final String link) {
|
||||
this._link = link;
|
||||
this.link = link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -176,7 +176,7 @@ public class Channel extends WireFeed {
|
|||
* @return the channel uri, <b>null</b> if none.
|
||||
*/
|
||||
public String getUri() {
|
||||
return this._uri;
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -186,7 +186,7 @@ public class Channel extends WireFeed {
|
|||
* @param uri the channel uri, <b>null</b> if none.
|
||||
*/
|
||||
public void setUri(final String uri) {
|
||||
this._uri = uri;
|
||||
this.uri = uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -197,7 +197,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public Image getImage() {
|
||||
return this._image;
|
||||
return image;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -208,7 +208,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setImage(final Image image) {
|
||||
this._image = image;
|
||||
this.image = image;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -220,7 +220,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public List<Item> getItems() {
|
||||
return this._items == null ? (this._items = new ArrayList<Item>()) : this._items;
|
||||
return items == null ? (items = new ArrayList<Item>()) : items;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -232,7 +232,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setItems(final List<Item> items) {
|
||||
this._items = items;
|
||||
this.items = items;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -243,7 +243,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public TextInput getTextInput() {
|
||||
return this._textInput;
|
||||
return textInput;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -254,7 +254,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setTextInput(final TextInput textInput) {
|
||||
this._textInput = textInput;
|
||||
this.textInput = textInput;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -265,7 +265,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getLanguage() {
|
||||
return this._language;
|
||||
return language;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -276,7 +276,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setLanguage(final String language) {
|
||||
this._language = language;
|
||||
this.language = language;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -287,7 +287,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getRating() {
|
||||
return this._rating;
|
||||
return rating;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -298,7 +298,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setRating(final String rating) {
|
||||
this._rating = rating;
|
||||
this.rating = rating;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -309,7 +309,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getCopyright() {
|
||||
return this._copyright;
|
||||
return copyright;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -320,7 +320,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setCopyright(final String copyright) {
|
||||
this._copyright = copyright;
|
||||
this.copyright = copyright;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -331,7 +331,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public Date getPubDate() {
|
||||
return this._pubDate == null ? null : new Date(this._pubDate.getTime());
|
||||
return pubDate == null ? null : new Date(pubDate.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -342,7 +342,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setPubDate(final Date pubDate) {
|
||||
this._pubDate = pubDate == null ? null : new Date(pubDate.getTime());
|
||||
this.pubDate = pubDate == null ? null : new Date(pubDate.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -353,7 +353,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public Date getLastBuildDate() {
|
||||
return this._lastBuildDate == null ? null : new Date(this._lastBuildDate.getTime());
|
||||
return lastBuildDate == null ? null : new Date(lastBuildDate.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -365,7 +365,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setLastBuildDate(final Date lastBuildDate) {
|
||||
this._lastBuildDate = lastBuildDate == null ? null : new Date(lastBuildDate.getTime());
|
||||
this.lastBuildDate = lastBuildDate == null ? null : new Date(lastBuildDate.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -376,7 +376,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getDocs() {
|
||||
return this._docs;
|
||||
return docs;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -387,7 +387,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setDocs(final String docs) {
|
||||
this._docs = docs;
|
||||
this.docs = docs;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -398,7 +398,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getManagingEditor() {
|
||||
return this._managingEditor;
|
||||
return managingEditor;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -410,7 +410,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setManagingEditor(final String managingEditor) {
|
||||
this._managingEditor = managingEditor;
|
||||
this.managingEditor = managingEditor;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -421,7 +421,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getWebMaster() {
|
||||
return this._webMaster;
|
||||
return webMaster;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -432,7 +432,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setWebMaster(final String webMaster) {
|
||||
this._webMaster = webMaster;
|
||||
this.webMaster = webMaster;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -444,7 +444,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public List<Integer> getSkipHours() {
|
||||
return this._skipHours != null ? this._skipHours : new ArrayList<Integer>();
|
||||
return skipHours != null ? skipHours : new ArrayList<Integer>();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -469,7 +469,7 @@ public class Channel extends WireFeed {
|
|||
}
|
||||
}
|
||||
}
|
||||
this._skipHours = skipHours;
|
||||
this.skipHours = skipHours;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -481,7 +481,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public List<String> getSkipDays() {
|
||||
return this._skipDays != null ? this._skipDays : new ArrayList<String>();
|
||||
return skipDays != null ? skipDays : new ArrayList<String>();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -507,7 +507,7 @@ public class Channel extends WireFeed {
|
|||
}
|
||||
}
|
||||
}
|
||||
this._skipDays = skipDays;
|
||||
this.skipDays = skipDays;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -518,7 +518,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public Cloud getCloud() {
|
||||
return this._cloud;
|
||||
return cloud;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -529,7 +529,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setCloud(final Cloud cloud) {
|
||||
this._cloud = cloud;
|
||||
this.cloud = cloud;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -541,7 +541,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public List<Category> getCategories() {
|
||||
return this._categories == null ? (this._categories = new ArrayList<Category>()) : this._categories;
|
||||
return categories == null ? (categories = new ArrayList<Category>()) : categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -553,7 +553,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setCategories(final List<Category> categories) {
|
||||
this._categories = categories;
|
||||
this.categories = categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -564,7 +564,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public String getGenerator() {
|
||||
return this._generator;
|
||||
return generator;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -575,7 +575,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setGenerator(final String generator) {
|
||||
this._generator = generator;
|
||||
this.generator = generator;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -586,7 +586,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public int getTtl() {
|
||||
return this._ttl;
|
||||
return ttl;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -597,7 +597,7 @@ public class Channel extends WireFeed {
|
|||
*
|
||||
*/
|
||||
public void setTtl(final int ttl) {
|
||||
this._ttl = ttl;
|
||||
this.ttl = ttl;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -610,7 +610,7 @@ public class Channel extends WireFeed {
|
|||
*/
|
||||
@Override
|
||||
public List<Module> getModules() {
|
||||
return this._modules == null ? (this._modules = new ArrayList<Module>()) : this._modules;
|
||||
return modules == null ? (modules = new ArrayList<Module>()) : modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -623,7 +623,7 @@ public class Channel extends WireFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setModules(final List<Module> modules) {
|
||||
this._modules = modules;
|
||||
this.modules = modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -635,7 +635,7 @@ public class Channel extends WireFeed {
|
|||
*/
|
||||
@Override
|
||||
public Module getModule(final String uri) {
|
||||
return ModuleUtils.getModule(this._modules, uri);
|
||||
return ModuleUtils.getModule(modules, uri);
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -29,12 +29,12 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class Cloud implements Cloneable, Serializable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _domain;
|
||||
private int _port;
|
||||
private String _path;
|
||||
private String _registerProcedure;
|
||||
private String _protocol;
|
||||
private final ObjectBean objBean;
|
||||
private String domain;
|
||||
private int port;
|
||||
private String path;
|
||||
private String registerProcedure;
|
||||
private String protocol;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -42,7 +42,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Cloud() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -56,7 +56,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -70,7 +70,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public boolean equals(final Object other) {
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -84,7 +84,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -96,7 +96,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -107,7 +107,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getDomain() {
|
||||
return this._domain;
|
||||
return domain;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -118,7 +118,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setDomain(final String domain) {
|
||||
this._domain = domain;
|
||||
this.domain = domain;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -129,7 +129,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public int getPort() {
|
||||
return this._port;
|
||||
return port;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -140,7 +140,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setPort(final int port) {
|
||||
this._port = port;
|
||||
this.port = port;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -151,7 +151,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getPath() {
|
||||
return this._path;
|
||||
return path;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -162,7 +162,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setPath(final String path) {
|
||||
this._path = path;
|
||||
this.path = path;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -173,7 +173,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getRegisterProcedure() {
|
||||
return this._registerProcedure;
|
||||
return registerProcedure;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -185,7 +185,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setRegisterProcedure(final String registerProcedure) {
|
||||
this._registerProcedure = registerProcedure;
|
||||
this.registerProcedure = registerProcedure;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -196,7 +196,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getProtocol() {
|
||||
return this._protocol;
|
||||
return protocol;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -207,7 +207,7 @@ public class Cloud implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setProtocol(final String protocol) {
|
||||
this._protocol = protocol;
|
||||
this.protocol = protocol;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -31,9 +31,9 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
public class Content implements Cloneable, Serializable {
|
||||
public static final String HTML = "html";
|
||||
public static final String TEXT = "text";
|
||||
private final ObjectBean _objBean;
|
||||
private String _type;
|
||||
private String _value;
|
||||
private final ObjectBean objBean;
|
||||
private String type;
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -41,7 +41,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Content() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -52,7 +52,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setType(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -63,7 +63,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -74,7 +74,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setValue(final String value) {
|
||||
this._value = value;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -85,7 +85,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getValue() {
|
||||
return this._value;
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -99,7 +99,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -117,7 +117,7 @@ public class Content implements Cloneable, Serializable {
|
|||
return false;
|
||||
}
|
||||
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -131,7 +131,7 @@ public class Content implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -143,6 +143,6 @@ public class Content implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -29,9 +29,9 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class Description implements Cloneable, Serializable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _type;
|
||||
private String _value;
|
||||
private final ObjectBean objBean;
|
||||
private String type;
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -39,7 +39,7 @@ public class Description implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Description() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -53,7 +53,7 @@ public class Description implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -70,7 +70,7 @@ public class Description implements Cloneable, Serializable {
|
|||
if (!(other instanceof Description)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -84,7 +84,7 @@ public class Description implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -96,7 +96,7 @@ public class Description implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -107,7 +107,7 @@ public class Description implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -118,7 +118,7 @@ public class Description implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setType(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -129,7 +129,7 @@ public class Description implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getValue() {
|
||||
return this._value;
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -140,7 +140,7 @@ public class Description implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setValue(final String value) {
|
||||
this._value = value;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -29,10 +29,10 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class Enclosure implements Cloneable, Serializable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _url;
|
||||
private long _length;
|
||||
private String _type;
|
||||
private final ObjectBean objBean;
|
||||
private String url;
|
||||
private long length;
|
||||
private String type;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -40,7 +40,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Enclosure() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -54,7 +54,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -71,7 +71,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
if (!(other instanceof Enclosure)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -85,7 +85,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -97,7 +97,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -108,7 +108,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getUrl() {
|
||||
return this._url;
|
||||
return url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -119,7 +119,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setUrl(final String url) {
|
||||
this._url = url;
|
||||
this.url = url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -130,7 +130,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public long getLength() {
|
||||
return this._length;
|
||||
return length;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -141,7 +141,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setLength(final long length) {
|
||||
this._length = length;
|
||||
this.length = length;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -152,7 +152,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -163,7 +163,7 @@ public class Enclosure implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setType(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -29,9 +29,9 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class Guid implements Cloneable, Serializable {
|
||||
private final ObjectBean _objBean;
|
||||
private boolean _permaLink;
|
||||
private String _value;
|
||||
private final ObjectBean objBean;
|
||||
private boolean permaLink;
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -39,7 +39,7 @@ public class Guid implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Guid() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -53,7 +53,7 @@ public class Guid implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -70,7 +70,7 @@ public class Guid implements Cloneable, Serializable {
|
|||
if (!(other instanceof Guid)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -84,7 +84,7 @@ public class Guid implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -96,7 +96,7 @@ public class Guid implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -107,7 +107,7 @@ public class Guid implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public boolean isPermaLink() {
|
||||
return this._permaLink;
|
||||
return permaLink;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -118,7 +118,7 @@ public class Guid implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setPermaLink(final boolean permaLink) {
|
||||
this._permaLink = permaLink;
|
||||
this.permaLink = permaLink;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -129,7 +129,7 @@ public class Guid implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getValue() {
|
||||
return this._value;
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -140,7 +140,7 @@ public class Guid implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setValue(final String value) {
|
||||
this._value = value;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -28,13 +28,13 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class Image implements Cloneable, Serializable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _title;
|
||||
private String _url;
|
||||
private String _link;
|
||||
private Integer _width = -1;
|
||||
private Integer _height = -1;
|
||||
private String _description;
|
||||
private final ObjectBean objBean;
|
||||
private String title;
|
||||
private String url;
|
||||
private String link;
|
||||
private Integer width = -1;
|
||||
private Integer height = -1;
|
||||
private String description;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -42,7 +42,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Image() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -56,7 +56,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -73,7 +73,7 @@ public class Image implements Cloneable, Serializable {
|
|||
if (!(other instanceof Image)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -87,7 +87,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -99,7 +99,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -110,7 +110,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getTitle() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -121,7 +121,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setTitle(final String title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -132,7 +132,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getUrl() {
|
||||
return this._url;
|
||||
return url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -143,7 +143,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setUrl(final String url) {
|
||||
this._url = url;
|
||||
this.url = url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -154,7 +154,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getLink() {
|
||||
return this._link;
|
||||
return link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -165,7 +165,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setLink(final String link) {
|
||||
this._link = link;
|
||||
this.link = link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -176,7 +176,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Integer getWidth() {
|
||||
return this._width;
|
||||
return width;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -187,7 +187,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setWidth(final Integer width) {
|
||||
this._width = width;
|
||||
this.width = width;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -198,7 +198,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Integer getHeight() {
|
||||
return this._height;
|
||||
return height;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -209,7 +209,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setHeight(final Integer height) {
|
||||
this._height = height;
|
||||
this.height = height;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -220,7 +220,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getDescription() {
|
||||
return this._description;
|
||||
return description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -231,7 +231,7 @@ public class Image implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setDescription(final String description) {
|
||||
this._description = description;
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -42,22 +42,22 @@ import com.sun.syndication.feed.module.impl.ModuleUtils;
|
|||
*
|
||||
*/
|
||||
public class Item implements Cloneable, Serializable, Extendable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _title;
|
||||
private String _link;
|
||||
private String _uri;
|
||||
private Description _description;
|
||||
private Content _content;
|
||||
private Source _source;
|
||||
private List<Enclosure> _enclosures;
|
||||
private List<Category> _categories;
|
||||
private Guid _guid;
|
||||
private String _comments;
|
||||
private String _author;
|
||||
private Date _pubDate;
|
||||
private Date _expirationDate;
|
||||
private List<Module> _modules;
|
||||
private List<Element> _foreignMarkup;
|
||||
private final ObjectBean objBean;
|
||||
private String title;
|
||||
private String link;
|
||||
private String uri;
|
||||
private Description description;
|
||||
private Content content;
|
||||
private Source source;
|
||||
private List<Enclosure> enclosures;
|
||||
private List<Category> categories;
|
||||
private Guid guid;
|
||||
private String comments;
|
||||
private String author;
|
||||
private Date pubDate;
|
||||
private Date expirationDate;
|
||||
private List<Module> modules;
|
||||
private List<Element> foreignMarkup;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -65,7 +65,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Item() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -79,7 +79,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -99,7 +99,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
// can't use foreign markup in equals, due to JDOM equals impl
|
||||
final List<Element> fm = getForeignMarkup();
|
||||
setForeignMarkup(((Item) other).getForeignMarkup());
|
||||
final boolean ret = this._objBean.equals(other);
|
||||
final boolean ret = objBean.equals(other);
|
||||
// restore foreign markup
|
||||
setForeignMarkup(fm);
|
||||
return ret;
|
||||
|
@ -116,7 +116,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -128,7 +128,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -139,7 +139,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public String getTitle() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -150,7 +150,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setTitle(final String title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -161,7 +161,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public String getLink() {
|
||||
return this._link;
|
||||
return link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -172,7 +172,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setLink(final String link) {
|
||||
this._link = link;
|
||||
this.link = link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -182,7 +182,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
* @return the item uri, <b>null</b> if none.
|
||||
*/
|
||||
public String getUri() {
|
||||
return this._uri;
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -192,7 +192,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
* @param uri the item uri to set, <b>null</b> if none.
|
||||
*/
|
||||
public void setUri(final String uri) {
|
||||
this._uri = uri;
|
||||
this.uri = uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -203,7 +203,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Description getDescription() {
|
||||
return this._description;
|
||||
return description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -214,7 +214,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setDescription(final Description description) {
|
||||
this._description = description;
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -225,7 +225,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Content getContent() {
|
||||
return this._content;
|
||||
return content;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -236,7 +236,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setContent(final Content content) {
|
||||
this._content = content;
|
||||
this.content = content;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -247,7 +247,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Source getSource() {
|
||||
return this._source;
|
||||
return source;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -258,7 +258,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setSource(final Source source) {
|
||||
this._source = source;
|
||||
this.source = source;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -270,7 +270,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public List<Enclosure> getEnclosures() {
|
||||
return this._enclosures == null ? (this._enclosures = new ArrayList<Enclosure>()) : this._enclosures;
|
||||
return enclosures == null ? (enclosures = new ArrayList<Enclosure>()) : enclosures;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -282,7 +282,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setEnclosures(final List<Enclosure> enclosures) {
|
||||
this._enclosures = enclosures;
|
||||
this.enclosures = enclosures;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -294,7 +294,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public List<Category> getCategories() {
|
||||
return this._categories == null ? (this._categories = new ArrayList<Category>()) : this._categories;
|
||||
return categories == null ? (categories = new ArrayList<Category>()) : categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -306,7 +306,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setCategories(final List<Category> categories) {
|
||||
this._categories = categories;
|
||||
this.categories = categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -317,7 +317,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Guid getGuid() {
|
||||
return this._guid;
|
||||
return guid;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -328,7 +328,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setGuid(final Guid guid) {
|
||||
this._guid = guid;
|
||||
this.guid = guid;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -339,7 +339,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public String getComments() {
|
||||
return this._comments;
|
||||
return comments;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -350,7 +350,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setComments(final String comments) {
|
||||
this._comments = comments;
|
||||
this.comments = comments;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -361,7 +361,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public String getAuthor() {
|
||||
return this._author;
|
||||
return author;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -372,7 +372,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setAuthor(final String author) {
|
||||
this._author = author;
|
||||
this.author = author;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -385,7 +385,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public List<Module> getModules() {
|
||||
return this._modules == null ? (this._modules = new ArrayList<Module>()) : this._modules;
|
||||
return modules == null ? (modules = new ArrayList<Module>()) : modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -398,7 +398,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public void setModules(final List<Module> modules) {
|
||||
this._modules = modules;
|
||||
this.modules = modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -410,7 +410,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*/
|
||||
@Override
|
||||
public Module getModule(final String uri) {
|
||||
return ModuleUtils.getModule(this._modules, uri);
|
||||
return ModuleUtils.getModule(modules, uri);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -421,7 +421,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Date getPubDate() {
|
||||
return this._pubDate == null ? null : new Date(this._pubDate.getTime());
|
||||
return pubDate == null ? null : new Date(pubDate.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -432,7 +432,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setPubDate(final Date pubDate) {
|
||||
this._pubDate = pubDate == null ? null : new Date(pubDate.getTime());
|
||||
this.pubDate = pubDate == null ? null : new Date(pubDate.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -443,7 +443,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public Date getExpirationDate() {
|
||||
return this._expirationDate == null ? null : new Date(this._expirationDate.getTime());
|
||||
return expirationDate == null ? null : new Date(expirationDate.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -455,7 +455,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setExpirationDate(final Date expirationDate) {
|
||||
this._expirationDate = expirationDate == null ? null : new Date(expirationDate.getTime());
|
||||
this.expirationDate = expirationDate == null ? null : new Date(expirationDate.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -466,7 +466,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public List<Element> getForeignMarkup() {
|
||||
return this._foreignMarkup == null ? (this._foreignMarkup = new ArrayList<Element>()) : this._foreignMarkup;
|
||||
return foreignMarkup == null ? (foreignMarkup = new ArrayList<Element>()) : foreignMarkup;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -477,7 +477,7 @@ public class Item implements Cloneable, Serializable, Extendable {
|
|||
*
|
||||
*/
|
||||
public void setForeignMarkup(final List<Element> foreignMarkup) {
|
||||
this._foreignMarkup = foreignMarkup;
|
||||
this.foreignMarkup = foreignMarkup;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -29,9 +29,9 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class Source implements Cloneable, Serializable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _url;
|
||||
private String _value;
|
||||
private final ObjectBean objBean;
|
||||
private String url;
|
||||
private String value;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -39,7 +39,7 @@ public class Source implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public Source() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -53,7 +53,7 @@ public class Source implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -70,7 +70,7 @@ public class Source implements Cloneable, Serializable {
|
|||
if (!(other instanceof Source)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -84,7 +84,7 @@ public class Source implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -96,7 +96,7 @@ public class Source implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -107,7 +107,7 @@ public class Source implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getUrl() {
|
||||
return this._url;
|
||||
return url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -118,7 +118,7 @@ public class Source implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setUrl(final String url) {
|
||||
this._url = url;
|
||||
this.url = url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -129,7 +129,7 @@ public class Source implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getValue() {
|
||||
return this._value;
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -140,6 +140,6 @@ public class Source implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setValue(final String value) {
|
||||
this._value = value;
|
||||
this.value = value;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -29,11 +29,11 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class TextInput implements Cloneable, Serializable {
|
||||
private final ObjectBean _objBean;
|
||||
private String _title;
|
||||
private String _description;
|
||||
private String _name;
|
||||
private String _link;
|
||||
private final ObjectBean objBean;
|
||||
private String title;
|
||||
private String description;
|
||||
private String name;
|
||||
private String link;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -41,7 +41,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public TextInput() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -55,7 +55,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -72,7 +72,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
if (!(other instanceof TextInput)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -86,7 +86,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -98,7 +98,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -109,7 +109,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getTitle() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -120,7 +120,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setTitle(final String title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -131,7 +131,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getDescription() {
|
||||
return this._description;
|
||||
return description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -143,7 +143,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setDescription(final String description) {
|
||||
this._description = description;
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -154,7 +154,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getName() {
|
||||
return this._name;
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -165,7 +165,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setName(final String name) {
|
||||
this._name = name;
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -176,7 +176,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public String getLink() {
|
||||
return this._link;
|
||||
return link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -187,7 +187,7 @@ public class TextInput implements Cloneable, Serializable {
|
|||
*
|
||||
*/
|
||||
public void setLink(final String link) {
|
||||
this._link = link;
|
||||
this.link = link;
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -34,8 +34,8 @@ import com.sun.syndication.feed.module.DCSubjectImpl;
|
|||
*
|
||||
*/
|
||||
public class SyndCategoryImpl implements Serializable, SyndCategory {
|
||||
private final ObjectBean _objBean;
|
||||
private final DCSubject _subject;
|
||||
private final ObjectBean objBean;
|
||||
private final DCSubject subject;
|
||||
|
||||
/**
|
||||
* For implementations extending SyndContentImpl to be able to use the
|
||||
|
@ -45,8 +45,8 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
* @param subject the DC subject to wrap.
|
||||
*/
|
||||
SyndCategoryImpl(final DCSubject subject) {
|
||||
this._objBean = new ObjectBean(SyndCategory.class, this);
|
||||
this._subject = subject;
|
||||
objBean = new ObjectBean(SyndCategory.class, this);
|
||||
this.subject = subject;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -60,7 +60,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -77,7 +77,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
if (!(other instanceof SyndCategoryImpl)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -91,7 +91,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -103,7 +103,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -114,7 +114,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
*
|
||||
*/
|
||||
DCSubject getSubject() {
|
||||
return this._subject;
|
||||
return subject;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -135,7 +135,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
*/
|
||||
@Override
|
||||
public String getName() {
|
||||
return this._subject.getValue();
|
||||
return subject.getValue();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -147,7 +147,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
*/
|
||||
@Override
|
||||
public void setName(final String name) {
|
||||
this._subject.setValue(name);
|
||||
subject.setValue(name);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -159,7 +159,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
*/
|
||||
@Override
|
||||
public String getTaxonomyUri() {
|
||||
return this._subject.getTaxonomyUri();
|
||||
return subject.getTaxonomyUri();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -171,7 +171,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
*/
|
||||
@Override
|
||||
public void setTaxonomyUri(final String taxonomyUri) {
|
||||
this._subject.setTaxonomyUri(taxonomyUri);
|
||||
subject.setTaxonomyUri(taxonomyUri);
|
||||
}
|
||||
|
||||
}
|
||||
|
@ -195,7 +195,7 @@ public class SyndCategoryImpl implements Serializable, SyndCategory {
|
|||
*
|
||||
*/
|
||||
class SyndCategoryListFacade extends AbstractList<SyndCategory> {
|
||||
private final List<DCSubject> _subjects;
|
||||
private final List<DCSubject> subjects;
|
||||
|
||||
/**
|
||||
* Default constructor. Creates and empty list.
|
||||
|
@ -212,7 +212,7 @@ class SyndCategoryListFacade extends AbstractList<SyndCategory> {
|
|||
*
|
||||
*/
|
||||
public SyndCategoryListFacade(final List<DCSubject> subjects) {
|
||||
this._subjects = subjects;
|
||||
this.subjects = subjects;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -225,7 +225,7 @@ class SyndCategoryListFacade extends AbstractList<SyndCategory> {
|
|||
*/
|
||||
@Override
|
||||
public SyndCategory get(final int index) {
|
||||
return new SyndCategoryImpl(this._subjects.get(index));
|
||||
return new SyndCategoryImpl(subjects.get(index));
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -237,7 +237,7 @@ class SyndCategoryListFacade extends AbstractList<SyndCategory> {
|
|||
*/
|
||||
@Override
|
||||
public int size() {
|
||||
return this._subjects.size();
|
||||
return subjects.size();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -254,7 +254,7 @@ class SyndCategoryListFacade extends AbstractList<SyndCategory> {
|
|||
public SyndCategory set(final int index, final SyndCategory obj) {
|
||||
final SyndCategoryImpl sCat = (SyndCategoryImpl) obj;
|
||||
DCSubject subject = sCat != null ? sCat.getSubject() : null;
|
||||
subject = this._subjects.set(index, subject);
|
||||
subject = subjects.set(index, subject);
|
||||
return subject != null ? new SyndCategoryImpl(subject) : null;
|
||||
}
|
||||
|
||||
|
@ -270,7 +270,7 @@ class SyndCategoryListFacade extends AbstractList<SyndCategory> {
|
|||
public void add(final int index, final SyndCategory obj) {
|
||||
final SyndCategoryImpl sCat = (SyndCategoryImpl) obj;
|
||||
final DCSubject subject = sCat != null ? sCat.getSubject() : null;
|
||||
this._subjects.add(index, subject);
|
||||
subjects.add(index, subject);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -284,7 +284,7 @@ class SyndCategoryListFacade extends AbstractList<SyndCategory> {
|
|||
*/
|
||||
@Override
|
||||
public SyndCategory remove(final int index) {
|
||||
final DCSubject subject = this._subjects.remove(index);
|
||||
final DCSubject subject = subjects.remove(index);
|
||||
return subject != null ? new SyndCategoryImpl(subject) : null;
|
||||
}
|
||||
|
||||
|
|
|
@ -33,10 +33,10 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class SyndContentImpl implements Serializable, SyndContent {
|
||||
private final ObjectBean _objBean;
|
||||
private String _type;
|
||||
private String _value;
|
||||
private String _mode;
|
||||
private final ObjectBean objBean;
|
||||
private String type;
|
||||
private String value;
|
||||
private String mode;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -44,7 +44,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*
|
||||
*/
|
||||
public SyndContentImpl() {
|
||||
this._objBean = new ObjectBean(SyndContent.class, this);
|
||||
objBean = new ObjectBean(SyndContent.class, this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -58,7 +58,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -72,7 +72,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public boolean equals(final Object other) {
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -86,7 +86,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -98,7 +98,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -113,7 +113,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -128,7 +128,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public void setType(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -139,7 +139,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public String getMode() {
|
||||
return this._mode;
|
||||
return mode;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -150,7 +150,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public void setMode(final String mode) {
|
||||
this._mode = mode;
|
||||
this.mode = mode;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -162,7 +162,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public String getValue() {
|
||||
return this._value;
|
||||
return value;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -174,7 +174,7 @@ public class SyndContentImpl implements Serializable, SyndContent {
|
|||
*/
|
||||
@Override
|
||||
public void setValue(final String value) {
|
||||
this._value = value;
|
||||
this.value = value;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -13,10 +13,10 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
* @author Alejandro Abdelnur
|
||||
*/
|
||||
public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
||||
private final ObjectBean _objBean;
|
||||
private String _url;
|
||||
private String _type;
|
||||
private long _length;
|
||||
private final ObjectBean objBean;
|
||||
private String url;
|
||||
private String type;
|
||||
private long length;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -24,7 +24,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*
|
||||
*/
|
||||
public SyndEnclosureImpl() {
|
||||
this._objBean = new ObjectBean(SyndEnclosure.class, this);
|
||||
objBean = new ObjectBean(SyndEnclosure.class, this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -38,7 +38,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -52,7 +52,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public boolean equals(final Object other) {
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -66,7 +66,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -78,7 +78,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -89,7 +89,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public String getUrl() {
|
||||
return this._url;
|
||||
return url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -100,7 +100,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public void setUrl(final String url) {
|
||||
this._url = url;
|
||||
this.url = url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -111,7 +111,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public long getLength() {
|
||||
return this._length;
|
||||
return length;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -122,7 +122,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public void setLength(final long length) {
|
||||
this._length = length;
|
||||
this.length = length;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -133,7 +133,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -144,7 +144,7 @@ public class SyndEnclosureImpl implements Serializable, SyndEnclosure {
|
|||
*/
|
||||
@Override
|
||||
public void setType(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -47,25 +47,25 @@ import com.sun.syndication.feed.synd.impl.URINormalizer;
|
|||
*
|
||||
*/
|
||||
public class SyndEntryImpl implements Serializable, SyndEntry {
|
||||
private final ObjectBean _objBean;
|
||||
private String _uri;
|
||||
private String _link;
|
||||
private Date _updatedDate;
|
||||
private SyndContent _title;
|
||||
private SyndContent _description;
|
||||
private List<SyndLink> _links;
|
||||
private List<SyndContent> _contents; // deprecated by Atom 1.0
|
||||
private List<Module> _modules;
|
||||
private List<SyndEnclosure> _enclosures;
|
||||
private List<SyndPerson> _authors;
|
||||
private List<SyndPerson> _contributors;
|
||||
private SyndFeed _source;
|
||||
private List<Element> _foreignMarkup;
|
||||
private final ObjectBean objBean;
|
||||
private String uri;
|
||||
private String link;
|
||||
private Date updatedDate;
|
||||
private SyndContent title;
|
||||
private SyndContent description;
|
||||
private List<SyndLink> links;
|
||||
private List<SyndContent> contents; // deprecated by Atom 1.0
|
||||
private List<Module> modules;
|
||||
private List<SyndEnclosure> enclosures;
|
||||
private List<SyndPerson> authors;
|
||||
private List<SyndPerson> contributors;
|
||||
private SyndFeed source;
|
||||
private List<Element> foreignMarkup;
|
||||
private Object wireEntry; // com.sun.syndication.feed.atom.Entry or
|
||||
// com.sun.syndication.feed.rss.Item
|
||||
|
||||
// ISSUE: some converters assume this is never null
|
||||
private List<SyndCategory> _categories = new ArrayList<SyndCategory>();
|
||||
private List<SyndCategory> categories = new ArrayList<SyndCategory>();
|
||||
|
||||
private static final Set<String> IGNORE_PROPERTIES = new HashSet<String>();
|
||||
|
||||
|
@ -95,7 +95,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*
|
||||
*/
|
||||
protected SyndEntryImpl(final Class beanClass, final Set convenienceProperties) {
|
||||
this._objBean = new ObjectBean(beanClass, this, convenienceProperties);
|
||||
objBean = new ObjectBean(beanClass, this, convenienceProperties);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -118,7 +118,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -144,7 +144,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
// can't use foreign markup in equals, due to JDOM equals impl
|
||||
final List<Element> fm = getForeignMarkup();
|
||||
setForeignMarkup(((SyndEntryImpl) other).getForeignMarkup());
|
||||
final boolean ret = this._objBean.equals(other);
|
||||
final boolean ret = objBean.equals(other);
|
||||
// restore foreign markup
|
||||
setForeignMarkup(fm);
|
||||
return ret;
|
||||
|
@ -161,7 +161,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -173,7 +173,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -193,7 +193,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public String getUri() {
|
||||
return this._uri;
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -211,7 +211,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setUri(final String uri) {
|
||||
this._uri = URINormalizer.normalize(uri);
|
||||
this.uri = URINormalizer.normalize(uri);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -223,8 +223,8 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public String getTitle() {
|
||||
if (this._title != null) {
|
||||
return this._title.getValue();
|
||||
if (title != null) {
|
||||
return title.getValue();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
@ -238,10 +238,10 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setTitle(final String title) {
|
||||
if (this._title == null) {
|
||||
this._title = new SyndContentImpl();
|
||||
if (this.title == null) {
|
||||
this.title = new SyndContentImpl();
|
||||
}
|
||||
this._title.setValue(title);
|
||||
this.title.setValue(title);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -253,7 +253,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public SyndContent getTitleEx() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -265,7 +265,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setTitleEx(final SyndContent title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -277,7 +277,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public String getLink() {
|
||||
return this._link;
|
||||
return link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -289,7 +289,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setLink(final String link) {
|
||||
this._link = link;
|
||||
this.link = link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -301,7 +301,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public SyndContent getDescription() {
|
||||
return this._description;
|
||||
return description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -313,7 +313,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setDescription(final SyndContent description) {
|
||||
this._description = description;
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -326,7 +326,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public List<SyndContent> getContents() {
|
||||
return this._contents == null ? (this._contents = new ArrayList<SyndContent>()) : this._contents;
|
||||
return contents == null ? (contents = new ArrayList<SyndContent>()) : contents;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -339,7 +339,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setContents(final List<SyndContent> contents) {
|
||||
this._contents = contents;
|
||||
this.contents = contents;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -352,7 +352,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public List<SyndEnclosure> getEnclosures() {
|
||||
return this._enclosures == null ? (this._enclosures = new ArrayList<SyndEnclosure>()) : this._enclosures;
|
||||
return enclosures == null ? (enclosures = new ArrayList<SyndEnclosure>()) : enclosures;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -365,7 +365,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setEnclosures(final List<SyndEnclosure> enclosures) {
|
||||
this._enclosures = enclosures;
|
||||
this.enclosures = enclosures;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -409,7 +409,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public List<SyndCategory> getCategories() {
|
||||
return this._categories;
|
||||
return categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -425,7 +425,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setCategories(final List<SyndCategory> categories) {
|
||||
this._categories = categories;
|
||||
this.categories = categories;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -438,13 +438,13 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public List<Module> getModules() {
|
||||
if (this._modules == null) {
|
||||
this._modules = new ArrayList<Module>();
|
||||
if (modules == null) {
|
||||
modules = new ArrayList<Module>();
|
||||
}
|
||||
if (ModuleUtils.getModule(this._modules, DCModule.URI) == null) {
|
||||
this._modules.add(new DCModuleImpl());
|
||||
if (ModuleUtils.getModule(modules, DCModule.URI) == null) {
|
||||
modules.add(new DCModuleImpl());
|
||||
}
|
||||
return this._modules;
|
||||
return modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -457,7 +457,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setModules(final List<Module> modules) {
|
||||
this._modules = modules;
|
||||
this.modules = modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -522,7 +522,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public List<SyndLink> getLinks() {
|
||||
return this._links == null ? (this._links = new ArrayList<SyndLink>()) : this._links;
|
||||
return links == null ? (links = new ArrayList<SyndLink>()) : links;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -533,7 +533,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setLinks(final List<SyndLink> links) {
|
||||
this._links = links;
|
||||
this.links = links;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -544,7 +544,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public Date getUpdatedDate() {
|
||||
return this._updatedDate == null ? null : new Date(this._updatedDate.getTime());
|
||||
return updatedDate == null ? null : new Date(updatedDate.getTime());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -555,12 +555,12 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setUpdatedDate(final Date updatedDate) {
|
||||
this._updatedDate = new Date(updatedDate.getTime());
|
||||
this.updatedDate = new Date(updatedDate.getTime());
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SyndPerson> getAuthors() {
|
||||
return this._authors == null ? (this._authors = new ArrayList<SyndPerson>()) : this._authors;
|
||||
return authors == null ? (authors = new ArrayList<SyndPerson>()) : authors;
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -569,7 +569,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setAuthors(final List<SyndPerson> authors) {
|
||||
this._authors = authors;
|
||||
this.authors = authors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -586,10 +586,10 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
public String getAuthor() {
|
||||
String author;
|
||||
|
||||
// Start out looking for one or more authors in _authors. For non-Atom
|
||||
// feeds, _authors may actually be null.
|
||||
if (this._authors != null && this._authors.size() > 0) {
|
||||
author = this._authors.get(0).getName();
|
||||
// Start out looking for one or more authors in authors. For non-Atom
|
||||
// feeds, authors may actually be null.
|
||||
if (authors != null && authors.size() > 0) {
|
||||
author = authors.get(0).getName();
|
||||
} else {
|
||||
author = getDCModule().getCreator();
|
||||
}
|
||||
|
@ -624,7 +624,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
|
||||
@Override
|
||||
public List<SyndPerson> getContributors() {
|
||||
return this._contributors == null ? (this._contributors = new ArrayList<SyndPerson>()) : this._contributors;
|
||||
return contributors == null ? (contributors = new ArrayList<SyndPerson>()) : contributors;
|
||||
}
|
||||
|
||||
/*
|
||||
|
@ -634,17 +634,17 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setContributors(final List<SyndPerson> contributors) {
|
||||
this._contributors = contributors;
|
||||
this.contributors = contributors;
|
||||
}
|
||||
|
||||
@Override
|
||||
public SyndFeed getSource() {
|
||||
return this._source;
|
||||
return source;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setSource(final SyndFeed source) {
|
||||
this._source = source;
|
||||
this.source = source;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -657,7 +657,7 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public List<Element> getForeignMarkup() {
|
||||
return this._foreignMarkup == null ? (this._foreignMarkup = new ArrayList<Element>()) : this._foreignMarkup;
|
||||
return foreignMarkup == null ? (foreignMarkup = new ArrayList<Element>()) : foreignMarkup;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -670,12 +670,12 @@ public class SyndEntryImpl implements Serializable, SyndEntry {
|
|||
*/
|
||||
@Override
|
||||
public void setForeignMarkup(final List<Element> foreignMarkup) {
|
||||
this._foreignMarkup = foreignMarkup;
|
||||
this.foreignMarkup = foreignMarkup;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Object getWireEntry() {
|
||||
return this.wireEntry;
|
||||
return wireEntry;
|
||||
}
|
||||
|
||||
public void setWireEntry(final Object wireEntry) {
|
||||
|
|
|
@ -53,21 +53,21 @@ import com.sun.syndication.feed.synd.impl.URINormalizer;
|
|||
*/
|
||||
public class SyndFeedImpl implements Serializable, SyndFeed {
|
||||
|
||||
private final ObjectBean _objBean;
|
||||
private final ObjectBean objBean;
|
||||
|
||||
private String _encoding;
|
||||
private String _uri;
|
||||
private SyndContent _title;
|
||||
private SyndContent _description;
|
||||
private String _feedType;
|
||||
private String _link;
|
||||
private List<SyndLink> _links;
|
||||
private SyndImage _image;
|
||||
private List<SyndEntry> _entries;
|
||||
private List<Module> _modules;
|
||||
private List<SyndPerson> _authors;
|
||||
private List<SyndPerson> _contributors;
|
||||
private List<Element> _foreignMarkup;
|
||||
private String encoding;
|
||||
private String uri;
|
||||
private SyndContent title;
|
||||
private SyndContent description;
|
||||
private String feedType;
|
||||
private String link;
|
||||
private List<SyndLink> links;
|
||||
private SyndImage image;
|
||||
private List<SyndEntry> entries;
|
||||
private List<Module> modules;
|
||||
private List<SyndPerson> authors;
|
||||
private List<SyndPerson> contributors;
|
||||
private List<Element> foreignMarkup;
|
||||
|
||||
private WireFeed wireFeed = null;
|
||||
private boolean preserveWireFeed = false;
|
||||
|
@ -118,7 +118,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*
|
||||
*/
|
||||
protected SyndFeedImpl(final Class beanClass, final Set convenienceProperties) {
|
||||
this._objBean = new ObjectBean(beanClass, this, convenienceProperties);
|
||||
objBean = new ObjectBean(beanClass, this, convenienceProperties);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -155,15 +155,15 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
this(SyndFeed.class, IGNORE_PROPERTIES);
|
||||
|
||||
if (preserveWireFeed) {
|
||||
this.wireFeed = feed;
|
||||
wireFeed = feed;
|
||||
this.preserveWireFeed = preserveWireFeed;
|
||||
}
|
||||
|
||||
if (feed != null) {
|
||||
this._feedType = feed.getFeedType();
|
||||
final Converter converter = CONVERTERS.getConverter(this._feedType);
|
||||
feedType = feed.getFeedType();
|
||||
final Converter converter = CONVERTERS.getConverter(feedType);
|
||||
if (converter == null) {
|
||||
throw new IllegalArgumentException("Invalid feed type [" + this._feedType + "]");
|
||||
throw new IllegalArgumentException("Invalid feed type [" + feedType + "]");
|
||||
}
|
||||
converter.copyInto(feed, this);
|
||||
}
|
||||
|
@ -181,7 +181,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -201,7 +201,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
// can't use foreign markup in equals, due to JDOM equals impl
|
||||
final List<Element> fm = getForeignMarkup();
|
||||
setForeignMarkup(((SyndFeedImpl) other).getForeignMarkup());
|
||||
final boolean ret = this._objBean.equals(other);
|
||||
final boolean ret = objBean.equals(other);
|
||||
setForeignMarkup(fm); // restore foreign markup
|
||||
return ret;
|
||||
}
|
||||
|
@ -217,7 +217,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -229,7 +229,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -244,7 +244,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public WireFeed createWireFeed() {
|
||||
return this.createWireFeed(this._feedType);
|
||||
return this.createWireFeed(feedType);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -281,7 +281,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public WireFeed originalWireFeed() {
|
||||
return this.wireFeed;
|
||||
return wireFeed;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -294,7 +294,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public String getFeedType() {
|
||||
return this._feedType;
|
||||
return feedType;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -306,7 +306,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setFeedType(final String feedType) {
|
||||
this._feedType = feedType;
|
||||
this.feedType = feedType;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -319,7 +319,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public String getEncoding() {
|
||||
return this._encoding;
|
||||
return encoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -331,7 +331,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setEncoding(final String encoding) {
|
||||
this._encoding = encoding;
|
||||
this.encoding = encoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -363,7 +363,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public String getUri() {
|
||||
return this._uri;
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -393,7 +393,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setUri(final String uri) {
|
||||
this._uri = URINormalizer.normalize(uri);
|
||||
this.uri = URINormalizer.normalize(uri);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -405,8 +405,8 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public String getTitle() {
|
||||
if (this._title != null) {
|
||||
return this._title.getValue();
|
||||
if (title != null) {
|
||||
return title.getValue();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
@ -420,10 +420,10 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setTitle(final String title) {
|
||||
if (this._title == null) {
|
||||
this._title = new SyndContentImpl();
|
||||
if (this.title == null) {
|
||||
this.title = new SyndContentImpl();
|
||||
}
|
||||
this._title.setValue(title);
|
||||
this.title.setValue(title);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -435,7 +435,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public SyndContent getTitleEx() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -447,7 +447,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setTitleEx(final SyndContent title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -471,7 +471,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public String getLink() {
|
||||
return this._link;
|
||||
return link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -495,7 +495,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setLink(final String link) {
|
||||
this._link = link;
|
||||
this.link = link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -507,8 +507,8 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public String getDescription() {
|
||||
if (this._description != null) {
|
||||
return this._description.getValue();
|
||||
if (description != null) {
|
||||
return description.getValue();
|
||||
}
|
||||
return null;
|
||||
}
|
||||
|
@ -522,10 +522,10 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setDescription(final String description) {
|
||||
if (this._description == null) {
|
||||
this._description = new SyndContentImpl();
|
||||
if (this.description == null) {
|
||||
this.description = new SyndContentImpl();
|
||||
}
|
||||
this._description.setValue(description);
|
||||
this.description.setValue(description);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -537,7 +537,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public SyndContent getDescriptionEx() {
|
||||
return this._description;
|
||||
return description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -549,7 +549,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setDescriptionEx(final SyndContent description) {
|
||||
this._description = description;
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -621,7 +621,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public SyndImage getImage() {
|
||||
return this._image;
|
||||
return image;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -633,7 +633,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setImage(final SyndImage image) {
|
||||
this._image = image;
|
||||
this.image = image;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -678,7 +678,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public List<SyndEntry> getEntries() {
|
||||
return this._entries == null ? (this._entries = new ArrayList<SyndEntry>()) : this._entries;
|
||||
return entries == null ? (entries = new ArrayList<SyndEntry>()) : entries;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -691,7 +691,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setEntries(final List<SyndEntry> entries) {
|
||||
this._entries = entries;
|
||||
this.entries = entries;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -734,13 +734,13 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public List<Module> getModules() {
|
||||
if (this._modules == null) {
|
||||
this._modules = new ArrayList<Module>();
|
||||
if (modules == null) {
|
||||
modules = new ArrayList<Module>();
|
||||
}
|
||||
if (ModuleUtils.getModule(this._modules, DCModule.URI) == null) {
|
||||
this._modules.add(new DCModuleImpl());
|
||||
if (ModuleUtils.getModule(modules, DCModule.URI) == null) {
|
||||
modules.add(new DCModuleImpl());
|
||||
}
|
||||
return this._modules;
|
||||
return modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -753,7 +753,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setModules(final List<Module> modules) {
|
||||
this._modules = modules;
|
||||
this.modules = modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -821,7 +821,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public List<SyndLink> getLinks() {
|
||||
return this._links == null ? (this._links = new ArrayList<SyndLink>()) : this._links;
|
||||
return links == null ? (links = new ArrayList<SyndLink>()) : links;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -832,17 +832,17 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setLinks(final List<SyndLink> links) {
|
||||
this._links = links;
|
||||
this.links = links;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<SyndPerson> getAuthors() {
|
||||
return this._authors == null ? (this._authors = new ArrayList<SyndPerson>()) : this._authors;
|
||||
return authors == null ? (authors = new ArrayList<SyndPerson>()) : authors;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setAuthors(final List<SyndPerson> authors) {
|
||||
this._authors = authors;
|
||||
this.authors = authors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -877,12 +877,12 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
|
||||
@Override
|
||||
public List<SyndPerson> getContributors() {
|
||||
return this._contributors == null ? (this._contributors = new ArrayList<SyndPerson>()) : this._contributors;
|
||||
return contributors == null ? (contributors = new ArrayList<SyndPerson>()) : contributors;
|
||||
}
|
||||
|
||||
@Override
|
||||
public void setContributors(final List<SyndPerson> contributors) {
|
||||
this._contributors = contributors;
|
||||
this.contributors = contributors;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -894,7 +894,7 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public List<Element> getForeignMarkup() {
|
||||
return this._foreignMarkup == null ? (this._foreignMarkup = new ArrayList<Element>()) : this._foreignMarkup;
|
||||
return foreignMarkup == null ? (foreignMarkup = new ArrayList<Element>()) : foreignMarkup;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -906,11 +906,11 @@ public class SyndFeedImpl implements Serializable, SyndFeed {
|
|||
*/
|
||||
@Override
|
||||
public void setForeignMarkup(final List<Element> foreignMarkup) {
|
||||
this._foreignMarkup = foreignMarkup;
|
||||
this.foreignMarkup = foreignMarkup;
|
||||
}
|
||||
|
||||
@Override
|
||||
public boolean isPreservingWireFeed() {
|
||||
return this.preserveWireFeed;
|
||||
return preserveWireFeed;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -33,11 +33,11 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*
|
||||
*/
|
||||
public class SyndImageImpl implements Serializable, SyndImage {
|
||||
private final ObjectBean _objBean;
|
||||
private String _title;
|
||||
private String _url;
|
||||
private String _link;
|
||||
private String _description;
|
||||
private final ObjectBean objBean;
|
||||
private String title;
|
||||
private String url;
|
||||
private String link;
|
||||
private String description;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -45,7 +45,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*
|
||||
*/
|
||||
public SyndImageImpl() {
|
||||
this._objBean = new ObjectBean(SyndImage.class, this);
|
||||
objBean = new ObjectBean(SyndImage.class, this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -59,7 +59,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -73,7 +73,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public boolean equals(final Object other) {
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -87,7 +87,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -99,7 +99,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -111,7 +111,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public String getTitle() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -123,7 +123,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public void setTitle(final String title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -135,7 +135,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public String getUrl() {
|
||||
return this._url;
|
||||
return url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -147,7 +147,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public void setUrl(final String url) {
|
||||
this._url = url;
|
||||
this.url = url;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -159,7 +159,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public String getLink() {
|
||||
return this._link;
|
||||
return link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -171,7 +171,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public void setLink(final String link) {
|
||||
this._link = link;
|
||||
this.link = link;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -183,7 +183,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public String getDescription() {
|
||||
return this._description;
|
||||
return description;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -195,7 +195,7 @@ public class SyndImageImpl implements Serializable, SyndImage {
|
|||
*/
|
||||
@Override
|
||||
public void setDescription(final String description) {
|
||||
this._description = description;
|
||||
this.description = description;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -30,14 +30,14 @@ import com.sun.syndication.feed.impl.ObjectBean;
|
|||
*/
|
||||
public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
||||
|
||||
private final ObjectBean _objBean;
|
||||
private final ObjectBean objBean;
|
||||
|
||||
private String _href;
|
||||
private String _rel;
|
||||
private String _type;
|
||||
private String _hreflang;
|
||||
private String _title;
|
||||
private long _length;
|
||||
private String href;
|
||||
private String rel;
|
||||
private String type;
|
||||
private String hreflang;
|
||||
private String title;
|
||||
private long length;
|
||||
|
||||
/**
|
||||
* Default constructor. All properties are set to <b>null</b>.
|
||||
|
@ -45,7 +45,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*
|
||||
*/
|
||||
public SyndLinkImpl() {
|
||||
this._objBean = new ObjectBean(this.getClass(), this);
|
||||
objBean = new ObjectBean(this.getClass(), this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -59,7 +59,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -76,7 +76,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
if (!(other instanceof SyndLinkImpl)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -90,7 +90,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -102,7 +102,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -114,7 +114,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public String getRel() {
|
||||
return this._rel;
|
||||
return rel;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -127,7 +127,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
@Override
|
||||
public void setRel(final String rel) {
|
||||
// TODO add check, ask P@ about the check
|
||||
this._rel = rel;
|
||||
this.rel = rel;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -139,7 +139,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -151,7 +151,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public void setType(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -163,7 +163,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public String getHref() {
|
||||
return this._href;
|
||||
return href;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -175,7 +175,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public void setHref(final String href) {
|
||||
this._href = href;
|
||||
this.href = href;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -187,7 +187,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public String getTitle() {
|
||||
return this._title;
|
||||
return title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -199,7 +199,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public void setTitle(final String title) {
|
||||
this._title = title;
|
||||
this.title = title;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -210,7 +210,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public String getHreflang() {
|
||||
return this._hreflang;
|
||||
return hreflang;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -221,7 +221,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public void setHreflang(final String hreflang) {
|
||||
this._hreflang = hreflang;
|
||||
this.hreflang = hreflang;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -232,7 +232,7 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public long getLength() {
|
||||
return this._length;
|
||||
return length;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -243,6 +243,6 @@ public class SyndLinkImpl implements Cloneable, Serializable, SyndLink {
|
|||
*/
|
||||
@Override
|
||||
public void setLength(final long length) {
|
||||
this._length = length;
|
||||
this.length = length;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -33,18 +33,18 @@ import com.sun.syndication.feed.module.impl.ModuleUtils;
|
|||
*
|
||||
*/
|
||||
public class SyndPersonImpl implements Serializable, SyndPerson {
|
||||
private final ObjectBean _objBean;
|
||||
private String _name;
|
||||
private String _uri;
|
||||
private String _email;
|
||||
private List<Module> _modules;
|
||||
private final ObjectBean objBean;
|
||||
private String name;
|
||||
private String uri;
|
||||
private String email;
|
||||
private List<Module> modules;
|
||||
|
||||
/**
|
||||
* For implementations extending SyndContentImpl to be able to use the
|
||||
* ObjectBean functionality with extended interfaces.
|
||||
*/
|
||||
public SyndPersonImpl() {
|
||||
this._objBean = new ObjectBean(SyndPerson.class, this);
|
||||
objBean = new ObjectBean(SyndPerson.class, this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -58,7 +58,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public Object clone() throws CloneNotSupportedException {
|
||||
return this._objBean.clone();
|
||||
return objBean.clone();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -75,7 +75,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
if (!(other instanceof SyndPersonImpl)) {
|
||||
return false;
|
||||
}
|
||||
return this._objBean.equals(other);
|
||||
return objBean.equals(other);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -89,7 +89,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public int hashCode() {
|
||||
return this._objBean.hashCode();
|
||||
return objBean.hashCode();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -101,7 +101,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public String toString() {
|
||||
return this._objBean.toString();
|
||||
return objBean.toString();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -113,7 +113,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public String getName() {
|
||||
return this._name;
|
||||
return name;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -125,7 +125,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public void setName(final String name) {
|
||||
this._name = name;
|
||||
this.name = name;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -137,7 +137,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public String getEmail() {
|
||||
return this._email;
|
||||
return email;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -149,7 +149,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public void setEmail(final String email) {
|
||||
this._email = email;
|
||||
this.email = email;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -161,7 +161,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public String getUri() {
|
||||
return this._uri;
|
||||
return uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -173,7 +173,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public void setUri(final String uri) {
|
||||
this._uri = uri;
|
||||
this.uri = uri;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -185,10 +185,10 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public List<Module> getModules() {
|
||||
if (this._modules == null) {
|
||||
this._modules = new ArrayList<Module>();
|
||||
if (modules == null) {
|
||||
modules = new ArrayList<Module>();
|
||||
}
|
||||
return this._modules;
|
||||
return modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -201,7 +201,7 @@ public class SyndPersonImpl implements Serializable, SyndPerson {
|
|||
*/
|
||||
@Override
|
||||
public void setModules(final List<Module> modules) {
|
||||
this._modules = modules;
|
||||
this.modules = modules;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -44,19 +44,19 @@ import com.sun.syndication.feed.synd.SyndPersonImpl;
|
|||
/**
|
||||
*/
|
||||
public class ConverterForAtom03 implements Converter {
|
||||
private final String _type;
|
||||
private final String type;
|
||||
|
||||
public ConverterForAtom03() {
|
||||
this("atom_0.3");
|
||||
}
|
||||
|
||||
protected ConverterForAtom03(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -46,19 +46,19 @@ import com.sun.syndication.feed.synd.SyndPerson;
|
|||
/**
|
||||
*/
|
||||
public class ConverterForAtom10 implements Converter {
|
||||
private final String _type;
|
||||
private final String type;
|
||||
|
||||
public ConverterForAtom10() {
|
||||
this("atom_1.0");
|
||||
}
|
||||
|
||||
protected ConverterForAtom10(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -34,19 +34,19 @@ import com.sun.syndication.feed.synd.SyndImageImpl;
|
|||
/**
|
||||
*/
|
||||
public class ConverterForRSS090 implements Converter {
|
||||
private final String _type;
|
||||
private final String type;
|
||||
|
||||
public ConverterForRSS090() {
|
||||
this("rss_0.9");
|
||||
}
|
||||
|
||||
protected ConverterForRSS090(final String type) {
|
||||
this._type = type;
|
||||
this.type = type;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -25,11 +25,11 @@ public class SAXBuilder extends org.jdom2.input.SAXBuilder {
|
|||
*
|
||||
* @deprecated use SAXBuilder(XMLReaderJDOMFactory) with either
|
||||
* XMLReaders.DTDVALIDATING or XMLReaders.NONVALIDATING
|
||||
* @param _validate
|
||||
* @param validate
|
||||
*/
|
||||
@Deprecated
|
||||
public SAXBuilder(final boolean _validate) {
|
||||
super(_validate ? XMLReaders.DTDVALIDATING : XMLReaders.NONVALIDATING);
|
||||
public SAXBuilder(final boolean validate) {
|
||||
super(validate ? XMLReaders.DTDVALIDATING : XMLReaders.NONVALIDATING);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -38,7 +38,7 @@ import com.sun.syndication.feed.synd.SyndFeedImpl;
|
|||
*
|
||||
*/
|
||||
public class SyndFeedInput {
|
||||
private final WireFeedInput _feedInput;
|
||||
private final WireFeedInput feedInput;
|
||||
private boolean preserveWireFeed = false;
|
||||
|
||||
/**
|
||||
|
@ -59,7 +59,7 @@ public class SyndFeedInput {
|
|||
*
|
||||
*/
|
||||
public SyndFeedInput(final boolean validate) {
|
||||
this._feedInput = new WireFeedInput(validate);
|
||||
feedInput = new WireFeedInput(validate);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -81,7 +81,7 @@ public class SyndFeedInput {
|
|||
*
|
||||
*/
|
||||
public void setXmlHealerOn(final boolean heals) {
|
||||
this._feedInput.setXmlHealerOn(heals);
|
||||
feedInput.setXmlHealerOn(heals);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -104,7 +104,7 @@ public class SyndFeedInput {
|
|||
*
|
||||
*/
|
||||
public boolean getXmlHealerOn() {
|
||||
return this._feedInput.getXmlHealerOn();
|
||||
return feedInput.getXmlHealerOn();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -121,7 +121,7 @@ public class SyndFeedInput {
|
|||
*
|
||||
*/
|
||||
public SyndFeed build(final File file) throws FileNotFoundException, IOException, IllegalArgumentException, FeedException {
|
||||
return new SyndFeedImpl(this._feedInput.build(file), this.preserveWireFeed);
|
||||
return new SyndFeedImpl(feedInput.build(file), preserveWireFeed);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -136,7 +136,7 @@ public class SyndFeedInput {
|
|||
*
|
||||
*/
|
||||
public SyndFeed build(final Reader reader) throws IllegalArgumentException, FeedException {
|
||||
return new SyndFeedImpl(this._feedInput.build(reader), this.preserveWireFeed);
|
||||
return new SyndFeedImpl(feedInput.build(reader), preserveWireFeed);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -151,7 +151,7 @@ public class SyndFeedInput {
|
|||
*
|
||||
*/
|
||||
public SyndFeed build(final InputSource is) throws IllegalArgumentException, FeedException {
|
||||
return new SyndFeedImpl(this._feedInput.build(is), this.preserveWireFeed);
|
||||
return new SyndFeedImpl(feedInput.build(is), preserveWireFeed);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -166,7 +166,7 @@ public class SyndFeedInput {
|
|||
*
|
||||
*/
|
||||
public SyndFeed build(final org.w3c.dom.Document document) throws IllegalArgumentException, FeedException {
|
||||
return new SyndFeedImpl(this._feedInput.build(document), this.preserveWireFeed);
|
||||
return new SyndFeedImpl(feedInput.build(document), preserveWireFeed);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -181,7 +181,7 @@ public class SyndFeedInput {
|
|||
*
|
||||
*/
|
||||
public SyndFeed build(final Document document) throws IllegalArgumentException, FeedException {
|
||||
return new SyndFeedImpl(this._feedInput.build(document), this.preserveWireFeed);
|
||||
return new SyndFeedImpl(feedInput.build(document), preserveWireFeed);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -190,7 +190,7 @@ public class SyndFeedInput {
|
|||
* default.
|
||||
*/
|
||||
public boolean isPreserveWireFeed() {
|
||||
return this.preserveWireFeed;
|
||||
return preserveWireFeed;
|
||||
}
|
||||
|
||||
/**
|
||||
|
|
|
@ -35,7 +35,7 @@ import com.sun.syndication.feed.synd.SyndFeed;
|
|||
*
|
||||
*/
|
||||
public class SyndFeedOutput {
|
||||
private final WireFeedOutput _feedOutput;
|
||||
private final WireFeedOutput feedOutput;
|
||||
|
||||
/**
|
||||
* Creates a SyndFeedOutput instance.
|
||||
|
@ -43,7 +43,7 @@ public class SyndFeedOutput {
|
|||
*
|
||||
*/
|
||||
public SyndFeedOutput() {
|
||||
this._feedOutput = new WireFeedOutput();
|
||||
feedOutput = new WireFeedOutput();
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -64,7 +64,7 @@ public class SyndFeedOutput {
|
|||
*
|
||||
*/
|
||||
public String outputString(final SyndFeed feed) throws FeedException {
|
||||
return this._feedOutput.outputString(feed.createWireFeed());
|
||||
return feedOutput.outputString(feed.createWireFeed());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -86,7 +86,7 @@ public class SyndFeedOutput {
|
|||
*
|
||||
*/
|
||||
public String outputString(final SyndFeed feed, final boolean prettyPrint) throws FeedException {
|
||||
return this._feedOutput.outputString(feed.createWireFeed(), prettyPrint);
|
||||
return feedOutput.outputString(feed.createWireFeed(), prettyPrint);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -110,7 +110,7 @@ public class SyndFeedOutput {
|
|||
*
|
||||
*/
|
||||
public void output(final SyndFeed feed, final File file) throws IOException, FeedException {
|
||||
this._feedOutput.output(feed.createWireFeed(), file);
|
||||
feedOutput.output(feed.createWireFeed(), file);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -135,7 +135,7 @@ public class SyndFeedOutput {
|
|||
*
|
||||
*/
|
||||
public void output(final SyndFeed feed, final File file, final boolean prettyPrint) throws IOException, FeedException {
|
||||
this._feedOutput.output(feed.createWireFeed(), file, prettyPrint);
|
||||
feedOutput.output(feed.createWireFeed(), file, prettyPrint);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -159,7 +159,7 @@ public class SyndFeedOutput {
|
|||
*
|
||||
*/
|
||||
public void output(final SyndFeed feed, final Writer writer) throws IOException, FeedException {
|
||||
this._feedOutput.output(feed.createWireFeed(), writer);
|
||||
feedOutput.output(feed.createWireFeed(), writer);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -184,7 +184,7 @@ public class SyndFeedOutput {
|
|||
*
|
||||
*/
|
||||
public void output(final SyndFeed feed, final Writer writer, final boolean prettyPrint) throws IOException, FeedException {
|
||||
this._feedOutput.output(feed.createWireFeed(), writer, prettyPrint);
|
||||
feedOutput.output(feed.createWireFeed(), writer, prettyPrint);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -202,7 +202,7 @@ public class SyndFeedOutput {
|
|||
*
|
||||
*/
|
||||
public org.w3c.dom.Document outputW3CDom(final SyndFeed feed) throws FeedException {
|
||||
return this._feedOutput.outputW3CDom(feed.createWireFeed());
|
||||
return feedOutput.outputW3CDom(feed.createWireFeed());
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -220,7 +220,7 @@ public class SyndFeedOutput {
|
|||
*
|
||||
*/
|
||||
public Document outputJDom(final SyndFeed feed) throws FeedException {
|
||||
return this._feedOutput.outputJDom(feed.createWireFeed());
|
||||
return feedOutput.outputJDom(feed.createWireFeed());
|
||||
}
|
||||
|
||||
}
|
||||
|
|
|
@ -83,9 +83,9 @@ public class WireFeedInput {
|
|||
}
|
||||
}
|
||||
|
||||
private final boolean _validate;
|
||||
private final boolean validate;
|
||||
|
||||
private boolean _xmlHealerOn;
|
||||
private boolean xmlHealerOn;
|
||||
|
||||
/**
|
||||
* Returns the list of supported input feed types.
|
||||
|
@ -118,8 +118,8 @@ public class WireFeedInput {
|
|||
*
|
||||
*/
|
||||
public WireFeedInput(final boolean validate) {
|
||||
this._validate = false; // TODO FIX THIS THINGY
|
||||
this._xmlHealerOn = true;
|
||||
this.validate = false; // TODO FIX THIS THINGY
|
||||
xmlHealerOn = true;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -141,7 +141,7 @@ public class WireFeedInput {
|
|||
*
|
||||
*/
|
||||
public void setXmlHealerOn(final boolean heals) {
|
||||
this._xmlHealerOn = heals;
|
||||
xmlHealerOn = heals;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -164,7 +164,7 @@ public class WireFeedInput {
|
|||
*
|
||||
*/
|
||||
public boolean getXmlHealerOn() {
|
||||
return this._xmlHealerOn;
|
||||
return xmlHealerOn;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -186,7 +186,7 @@ public class WireFeedInput {
|
|||
public WireFeed build(final File file) throws FileNotFoundException, IOException, IllegalArgumentException, FeedException {
|
||||
WireFeed feed;
|
||||
Reader reader = new FileReader(file);
|
||||
if (this._xmlHealerOn) {
|
||||
if (xmlHealerOn) {
|
||||
reader = new XmlFixerReader(reader);
|
||||
}
|
||||
feed = this.build(reader);
|
||||
|
@ -211,7 +211,7 @@ public class WireFeedInput {
|
|||
public WireFeed build(Reader reader) throws IllegalArgumentException, FeedException {
|
||||
final SAXBuilder saxBuilder = createSAXBuilder();
|
||||
try {
|
||||
if (this._xmlHealerOn) {
|
||||
if (xmlHealerOn) {
|
||||
reader = new XmlFixerReader(reader);
|
||||
}
|
||||
final Document document = saxBuilder.build(reader);
|
||||
|
@ -297,7 +297,7 @@ public class WireFeedInput {
|
|||
if (parser == null) {
|
||||
throw new IllegalArgumentException("Invalid document");
|
||||
}
|
||||
return parser.parse(document, this._validate);
|
||||
return parser.parse(document, validate);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -306,7 +306,7 @@ public class WireFeedInput {
|
|||
* @return a new org.jdom2.input.SAXBuilder object
|
||||
*/
|
||||
protected SAXBuilder createSAXBuilder() {
|
||||
final SAXBuilder saxBuilder = new SAXBuilder(this._validate ? XMLReaders.DTDVALIDATING : XMLReaders.NONVALIDATING);
|
||||
final SAXBuilder saxBuilder = new SAXBuilder(validate ? XMLReaders.DTDVALIDATING : XMLReaders.NONVALIDATING);
|
||||
saxBuilder.setEntityResolver(RESOLVER);
|
||||
|
||||
//
|
||||
|
|
|
@ -67,11 +67,11 @@ public class XmlReader extends Reader {
|
|||
private static final String UTF_16LE = "UTF-16LE";
|
||||
private static final String UTF_16 = "UTF-16";
|
||||
|
||||
private static String _staticDefaultEncoding = null;
|
||||
private static String staticDefaultEncoding = null;
|
||||
|
||||
private Reader _reader;
|
||||
private String _encoding;
|
||||
private final String _defaultEncoding;
|
||||
private Reader reader;
|
||||
private String encoding;
|
||||
private final String defaultEncoding;
|
||||
|
||||
/**
|
||||
* Sets the default encoding to use if none is set in HTTP content-type, XML
|
||||
|
@ -85,7 +85,7 @@ public class XmlReader extends Reader {
|
|||
* @param encoding charset encoding to default to.
|
||||
*/
|
||||
public static void setDefaultEncoding(final String encoding) {
|
||||
_staticDefaultEncoding = encoding;
|
||||
staticDefaultEncoding = encoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -98,7 +98,7 @@ public class XmlReader extends Reader {
|
|||
* @return the default encoding to use.
|
||||
*/
|
||||
public static String getDefaultEncoding() {
|
||||
return _staticDefaultEncoding;
|
||||
return staticDefaultEncoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -167,7 +167,7 @@ public class XmlReader extends Reader {
|
|||
*
|
||||
*/
|
||||
public XmlReader(final InputStream is, final boolean lenient, final String defaultEncoding) throws IOException, XmlReaderException {
|
||||
this._defaultEncoding = defaultEncoding == null ? _staticDefaultEncoding : defaultEncoding;
|
||||
this.defaultEncoding = defaultEncoding == null ? staticDefaultEncoding : defaultEncoding;
|
||||
try {
|
||||
doRawStream(is, lenient);
|
||||
} catch (final XmlReaderException ex) {
|
||||
|
@ -255,7 +255,7 @@ public class XmlReader extends Reader {
|
|||
*
|
||||
*/
|
||||
public XmlReader(final URLConnection conn) throws IOException {
|
||||
this._defaultEncoding = _staticDefaultEncoding;
|
||||
defaultEncoding = staticDefaultEncoding;
|
||||
final boolean lenient = true;
|
||||
if (conn instanceof HttpURLConnection) {
|
||||
try {
|
||||
|
@ -338,7 +338,7 @@ public class XmlReader extends Reader {
|
|||
*/
|
||||
public XmlReader(final InputStream is, final String httpContentType, final boolean lenient, final String defaultEncoding) throws IOException,
|
||||
XmlReaderException {
|
||||
this._defaultEncoding = defaultEncoding == null ? _staticDefaultEncoding : defaultEncoding;
|
||||
this.defaultEncoding = defaultEncoding == null ? staticDefaultEncoding : defaultEncoding;
|
||||
try {
|
||||
doHttpStream(is, httpContentType, lenient);
|
||||
} catch (final XmlReaderException ex) {
|
||||
|
@ -407,7 +407,7 @@ public class XmlReader extends Reader {
|
|||
encoding = ex.getContentTypeEncoding();
|
||||
}
|
||||
if (encoding == null) {
|
||||
encoding = this._defaultEncoding == null ? UTF_8 : this._defaultEncoding;
|
||||
encoding = defaultEncoding == null ? UTF_8 : defaultEncoding;
|
||||
}
|
||||
prepareReader(ex.getInputStream(), encoding);
|
||||
}
|
||||
|
@ -421,12 +421,12 @@ public class XmlReader extends Reader {
|
|||
*
|
||||
*/
|
||||
public String getEncoding() {
|
||||
return this._encoding;
|
||||
return encoding;
|
||||
}
|
||||
|
||||
@Override
|
||||
public int read(final char[] buf, final int offset, final int len) throws IOException {
|
||||
return this._reader.read(buf, offset, len);
|
||||
return reader.read(buf, offset, len);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -438,7 +438,7 @@ public class XmlReader extends Reader {
|
|||
*/
|
||||
@Override
|
||||
public void close() throws IOException {
|
||||
this._reader.close();
|
||||
reader.close();
|
||||
}
|
||||
|
||||
private void doRawStream(final InputStream is, final boolean lenient) throws IOException {
|
||||
|
@ -462,8 +462,8 @@ public class XmlReader extends Reader {
|
|||
}
|
||||
|
||||
private void prepareReader(final InputStream is, final String encoding) throws IOException {
|
||||
this._reader = new InputStreamReader(is, encoding);
|
||||
this._encoding = encoding;
|
||||
reader = new InputStreamReader(is, encoding);
|
||||
this.encoding = encoding;
|
||||
}
|
||||
|
||||
// InputStream is passed for XmlReaderException creation only
|
||||
|
@ -471,7 +471,7 @@ public class XmlReader extends Reader {
|
|||
String encoding;
|
||||
if (bomEnc == null) {
|
||||
if (xmlGuessEnc == null || xmlEnc == null) {
|
||||
encoding = this._defaultEncoding == null ? UTF_8 : this._defaultEncoding;
|
||||
encoding = defaultEncoding == null ? UTF_8 : defaultEncoding;
|
||||
} else if (xmlEnc.equals(UTF_16) && (xmlGuessEnc.equals(UTF_16BE) || xmlGuessEnc.equals(UTF_16LE))) {
|
||||
encoding = xmlGuessEnc;
|
||||
} else {
|
||||
|
@ -513,7 +513,7 @@ public class XmlReader extends Reader {
|
|||
if (appXml) {
|
||||
encoding = calculateRawEncoding(bomEnc, xmlGuessEnc, xmlEnc, is);
|
||||
} else {
|
||||
encoding = this._defaultEncoding == null ? US_ASCII : this._defaultEncoding;
|
||||
encoding = defaultEncoding == null ? US_ASCII : defaultEncoding;
|
||||
}
|
||||
} else if (bomEnc != null && (cTEnc.equals(UTF_16BE) || cTEnc.equals(UTF_16LE))) {
|
||||
throw new XmlReaderException(HTTP_EX_1.format(new Object[] { cTMime, cTEnc, bomEnc, xmlGuessEnc, xmlEnc }), cTMime, cTEnc, bomEnc,
|
||||
|
|
|
@ -18,12 +18,12 @@ import java.io.InputStream;
|
|||
*
|
||||
*/
|
||||
public class XmlReaderException extends IOException {
|
||||
private final String _bomEncoding;
|
||||
private final String _xmlGuessEncoding;
|
||||
private final String _xmlEncoding;
|
||||
private final String _contentTypeMime;
|
||||
private final String _contentTypeEncoding;
|
||||
private final InputStream _is;
|
||||
private final String bomEncoding;
|
||||
private final String xmlGuessEncoding;
|
||||
private final String xmlEncoding;
|
||||
private final String contentTypeMime;
|
||||
private final String contentTypeEncoding;
|
||||
private final InputStream is;
|
||||
|
||||
/**
|
||||
* Creates an exception instance if the charset encoding could not be
|
||||
|
@ -62,12 +62,12 @@ public class XmlReaderException extends IOException {
|
|||
public XmlReaderException(final String msg, final String ctMime, final String ctEnc, final String bomEnc, final String xmlGuessEnc, final String xmlEnc,
|
||||
final InputStream is) {
|
||||
super(msg);
|
||||
this._contentTypeMime = ctMime;
|
||||
this._contentTypeEncoding = ctEnc;
|
||||
this._bomEncoding = bomEnc;
|
||||
this._xmlGuessEncoding = xmlGuessEnc;
|
||||
this._xmlEncoding = xmlEnc;
|
||||
this._is = is;
|
||||
contentTypeMime = ctMime;
|
||||
contentTypeEncoding = ctEnc;
|
||||
bomEncoding = bomEnc;
|
||||
xmlGuessEncoding = xmlGuessEnc;
|
||||
xmlEncoding = xmlEnc;
|
||||
this.is = is;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -78,7 +78,7 @@ public class XmlReaderException extends IOException {
|
|||
*
|
||||
*/
|
||||
public String getBomEncoding() {
|
||||
return this._bomEncoding;
|
||||
return bomEncoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -89,7 +89,7 @@ public class XmlReaderException extends IOException {
|
|||
*
|
||||
*/
|
||||
public String getXmlGuessEncoding() {
|
||||
return this._xmlGuessEncoding;
|
||||
return xmlGuessEncoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -100,7 +100,7 @@ public class XmlReaderException extends IOException {
|
|||
*
|
||||
*/
|
||||
public String getXmlEncoding() {
|
||||
return this._xmlEncoding;
|
||||
return xmlEncoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -113,7 +113,7 @@ public class XmlReaderException extends IOException {
|
|||
*
|
||||
*/
|
||||
public String getContentTypeMime() {
|
||||
return this._contentTypeMime;
|
||||
return contentTypeMime;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -127,7 +127,7 @@ public class XmlReaderException extends IOException {
|
|||
*
|
||||
*/
|
||||
public String getContentTypeEncoding() {
|
||||
return this._contentTypeEncoding;
|
||||
return contentTypeEncoding;
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -139,6 +139,6 @@ public class XmlReaderException extends IOException {
|
|||
*
|
||||
*/
|
||||
public InputStream getInputStream() {
|
||||
return this._is;
|
||||
return is;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -46,7 +46,7 @@ public class Atom03Generator extends BaseWireFeedGenerator {
|
|||
private static final String ATOM_03_URI = "http://purl.org/atom/ns#";
|
||||
private static final Namespace ATOM_NS = Namespace.getNamespace(ATOM_03_URI);
|
||||
|
||||
private final String _version;
|
||||
private final String version;
|
||||
|
||||
public Atom03Generator() {
|
||||
this("atom_0.3", "0.3");
|
||||
|
@ -54,11 +54,11 @@ public class Atom03Generator extends BaseWireFeedGenerator {
|
|||
|
||||
protected Atom03Generator(final String type, final String version) {
|
||||
super(type);
|
||||
this._version = version;
|
||||
this.version = version;
|
||||
}
|
||||
|
||||
protected String getVersion() {
|
||||
return this._version;
|
||||
return version;
|
||||
}
|
||||
|
||||
protected Namespace getFeedNamespace() {
|
||||
|
|
|
@ -53,7 +53,7 @@ public class Atom10Generator extends BaseWireFeedGenerator {
|
|||
private static final String ATOM_10_URI = "http://www.w3.org/2005/Atom";
|
||||
private static final Namespace ATOM_NS = Namespace.getNamespace(ATOM_10_URI);
|
||||
|
||||
private final String _version;
|
||||
private final String version;
|
||||
|
||||
public Atom10Generator() {
|
||||
this("atom_1.0", "1.0");
|
||||
|
@ -61,11 +61,11 @@ public class Atom10Generator extends BaseWireFeedGenerator {
|
|||
|
||||
protected Atom10Generator(final String type, final String version) {
|
||||
super(type);
|
||||
this._version = version;
|
||||
this.version = version;
|
||||
}
|
||||
|
||||
protected String getVersion() {
|
||||
return this._version;
|
||||
return version;
|
||||
}
|
||||
|
||||
protected Namespace getFeedNamespace() {
|
||||
|
|
|
@ -31,55 +31,55 @@ public abstract class BaseWireFeedGenerator implements WireFeedGenerator {
|
|||
*/
|
||||
private static final String PERSON_MODULE_GENERATORS_POSFIX_KEY = ".person.ModuleGenerator.classes";
|
||||
|
||||
private final String _type;
|
||||
private final ModuleGenerators _feedModuleGenerators;
|
||||
private final ModuleGenerators _itemModuleGenerators;
|
||||
private final ModuleGenerators _personModuleGenerators;
|
||||
private final Namespace[] _allModuleNamespaces;
|
||||
private final String type;
|
||||
private final ModuleGenerators feedModuleGenerators;
|
||||
private final ModuleGenerators itemModuleGenerators;
|
||||
private final ModuleGenerators personModuleGenerators;
|
||||
private final Namespace[] allModuleNamespaces;
|
||||
|
||||
protected BaseWireFeedGenerator(final String type) {
|
||||
this._type = type;
|
||||
this._feedModuleGenerators = new ModuleGenerators(type + FEED_MODULE_GENERATORS_POSFIX_KEY, this);
|
||||
this._itemModuleGenerators = new ModuleGenerators(type + ITEM_MODULE_GENERATORS_POSFIX_KEY, this);
|
||||
this._personModuleGenerators = new ModuleGenerators(type + PERSON_MODULE_GENERATORS_POSFIX_KEY, this);
|
||||
this.type = type;
|
||||
feedModuleGenerators = new ModuleGenerators(type + FEED_MODULE_GENERATORS_POSFIX_KEY, this);
|
||||
itemModuleGenerators = new ModuleGenerators(type + ITEM_MODULE_GENERATORS_POSFIX_KEY, this);
|
||||
personModuleGenerators = new ModuleGenerators(type + PERSON_MODULE_GENERATORS_POSFIX_KEY, this);
|
||||
final Set allModuleNamespaces = new HashSet();
|
||||
Iterator i = this._feedModuleGenerators.getAllNamespaces().iterator();
|
||||
Iterator i = feedModuleGenerators.getAllNamespaces().iterator();
|
||||
while (i.hasNext()) {
|
||||
allModuleNamespaces.add(i.next());
|
||||
}
|
||||
i = this._itemModuleGenerators.getAllNamespaces().iterator();
|
||||
i = itemModuleGenerators.getAllNamespaces().iterator();
|
||||
while (i.hasNext()) {
|
||||
allModuleNamespaces.add(i.next());
|
||||
}
|
||||
i = this._personModuleGenerators.getAllNamespaces().iterator();
|
||||
i = personModuleGenerators.getAllNamespaces().iterator();
|
||||
while (i.hasNext()) {
|
||||
allModuleNamespaces.add(i.next());
|
||||
}
|
||||
this._allModuleNamespaces = new Namespace[allModuleNamespaces.size()];
|
||||
allModuleNamespaces.toArray(this._allModuleNamespaces);
|
||||
this.allModuleNamespaces = new Namespace[allModuleNamespaces.size()];
|
||||
allModuleNamespaces.toArray(this.allModuleNamespaces);
|
||||
}
|
||||
|
||||
@Override
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
protected void generateModuleNamespaceDefs(final Element root) {
|
||||
for (final Namespace _allModuleNamespace : this._allModuleNamespaces) {
|
||||
for (final Namespace _allModuleNamespace : allModuleNamespaces) {
|
||||
root.addNamespaceDeclaration(_allModuleNamespace);
|
||||
}
|
||||
}
|
||||
|
||||
protected void generateFeedModules(final List modules, final Element feed) {
|
||||
this._feedModuleGenerators.generateModules(modules, feed);
|
||||
feedModuleGenerators.generateModules(modules, feed);
|
||||
}
|
||||
|
||||
public void generateItemModules(final List modules, final Element item) {
|
||||
this._itemModuleGenerators.generateModules(modules, item);
|
||||
itemModuleGenerators.generateModules(modules, item);
|
||||
}
|
||||
|
||||
public void generatePersonModules(final List modules, final Element person) {
|
||||
this._personModuleGenerators.generateModules(modules, person);
|
||||
personModuleGenerators.generateModules(modules, person);
|
||||
}
|
||||
|
||||
protected void generateForeignMarkup(final Element e, final List foreignMarkup) {
|
||||
|
|
|
@ -35,18 +35,18 @@ public abstract class BaseWireFeedParser implements WireFeedParser {
|
|||
*/
|
||||
private static final String PERSON_MODULE_PARSERS_POSFIX_KEY = ".person.ModuleParser.classes";
|
||||
|
||||
private final String _type;
|
||||
private final ModuleParsers _feedModuleParsers;
|
||||
private final ModuleParsers _itemModuleParsers;
|
||||
private final ModuleParsers _personModuleParsers;
|
||||
private final Namespace _namespace;
|
||||
private final String type;
|
||||
private final ModuleParsers feedModuleParsers;
|
||||
private final ModuleParsers itemModuleParsers;
|
||||
private final ModuleParsers personModuleParsers;
|
||||
private final Namespace namespace;
|
||||
|
||||
protected BaseWireFeedParser(final String type, final Namespace namespace) {
|
||||
this._type = type;
|
||||
this._namespace = namespace;
|
||||
this._feedModuleParsers = new ModuleParsers(type + FEED_MODULE_PARSERS_POSFIX_KEY, this);
|
||||
this._itemModuleParsers = new ModuleParsers(type + ITEM_MODULE_PARSERS_POSFIX_KEY, this);
|
||||
this._personModuleParsers = new ModuleParsers(type + PERSON_MODULE_PARSERS_POSFIX_KEY, this);
|
||||
this.type = type;
|
||||
this.namespace = namespace;
|
||||
feedModuleParsers = new ModuleParsers(type + FEED_MODULE_PARSERS_POSFIX_KEY, this);
|
||||
itemModuleParsers = new ModuleParsers(type + ITEM_MODULE_PARSERS_POSFIX_KEY, this);
|
||||
personModuleParsers = new ModuleParsers(type + PERSON_MODULE_PARSERS_POSFIX_KEY, this);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -60,19 +60,19 @@ public abstract class BaseWireFeedParser implements WireFeedParser {
|
|||
*/
|
||||
@Override
|
||||
public String getType() {
|
||||
return this._type;
|
||||
return type;
|
||||
}
|
||||
|
||||
protected List<Module> parseFeedModules(final Element feedElement) {
|
||||
return this._feedModuleParsers.parseModules(feedElement);
|
||||
return feedModuleParsers.parseModules(feedElement);
|
||||
}
|
||||
|
||||
protected List<Module> parseItemModules(final Element itemElement) {
|
||||
return this._itemModuleParsers.parseModules(itemElement);
|
||||
return itemModuleParsers.parseModules(itemElement);
|
||||
}
|
||||
|
||||
protected List<Module> parsePersonModules(final Element itemElement) {
|
||||
return this._personModuleParsers.parseModules(itemElement);
|
||||
return personModuleParsers.parseModules(itemElement);
|
||||
}
|
||||
|
||||
protected List<Element> extractForeignMarkup(final Element e, final Extendable ext, final Namespace basens) {
|
||||
|
@ -103,7 +103,7 @@ public abstract class BaseWireFeedParser implements WireFeedParser {
|
|||
protected Attribute getAttribute(final Element e, final String attributeName) {
|
||||
Attribute attribute = e.getAttribute(attributeName);
|
||||
if (attribute == null) {
|
||||
attribute = e.getAttribute(attributeName, this._namespace);
|
||||
attribute = e.getAttribute(attributeName, namespace);
|
||||
}
|
||||
return attribute;
|
||||
}
|
||||
|
|
|
@ -29,7 +29,7 @@ import com.sun.syndication.io.ModuleGenerator;
|
|||
/**
|
||||
*/
|
||||
public class ModuleGenerators extends PluginManager {
|
||||
private Set _allNamespaces;
|
||||
private Set allNamespaces;
|
||||
|
||||
public ModuleGenerators(final String propertyKey, final BaseWireFeedGenerator parentGenerator) {
|
||||
super(propertyKey, null, parentGenerator);
|
||||
|
@ -61,14 +61,14 @@ public class ModuleGenerators extends PluginManager {
|
|||
}
|
||||
|
||||
public Set getAllNamespaces() {
|
||||
if (this._allNamespaces == null) {
|
||||
this._allNamespaces = new HashSet();
|
||||
if (allNamespaces == null) {
|
||||
allNamespaces = new HashSet();
|
||||
final List mUris = getModuleNamespaces();
|
||||
for (int i = 0; i < mUris.size(); i++) {
|
||||
final ModuleGenerator mGen = getGenerator((String) mUris.get(i));
|
||||
this._allNamespaces.addAll(mGen.getNamespaces());
|
||||
allNamespaces.addAll(mGen.getNamespaces());
|
||||
}
|
||||
}
|
||||
return this._allNamespaces;
|
||||
return allNamespaces;
|
||||
}
|
||||
}
|
||||
|
|
|
@ -35,12 +35,12 @@ import com.sun.syndication.io.WireFeedParser;
|
|||
*
|
||||
*/
|
||||
public abstract class PluginManager {
|
||||
private final String[] _propertyValues;
|
||||
private Map _pluginsMap;
|
||||
private List _pluginsList;
|
||||
private final List _keys;
|
||||
private final WireFeedParser _parentParser;
|
||||
private final WireFeedGenerator _parentGenerator;
|
||||
private final String[] propertyValues;
|
||||
private Map pluginsMap;
|
||||
private List pluginsList;
|
||||
private final List keys;
|
||||
private final WireFeedParser parentParser;
|
||||
private final WireFeedGenerator parentGenerator;
|
||||
|
||||
/**
|
||||
* Creates a PluginManager
|
||||
|
@ -54,39 +54,39 @@ public abstract class PluginManager {
|
|||
}
|
||||
|
||||
protected PluginManager(final String propertyKey, final WireFeedParser parentParser, final WireFeedGenerator parentGenerator) {
|
||||
this._parentParser = parentParser;
|
||||
this._parentGenerator = parentGenerator;
|
||||
this._propertyValues = PropertiesLoader.getPropertiesLoader().getTokenizedProperty(propertyKey, ", ");
|
||||
this.parentParser = parentParser;
|
||||
this.parentGenerator = parentGenerator;
|
||||
propertyValues = PropertiesLoader.getPropertiesLoader().getTokenizedProperty(propertyKey, ", ");
|
||||
loadPlugins();
|
||||
this._pluginsMap = Collections.unmodifiableMap(this._pluginsMap);
|
||||
this._pluginsList = Collections.unmodifiableList(this._pluginsList);
|
||||
this._keys = Collections.unmodifiableList(new ArrayList(this._pluginsMap.keySet()));
|
||||
pluginsMap = Collections.unmodifiableMap(pluginsMap);
|
||||
pluginsList = Collections.unmodifiableList(pluginsList);
|
||||
keys = Collections.unmodifiableList(new ArrayList(pluginsMap.keySet()));
|
||||
}
|
||||
|
||||
protected abstract String getKey(Object obj);
|
||||
|
||||
protected List getKeys() {
|
||||
return this._keys;
|
||||
return keys;
|
||||
}
|
||||
|
||||
protected List getPlugins() {
|
||||
return this._pluginsList;
|
||||
return pluginsList;
|
||||
}
|
||||
|
||||
protected Map getPluginMap() {
|
||||
return this._pluginsMap;
|
||||
return pluginsMap;
|
||||
}
|
||||
|
||||
protected Object getPlugin(final String key) {
|
||||
return this._pluginsMap.get(key);
|
||||
return pluginsMap.get(key);
|
||||
}
|
||||
|
||||
// PRIVATE - LOADER PART
|
||||
|
||||
private void loadPlugins() {
|
||||
final List finalPluginsList = new ArrayList();
|
||||
this._pluginsList = new ArrayList();
|
||||
this._pluginsMap = new HashMap();
|
||||
pluginsList = new ArrayList();
|
||||
pluginsMap = new HashMap();
|
||||
String className = null;
|
||||
try {
|
||||
final Class[] classes = getClasses();
|
||||
|
@ -94,24 +94,24 @@ public abstract class PluginManager {
|
|||
className = classe.getName();
|
||||
final Object plugin = classe.newInstance();
|
||||
if (plugin instanceof DelegatingModuleParser) {
|
||||
((DelegatingModuleParser) plugin).setFeedParser(this._parentParser);
|
||||
((DelegatingModuleParser) plugin).setFeedParser(parentParser);
|
||||
}
|
||||
if (plugin instanceof DelegatingModuleGenerator) {
|
||||
((DelegatingModuleGenerator) plugin).setFeedGenerator(this._parentGenerator);
|
||||
((DelegatingModuleGenerator) plugin).setFeedGenerator(parentGenerator);
|
||||
}
|
||||
|
||||
this._pluginsMap.put(getKey(plugin), plugin);
|
||||
this._pluginsList.add(plugin); // to preserve the order of
|
||||
// definition
|
||||
pluginsMap.put(getKey(plugin), plugin);
|
||||
pluginsList.add(plugin); // to preserve the order of
|
||||
// definition
|
||||
// in the rome.properties files
|
||||
}
|
||||
Iterator i = this._pluginsMap.values().iterator();
|
||||
Iterator i = pluginsMap.values().iterator();
|
||||
while (i.hasNext()) {
|
||||
finalPluginsList.add(i.next()); // to remove overridden plugin
|
||||
// impls
|
||||
}
|
||||
|
||||
i = this._pluginsList.iterator();
|
||||
i = pluginsList.iterator();
|
||||
while (i.hasNext()) {
|
||||
final Object plugin = i.next();
|
||||
if (!finalPluginsList.contains(plugin)) {
|
||||
|
@ -144,7 +144,7 @@ public abstract class PluginManager {
|
|||
final ClassLoader classLoader = Thread.currentThread().getContextClassLoader();
|
||||
final List classes = new ArrayList();
|
||||
final boolean useLoadClass = Boolean.valueOf(System.getProperty("rome.pluginmanager.useloadclass", "false")).booleanValue();
|
||||
for (final String _propertyValue : this._propertyValues) {
|
||||
for (final String _propertyValue : propertyValues) {
|
||||
final Class mClass = useLoadClass ? classLoader.loadClass(_propertyValue) : Class.forName(_propertyValue, true, classLoader);
|
||||
classes.add(mClass);
|
||||
}
|
||||
|
|
|
@ -56,7 +56,7 @@ public class PropertiesLoader {
|
|||
}
|
||||
}
|
||||
|
||||
private final Properties[] _properties;
|
||||
private final Properties[] properties;
|
||||
|
||||
/**
|
||||
* Creates a PropertiesLoader.
|
||||
|
@ -100,8 +100,8 @@ public class PropertiesLoader {
|
|||
propertiesList.add(p);
|
||||
}
|
||||
|
||||
this._properties = new Properties[propertiesList.size()];
|
||||
propertiesList.toArray(this._properties);
|
||||
properties = new Properties[propertiesList.size()];
|
||||
propertiesList.toArray(properties);
|
||||
}
|
||||
|
||||
/**
|
||||
|
@ -119,8 +119,8 @@ public class PropertiesLoader {
|
|||
*/
|
||||
public String[] getTokenizedProperty(final String key, final String separator) {
|
||||
final List<String> entriesList = new ArrayList<String>();
|
||||
for (final Properties _propertie : this._properties) {
|
||||
final String values = _propertie.getProperty(key);
|
||||
for (final Properties property : properties) {
|
||||
final String values = property.getProperty(key);
|
||||
if (values != null) {
|
||||
final StringTokenizer st = new StringTokenizer(values, separator);
|
||||
while (st.hasMoreTokens()) {
|
||||
|
@ -147,8 +147,8 @@ public class PropertiesLoader {
|
|||
*/
|
||||
public String[] getProperty(final String key) {
|
||||
final List<String> entriesList = new ArrayList<String>();
|
||||
for (final Properties _propertie : this._properties) {
|
||||
final String values = _propertie.getProperty(key);
|
||||
for (final Properties property : properties) {
|
||||
final String values = property.getProperty(key);
|
||||
if (values != null) {
|
||||
entriesList.add(values);
|
||||
}
|
||||
|
|
|
@ -28,7 +28,7 @@ import org.jdom2.Element;
|
|||
*
|
||||
*/
|
||||
public class RSS091NetscapeGenerator extends RSS091UserlandGenerator {
|
||||
private String _version;
|
||||
private String version;
|
||||
|
||||
public RSS091NetscapeGenerator() {
|
||||
this("rss_0.91N", "0.91");
|
||||
|
|
|
@ -38,7 +38,7 @@ import com.sun.syndication.io.FeedException;
|
|||
*
|
||||
*/
|
||||
public class RSS091UserlandGenerator extends RSS090Generator {
|
||||
private final String _version;
|
||||
private final String version;
|
||||
|
||||
public RSS091UserlandGenerator() {
|
||||
this("rss_0.91U", "0.91");
|
||||
|
@ -46,7 +46,7 @@ public class RSS091UserlandGenerator extends RSS090Generator {
|
|||
|
||||
protected RSS091UserlandGenerator(final String type, final String version) {
|
||||
super(type);
|
||||
this._version = version;
|
||||
this.version = version;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -62,7 +62,7 @@ public class RSS091UserlandGenerator extends RSS090Generator {
|
|||
}
|
||||
|
||||
protected String getVersion() {
|
||||
return this._version;
|
||||
return version;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -33,14 +33,14 @@ public class XmlFixerReader extends Reader {
|
|||
public XmlFixerReader(final Reader in) {
|
||||
super(in);
|
||||
this.in = in;
|
||||
this._buffer = new StringBuffer();
|
||||
this._state = 0;
|
||||
buffer = new StringBuffer();
|
||||
state = 0;
|
||||
}
|
||||
|
||||
private boolean trimmed;
|
||||
private final StringBuffer _buffer;
|
||||
private int _bufferPos;
|
||||
private int _state = 0;
|
||||
private final StringBuffer buffer;
|
||||
private int bufferPos;
|
||||
private int state = 0;
|
||||
|
||||
private boolean trimStream() throws IOException {
|
||||
boolean hasContent = true;
|
||||
|
@ -50,7 +50,7 @@ public class XmlFixerReader extends Reader {
|
|||
do {
|
||||
switch (state) {
|
||||
case 0:
|
||||
c = this.in.read();
|
||||
c = in.read();
|
||||
if (c == -1) {
|
||||
loop = false;
|
||||
hasContent = false;
|
||||
|
@ -58,114 +58,114 @@ public class XmlFixerReader extends Reader {
|
|||
loop = true;
|
||||
} else if (c == '<') {
|
||||
state = 1;
|
||||
this._buffer.setLength(0);
|
||||
this._bufferPos = 0;
|
||||
this._buffer.append((char) c);
|
||||
buffer.setLength(0);
|
||||
bufferPos = 0;
|
||||
buffer.append((char) c);
|
||||
loop = true;
|
||||
} else {
|
||||
this._buffer.setLength(0);
|
||||
this._bufferPos = 0;
|
||||
this._buffer.append((char) c);
|
||||
buffer.setLength(0);
|
||||
bufferPos = 0;
|
||||
buffer.append((char) c);
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
}
|
||||
break;
|
||||
case 1:
|
||||
c = this.in.read();
|
||||
c = in.read();
|
||||
if (c == -1) {
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
} else if (c != '!') {
|
||||
this._buffer.append((char) c);
|
||||
this._state = 3;
|
||||
buffer.append((char) c);
|
||||
this.state = 3;
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
} else {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
state = 2;
|
||||
loop = true;
|
||||
}
|
||||
break;
|
||||
case 2:
|
||||
c = this.in.read();
|
||||
c = in.read();
|
||||
if (c == -1) {
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
} else if (c == '-') {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
state = 3;
|
||||
loop = true;
|
||||
} else {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
}
|
||||
break;
|
||||
case 3:
|
||||
c = this.in.read();
|
||||
c = in.read();
|
||||
if (c == -1) {
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
} else if (c == '-') {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
state = 4;
|
||||
loop = true;
|
||||
} else {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
}
|
||||
break;
|
||||
case 4:
|
||||
c = this.in.read();
|
||||
c = in.read();
|
||||
if (c == -1) {
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
} else if (c != '-') {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
loop = true;
|
||||
} else {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
state = 5;
|
||||
loop = true;
|
||||
}
|
||||
break;
|
||||
case 5:
|
||||
c = this.in.read();
|
||||
c = in.read();
|
||||
if (c == -1) {
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
} else if (c != '-') {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
loop = true;
|
||||
state = 4;
|
||||
} else {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
state = 6;
|
||||
loop = true;
|
||||
}
|
||||
break;
|
||||
case 6:
|
||||
c = this.in.read();
|
||||
c = in.read();
|
||||
if (c == -1) {
|
||||
loop = false;
|
||||
hasContent = true;
|
||||
this._state = 3;
|
||||
this.state = 3;
|
||||
} else if (c != '>') {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
loop = true;
|
||||
state = 4;
|
||||
} else {
|
||||
this._buffer.setLength(0);
|
||||
buffer.setLength(0);
|
||||
state = 0;
|
||||
loop = true;
|
||||
}
|
||||
|
@ -180,24 +180,24 @@ public class XmlFixerReader extends Reader {
|
|||
@Override
|
||||
public int read() throws IOException {
|
||||
boolean loop;
|
||||
if (!this.trimmed) { // trims XML stream
|
||||
this.trimmed = true;
|
||||
if (!trimmed) { // trims XML stream
|
||||
trimmed = true;
|
||||
if (!trimStream()) {
|
||||
return -1;
|
||||
}
|
||||
}
|
||||
int c;
|
||||
do { // converts literal entities to coded entities
|
||||
switch (this._state) {
|
||||
switch (state) {
|
||||
case 0: // reading chars from stream
|
||||
c = this.in.read();
|
||||
c = in.read();
|
||||
if (c > -1) {
|
||||
if (c == '&') {
|
||||
this._state = 1;
|
||||
this._buffer.setLength(0);
|
||||
this._bufferPos = 0;
|
||||
this._buffer.append((char) c);
|
||||
this._state = 1;
|
||||
state = 1;
|
||||
buffer.setLength(0);
|
||||
bufferPos = 0;
|
||||
buffer.append((char) c);
|
||||
state = 1;
|
||||
loop = true;
|
||||
} else {
|
||||
loop = false;
|
||||
|
@ -207,49 +207,49 @@ public class XmlFixerReader extends Reader {
|
|||
}
|
||||
break;
|
||||
case 1: // reading entity from stream
|
||||
c = this.in.read();
|
||||
c = in.read();
|
||||
if (c > -1) {
|
||||
if (c == ';') {
|
||||
this._buffer.append((char) c);
|
||||
this._state = 2;
|
||||
buffer.append((char) c);
|
||||
state = 2;
|
||||
loop = true;
|
||||
} else if (c >= 'a' && c <= 'z' || c >= 'A' && c <= 'Z' || c == '#' || c >= '0' && c <= '9') {
|
||||
this._buffer.append((char) c);
|
||||
buffer.append((char) c);
|
||||
loop = true;
|
||||
} else {
|
||||
// no ';' to match the '&' lets just make the '&'
|
||||
// a legal xml character entity '&'
|
||||
this._buffer.insert(1, "amp;");
|
||||
this._buffer.append((char) c);
|
||||
this._state = 3;
|
||||
buffer.insert(1, "amp;");
|
||||
buffer.append((char) c);
|
||||
state = 3;
|
||||
loop = true;
|
||||
}
|
||||
} else {
|
||||
// no ';' to match the '&' lets just make the '&'
|
||||
// a legal xml character entity '&'
|
||||
this._buffer.insert(1, "amp;");
|
||||
this._state = 3;
|
||||
buffer.insert(1, "amp;");
|
||||
state = 3;
|
||||
loop = true;
|
||||
}
|
||||
break;
|
||||
case 2: // replacing entity
|
||||
c = 0;
|
||||
final String literalEntity = this._buffer.toString();
|
||||
final String literalEntity = buffer.toString();
|
||||
final String codedEntity = CODED_ENTITIES.get(literalEntity);
|
||||
if (codedEntity != null) {
|
||||
this._buffer.setLength(0);
|
||||
this._buffer.append(codedEntity);
|
||||
buffer.setLength(0);
|
||||
buffer.append(codedEntity);
|
||||
} // else we leave what was in the stream
|
||||
this._state = 3;
|
||||
state = 3;
|
||||
loop = true;
|
||||
break;
|
||||
case 3: // consuming buffer
|
||||
if (this._bufferPos < this._buffer.length()) {
|
||||
c = this._buffer.charAt(this._bufferPos++);
|
||||
if (bufferPos < buffer.length()) {
|
||||
c = buffer.charAt(bufferPos++);
|
||||
loop = false;
|
||||
} else {
|
||||
c = 0;
|
||||
this._state = 0;
|
||||
state = 0;
|
||||
loop = true;
|
||||
}
|
||||
break;
|
||||
|
@ -292,7 +292,7 @@ public class XmlFixerReader extends Reader {
|
|||
|
||||
@Override
|
||||
public boolean ready() throws IOException {
|
||||
return this._state != 0 || this.in.ready();
|
||||
return state != 0 || in.ready();
|
||||
}
|
||||
|
||||
@Override
|
||||
|
@ -312,7 +312,7 @@ public class XmlFixerReader extends Reader {
|
|||
|
||||
@Override
|
||||
public void close() throws IOException {
|
||||
this.in.close();
|
||||
in.close();
|
||||
}
|
||||
|
||||
private static Map<String, String> CODED_ENTITIES = new HashMap<String, String>();
|
||||
|
|
|
@ -19,19 +19,19 @@ import com.sun.syndication.io.WireFeedInput;
|
|||
*
|
||||
*/
|
||||
public abstract class FeedTest extends TestCase {
|
||||
private final String _feedFileName;
|
||||
private Document _jDomDoc = null;
|
||||
private WireFeed _wireFeed = null;
|
||||
private SyndFeed _syndFeed = null;
|
||||
private final String feedFileName;
|
||||
private Document jDomDoc = null;
|
||||
private WireFeed wireFeed = null;
|
||||
private SyndFeed syndFeed = null;
|
||||
|
||||
private boolean preservingWireFeed = false;
|
||||
|
||||
protected FeedTest(final String feedFileName) {
|
||||
this._feedFileName = feedFileName;
|
||||
this.feedFileName = feedFileName;
|
||||
}
|
||||
|
||||
protected String getFeedFileName() {
|
||||
return this._feedFileName;
|
||||
return feedFileName;
|
||||
}
|
||||
|
||||
protected Reader getFeedReader() throws Exception {
|
||||
|
@ -57,26 +57,26 @@ public abstract class FeedTest extends TestCase {
|
|||
}
|
||||
|
||||
protected Document getCachedJDomDoc() throws Exception {
|
||||
if (this._jDomDoc == null) {
|
||||
this._jDomDoc = getJDomDoc();
|
||||
if (jDomDoc == null) {
|
||||
jDomDoc = getJDomDoc();
|
||||
}
|
||||
return this._jDomDoc;
|
||||
return jDomDoc;
|
||||
}
|
||||
|
||||
protected WireFeed getCachedWireFeed() throws Exception {
|
||||
if (this._wireFeed == null) {
|
||||
this._wireFeed = getWireFeed();
|
||||
if (wireFeed == null) {
|
||||
wireFeed = getWireFeed();
|
||||
}
|
||||
return this._wireFeed;
|
||||
return wireFeed;
|
||||
}
|
||||
|
||||
protected SyndFeed getCachedSyndFeed(final boolean preserveWireFeed) throws Exception {
|
||||
|
||||
if (this._syndFeed == null || this.preservingWireFeed != preserveWireFeed) {
|
||||
this._syndFeed = getSyndFeed(preserveWireFeed);
|
||||
this.preservingWireFeed = preserveWireFeed;
|
||||
if (syndFeed == null || preservingWireFeed != preserveWireFeed) {
|
||||
syndFeed = getSyndFeed(preserveWireFeed);
|
||||
preservingWireFeed = preserveWireFeed;
|
||||
}
|
||||
return this._syndFeed;
|
||||
return syndFeed;
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -18,7 +18,7 @@ import com.sun.syndication.io.impl.DateParser;
|
|||
*
|
||||
*/
|
||||
public abstract class SyndFeedTest extends FeedTest {
|
||||
private String _prefix = null;
|
||||
private String prefix = null;
|
||||
|
||||
protected SyndFeedTest(final String feedType) {
|
||||
this(feedType, feedType + ".xml");
|
||||
|
@ -26,11 +26,11 @@ public abstract class SyndFeedTest extends FeedTest {
|
|||
|
||||
protected SyndFeedTest(final String feedType, final String feedFileName) {
|
||||
super(feedFileName);
|
||||
this._prefix = feedType;
|
||||
prefix = feedType;
|
||||
}
|
||||
|
||||
protected String getPrefix() {
|
||||
return this._prefix;
|
||||
return prefix;
|
||||
}
|
||||
|
||||
protected void assertProperty(final String property, final String value) {
|
||||
|
@ -38,7 +38,7 @@ public abstract class SyndFeedTest extends FeedTest {
|
|||
}
|
||||
|
||||
protected void assertEqualsStr(final String expected, final String actual) {
|
||||
assertEquals(this._prefix + "." + expected, actual);
|
||||
assertEquals(prefix + "." + expected, actual);
|
||||
}
|
||||
|
||||
public void testPreserveWireFeed() throws Exception {
|
||||
|
|
|
@ -6,24 +6,24 @@ import com.sun.syndication.io.impl.Base64;
|
|||
|
||||
public class TestBase64 extends TestCase {
|
||||
|
||||
private void _testEncodeDecode(final String s) {
|
||||
private void testEncodeDecode(final String s) {
|
||||
final String encoded = Base64.encode(s);
|
||||
final String decoded = Base64.decode(encoded);
|
||||
assertEquals(s, decoded);
|
||||
}
|
||||
|
||||
public void testEncodeDecode() {
|
||||
_testEncodeDecode("");
|
||||
_testEncodeDecode("A");
|
||||
_testEncodeDecode("AB");
|
||||
_testEncodeDecode("ABC");
|
||||
_testEncodeDecode("ABCD");
|
||||
_testEncodeDecode("ABCDE");
|
||||
_testEncodeDecode("&");
|
||||
_testEncodeDecode("a&");
|
||||
_testEncodeDecode("ab&");
|
||||
_testEncodeDecode("abc&");
|
||||
_testEncodeDecode("abcd&");
|
||||
testEncodeDecode("");
|
||||
testEncodeDecode("A");
|
||||
testEncodeDecode("AB");
|
||||
testEncodeDecode("ABC");
|
||||
testEncodeDecode("ABCD");
|
||||
testEncodeDecode("ABCDE");
|
||||
testEncodeDecode("&");
|
||||
testEncodeDecode("a&");
|
||||
testEncodeDecode("ab&");
|
||||
testEncodeDecode("abc&");
|
||||
testEncodeDecode("abcd&");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -52,7 +52,7 @@ public class TestSyndFeedAtom03 extends SyndFeedTest {
|
|||
assertEquals(this.getCachedSyndFeed().getPublishedDate(), d);
|
||||
}
|
||||
|
||||
protected void _testEntry(final int i) throws Exception {
|
||||
protected void testEntry(final int i) throws Exception {
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
assertProperty(entry.getTitle(), "feed.entry[" + i + "].title");
|
||||
|
@ -66,11 +66,11 @@ public class TestSyndFeedAtom03 extends SyndFeedTest {
|
|||
}
|
||||
|
||||
public void testEntry0() throws Exception {
|
||||
_testEntry(0);
|
||||
testEntry(0);
|
||||
}
|
||||
|
||||
public void testEntry1() throws Exception {
|
||||
_testEntry(1);
|
||||
testEntry(1);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -43,10 +43,10 @@ public class TestSyndFeedAtom03DCSyModules extends TestSyndFeedAtom03 {
|
|||
|
||||
public void testFeedDCModule() throws Exception {
|
||||
final DCModule dc = (DCModule) this.getCachedSyndFeed().getModule(DCModule.URI);
|
||||
_testDCModule(dc, "feed.", false, 0);
|
||||
testDCModule(dc, "feed.", false, 0);
|
||||
}
|
||||
|
||||
protected void _testDCModule(final DCModule dc, final String prefix, final boolean isEntry, final int index) throws Exception {
|
||||
protected void testDCModule(final DCModule dc, final String prefix, final boolean isEntry, final int index) throws Exception {
|
||||
assertNotNull(dc);
|
||||
assertProperty(dc.getTitle(), prefix + "dc:title");
|
||||
|
||||
|
@ -98,15 +98,15 @@ public class TestSyndFeedAtom03DCSyModules extends TestSyndFeedAtom03 {
|
|||
}
|
||||
|
||||
public void testEntriesDCModule() throws Exception {
|
||||
_testEntryDCModule(0);
|
||||
_testEntryDCModule(1);
|
||||
testEntryDCModule(0);
|
||||
testEntryDCModule(1);
|
||||
}
|
||||
|
||||
protected void _testEntryDCModule(final int i) throws Exception {
|
||||
protected void testEntryDCModule(final int i) throws Exception {
|
||||
final List<SyndEntry> entries = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = entries.get(i);
|
||||
final DCModule dc = (DCModule) entry.getModule(DCModule.URI);
|
||||
_testDCModule(dc, "feed.entry[" + i + "].", true, i);
|
||||
testDCModule(dc, "feed.entry[" + i + "].", true, i);
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -73,7 +73,7 @@ public class TestSyndFeedAtom10 extends TestSyndFeedAtom03 {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected void _testEntry(final int i) throws Exception {
|
||||
protected void testEntry(final int i) throws Exception {
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
|
||||
|
@ -111,12 +111,12 @@ public class TestSyndFeedAtom10 extends TestSyndFeedAtom03 {
|
|||
|
||||
@Override
|
||||
public void testEntry0() throws Exception {
|
||||
_testEntry(0);
|
||||
testEntry(0);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void testEntry1() throws Exception {
|
||||
_testEntry(1);
|
||||
testEntry(1);
|
||||
}
|
||||
|
||||
@Override
|
||||
|
|
|
@ -53,24 +53,24 @@ public class TestSyndFeedRSS090 extends SyndFeedTest {
|
|||
assertProperty(this.getCachedSyndFeed().getImage().getLink(), "image.link");
|
||||
}
|
||||
|
||||
protected void _testItem(final int i) throws Exception {
|
||||
protected void testItem(final int i) throws Exception {
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
assertProperty(entry.getTitle(), "item[" + i + "].title");
|
||||
assertProperty(entry.getLink(), "item[" + i + "].link");
|
||||
|
||||
_testUri(entry, i);
|
||||
testUri(entry, i);
|
||||
}
|
||||
|
||||
public void testItem0() throws Exception {
|
||||
_testItem(0);
|
||||
testItem(0);
|
||||
}
|
||||
|
||||
public void testItem1() throws Exception {
|
||||
_testItem(1);
|
||||
testItem(1);
|
||||
}
|
||||
|
||||
protected void _testUri(final SyndEntry entry, final int i) throws Exception {
|
||||
protected void testUri(final SyndEntry entry, final int i) throws Exception {
|
||||
assertProperty(entry.getUri(), "item[" + i + "].link");
|
||||
}
|
||||
|
||||
|
|
|
@ -63,7 +63,7 @@ public class TestSyndFeedRSS091N extends SyndFeedTest {
|
|||
assertProperty(this.getCachedSyndFeed().getImage().getDescription(), "channel.image.description");
|
||||
}
|
||||
|
||||
protected void _testItem(final int i) throws Exception {
|
||||
protected void testItem(final int i) throws Exception {
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
assertProperty(entry.getTitle(), "channel.item[" + i + "].title");
|
||||
|
@ -71,7 +71,7 @@ public class TestSyndFeedRSS091N extends SyndFeedTest {
|
|||
assertProperty(entry.getDescription().getValue(), "channel.item[" + i + "].description");
|
||||
}
|
||||
|
||||
protected void _testUri(final SyndEntry entry, final int i) throws Exception {
|
||||
protected void testUri(final SyndEntry entry, final int i) throws Exception {
|
||||
assertProperty(entry.getUri(), "channel.item[" + i + "].link");
|
||||
}
|
||||
|
||||
|
|
|
@ -31,19 +31,19 @@ public class TestSyndFeedRSS092 extends TestSyndFeedRSS091N {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected void _testItem(final int i) throws Exception {
|
||||
super._testItem(i);
|
||||
protected void testItem(final int i) throws Exception {
|
||||
super.testItem(i);
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
|
||||
assertProperty(entry.getTitle(), "channel.item[" + i + "].title");
|
||||
assertProperty(entry.getLink(), "channel.item[" + i + "].link");
|
||||
assertProperty(entry.getDescription().getValue(), "channel.item[" + i + "].description");
|
||||
_testCategories(entry.getCategories(), "channel.item[" + i + "]");
|
||||
_testEnclosures(entry.getEnclosures(), "channel.item[" + i + "]");
|
||||
testCategories(entry.getCategories(), "channel.item[" + i + "]");
|
||||
testEnclosures(entry.getEnclosures(), "channel.item[" + i + "]");
|
||||
}
|
||||
|
||||
protected void _testCategories(final List<SyndCategory> cats, final String prefix) throws Exception {
|
||||
protected void testCategories(final List<SyndCategory> cats, final String prefix) throws Exception {
|
||||
final Set<String> s1 = new HashSet<String>();
|
||||
final Set<String> s2 = new HashSet<String>();
|
||||
for (int i = 0; i < cats.size(); i++) {
|
||||
|
@ -54,7 +54,7 @@ public class TestSyndFeedRSS092 extends TestSyndFeedRSS091N {
|
|||
assertTrue(s1.equals(s2));
|
||||
}
|
||||
|
||||
protected void _testEnclosures(final List<SyndEnclosure> encs, final String prefix) throws Exception {
|
||||
protected void testEnclosures(final List<SyndEnclosure> encs, final String prefix) throws Exception {
|
||||
final Set<String> s1 = new HashSet<String>();
|
||||
final Set<String> s2 = new HashSet<String>();
|
||||
for (int i = 0; i < encs.size(); i++) {
|
||||
|
|
|
@ -17,7 +17,7 @@ public class TestSyndFeedRSS092Alt extends TestSyndFeedRSS092 {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected void _testEnclosures(final List<SyndEnclosure> encs, final String prefix) throws Exception {
|
||||
protected void testEnclosures(final List<SyndEnclosure> encs, final String prefix) throws Exception {
|
||||
final Set<String> s1 = new HashSet<String>();
|
||||
final Set<String> s2 = new HashSet<String>();
|
||||
for (int i = 0; i < encs.size(); i++) {
|
||||
|
|
|
@ -29,16 +29,16 @@ public class TestSyndFeedRSS093 extends TestSyndFeedRSS092 {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected void _testItem(final int i) throws Exception {
|
||||
super._testItem(i);
|
||||
protected void testItem(final int i) throws Exception {
|
||||
super.testItem(i);
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
final Date d = DateParser.parseRFC822("Mon, 0" + (i + 1) + " Jan 2001 00:00:00 GMT");
|
||||
assertEquals(entry.getPublishedDate(), d);
|
||||
_testDescriptionType(entry, i);
|
||||
testDescriptionType(entry, i);
|
||||
}
|
||||
|
||||
protected void _testDescriptionType(final SyndEntry entry, final int i) throws Exception {
|
||||
protected void testDescriptionType(final SyndEntry entry, final int i) throws Exception {
|
||||
assertProperty(entry.getDescription().getType(), "channel.item[" + i + "].description^type");
|
||||
}
|
||||
|
||||
|
|
|
@ -26,16 +26,16 @@ public class TestSyndFeedRSS094 extends TestSyndFeedRSS093 {
|
|||
}
|
||||
|
||||
public void testCategories() throws Exception {
|
||||
_testCategories(this.getCachedSyndFeed().getCategories(), "channel");
|
||||
testCategories(this.getCachedSyndFeed().getCategories(), "channel");
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void _testDescriptionType(final SyndEntry entry, final int i) throws Exception {
|
||||
protected void testDescriptionType(final SyndEntry entry, final int i) throws Exception {
|
||||
}
|
||||
|
||||
@Override
|
||||
protected void _testItem(final int i) throws Exception {
|
||||
super._testItem(i);
|
||||
protected void testItem(final int i) throws Exception {
|
||||
super.testItem(i);
|
||||
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
|
@ -45,7 +45,7 @@ public class TestSyndFeedRSS094 extends TestSyndFeedRSS093 {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected void _testUri(final SyndEntry entry, final int i) throws Exception {
|
||||
protected void testUri(final SyndEntry entry, final int i) throws Exception {
|
||||
assertProperty(entry.getUri(), "channel.item[" + i + "].guid");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -31,8 +31,8 @@ public class TestSyndFeedRSS10 extends TestSyndFeedRSS090 {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected void _testItem(final int i) throws Exception {
|
||||
super._testItem(i);
|
||||
protected void testItem(final int i) throws Exception {
|
||||
super.testItem(i);
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
assertProperty(entry.getDescription().getValue(), "item[" + i + "].description");
|
||||
|
@ -40,7 +40,7 @@ public class TestSyndFeedRSS10 extends TestSyndFeedRSS090 {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected void _testUri(final SyndEntry entry, final int i) throws Exception {
|
||||
protected void testUri(final SyndEntry entry, final int i) throws Exception {
|
||||
assertProperty(entry.getUri(), "channel.items[" + i + "]^rdf:resource");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -29,10 +29,10 @@ public class TestSyndFeedRSS10DCMulti extends TestSyndFeedRSS10 {
|
|||
|
||||
public void testChannelDCModule() throws Exception {
|
||||
final DCModule dc = (DCModule) this.getCachedSyndFeed().getModule(DCModule.URI);
|
||||
_testDCModule(dc, "channel.");
|
||||
testDCModule(dc, "channel.");
|
||||
}
|
||||
|
||||
protected void _testDCModule(final DCModule dc, final String prefix) throws Exception {
|
||||
protected void testDCModule(final DCModule dc, final String prefix) throws Exception {
|
||||
assertNotNull(dc);
|
||||
|
||||
assertProperty(dc.getTitles().get(0), prefix + "dc:title[0]");
|
||||
|
@ -90,14 +90,14 @@ public class TestSyndFeedRSS10DCMulti extends TestSyndFeedRSS10 {
|
|||
}
|
||||
|
||||
public void testItemsDCModule() throws Exception {
|
||||
_testItemDCModule(0);
|
||||
_testItemDCModule(1);
|
||||
testItemDCModule(0);
|
||||
testItemDCModule(1);
|
||||
}
|
||||
|
||||
protected void _testItemDCModule(final int i) throws Exception {
|
||||
protected void testItemDCModule(final int i) throws Exception {
|
||||
final List<SyndEntry> entries = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = entries.get(i);
|
||||
final DCModule dc = (DCModule) entry.getModule(DCModule.URI);
|
||||
_testDCModule(dc, "item[" + i + "].");
|
||||
testDCModule(dc, "item[" + i + "].");
|
||||
}
|
||||
}
|
||||
|
|
|
@ -36,10 +36,10 @@ public class TestSyndFeedRSS10DCSyModules extends TestSyndFeedRSS10 {
|
|||
|
||||
public void testChannelDCModule() throws Exception {
|
||||
final DCModule dc = (DCModule) this.getCachedSyndFeed().getModule(DCModule.URI);
|
||||
_testDCModule(dc, "channel.");
|
||||
testDCModule(dc, "channel.");
|
||||
}
|
||||
|
||||
protected void _testDCModule(final DCModule dc, final String prefix) throws Exception {
|
||||
protected void testDCModule(final DCModule dc, final String prefix) throws Exception {
|
||||
assertNotNull(dc);
|
||||
assertProperty(dc.getTitle(), prefix + "dc:title");
|
||||
assertProperty(dc.getCreator(), prefix + "dc:creator");
|
||||
|
@ -79,15 +79,15 @@ public class TestSyndFeedRSS10DCSyModules extends TestSyndFeedRSS10 {
|
|||
}
|
||||
|
||||
public void testItemsDCModule() throws Exception {
|
||||
_testItemDCModule(0);
|
||||
_testItemDCModule(1);
|
||||
testItemDCModule(0);
|
||||
testItemDCModule(1);
|
||||
}
|
||||
|
||||
protected void _testItemDCModule(final int i) throws Exception {
|
||||
protected void testItemDCModule(final int i) throws Exception {
|
||||
final List<SyndEntry> entries = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = entries.get(i);
|
||||
final DCModule dc = (DCModule) entry.getModule(DCModule.URI);
|
||||
_testDCModule(dc, "item[" + i + "].");
|
||||
testDCModule(dc, "item[" + i + "].");
|
||||
|
||||
}
|
||||
|
||||
|
|
|
@ -30,8 +30,8 @@ public class TestSyndFeedRSS20 extends TestSyndFeedRSS094 {
|
|||
}
|
||||
|
||||
@Override
|
||||
protected void _testItem(final int i) throws Exception {
|
||||
super._testItem(i);
|
||||
protected void testItem(final int i) throws Exception {
|
||||
super.testItem(i);
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
assertProperty(entry.getContents().get(0).getValue(), "channel.item[" + i + "].content");
|
||||
|
|
|
@ -41,39 +41,39 @@ public class TestXmlFixerReader extends TestCase {
|
|||
private static final String XML_PROLOG = "<?xml version=\"1.0\" ?>";
|
||||
|
||||
public void testTrim() throws Exception {
|
||||
_testValidTrim("", "<hello></hello>");
|
||||
_testValidTrim("", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" ", "<hello></hello>");
|
||||
_testValidTrim(" ", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" \n", "<hello></hello>");
|
||||
_testValidTrim(" \n", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim("<!-- - -- -->", "<hello></hello>");
|
||||
_testValidTrim("<!-- - -- -->", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- -->", "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- -->", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> ", "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> <!-- - -- --> ", "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> \n <!-- - -- --> ", "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> \n <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim("", "<hello></hello>");
|
||||
testValidTrim("", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" ", "<hello></hello>");
|
||||
testValidTrim(" ", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" \n", "<hello></hello>");
|
||||
testValidTrim(" \n", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim("<!-- - -- -->", "<hello></hello>");
|
||||
testValidTrim("<!-- - -- -->", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- -->", "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- -->", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> ", "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> <!-- - -- --> ", "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> \n <!-- - -- --> ", "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> \n <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
|
||||
_testInvalidTrim("x", "<hello></hello>");
|
||||
_testInvalidTrim("x", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" x", "<hello></hello>");
|
||||
_testInvalidTrim(" x", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" x\n", "<hello></hello>");
|
||||
_testInvalidTrim(" x\n", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim("<!-- - -- - ->", "<hello></hello>");
|
||||
_testInvalidTrim("<!-- - -- - ->", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- -- >", "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- -- >", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- -->x ", "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- -->x ", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- --> x <!-- - -- --> ", "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- --> x <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- --> x\n <!-- - -- --> ", "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- --> x\n <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim("x", "<hello></hello>");
|
||||
testInvalidTrim("x", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" x", "<hello></hello>");
|
||||
testInvalidTrim(" x", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" x\n", "<hello></hello>");
|
||||
testInvalidTrim(" x\n", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim("<!-- - -- - ->", "<hello></hello>");
|
||||
testInvalidTrim("<!-- - -- - ->", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- -- >", "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- -- >", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- -->x ", "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- -->x ", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- --> x <!-- - -- --> ", "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- --> x <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- --> x\n <!-- - -- --> ", "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- --> x\n <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
}
|
||||
|
||||
public void testAmpHandling() throws Exception {
|
||||
|
@ -85,40 +85,40 @@ public class TestXmlFixerReader extends TestCase {
|
|||
}
|
||||
|
||||
public void testHtmlEntities() throws Exception {
|
||||
_testValidEntities("<hello></hello>");
|
||||
_testValidEntities(XML_PROLOG + "<hello></hello>");
|
||||
_testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello></hello>");
|
||||
testValidEntities("<hello></hello>");
|
||||
testValidEntities(XML_PROLOG + "<hello></hello>");
|
||||
testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello></hello>");
|
||||
|
||||
_testValidEntities("<hello>'¥ú¥</hello>");
|
||||
_testValidEntities(XML_PROLOG + "<hello>'¥ú¥</hello>");
|
||||
_testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'¥ú¥</hello>");
|
||||
testValidEntities("<hello>'¥ú¥</hello>");
|
||||
testValidEntities(XML_PROLOG + "<hello>'¥ú¥</hello>");
|
||||
testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'¥ú¥</hello>");
|
||||
|
||||
_testValidEntities("<hello>ΠΡ#913;Ρ</hello>");
|
||||
_testValidEntities(XML_PROLOG + "<hello>ΠΡΑΡ</hello>");
|
||||
_testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>ΠΡΑΡ</hello>");
|
||||
testValidEntities("<hello>ΠΡ#913;Ρ</hello>");
|
||||
testValidEntities(XML_PROLOG + "<hello>ΠΡΑΡ</hello>");
|
||||
testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>ΠΡΑΡ</hello>");
|
||||
|
||||
_testValidEntities("<hello>Œ—–—</hello>");
|
||||
_testValidEntities(XML_PROLOG + "<hello>Œ—–—</hello>");
|
||||
_testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>Œ—–—</hello>");
|
||||
testValidEntities("<hello>Œ—–—</hello>");
|
||||
testValidEntities(XML_PROLOG + "<hello>Œ—–—</hello>");
|
||||
testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>Œ—–—</hello>");
|
||||
|
||||
_testInvalidEntities("<hello>'&yexn;ú¥</hello>");
|
||||
_testInvalidEntities(XML_PROLOG + "<hello>'&yexn;ú¥</hello>");
|
||||
_testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'&yexn;ú¥</hello>");
|
||||
testInvalidEntities("<hello>'&yexn;ú¥</hello>");
|
||||
testInvalidEntities(XML_PROLOG + "<hello>'&yexn;ú¥</hello>");
|
||||
testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'&yexn;ú¥</hello>");
|
||||
|
||||
_testInvalidEntities("<hello>Π&Rhox;#913;Ρ</hello>");
|
||||
_testInvalidEntities(XML_PROLOG + "<hello>Π&Rhox;ΑΡ</hello>");
|
||||
_testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>Π&Rhox;ΑΡ</hello>");
|
||||
testInvalidEntities("<hello>Π&Rhox;#913;Ρ</hello>");
|
||||
testInvalidEntities(XML_PROLOG + "<hello>Π&Rhox;ΑΡ</hello>");
|
||||
testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>Π&Rhox;ΑΡ</hello>");
|
||||
|
||||
_testInvalidEntities("<hello>'¥x50;¥</hello>");
|
||||
_testInvalidEntities(XML_PROLOG + "<hello>'¥x50;¥</hello>");
|
||||
_testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'¥x50;¥</hello>");
|
||||
testInvalidEntities("<hello>'¥x50;¥</hello>");
|
||||
testInvalidEntities(XML_PROLOG + "<hello>'¥x50;¥</hello>");
|
||||
testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'¥x50;¥</hello>");
|
||||
|
||||
_testInvalidEntities("<hello>ΠΡ	x13;Ρ</hello>");
|
||||
_testInvalidEntities(XML_PROLOG + "<hello>ΠΡ	x13;Ρ</hello>");
|
||||
_testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>ΠΡ	x13;Ρ</hello>");
|
||||
testInvalidEntities("<hello>ΠΡ	x13;Ρ</hello>");
|
||||
testInvalidEntities(XML_PROLOG + "<hello>ΠΡ	x13;Ρ</hello>");
|
||||
testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>ΠΡ	x13;Ρ</hello>");
|
||||
}
|
||||
|
||||
protected void _testXmlParse(final String garbish, final String xmlDoc) throws Exception {
|
||||
protected void testXmlParse(final String garbish, final String xmlDoc) throws Exception {
|
||||
final InputStream is = getStream(garbish, xmlDoc);
|
||||
Reader reader = new XmlReader(is);
|
||||
reader = new XmlFixerReader(reader);
|
||||
|
@ -126,25 +126,25 @@ public class TestXmlFixerReader extends TestCase {
|
|||
saxBuilder.build(reader);
|
||||
}
|
||||
|
||||
protected void _testValidTrim(final String garbish, final String xmlDoc) throws Exception {
|
||||
_testXmlParse(garbish, xmlDoc);
|
||||
protected void testValidTrim(final String garbish, final String xmlDoc) throws Exception {
|
||||
testXmlParse(garbish, xmlDoc);
|
||||
}
|
||||
|
||||
protected void _testInvalidTrim(final String garbish, final String xmlDoc) throws Exception {
|
||||
protected void testInvalidTrim(final String garbish, final String xmlDoc) throws Exception {
|
||||
try {
|
||||
_testXmlParse(garbish, xmlDoc);
|
||||
testXmlParse(garbish, xmlDoc);
|
||||
assertTrue(false);
|
||||
} catch (final Exception ex) {
|
||||
}
|
||||
}
|
||||
|
||||
protected void _testValidEntities(final String xmlDoc) throws Exception {
|
||||
_testXmlParse("", xmlDoc);
|
||||
protected void testValidEntities(final String xmlDoc) throws Exception {
|
||||
testXmlParse("", xmlDoc);
|
||||
}
|
||||
|
||||
protected void _testInvalidEntities(final String xmlDoc) throws Exception {
|
||||
protected void testInvalidEntities(final String xmlDoc) throws Exception {
|
||||
try {
|
||||
_testXmlParse("", xmlDoc);
|
||||
testXmlParse("", xmlDoc);
|
||||
assertTrue(false);
|
||||
} catch (final Exception ex) {
|
||||
}
|
||||
|
|
|
@ -48,7 +48,7 @@ public class TestXmlReader extends TestCase {
|
|||
test.testHttp();
|
||||
}
|
||||
|
||||
protected void _testRawNoBomValid(final String encoding) throws Exception {
|
||||
protected void testRawNoBomValid(final String encoding) throws Exception {
|
||||
InputStream is = getXmlStream("no-bom", XML1, encoding, encoding);
|
||||
XmlReader xmlReader = new XmlReader(is, false);
|
||||
assertEquals(xmlReader.getEncoding(), "UTF-8");
|
||||
|
@ -70,7 +70,7 @@ public class TestXmlReader extends TestCase {
|
|||
assertEquals(xmlReader.getEncoding(), encoding);
|
||||
}
|
||||
|
||||
protected void _testRawNoBomInvalid(final String encoding) throws Exception {
|
||||
protected void testRawNoBomInvalid(final String encoding) throws Exception {
|
||||
final InputStream is = getXmlStream("no-bom", XML3, encoding, encoding);
|
||||
try {
|
||||
final XmlReader xmlReader = new XmlReader(is, false);
|
||||
|
@ -81,12 +81,12 @@ public class TestXmlReader extends TestCase {
|
|||
}
|
||||
|
||||
public void testRawNoBom() throws Exception {
|
||||
_testRawNoBomValid("US-ASCII");
|
||||
_testRawNoBomValid("UTF-8");
|
||||
_testRawNoBomValid("ISO-8859-1");
|
||||
testRawNoBomValid("US-ASCII");
|
||||
testRawNoBomValid("UTF-8");
|
||||
testRawNoBomValid("ISO-8859-1");
|
||||
}
|
||||
|
||||
protected void _testRawBomValid(final String encoding) throws Exception {
|
||||
protected void testRawBomValid(final String encoding) throws Exception {
|
||||
final InputStream is = getXmlStream(encoding + "-bom", XML3, encoding, encoding);
|
||||
final XmlReader xmlReader = new XmlReader(is, false);
|
||||
if (!encoding.equals("UTF-16")) {
|
||||
|
@ -96,7 +96,7 @@ public class TestXmlReader extends TestCase {
|
|||
}
|
||||
}
|
||||
|
||||
protected void _testRawBomInvalid(final String bomEnc, final String streamEnc, final String prologEnc) throws Exception {
|
||||
protected void testRawBomInvalid(final String bomEnc, final String streamEnc, final String prologEnc) throws Exception {
|
||||
final InputStream is = getXmlStream(bomEnc, XML3, streamEnc, prologEnc);
|
||||
try {
|
||||
final XmlReader xmlReader = new XmlReader(is, false);
|
||||
|
@ -107,83 +107,83 @@ public class TestXmlReader extends TestCase {
|
|||
}
|
||||
|
||||
public void testRawBom() throws Exception {
|
||||
_testRawBomValid("UTF-8");
|
||||
_testRawBomValid("UTF-16BE");
|
||||
_testRawBomValid("UTF-16LE");
|
||||
_testRawBomValid("UTF-16");
|
||||
testRawBomValid("UTF-8");
|
||||
testRawBomValid("UTF-16BE");
|
||||
testRawBomValid("UTF-16LE");
|
||||
testRawBomValid("UTF-16");
|
||||
|
||||
_testRawBomInvalid("UTF-8-bom", "US-ASCII", "US-ASCII");
|
||||
_testRawBomInvalid("UTF-8-bom", "ISO-8859-1", "ISO-8859-1");
|
||||
_testRawBomInvalid("UTF-8-bom", "UTF-8", "UTF-16");
|
||||
_testRawBomInvalid("UTF-8-bom", "UTF-8", "UTF-16BE");
|
||||
_testRawBomInvalid("UTF-8-bom", "UTF-8", "UTF-16LE");
|
||||
_testRawBomInvalid("UTF-16BE-bom", "UTF-16BE", "UTF-16LE");
|
||||
_testRawBomInvalid("UTF-16LE-bom", "UTF-16LE", "UTF-16BE");
|
||||
_testRawBomInvalid("UTF-16LE-bom", "UTF-16LE", "UTF-8");
|
||||
testRawBomInvalid("UTF-8-bom", "US-ASCII", "US-ASCII");
|
||||
testRawBomInvalid("UTF-8-bom", "ISO-8859-1", "ISO-8859-1");
|
||||
testRawBomInvalid("UTF-8-bom", "UTF-8", "UTF-16");
|
||||
testRawBomInvalid("UTF-8-bom", "UTF-8", "UTF-16BE");
|
||||
testRawBomInvalid("UTF-8-bom", "UTF-8", "UTF-16LE");
|
||||
testRawBomInvalid("UTF-16BE-bom", "UTF-16BE", "UTF-16LE");
|
||||
testRawBomInvalid("UTF-16LE-bom", "UTF-16LE", "UTF-16BE");
|
||||
testRawBomInvalid("UTF-16LE-bom", "UTF-16LE", "UTF-8");
|
||||
}
|
||||
|
||||
public void testHttp() throws Exception {
|
||||
_testHttpValid("application/xml", "no-bom", "US-ASCII", null);
|
||||
_testHttpValid("application/xml", "UTF-8-bom", "US-ASCII", null);
|
||||
_testHttpValid("application/xml", "UTF-8-bom", "UTF-8", null);
|
||||
_testHttpValid("application/xml", "UTF-8-bom", "UTF-8", "UTF-8");
|
||||
_testHttpValid("application/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", null);
|
||||
_testHttpValid("application/xml;charset=\"UTF-8\"", "UTF-8-bom", "UTF-8", null);
|
||||
_testHttpValid("application/xml;charset='UTF-8'", "UTF-8-bom", "UTF-8", null);
|
||||
_testHttpValid("application/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", "UTF-8");
|
||||
_testHttpValid("application/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", null);
|
||||
_testHttpValid("application/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16");
|
||||
_testHttpValid("application/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE");
|
||||
testHttpValid("application/xml", "no-bom", "US-ASCII", null);
|
||||
testHttpValid("application/xml", "UTF-8-bom", "US-ASCII", null);
|
||||
testHttpValid("application/xml", "UTF-8-bom", "UTF-8", null);
|
||||
testHttpValid("application/xml", "UTF-8-bom", "UTF-8", "UTF-8");
|
||||
testHttpValid("application/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", null);
|
||||
testHttpValid("application/xml;charset=\"UTF-8\"", "UTF-8-bom", "UTF-8", null);
|
||||
testHttpValid("application/xml;charset='UTF-8'", "UTF-8-bom", "UTF-8", null);
|
||||
testHttpValid("application/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", "UTF-8");
|
||||
testHttpValid("application/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", null);
|
||||
testHttpValid("application/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16");
|
||||
testHttpValid("application/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE");
|
||||
|
||||
_testHttpInvalid("application/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", null);
|
||||
_testHttpInvalid("application/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16");
|
||||
_testHttpInvalid("application/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE");
|
||||
_testHttpInvalid("application/xml", "UTF-8-bom", "US-ASCII", "US-ASCII");
|
||||
_testHttpInvalid("application/xml;charset=UTF-16", "UTF-16LE", "UTF-8", "UTF-8");
|
||||
_testHttpInvalid("application/xml;charset=UTF-16", "no-bom", "UTF-16BE", "UTF-16BE");
|
||||
testHttpInvalid("application/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", null);
|
||||
testHttpInvalid("application/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16");
|
||||
testHttpInvalid("application/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE");
|
||||
testHttpInvalid("application/xml", "UTF-8-bom", "US-ASCII", "US-ASCII");
|
||||
testHttpInvalid("application/xml;charset=UTF-16", "UTF-16LE", "UTF-8", "UTF-8");
|
||||
testHttpInvalid("application/xml;charset=UTF-16", "no-bom", "UTF-16BE", "UTF-16BE");
|
||||
|
||||
_testHttpValid("text/xml", "no-bom", "US-ASCII", null);
|
||||
_testHttpValid("text/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", "UTF-8");
|
||||
_testHttpValid("text/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", null);
|
||||
_testHttpValid("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", null);
|
||||
_testHttpValid("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16");
|
||||
_testHttpValid("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE");
|
||||
_testHttpValid("text/xml", "UTF-8-bom", "US-ASCII", null);
|
||||
testHttpValid("text/xml", "no-bom", "US-ASCII", null);
|
||||
testHttpValid("text/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", "UTF-8");
|
||||
testHttpValid("text/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", null);
|
||||
testHttpValid("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", null);
|
||||
testHttpValid("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16");
|
||||
testHttpValid("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE");
|
||||
testHttpValid("text/xml", "UTF-8-bom", "US-ASCII", null);
|
||||
|
||||
_testAlternateDefaultEncoding("application/xml", "UTF-8-bom", "UTF-8", null, null);
|
||||
_testAlternateDefaultEncoding("application/xml", "no-bom", "US-ASCII", null, "US-ASCII");
|
||||
_testAlternateDefaultEncoding("application/xml", "UTF-8-bom", "UTF-8", null, "UTF-8");
|
||||
_testAlternateDefaultEncoding("text/xml", "no-bom", "US-ASCII", null, null);
|
||||
_testAlternateDefaultEncoding("text/xml", "no-bom", "US-ASCII", null, "US-ASCII");
|
||||
_testAlternateDefaultEncoding("text/xml", "no-bom", "US-ASCII", null, "UTF-8");
|
||||
testAlternateDefaultEncoding("application/xml", "UTF-8-bom", "UTF-8", null, null);
|
||||
testAlternateDefaultEncoding("application/xml", "no-bom", "US-ASCII", null, "US-ASCII");
|
||||
testAlternateDefaultEncoding("application/xml", "UTF-8-bom", "UTF-8", null, "UTF-8");
|
||||
testAlternateDefaultEncoding("text/xml", "no-bom", "US-ASCII", null, null);
|
||||
testAlternateDefaultEncoding("text/xml", "no-bom", "US-ASCII", null, "US-ASCII");
|
||||
testAlternateDefaultEncoding("text/xml", "no-bom", "US-ASCII", null, "UTF-8");
|
||||
|
||||
_testHttpInvalid("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", null);
|
||||
_testHttpInvalid("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16");
|
||||
_testHttpInvalid("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE");
|
||||
_testHttpInvalid("text/xml;charset=UTF-16", "no-bom", "UTF-16BE", "UTF-16BE");
|
||||
_testHttpInvalid("text/xml;charset=UTF-16", "no-bom", "UTF-16BE", null);
|
||||
testHttpInvalid("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", null);
|
||||
testHttpInvalid("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16");
|
||||
testHttpInvalid("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE");
|
||||
testHttpInvalid("text/xml;charset=UTF-16", "no-bom", "UTF-16BE", "UTF-16BE");
|
||||
testHttpInvalid("text/xml;charset=UTF-16", "no-bom", "UTF-16BE", null);
|
||||
|
||||
_testHttpLenient("text/xml", "no-bom", "US-ASCII", null, "US-ASCII");
|
||||
_testHttpLenient("text/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", "UTF-8", "UTF-8");
|
||||
_testHttpLenient("text/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", null, "UTF-8");
|
||||
_testHttpLenient("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", null, "UTF-16BE");
|
||||
_testHttpLenient("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16", "UTF-16");
|
||||
_testHttpLenient("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE", "UTF-16BE");
|
||||
_testHttpLenient("text/xml", "UTF-8-bom", "US-ASCII", null, "US-ASCII");
|
||||
testHttpLenient("text/xml", "no-bom", "US-ASCII", null, "US-ASCII");
|
||||
testHttpLenient("text/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", "UTF-8", "UTF-8");
|
||||
testHttpLenient("text/xml;charset=UTF-8", "UTF-8-bom", "UTF-8", null, "UTF-8");
|
||||
testHttpLenient("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", null, "UTF-16BE");
|
||||
testHttpLenient("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16", "UTF-16");
|
||||
testHttpLenient("text/xml;charset=UTF-16", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE", "UTF-16BE");
|
||||
testHttpLenient("text/xml", "UTF-8-bom", "US-ASCII", null, "US-ASCII");
|
||||
|
||||
_testHttpLenient("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", null, "UTF-16BE");
|
||||
_testHttpLenient("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16", "UTF-16");
|
||||
_testHttpLenient("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE", "UTF-16BE");
|
||||
_testHttpLenient("text/xml;charset=UTF-16", "no-bom", "UTF-16BE", "UTF-16BE", "UTF-16BE");
|
||||
_testHttpLenient("text/xml;charset=UTF-16", "no-bom", "UTF-16BE", null, "UTF-16");
|
||||
testHttpLenient("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", null, "UTF-16BE");
|
||||
testHttpLenient("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16", "UTF-16");
|
||||
testHttpLenient("text/xml;charset=UTF-16BE", "UTF-16BE-bom", "UTF-16BE", "UTF-16BE", "UTF-16BE");
|
||||
testHttpLenient("text/xml;charset=UTF-16", "no-bom", "UTF-16BE", "UTF-16BE", "UTF-16BE");
|
||||
testHttpLenient("text/xml;charset=UTF-16", "no-bom", "UTF-16BE", null, "UTF-16");
|
||||
|
||||
_testHttpLenient("text/html", "no-bom", "US-ASCII", "US-ASCII", "US-ASCII");
|
||||
_testHttpLenient("text/html", "no-bom", "US-ASCII", null, "US-ASCII");
|
||||
_testHttpLenient("text/html;charset=UTF-8", "no-bom", "US-ASCII", "UTF-8", "UTF-8");
|
||||
_testHttpLenient("text/html;charset=UTF-16BE", "no-bom", "US-ASCII", "UTF-8", "UTF-8");
|
||||
testHttpLenient("text/html", "no-bom", "US-ASCII", "US-ASCII", "US-ASCII");
|
||||
testHttpLenient("text/html", "no-bom", "US-ASCII", null, "US-ASCII");
|
||||
testHttpLenient("text/html;charset=UTF-8", "no-bom", "US-ASCII", "UTF-8", "UTF-8");
|
||||
testHttpLenient("text/html;charset=UTF-16BE", "no-bom", "US-ASCII", "UTF-8", "UTF-8");
|
||||
}
|
||||
|
||||
public void _testAlternateDefaultEncoding(final String cT, final String bomEnc, final String streamEnc, final String prologEnc, final String alternateEnc)
|
||||
public void testAlternateDefaultEncoding(final String cT, final String bomEnc, final String streamEnc, final String prologEnc, final String alternateEnc)
|
||||
throws Exception {
|
||||
try {
|
||||
final InputStream is = getXmlStream(bomEnc, prologEnc == null ? XML1 : XML3, streamEnc, prologEnc);
|
||||
|
@ -201,7 +201,7 @@ public class TestXmlReader extends TestCase {
|
|||
}
|
||||
}
|
||||
|
||||
public void _testHttpValid(final String cT, final String bomEnc, final String streamEnc, final String prologEnc) throws Exception {
|
||||
public void testHttpValid(final String cT, final String bomEnc, final String streamEnc, final String prologEnc) throws Exception {
|
||||
final InputStream is = getXmlStream(bomEnc, prologEnc == null ? XML1 : XML3, streamEnc, prologEnc);
|
||||
final XmlReader xmlReader = new XmlReader(is, cT, false);
|
||||
if (!streamEnc.equals("UTF-16")) {
|
||||
|
@ -212,7 +212,7 @@ public class TestXmlReader extends TestCase {
|
|||
}
|
||||
}
|
||||
|
||||
protected void _testHttpInvalid(final String cT, final String bomEnc, final String streamEnc, final String prologEnc) throws Exception {
|
||||
protected void testHttpInvalid(final String cT, final String bomEnc, final String streamEnc, final String prologEnc) throws Exception {
|
||||
final InputStream is = getXmlStream(bomEnc, prologEnc == null ? XML2 : XML3, streamEnc, prologEnc);
|
||||
try {
|
||||
new XmlReader(is, cT, false);
|
||||
|
@ -222,7 +222,7 @@ public class TestXmlReader extends TestCase {
|
|||
}
|
||||
}
|
||||
|
||||
protected void _testHttpLenient(final String cT, final String bomEnc, final String streamEnc, final String prologEnc, final String shouldbe)
|
||||
protected void testHttpLenient(final String cT, final String bomEnc, final String streamEnc, final String prologEnc, final String shouldbe)
|
||||
throws Exception {
|
||||
final InputStream is = getXmlStream(bomEnc, prologEnc == null ? XML2 : XML3, streamEnc, prologEnc);
|
||||
final XmlReader xmlReader = new XmlReader(is, cT, true);
|
||||
|
|
|
@ -52,77 +52,77 @@ public class Issue1Test extends SyndFeedTest {
|
|||
}
|
||||
|
||||
public void testHtmlEntities() throws Exception {
|
||||
_testValidEntities("<hello></hello>");
|
||||
_testValidEntities(XML_PROLOG + "<hello></hello>");
|
||||
_testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello></hello>");
|
||||
testValidEntities("<hello></hello>");
|
||||
testValidEntities(XML_PROLOG + "<hello></hello>");
|
||||
testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello></hello>");
|
||||
|
||||
_testValidEntities("<hello>'¥ú¥</hello>");
|
||||
_testValidEntities(XML_PROLOG + "<hello>'¥ú¥</hello>");
|
||||
_testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'¥ú¥</hello>");
|
||||
testValidEntities("<hello>'¥ú¥</hello>");
|
||||
testValidEntities(XML_PROLOG + "<hello>'¥ú¥</hello>");
|
||||
testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'¥ú¥</hello>");
|
||||
|
||||
_testValidEntities("<hello>ΠΡ#913;Ρ</hello>");
|
||||
_testValidEntities(XML_PROLOG + "<hello>ΠΡΑΡ</hello>");
|
||||
_testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>ΠΡΑΡ</hello>");
|
||||
testValidEntities("<hello>ΠΡ#913;Ρ</hello>");
|
||||
testValidEntities(XML_PROLOG + "<hello>ΠΡΑΡ</hello>");
|
||||
testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>ΠΡΑΡ</hello>");
|
||||
|
||||
_testValidEntities("<hello>Œ—–—</hello>");
|
||||
_testValidEntities(XML_PROLOG + "<hello>Œ—–—</hello>");
|
||||
_testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>Œ—–—</hello>");
|
||||
testValidEntities("<hello>Œ—–—</hello>");
|
||||
testValidEntities(XML_PROLOG + "<hello>Œ—–—</hello>");
|
||||
testValidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>Œ—–—</hello>");
|
||||
|
||||
_testInvalidEntities("<hello>'&yexn;ú¥</hello>");
|
||||
_testInvalidEntities(XML_PROLOG + "<hello>'&yexn;ú¥</hello>");
|
||||
_testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'&yexn;ú¥</hello>");
|
||||
testInvalidEntities("<hello>'&yexn;ú¥</hello>");
|
||||
testInvalidEntities(XML_PROLOG + "<hello>'&yexn;ú¥</hello>");
|
||||
testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'&yexn;ú¥</hello>");
|
||||
|
||||
_testInvalidEntities("<hello>Π&Rhox;#913;Ρ</hello>");
|
||||
_testInvalidEntities(XML_PROLOG + "<hello>Π&Rhox;ΑΡ</hello>");
|
||||
_testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>Π&Rhox;ΑΡ</hello>");
|
||||
testInvalidEntities("<hello>Π&Rhox;#913;Ρ</hello>");
|
||||
testInvalidEntities(XML_PROLOG + "<hello>Π&Rhox;ΑΡ</hello>");
|
||||
testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>Π&Rhox;ΑΡ</hello>");
|
||||
|
||||
_testInvalidEntities("<hello>'¥x50;¥</hello>");
|
||||
_testInvalidEntities(XML_PROLOG + "<hello>'¥x50;¥</hello>");
|
||||
_testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'¥x50;¥</hello>");
|
||||
testInvalidEntities("<hello>'¥x50;¥</hello>");
|
||||
testInvalidEntities(XML_PROLOG + "<hello>'¥x50;¥</hello>");
|
||||
testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>'¥x50;¥</hello>");
|
||||
|
||||
_testInvalidEntities("<hello>ΠΡ	x13;Ρ</hello>");
|
||||
_testInvalidEntities(XML_PROLOG + "<hello>ΠΡ	x13;Ρ</hello>");
|
||||
_testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>ΠΡ	x13;Ρ</hello>");
|
||||
testInvalidEntities("<hello>ΠΡ	x13;Ρ</hello>");
|
||||
testInvalidEntities(XML_PROLOG + "<hello>ΠΡ	x13;Ρ</hello>");
|
||||
testInvalidEntities(" <!-- just in case -->\n" + XML_PROLOG + "<hello>ΠΡ	x13;Ρ</hello>");
|
||||
}
|
||||
|
||||
public void testTrim() throws Exception {
|
||||
_testValidTrim("", "<hello></hello>");
|
||||
_testValidTrim("", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" ", "<hello></hello>");
|
||||
_testValidTrim(" ", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" \n", "<hello></hello>");
|
||||
_testValidTrim(" \n", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim("<!-- - -- -->", "<hello></hello>");
|
||||
_testValidTrim("<!-- - -- -->", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- -->", "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- -->", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> ", "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> <!-- - -- --> ", "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> \n <!-- - -- --> ", "<hello></hello>");
|
||||
_testValidTrim(" <!-- - -- --> \n <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim("", "<hello></hello>");
|
||||
testValidTrim("", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" ", "<hello></hello>");
|
||||
testValidTrim(" ", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" \n", "<hello></hello>");
|
||||
testValidTrim(" \n", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim("<!-- - -- -->", "<hello></hello>");
|
||||
testValidTrim("<!-- - -- -->", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- -->", "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- -->", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> ", "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> <!-- - -- --> ", "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> \n <!-- - -- --> ", "<hello></hello>");
|
||||
testValidTrim(" <!-- - -- --> \n <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
|
||||
// TODO lorenzo.sm: This test was added to trim \r char (as with \n).
|
||||
// Source of "bad" RSS http://www.diariohorizonte.com/rss/71/deportes
|
||||
_testValidTrim("\r\n<!-- hackedString Clean-->", XML_PROLOG + "<hello></hello>");
|
||||
testValidTrim("\r\n<!-- hackedString Clean-->", XML_PROLOG + "<hello></hello>");
|
||||
|
||||
_testInvalidTrim("x", "<hello></hello>");
|
||||
_testInvalidTrim("x", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" x", "<hello></hello>");
|
||||
_testInvalidTrim(" x", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" x\n", "<hello></hello>");
|
||||
_testInvalidTrim(" x\n", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim("<!-- - -- - ->", "<hello></hello>");
|
||||
_testInvalidTrim("<!-- - -- - ->", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- -- >", "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- -- >", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- -->x ", "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- -->x ", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- --> x <!-- - -- --> ", "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- --> x <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- --> x\n <!-- - -- --> ", "<hello></hello>");
|
||||
_testInvalidTrim(" <!-- - -- --> x\n <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim("x", "<hello></hello>");
|
||||
testInvalidTrim("x", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" x", "<hello></hello>");
|
||||
testInvalidTrim(" x", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" x\n", "<hello></hello>");
|
||||
testInvalidTrim(" x\n", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim("<!-- - -- - ->", "<hello></hello>");
|
||||
testInvalidTrim("<!-- - -- - ->", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- -- >", "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- -- >", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- -->x ", "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- -->x ", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- --> x <!-- - -- --> ", "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- --> x <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- --> x\n <!-- - -- --> ", "<hello></hello>");
|
||||
testInvalidTrim(" <!-- - -- --> x\n <!-- - -- --> ", XML_PROLOG + "<hello></hello>");
|
||||
}
|
||||
|
||||
// XML Stream generator
|
||||
|
@ -136,31 +136,31 @@ public class Issue1Test extends SyndFeedTest {
|
|||
return new ByteArrayInputStream(baos.toByteArray());
|
||||
}
|
||||
|
||||
protected void _testInvalidEntities(final String xmlDoc) throws Exception {
|
||||
protected void testInvalidEntities(final String xmlDoc) throws Exception {
|
||||
try {
|
||||
_testXmlParse("", xmlDoc);
|
||||
testXmlParse("", xmlDoc);
|
||||
assertTrue(false);
|
||||
} catch (final Exception ex) {
|
||||
}
|
||||
}
|
||||
|
||||
protected void _testInvalidTrim(final String garbish, final String xmlDoc) throws Exception {
|
||||
protected void testInvalidTrim(final String garbish, final String xmlDoc) throws Exception {
|
||||
try {
|
||||
_testXmlParse(garbish, xmlDoc);
|
||||
testXmlParse(garbish, xmlDoc);
|
||||
assertTrue(false);
|
||||
} catch (final Exception ex) {
|
||||
}
|
||||
}
|
||||
|
||||
protected void _testValidEntities(final String xmlDoc) throws Exception {
|
||||
_testXmlParse("", xmlDoc);
|
||||
protected void testValidEntities(final String xmlDoc) throws Exception {
|
||||
testXmlParse("", xmlDoc);
|
||||
}
|
||||
|
||||
protected void _testValidTrim(final String garbish, final String xmlDoc) throws Exception {
|
||||
_testXmlParse(garbish, xmlDoc);
|
||||
protected void testValidTrim(final String garbish, final String xmlDoc) throws Exception {
|
||||
testXmlParse(garbish, xmlDoc);
|
||||
}
|
||||
|
||||
protected void _testXmlParse(final String garbish, final String xmlDoc) throws Exception {
|
||||
protected void testXmlParse(final String garbish, final String xmlDoc) throws Exception {
|
||||
final InputStream is = getStream(garbish, xmlDoc);
|
||||
Reader reader = new XmlReader(is);
|
||||
reader = new XmlFixerReader(reader);
|
||||
|
|
|
@ -29,14 +29,14 @@ import com.sun.syndication.unittest.TestSyndFeedRSS094;
|
|||
public class Issue2Test extends TestSyndFeedRSS094 {
|
||||
|
||||
@Override
|
||||
protected void _testItem(final int i) throws Exception {
|
||||
super._testItem(i);
|
||||
protected void testItem(final int i) throws Exception {
|
||||
super.testItem(i);
|
||||
final List<SyndEntry> items = this.getCachedSyndFeed().getEntries();
|
||||
final SyndEntry entry = items.get(i);
|
||||
_testComments(entry, i);
|
||||
testComments(entry, i);
|
||||
}
|
||||
|
||||
protected void _testComments(final SyndEntry entry, final int i) throws Exception {
|
||||
protected void testComments(final SyndEntry entry, final int i) throws Exception {
|
||||
assertProperty(entry.findRelatedLink("comments").getHref(), "rss_0.94.channel.item[" + i + "].comments");
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue