diff --git a/.settings/org.eclipse.jdt.core.prefs b/.settings/org.eclipse.jdt.core.prefs new file mode 100644 index 0000000..21a9ec6 --- /dev/null +++ b/.settings/org.eclipse.jdt.core.prefs @@ -0,0 +1,258 @@ +#Wed Aug 12 09:49:59 EDT 2009 +eclipse.preferences.version=1 +org.eclipse.jdt.core.formatter.align_type_members_on_columns=false +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_enum_constant=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_explicit_constructor_call=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_arguments_in_qualified_allocation_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_assignment=0 +org.eclipse.jdt.core.formatter.alignment_for_binary_expression=16 +org.eclipse.jdt.core.formatter.alignment_for_compact_if=16 +org.eclipse.jdt.core.formatter.alignment_for_conditional_expression=80 +org.eclipse.jdt.core.formatter.alignment_for_enum_constants=0 +org.eclipse.jdt.core.formatter.alignment_for_expressions_in_array_initializer=16 +org.eclipse.jdt.core.formatter.alignment_for_multiple_fields=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_parameters_in_method_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_selector_in_method_invocation=16 +org.eclipse.jdt.core.formatter.alignment_for_superclass_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_enum_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_superinterfaces_in_type_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_constructor_declaration=16 +org.eclipse.jdt.core.formatter.alignment_for_throws_clause_in_method_declaration=16 +org.eclipse.jdt.core.formatter.blank_lines_after_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_after_package=1 +org.eclipse.jdt.core.formatter.blank_lines_before_field=0 +org.eclipse.jdt.core.formatter.blank_lines_before_first_class_body_declaration=0 +org.eclipse.jdt.core.formatter.blank_lines_before_imports=1 +org.eclipse.jdt.core.formatter.blank_lines_before_member_type=1 +org.eclipse.jdt.core.formatter.blank_lines_before_method=1 +org.eclipse.jdt.core.formatter.blank_lines_before_new_chunk=1 +org.eclipse.jdt.core.formatter.blank_lines_before_package=0 +org.eclipse.jdt.core.formatter.blank_lines_between_import_groups=1 +org.eclipse.jdt.core.formatter.blank_lines_between_type_declarations=1 +org.eclipse.jdt.core.formatter.brace_position_for_annotation_type_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_anonymous_type_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_array_initializer=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_block=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_block_in_case=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_constructor_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_constant=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_enum_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_method_declaration=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_switch=end_of_line +org.eclipse.jdt.core.formatter.brace_position_for_type_declaration=end_of_line +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_block_comment=false +org.eclipse.jdt.core.formatter.comment.clear_blank_lines_in_javadoc_comment=false +org.eclipse.jdt.core.formatter.comment.format_block_comments=true +org.eclipse.jdt.core.formatter.comment.format_header=false +org.eclipse.jdt.core.formatter.comment.format_html=true +org.eclipse.jdt.core.formatter.comment.format_javadoc_comments=true +org.eclipse.jdt.core.formatter.comment.format_line_comments=true +org.eclipse.jdt.core.formatter.comment.format_source_code=true +org.eclipse.jdt.core.formatter.comment.indent_parameter_description=true +org.eclipse.jdt.core.formatter.comment.indent_root_tags=true +org.eclipse.jdt.core.formatter.comment.insert_new_line_before_root_tags=insert +org.eclipse.jdt.core.formatter.comment.insert_new_line_for_parameter=insert +org.eclipse.jdt.core.formatter.comment.line_length=100 +org.eclipse.jdt.core.formatter.compact_else_if=true +org.eclipse.jdt.core.formatter.continuation_indentation=2 +org.eclipse.jdt.core.formatter.continuation_indentation_for_array_initializer=2 +org.eclipse.jdt.core.formatter.format_guardian_clause_on_one_line=false +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_annotation_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_constant_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_enum_declaration_header=true +org.eclipse.jdt.core.formatter.indent_body_declarations_compare_to_type_header=true +org.eclipse.jdt.core.formatter.indent_breaks_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_empty_lines=false +org.eclipse.jdt.core.formatter.indent_statements_compare_to_block=true +org.eclipse.jdt.core.formatter.indent_statements_compare_to_body=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_cases=true +org.eclipse.jdt.core.formatter.indent_switchstatements_compare_to_switch=false +org.eclipse.jdt.core.formatter.indentation.size=4 +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_local_variable=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_member=insert +org.eclipse.jdt.core.formatter.insert_new_line_after_annotation_on_parameter=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_after_opening_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_at_end_of_file_if_missing=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_catch_in_try_statement=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_closing_brace_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_else_in_if_statement=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_finally_in_try_statement=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_before_while_in_do_statement=do not insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_annotation_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_block=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_method_body=insert +org.eclipse.jdt.core.formatter.insert_new_line_in_empty_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_after_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_after_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_at_in_annotation_type_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_angle_bracket_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_after_closing_paren_in_cast=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_case=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_colon_in_labeled_statement=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_allocation_expression=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_annotation=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_constructor_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_constant_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_enum_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_explicitconstructorcall_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_increments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_for_inits=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_declaration_throws=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_method_invocation_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_field_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_multiple_local_declarations=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_parameterized_type_reference=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_superinterfaces=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_arguments=insert +org.eclipse.jdt.core.formatter.insert_space_after_comma_in_type_parameters=insert +org.eclipse.jdt.core.formatter.insert_space_after_ellipsis=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_opening_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_after_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_after_semicolon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_after_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_and_in_type_parameter=insert +org.eclipse.jdt.core.formatter.insert_space_before_assignment_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_at_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_binary_operator=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_cast=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_catch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_if=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_switch=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_synchronized=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_closing_paren_in_while=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_assert=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_case=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_default=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_colon_in_labeled_statement=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_constructor_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_constant_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_enum_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_explicitconstructorcall_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_increments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_for_inits=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_declaration_throws=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_method_invocation_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_field_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_multiple_local_declarations=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_superinterfaces=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_comma_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_ellipsis=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_parameterized_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_arguments=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_angle_bracket_in_type_parameters=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_annotation_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_anonymous_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_array_initializer=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_block=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_constructor_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_constant=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_enum_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_method_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_brace_in_type_declaration=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_bracket_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_catch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_for=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_if=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_parenthesized_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_switch=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_synchronized=insert +org.eclipse.jdt.core.formatter.insert_space_before_opening_paren_in_while=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_return=insert +org.eclipse.jdt.core.formatter.insert_space_before_parenthesized_expression_in_throw=insert +org.eclipse.jdt.core.formatter.insert_space_before_postfix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_prefix_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_conditional=insert +org.eclipse.jdt.core.formatter.insert_space_before_question_in_wildcard=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_semicolon_in_for=do not insert +org.eclipse.jdt.core.formatter.insert_space_before_unary_operator=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_brackets_in_array_type_reference=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_braces_in_array_initializer=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_brackets_in_array_allocation_expression=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_annotation_type_member_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_constructor_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_enum_constant=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_declaration=do not insert +org.eclipse.jdt.core.formatter.insert_space_between_empty_parens_in_method_invocation=do not insert +org.eclipse.jdt.core.formatter.keep_else_statement_on_same_line=false +org.eclipse.jdt.core.formatter.keep_empty_array_initializer_on_one_line=false +org.eclipse.jdt.core.formatter.keep_imple_if_on_one_line=false +org.eclipse.jdt.core.formatter.keep_then_statement_on_same_line=false +org.eclipse.jdt.core.formatter.lineSplit=200 +org.eclipse.jdt.core.formatter.never_indent_block_comments_on_first_column=false +org.eclipse.jdt.core.formatter.never_indent_line_comments_on_first_column=false +org.eclipse.jdt.core.formatter.number_of_blank_lines_at_beginning_of_method_body=0 +org.eclipse.jdt.core.formatter.number_of_empty_lines_to_preserve=1 +org.eclipse.jdt.core.formatter.put_empty_statement_on_new_line=true +org.eclipse.jdt.core.formatter.tabulation.char=mixed +org.eclipse.jdt.core.formatter.tabulation.size=8 +org.eclipse.jdt.core.formatter.use_tabs_only_for_leading_indentations=false +org.eclipse.jdt.core.formatter.wrap_before_binary_operator=true diff --git a/.settings/org.eclipse.jdt.ui.prefs b/.settings/org.eclipse.jdt.ui.prefs new file mode 100644 index 0000000..28ba8a8 --- /dev/null +++ b/.settings/org.eclipse.jdt.ui.prefs @@ -0,0 +1,4 @@ +#Wed Aug 12 09:49:59 EDT 2009 +eclipse.preferences.version=1 +formatter_profile=_D4SConventions +formatter_settings_version=11 diff --git a/build.xml b/build.xml index d3ab722..e9680b4 100755 --- a/build.xml +++ b/build.xml @@ -88,6 +88,8 @@ full.stubs: (optional) Set to 'false', it excludes auxiliary stub code plac + + @@ -218,15 +220,15 @@ full.stubs: (optional) Set to 'false', it excludes auxiliary stub code plac - - + + - - + + @@ -302,7 +304,7 @@ full.stubs: (optional) Set to 'false', it excludes auxiliary stub code plac - + @@ -380,6 +382,22 @@ full.stubs: (optional) Set to 'false', it excludes auxiliary stub code plac + + + + + + + + + + + + + + + + diff --git a/etc/build.properties b/etc/build.properties index cd6807e..96cfde6 100755 --- a/etc/build.properties +++ b/etc/build.properties @@ -1,13 +1,16 @@ package = org.gcube.informationsystem.collector +previous-package = org.diligentproject.informationservice.disic lib.dir = Dependencies/ISIC wsdl.1 = XMLCollectionAccess wsdl.2 = Sink_service wsdl.3 = SinkEntry_service +wsdl.4 = DISICService namespace.1=http://gcube-system.org/namespaces/informationsystem/collector namespace.2=http://gcube-system.org/namespaces/informationsystem/collector/Sink namespace.3=http://mds.globus.org/index/2004/07/12 namespace.4=http://gcube-system.org/namespaces/informationsystem/collector/XMLCollectionAccess namespace.5=http://gcube-system.org/namespaces/informationsystem/collector/XQueryAccess namespace.6=http://gcube-system.org/namespaces/informationsystem/collector/XMLStorageAccess +previous.namespace.1=http://diligentproject.org/namespaces/informationservice/disic/DISICService diff --git a/etc/deploy-jndi-config.xml b/etc/deploy-jndi-config.xml index 357f59d..9efdc8a 100755 --- a/etc/deploy-jndi-config.xml +++ b/etc/deploy-jndi-config.xml @@ -125,4 +125,35 @@ + + + + + + + + + + factory + + + org.globus.wsrf.jndi.BeanFactory + + + + resourceClass + org.gcube.informationsystem.collector.impl.state.AggregatorRegisteredResource + + + + + + + + diff --git a/etc/deploy-server.wsdd b/etc/deploy-server.wsdd index ac5a4b7..8bc6722 100755 --- a/etc/deploy-server.wsdd +++ b/etc/deploy-server.wsdd @@ -14,17 +14,7 @@ share/schema/org.gcube.informationsystem.collector/XMLCollectionAccess_service.wsdl - - - + + + + + + + share/schema/org.gcube.informationsystem.collector/previous/DISICService_service.wsdl + + + + + + + + + + share/schema/org.gcube.informationsystem.collector/Sink_service.wsdl + + + diff --git a/schema/XMLQueryAccess.wsdl b/schema/XMLQueryAccess.wsdl new file mode 100644 index 0000000..e69de29 diff --git a/schema/XMLStorageAccess.wsdl b/schema/XMLStorageAccess.wsdl new file mode 100644 index 0000000..e69de29 diff --git a/schema/previous/DISICService.wsdl b/schema/previous/DISICService.wsdl new file mode 100755 index 0000000..52ab8dc --- /dev/null +++ b/schema/previous/DISICService.wsdl @@ -0,0 +1,136 @@ + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + + \ No newline at end of file diff --git a/src/org/gcube/informationsystem/collector/impl/porttypes/OldService.java b/src/org/gcube/informationsystem/collector/impl/porttypes/OldService.java new file mode 100644 index 0000000..56fda2f --- /dev/null +++ b/src/org/gcube/informationsystem/collector/impl/porttypes/OldService.java @@ -0,0 +1,255 @@ +package org.gcube.informationsystem.collector.impl.porttypes; + +import javax.xml.namespace.QName; + +import org.diligentproject.informationservice.disic.stubs.DeleteProfileParams; +import org.globus.wsrf.utils.FaultHelper; +import org.oasis.wsrf.faults.BaseFaultType; +import org.xmldb.api.base.ResourceSet; +import org.xmldb.api.modules.XMLResource; + +import org.gcube.common.core.contexts.GCUBEServiceContext; +import org.gcube.common.core.porttypes.GCUBEPortType; +import org.gcube.common.core.utils.logging.GCUBELog; +import org.gcube.informationsystem.collector.impl.contexts.ICServiceContext; +import org.gcube.informationsystem.collector.impl.xmlstorage.exist.State; +import org.gcube.informationsystem.collector.impl.xmlstorage.exist.Sweeper; +import org.gcube.informationsystem.collector.impl.xmlstorage.exist.XQuery; + +/** + * An implementation of the diligentproject/informationservice/disic/DISICService portType.
+ * This is here to support backward compatibility with the "old" GHN in the infrastructure. + * @deprecated + * + * @author Manuele Simi (ISTI-CNR) + * + */ +public class OldService extends GCUBEPortType { + + private final GCUBELog logger = new GCUBELog(OldService.class); + + /** + * WS Properties namespace + */ + public static final QName RP_SET = new QName( + "http://gcube-system.org/namespaces/informationsystem/collector/XMLCollectionAccess", + "ICRP"); + + /** + * Executes the given XQuery on the embedded eXist DB instance + * + * @param xquery + * - a valid XQuery. It must be compliant with the syntax (with + * the exception of XML Schema-related features) as specified in + * W3C's recommendations outlined in the June 2006 candidate + * recommendation + * @return the result set wrapped in a <Resultset> tag. Each record is + * wrapped with a <Recordt> + * @throws BaseFaultType + * if the XQuery is not valid or the connection to eXist is + * broken + */ + public String executeXQuery(String xquery) throws BaseFaultType { + + StringBuilder response = new StringBuilder(); + try { + + logger.debug("executing XQuery: " + xquery); + + XQuery q = new XQuery(xquery); + ResourceSet result = State.query_manager.executeXQuery(q); + logger.debug("number of returned documents: " + result.getSize()); + response.append("\n"); + for (int i = 0; i < (int) result.getSize(); i++) { + XMLResource xmlres = (XMLResource) result.getResource((long) i); + // logger.debug("retrieved resource - " + xmlres.getContent()); + response.append("\n" + xmlres.getContent()+ "\n\n"); + } + response.append(""); + + } catch (Exception e) { + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addFaultCause(e); + faultHelper.addDescription("IC service: Exception when executing the requested XQuery"); + throw fault; + } + return response.toString(); + } + + /** + * Removes a profile from the Storage given its DILIGENT Resource ID + * + * @param params + * a stub class including private java.lang.String + * DILIGENTResourceID; the id of the profile to remove private + * java.lang.String profileType; the type of the profile to + * remove (e.g RunningInstance, DHN, Service, etc.); + * @return true if the resource is successfully deleted + * @throws BaseFaultType + * if the type parameter is not valid or an error occurs when + * deleting the profile + */ + + public boolean deleteProfile(DeleteProfileParams params) throws BaseFaultType { + + boolean response = false; + String id = params.getDILIGENTResourceID(); + String type = params.getProfileType(); + + if ((id == "") || (id == null)) { + logger.warn("invalid id"); + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addDescription("invalid id"); + throw fault; + } + + if ((type == "") || (type == null)) { + logger.warn("invalid profile type"); + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addDescription("invalid profile type"); + throw fault; + } + + try { + logger.debug("deleting profile " + id + " from collection " + type); + State.storage_manager.retrieveAndDeleteProfileFromID(id, type); + if (type.equalsIgnoreCase("RunningInstance")) + Sweeper.cleanResourceForRI(id); + + } catch (Exception e) { + logger.error("unable to remove resource: " + id, e); + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addFaultCause(e); + faultHelper + .addDescription("IC service: Exception when deleting the requested resource"); + throw fault; + } + return response; + } + + /** + * Removes a resource from the Storage given its ID + * + * @param id + * - the id of the resoure to remove + * @return true if the resource is successfully deleted + * @throws BaseFaultType + * if the id parameter is null or an error occurs when deleting + * the profile + */ + public boolean deleteResource(String id) throws BaseFaultType { + + boolean response = false; + + if ((id == "") || (id == null)) { + logger.warn("invalid id"); + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addDescription("invalid id"); + throw fault; + } + + try { + logger.debug("deleting resource: " + id); + State.storage_manager.retrieveAndDeleteResourceFromID(id); + } catch (Exception e) { + logger.error("unable to remove resource: " + id, e); + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addFaultCause(e); + faultHelper + .addDescription("IC service: Exception when deleting the requested resource"); + throw fault; + } + return response; + } + + /** + * Deletes the entire set of registered RPs from the storage + * + * @throws BaseFaultType + * if an error occurs when deleting the resources + */ + public void deleteAllRPs() throws BaseFaultType { + try { + logger.info("DeleteAllRPs operation invoked"); + Sweeper.cleanRPs(); + logger.info("All RPs have been deleted from the storage"); + } catch (Exception e) { + logger.error("unable to clean RPs collction: ", e); + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addFaultCause(e); + faultHelper.addDescription("IC service: Exception when deleting the requested resource"); + throw fault; + } + } + + /** + * Disposes the State service + * + * @throws BaseFaultType + * if the shutdown fails + */ + public void dispose() throws BaseFaultType { + try { + logger.info("Dispose operation invoked"); + logger.info("trying to shutdown the storage instances..."); + try { + State.storage_manager.shutdown(); + State.query_manager.shutdown(); + } catch (NullPointerException se) {/* nothng to do */ + } + State.storage_manager = null; + State.query_manager = null; + // request the interruption of the sweeper thread + State.sweeperT.interrupt(); + logger.info("done"); + } catch (Exception e) { + logger.error("unable to pose the IC with success ", e); + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addFaultCause(e); + faultHelper + .addDescription("-IC service: Unable to pose the service"); + throw fault; + } + } + + /** + * Initialized the State service + * + * @throws BaseFaultType + * if the initialization fails + */ + public void initialize() throws BaseFaultType { + + try { + logger.info("Initialize operation invoked"); + State.initialize(); + logger.info("done"); + } catch (Exception e) { + logger.error("Unable to initialize the IC state", e); + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addFaultCause(e); + faultHelper.addDescription("-IC service: Unable to initialize the service"); + throw fault; + } + } + + + + /* (non-Javadoc) + * @see org.gcube.common.core.porttypes.GCUBEPortType#getServiceContext() + */ + @Override + protected GCUBEServiceContext getServiceContext() { + return ICServiceContext.getContext(); + } + +} diff --git a/src/org/gcube/informationsystem/collector/impl/porttypes/XQueryAccess.java b/src/org/gcube/informationsystem/collector/impl/porttypes/XQueryAccess.java index 1dfc630..ef43aca 100644 --- a/src/org/gcube/informationsystem/collector/impl/porttypes/XQueryAccess.java +++ b/src/org/gcube/informationsystem/collector/impl/porttypes/XQueryAccess.java @@ -1,8 +1,16 @@ package org.gcube.informationsystem.collector.impl.porttypes; +import org.globus.wsrf.utils.FaultHelper; +import org.oasis.wsrf.faults.BaseFaultType; +import org.xmldb.api.base.ResourceSet; +import org.xmldb.api.modules.XMLResource; + import org.gcube.common.core.contexts.GCUBEServiceContext; import org.gcube.common.core.porttypes.GCUBEPortType; +import org.gcube.common.core.utils.logging.GCUBELog; import org.gcube.informationsystem.collector.impl.contexts.ICServiceContext; +import org.gcube.informationsystem.collector.impl.xmlstorage.exist.State; +import org.gcube.informationsystem.collector.impl.xmlstorage.exist.XQuery; /** * XQueryAccess portType implementation @@ -12,14 +20,39 @@ import org.gcube.informationsystem.collector.impl.contexts.ICServiceContext; */ public class XQueryAccess extends GCUBEPortType { + private final GCUBELog logger = new GCUBELog(XQueryAccess.class); + /** {@inheritDoc} */ @Override protected GCUBEServiceContext getServiceContext() { return ICServiceContext.getContext(); } /* + public XQueryExecuteResponse XQueryExecute(XQueryExecuteRequest XQueryExecuteRequest) throw XQueryFaultType { - + StringBuilder response = new StringBuilder(); + try { + + logger.debug("executing XQuery: " + xquery); + + XQuery q = new XQuery(xquery); + ResourceSet result = State.query_manager.executeXQuery(q); + logger.debug("number of returned documents: " + result.getSize()); + response.append("\n"); + for (int i = 0; i < (int) result.getSize(); i++) { + XMLResource xmlres = (XMLResource) result.getResource((long) i); + // logger.debug("retrieved resource - " + xmlres.getContent()); + response.append("\n" + xmlres.getContent()+ "\n\n"); + } + response.append(""); + + } catch (Exception e) { + BaseFaultType fault = new BaseFaultType(); + FaultHelper faultHelper = new FaultHelper(fault); + faultHelper.addFaultCause(e); + faultHelper.addDescription("IC service: Exception when executing the requested XQuery"); + throw fault; + } }*/