diff --git a/.editorconfig b/.editorconfig deleted file mode 100644 index f5ca14e..0000000 --- a/.editorconfig +++ /dev/null @@ -1,312 +0,0 @@ -# This file is for unifying the coding style for different editors and IDEs. -# More information at http://EditorConfig.org - -# No .editorconfig files above the root directory -root = true - -[*] -charset = utf-8 -end_of_line = lf -indent_size = 4 -indent_style = space -insert_final_newline = false -max_line_length = 130 -tab_width = 4 -trim_trailing_whitespace = true -ij_continuation_indent_size = 8 -ij_formatter_off_tag=@formatter:off -ij_formatter_on_tag = @formatter:on -ij_formatter_tags_enabled = true -ij_smart_tabs = false -ij_visual_guides = none -ij_wrap_on_typing = false - -[*.java] -indent_size = 3 -tab_width = 3 -ij_continuation_indent_size = 6 -ij_java_align_consecutive_assignments = false -ij_java_align_consecutive_variable_declarations = false -ij_java_align_group_field_declarations = false -ij_java_align_multiline_annotation_parameters = false -ij_java_align_multiline_array_initializer_expression = false -ij_java_align_multiline_assignment = false -ij_java_align_multiline_binary_operation = false -ij_java_align_multiline_chained_methods = false -ij_java_align_multiline_extends_list = false -ij_java_align_multiline_for = true -ij_java_align_multiline_method_parentheses = false -ij_java_align_multiline_parameters = false -ij_java_align_multiline_parameters_in_calls = false -ij_java_align_multiline_parenthesized_expression = false -ij_java_align_multiline_records = true -ij_java_align_multiline_resources = false -ij_java_align_multiline_ternary_operation = false -ij_java_align_multiline_text_blocks = false -ij_java_align_multiline_throws_list = false -ij_java_align_subsequent_simple_methods = false -ij_java_align_throws_keyword = false -ij_java_annotation_parameter_wrap = off -ij_java_array_initializer_new_line_after_left_brace = false -ij_java_array_initializer_right_brace_on_new_line = false -ij_java_array_initializer_wrap = normal -ij_java_assert_statement_colon_on_next_line = false -ij_java_assert_statement_wrap = off -ij_java_assignment_wrap = off -ij_java_binary_operation_sign_on_next_line = true -ij_java_binary_operation_wrap = normal -ij_java_blank_lines_after_anonymous_class_header = 0 -ij_java_blank_lines_after_class_header = 0 -ij_java_blank_lines_after_imports = 2 -ij_java_blank_lines_after_package = 1 -ij_java_blank_lines_around_class = 1 -ij_java_blank_lines_around_field = 0 -ij_java_blank_lines_around_field_in_interface = 0 -ij_java_blank_lines_around_initializer = 1 -ij_java_blank_lines_around_method = 1 -ij_java_blank_lines_around_method_in_interface = 1 -ij_java_blank_lines_before_class_end = 0 -ij_java_blank_lines_before_imports = 1 -ij_java_blank_lines_before_method_body = 0 -ij_java_blank_lines_before_package = 1 -ij_java_block_brace_style = end_of_line -ij_java_block_comment_at_first_column = true -ij_java_call_parameters_new_line_after_left_paren = false -ij_java_call_parameters_right_paren_on_new_line = false -ij_java_call_parameters_wrap = normal -ij_java_case_statement_on_separate_line = true -ij_java_catch_on_new_line = true -ij_java_class_annotation_wrap = split_into_lines -ij_java_class_brace_style = end_of_line -ij_java_class_count_to_use_import_on_demand = 100 -ij_java_class_names_in_javadoc = 1 -ij_java_do_not_indent_top_level_class_members = false -ij_java_do_not_wrap_after_single_annotation = false -ij_java_do_while_brace_force = never -ij_java_doc_add_blank_line_after_description = true -ij_java_doc_add_blank_line_after_param_comments = false -ij_java_doc_add_blank_line_after_return = false -ij_java_doc_add_p_tag_on_empty_lines = true -ij_java_doc_align_exception_comments = true -ij_java_doc_align_param_comments = true -ij_java_doc_do_not_wrap_if_one_line = false -ij_java_doc_enable_formatting = true -ij_java_doc_enable_leading_asterisks = true -ij_java_doc_indent_on_continuation = false -ij_java_doc_keep_empty_lines = false -ij_java_doc_keep_empty_parameter_tag = true -ij_java_doc_keep_empty_return_tag = true -ij_java_doc_keep_empty_throws_tag = true -ij_java_doc_keep_invalid_tags = true -ij_java_doc_param_description_on_new_line = true -ij_java_doc_preserve_line_breaks = true -ij_java_doc_use_throws_not_exception_tag = true -ij_java_else_on_new_line = true -ij_java_entity_dd_suffix = EJB -ij_java_entity_eb_suffix = Bean -ij_java_entity_hi_suffix = Home -ij_java_entity_lhi_prefix = Local -ij_java_entity_lhi_suffix = Home -ij_java_entity_li_prefix = Local -ij_java_entity_pk_class = java.lang.String -ij_java_entity_vo_suffix = VO -ij_java_enum_constants_wrap = off -ij_java_extends_keyword_wrap = normal -ij_java_extends_list_wrap = normal -ij_java_field_annotation_wrap = split_into_lines -ij_java_finally_on_new_line = true -ij_java_for_brace_force = never -ij_java_for_statement_new_line_after_left_paren = false -ij_java_for_statement_right_paren_on_new_line = false -ij_java_for_statement_wrap = off -ij_java_generate_final_locals = true -ij_java_generate_final_parameters = true -ij_java_if_brace_force = always -ij_java_imports_layout = $*, |, de.hybris.**, |, com.hybris.**, |, java.**, |, javax.**, |, org.**, |, com.**, |, de.**, |, * -ij_java_indent_case_from_switch = true -ij_java_insert_inner_class_imports = false -ij_java_insert_override_annotation = true -ij_java_keep_blank_lines_before_right_brace = 10 -ij_java_keep_blank_lines_between_package_declaration_and_header = 2 -ij_java_keep_blank_lines_in_code = 10 -ij_java_keep_blank_lines_in_declarations = 10 -ij_java_keep_control_statement_in_one_line = false -ij_java_keep_first_column_comment = false -ij_java_keep_indents_on_empty_lines = false -ij_java_keep_line_breaks = true -ij_java_keep_multiple_expressions_in_one_line = false -ij_java_keep_simple_blocks_in_one_line = false -ij_java_keep_simple_classes_in_one_line = false -ij_java_keep_simple_lambdas_in_one_line = false -ij_java_keep_simple_methods_in_one_line = false -ij_java_label_indent_absolute = false -ij_java_label_indent_size = 0 -ij_java_lambda_brace_style = end_of_line -ij_java_layout_static_imports_separately = true -ij_java_line_comment_add_space = false -ij_java_line_comment_at_first_column = true -ij_java_message_dd_suffix = EJB -ij_java_message_eb_suffix = Bean -ij_java_method_annotation_wrap = split_into_lines -ij_java_method_brace_style = end_of_line -ij_java_method_call_chain_wrap = normal -ij_java_method_parameters_new_line_after_left_paren = false -ij_java_method_parameters_right_paren_on_new_line = false -ij_java_method_parameters_wrap = normal -ij_java_modifier_list_wrap = false -ij_java_names_count_to_use_import_on_demand = 100 -ij_java_new_line_after_lparen_in_record_header = false -ij_java_parameter_annotation_wrap = off -ij_java_parentheses_expression_new_line_after_left_paren = false -ij_java_parentheses_expression_right_paren_on_new_line = false -ij_java_place_assignment_sign_on_next_line = false -ij_java_prefer_longer_names = true -ij_java_prefer_parameters_wrap = false -ij_java_record_components_wrap = normal -ij_java_repeat_synchronized = true -ij_java_replace_instanceof_and_cast = false -ij_java_replace_null_check = true -ij_java_replace_sum_lambda_with_method_ref = true -ij_java_resource_list_new_line_after_left_paren = false -ij_java_resource_list_right_paren_on_new_line = false -ij_java_resource_list_wrap = on_every_item -ij_java_rparen_on_new_line_in_record_header = false -ij_java_session_dd_suffix = EJB -ij_java_session_eb_suffix = Bean -ij_java_session_hi_suffix = Home -ij_java_session_lhi_prefix = Local -ij_java_session_lhi_suffix = Home -ij_java_session_li_prefix = Local -ij_java_session_si_suffix = Service -ij_java_space_after_closing_angle_bracket_in_type_argument = false -ij_java_space_after_colon = true -ij_java_space_after_comma = true -ij_java_space_after_comma_in_type_arguments = true -ij_java_space_after_for_semicolon = true -ij_java_space_after_quest = true -ij_java_space_after_type_cast = true -ij_java_space_before_annotation_array_initializer_left_brace = false -ij_java_space_before_annotation_parameter_list = false -ij_java_space_before_array_initializer_left_brace = true -ij_java_space_before_catch_keyword = true -ij_java_space_before_catch_left_brace = true -ij_java_space_before_catch_parentheses = true -ij_java_space_before_class_left_brace = true -ij_java_space_before_colon = true -ij_java_space_before_colon_in_foreach = true -ij_java_space_before_comma = false -ij_java_space_before_do_left_brace = true -ij_java_space_before_else_keyword = true -ij_java_space_before_else_left_brace = true -ij_java_space_before_finally_keyword = true -ij_java_space_before_finally_left_brace = true -ij_java_space_before_for_left_brace = true -ij_java_space_before_for_parentheses = true -ij_java_space_before_for_semicolon = false -ij_java_space_before_if_left_brace = true -ij_java_space_before_if_parentheses = true -ij_java_space_before_method_call_parentheses = false -ij_java_space_before_method_left_brace = true -ij_java_space_before_method_parentheses = false -ij_java_space_before_opening_angle_bracket_in_type_parameter = false -ij_java_space_before_quest = true -ij_java_space_before_switch_left_brace = true -ij_java_space_before_switch_parentheses = true -ij_java_space_before_synchronized_left_brace = true -ij_java_space_before_synchronized_parentheses = true -ij_java_space_before_try_left_brace = true -ij_java_space_before_try_parentheses = true -ij_java_space_before_type_parameter_list = false -ij_java_space_before_while_keyword = true -ij_java_space_before_while_left_brace = true -ij_java_space_before_while_parentheses = true -ij_java_space_inside_one_line_enum_braces = false -ij_java_space_within_empty_array_initializer_braces = false -ij_java_space_within_empty_method_call_parentheses = false -ij_java_space_within_empty_method_parentheses = false -ij_java_spaces_around_additive_operators = true -ij_java_spaces_around_assignment_operators = true -ij_java_spaces_around_bitwise_operators = true -ij_java_spaces_around_equality_operators = true -ij_java_spaces_around_lambda_arrow = true -ij_java_spaces_around_logical_operators = true -ij_java_spaces_around_method_ref_dbl_colon = false -ij_java_spaces_around_multiplicative_operators = true -ij_java_spaces_around_relational_operators = true -ij_java_spaces_around_shift_operators = true -ij_java_spaces_around_type_bounds_in_type_parameters = true -ij_java_spaces_around_unary_operator = false -ij_java_spaces_within_angle_brackets = false -ij_java_spaces_within_annotation_parentheses = false -ij_java_spaces_within_array_initializer_braces = true -ij_java_spaces_within_braces = false -ij_java_spaces_within_brackets = false -ij_java_spaces_within_cast_parentheses = false -ij_java_spaces_within_catch_parentheses = false -ij_java_spaces_within_for_parentheses = false -ij_java_spaces_within_if_parentheses = false -ij_java_spaces_within_method_call_parentheses = false -ij_java_spaces_within_method_parentheses = false -ij_java_spaces_within_parentheses = false -ij_java_spaces_within_record_header = false -ij_java_spaces_within_switch_parentheses = false -ij_java_spaces_within_synchronized_parentheses = false -ij_java_spaces_within_try_parentheses = false -ij_java_spaces_within_while_parentheses = false -ij_java_special_else_if_treatment = true -ij_java_subclass_name_suffix = Impl -ij_java_ternary_operation_signs_on_next_line = false -ij_java_ternary_operation_wrap = on_every_item -ij_java_test_name_suffix = Test -ij_java_throws_keyword_wrap = normal -ij_java_throws_list_wrap = normal -ij_java_use_external_annotations = false -ij_java_use_fq_class_names = false -ij_java_use_relative_indents = false -ij_java_use_single_class_imports = true -ij_java_variable_annotation_wrap = off -ij_java_visibility = public -ij_java_while_brace_force = never -ij_java_while_on_new_line = true -ij_java_wrap_comments = true -ij_java_wrap_first_method_in_call_chain = false -ij_java_wrap_long_lines = false - -[.editorconfig] -ij_editorconfig_align_group_field_declarations = false -ij_editorconfig_space_after_colon = false -ij_editorconfig_space_after_comma = true -ij_editorconfig_space_before_colon = false -ij_editorconfig_space_before_comma = false -ij_editorconfig_spaces_around_assignment_operators = true - -[{*.ant,*.edmx,*.fxml,*.jhm,*.jnlp,*.jrxml,*.pom,*.qrc,*.rng,*.tld,*.wadl,*.wsdd,*.wsdl,*.xjb,*.xml,*.xsd,*.xsl,*.xslt,*.xul}] -ij_xml_align_attributes = true -ij_xml_align_text = false -ij_xml_attribute_wrap = normal -ij_xml_block_comment_at_first_column = true -ij_xml_keep_blank_lines = 2 -ij_xml_keep_indents_on_empty_lines = false -ij_xml_keep_line_breaks = true -ij_xml_keep_line_breaks_in_text = true -ij_xml_keep_whitespaces = false -ij_xml_keep_whitespaces_around_cdata = preserve -ij_xml_keep_whitespaces_inside_cdata = false -ij_xml_line_comment_at_first_column = true -ij_xml_space_after_tag_name = false -ij_xml_space_around_equals_in_attribute = false -ij_xml_space_inside_empty_tag = true -ij_xml_text_wrap = normal - -[{*.yaml,*.yml}] -indent_size = 2 -ij_yaml_align_values_properties = do_not_align -ij_yaml_autoinsert_sequence_marker = true -ij_yaml_block_mapping_on_new_line = false -ij_yaml_indent_sequence_value = true -ij_yaml_keep_indents_on_empty_lines = false -ij_yaml_keep_line_breaks = true -ij_yaml_sequence_on_new_line = false -ij_yaml_space_before_colon = false -ij_yaml_spaces_within_braces = true -ij_yaml_spaces_within_brackets = true diff --git a/.github/CODEOWNERS b/.github/CODEOWNERS deleted file mode 100644 index 1c48460..0000000 --- a/.github/CODEOWNERS +++ /dev/null @@ -1 +0,0 @@ -* @rabestro diff --git a/.github/ISSUE_TEMPLATE/bug-issue.md b/.github/ISSUE_TEMPLATE/bug-issue.md deleted file mode 100644 index ab645cc..0000000 --- a/.github/ISSUE_TEMPLATE/bug-issue.md +++ /dev/null @@ -1,46 +0,0 @@ ---- -name: Bug Issue -about: Use this template for reporting a bug -labels: 'type:bug' - ---- - -Please make sure that this is a bug. As per our -[GitHub Policy](https://github.com/tensorflow/tensorflow/blob/master/ISSUES.md), -we only address code/doc bugs, performance issues, feature requests and -build/installation issues on GitHub. tag:bug_template - -**System information** -- Have I written custom code (as opposed to using a stock example script provided in TensorFlow): -- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): -- Mobile device (e.g. iPhone 8, Pixel 2, Samsung Galaxy) if the issue happens on mobile device: -- TensorFlow installed from (source or binary): -- TensorFlow version (use command below): -- Python version: -- Bazel version (if compiling from source): -- GCC/Compiler version (if compiling from source): -- CUDA/cuDNN version: -- GPU model and memory: - -You can collect some of this information using our environment capture -[script](https://github.com/tensorflow/tensorflow/tree/master/tools/tf_env_collect.sh) -You can also obtain the TensorFlow version with: -1. TF 1.0: `python -c "import tensorflow as tf; print(tf.GIT_VERSION, tf.VERSION)"` -2. TF 2.0: `python -c "import tensorflow as tf; print(tf.version.GIT_VERSION, tf.version.VERSION)"` - -**Describe the current behavior** - -**Describe the expected behavior** - -**[Contributing](https://www.tensorflow.org/community/contribute)** - -- Do you want to contribute a PR? (yes/no): -- Briefly describe your candidate solution(if contributing): - -**Standalone code to reproduce the issue** -Provide a reproducible test case that is the bare minimum necessary to generate -the problem. If possible, please share a link to Colab/Jupyter/any notebook. - -**Other info / logs** Include any logs or source code that would be helpful to -diagnose the problem. If including tracebacks, please include the full -traceback. Large logs and files should be attached. diff --git a/.github/ISSUE_TEMPLATE/feature-request.md b/.github/ISSUE_TEMPLATE/feature-request.md deleted file mode 100644 index 0bc1613..0000000 --- a/.github/ISSUE_TEMPLATE/feature-request.md +++ /dev/null @@ -1,17 +0,0 @@ ---- -name: Feature Request -about: Use this template for raising a feature request -labels: 'type:feature' - ---- - -Please make sure that this is a feature request. As per our [GitHub Policy](https://github.com/tensorflow/tensorflow/blob/master/ISSUES.md), we only address code/doc bugs, performance issues, feature requests and build/installation issues on GitHub. tag:feature_template - - -**Describe the feature and the current behavior/state.** - -**Will this change the current api? How?** - -**Who will benefit with this feature?** - -**Any Other info.** diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml deleted file mode 100644 index 72b8671..0000000 --- a/.github/workflows/build.yml +++ /dev/null @@ -1,36 +0,0 @@ -name: Build -on: - push: - branches: - - master - pull_request: - types: [opened, synchronize, reopened] -jobs: - build: - name: Build - runs-on: ubuntu-latest - steps: - - uses: actions/checkout@v2 - with: - fetch-depth: 0 # Shallow clones should be disabled for a better relevancy of analysis - - name: Set up JDK 17 - uses: actions/setup-java@v1 - with: - java-version: 17 - - name: Cache SonarCloud packages - uses: actions/cache@v1 - with: - path: ~/.sonar/cache - key: ${{ runner.os }}-sonar - restore-keys: ${{ runner.os }}-sonar - - name: Cache Gradle packages - uses: actions/cache@v1 - with: - path: ~/.gradle/caches - key: ${{ runner.os }}-gradle-${{ hashFiles('**/*.gradle') }} - restore-keys: ${{ runner.os }}-gradle - - name: Build and analyze - env: - GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} # Needed to get PR information, if any - SONAR_TOKEN: ${{ secrets.SONAR_TOKEN }} - run: ./gradlew build sonarqube --info diff --git a/.github/workflows/codeql-analysis.yml b/.github/workflows/codeql-analysis.yml deleted file mode 100644 index a73edb8..0000000 --- a/.github/workflows/codeql-analysis.yml +++ /dev/null @@ -1,74 +0,0 @@ -# For most projects, this workflow file will not need changing; you simply need -# to commit it to your repository. -# -# You may wish to alter this file to override the set of languages analyzed, -# or to provide custom queries or build logic. -# -# ******** NOTE ******** -# We have attempted to detect the languages in your repository. Please check -# the `language` matrix defined below to confirm you have the correct set of -# supported CodeQL languages. -# -name: "CodeQL" - -on: - push: - branches: [ master ] - pull_request: - # The branches below must be a subset of the branches above - branches: [ master ] - schedule: - - cron: '15 16 * * 1' - -jobs: - analyze: - name: Analyze - runs-on: ubuntu-latest - permissions: - actions: read - contents: read - security-events: write - - strategy: - fail-fast: false - matrix: - language: [ 'java' ] - # CodeQL supports [ 'cpp', 'csharp', 'go', 'java', 'javascript', 'python', 'ruby' ] - # Learn more about CodeQL language support at https://git.io/codeql-language-support - - steps: - - name: Checkout repository - uses: actions/checkout@v2 - - uses: actions/setup-java@v2 - with: - distribution: 'temurin' # See 'Supported distributions' for available options - java-version: '17' - - # Initializes the CodeQL tools for scanning. - - name: Initialize CodeQL - uses: github/codeql-action/init@v1 - with: - languages: ${{ matrix.language }} - # If you wish to specify custom queries, you can do so here or in a config file. - # By default, queries listed here will override any specified in a config file. - # Prefix the list here with "+" to use these queries and those in the config file. - # queries: ./path/to/local/query, your-org/your-repo/queries@main - - # Autobuild attempts to build any compiled languages (C/C++, C#, or Java). - # If this step fails, then you should remove it and run the build manually (see below) - - name: Autobuild - uses: github/codeql-action/autobuild@v1 - - # ℹ️ Command-line programs to run using the OS shell. - # 📚 https://git.io/JvXDl - - # ✏️ If the Autobuild fails above, remove it and uncomment the following three lines - # and modify them (or add more) to build your code if your project - # uses a compiled language - - #- run: | - # make bootstrap - # make release - - - name: Perform CodeQL Analysis - uses: github/codeql-action/analyze@v1 diff --git a/.gitignore b/.gitignore deleted file mode 100644 index b1b10da..0000000 --- a/.gitignore +++ /dev/null @@ -1,37 +0,0 @@ -############################## -## Java -############################## -.mtj.tmp/ -*.class -*.jar -*.war -*.ear -*.nar -hs_err_pid* - -############################## -## Gradle -############################## -bin/ -build/ -.gradle -.gradletasknamecache -gradle-app.setting -!gradle-wrapper.jar - -############################## -## IntelliJ -############################## -out/ -.idea/ -.idea_modules/ -*.iml -*.ipr -*.iws - -############################## -## OS X -############################## -.DS_Store -/algorithm/gradle.properties -/sample/gradle.properties diff --git a/.gitmessage b/.gitmessage deleted file mode 100644 index 055d59b..0000000 --- a/.gitmessage +++ /dev/null @@ -1,44 +0,0 @@ -# : (Max 50 char, Why is this change necessary?) -# |<---- Using a Maximum Of 50 Characters ---->| - -# |<---- Try To Limit Each Line to a Maximum Of 72 Characters ---->| -# Explain how the commit addresses the issue - -# IMPORTANT!! Describe any side effects of the change. - -# Provide links or keys to any relevant tickets, articles or other resources -# Examples: "Jira issue [ABC-123]" or "Closes Github issue #123" - -# --- COMMIT END --- -# Type can be -# feat (new feature) -# fix (bug fix) -# refactor (refactoring production code) -# style (formatting, missing semi colons, etc; no code change) -# docs (changes to documentation) -# test (adding or refactoring tests; no production code change) -# chore (updating grunt tasks etc; no production code change) -# wip (work in progress commit to be squashed -- do not push!)** -# -------------------- -# Remember to -# - Capitalize the subject line -# - Use the imperative mood in the subject line -# - Do not end the subject line with a period -# - Separate subject from body with a blank line -# - Use the body to explain what and why vs. how -# - Can use multiple lines with "-" for bullet points in body. -# -------------------- -# ** wip commit type -# A wip commit should only happen on a local branch. These commits are for -# unfinished snapshots that should not be checked into a shared branch. -# These commits should be squashed before changes are merged to -# a shared branch. -# -------------------- -# For more information about this template and useful commit messages, check out -# - https://gist.github.com/median-man/3a7c4324005e96f02691f3a20aeac26b -# - https://gist.github.com/adeekshith/cd4c95a064977cdc6c50 -# - https://robots.thoughtbot.com/5-useful-tips-for-a-better-commit-message -# - https://tbaggery.com/2008/04/19/a-note-about-git-commit-messages.html -# - https://8thlight.com/blog/kevin-liddle/2012/09/27/mind-your-git-manners.html -# -# diff --git a/.idea/.gitignore b/.idea/.gitignore deleted file mode 100644 index 13566b8..0000000 --- a/.idea/.gitignore +++ /dev/null @@ -1,8 +0,0 @@ -# Default ignored files -/shelf/ -/workspace.xml -# Editor-based HTTP Client requests -/httpRequests/ -# Datasource local storage ignored files -/dataSources/ -/dataSources.local.xml diff --git a/.idea/codeStyles/codeStyleConfig.xml b/.idea/codeStyles/codeStyleConfig.xml deleted file mode 100644 index a55e7a1..0000000 --- a/.idea/codeStyles/codeStyleConfig.xml +++ /dev/null @@ -1,5 +0,0 @@ - - - - \ No newline at end of file diff --git a/.idea/compiler.xml b/.idea/compiler.xml deleted file mode 100644 index b589d56..0000000 --- a/.idea/compiler.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/.idea/gradle.xml b/.idea/gradle.xml deleted file mode 100644 index 3643ec5..0000000 --- a/.idea/gradle.xml +++ /dev/null @@ -1,24 +0,0 @@ - - - - - - - \ No newline at end of file diff --git a/.idea/jarRepositories.xml b/.idea/jarRepositories.xml deleted file mode 100644 index 9c37e0e..0000000 --- a/.idea/jarRepositories.xml +++ /dev/null @@ -1,40 +0,0 @@ - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/misc.xml b/.idea/misc.xml deleted file mode 100644 index 4cbd4e5..0000000 --- a/.idea/misc.xml +++ /dev/null @@ -1,18 +0,0 @@ - - - - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/scopes/SearchAlgorithms.xml b/.idea/scopes/SearchAlgorithms.xml deleted file mode 100644 index 762eb69..0000000 --- a/.idea/scopes/SearchAlgorithms.xml +++ /dev/null @@ -1,3 +0,0 @@ - - - \ No newline at end of file diff --git a/.idea/uiDesigner.xml b/.idea/uiDesigner.xml deleted file mode 100644 index e96534f..0000000 --- a/.idea/uiDesigner.xml +++ /dev/null @@ -1,124 +0,0 @@ - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - \ No newline at end of file diff --git a/.idea/vcs.xml b/.idea/vcs.xml deleted file mode 100644 index 94a25f7..0000000 --- a/.idea/vcs.xml +++ /dev/null @@ -1,6 +0,0 @@ - - - - - - \ No newline at end of file diff --git a/CNAME b/CNAME deleted file mode 100644 index e1f8911..0000000 --- a/CNAME +++ /dev/null @@ -1 +0,0 @@ -algorithms.jc.id.lv \ No newline at end of file diff --git a/LICENSE b/LICENSE deleted file mode 100644 index 244293b..0000000 --- a/LICENSE +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) 2022 Jegors Čemisovs - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/README.md b/README.md deleted file mode 100644 index 8d95bb6..0000000 --- a/README.md +++ /dev/null @@ -1,139 +0,0 @@ -[![Quality Gate Status](https://sonarcloud.io/api/project_badges/measure?project=rabestro_algorithms&metric=alert_status)](https://sonarcloud.io/summary/new_code?id=rabestro_algorithms) - -# Graph search algorithms - -The project implements an interface for the weighted graph, as well as two algorithms for finding a path in the graph. - -There are implementations and tests for two algorithms: - -- [Breadth-first search](https://en.wikipedia.org/wiki/Breadth-first_search) -- [Dijkstra's Algorithm](https://en.wikipedia.org/wiki/Dijkstra%27s_algorithm) - -The implementation is written in Java 17. [API documentation](https://algorithms.jc.id.lv/docs/api/) is available. You -can also see the [specifications](https://algorithms.jc.id.lv/docs/spock-reports/) generated with the spock-reports. - -## Demo. Graph Shell - -To demonstrate the work of search algorithms, I made a small console program '[Graph Shell](graph-shell/README.md)'. The program -allows you to select [one of three build-in graph samples](#Graph-Samples) and search for a path using two algorithms. The source -code of the program is located in `graph-shell` module. - -[![asciicast](https://asciinema.org/a/468058.svg)](https://asciinema.org/a/468058) - -### Usage in other projects - -These algorithms used in the [Hypermetro](https://rabestro.github.io/hypermetro/) project, where they are -utilized to find the optimal route in the metro schema. - - -## How to use the algorithms in your program - -The first step is to create a graph structure. The Graph interface is generic, so you can use any Java type for vertex -and any [Number](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Number.html) type for distance. - -### Example - -In the following Java code we create a graph structure with eight nodes. We -use [Character](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Character.html) class for vertex -identification and [Integer](https://docs.oracle.com/en/java/javase/17/docs/api/java.base/java/lang/Integer.html) for the -distance. You can see the graphic representation of the scheme [here](docs/assets/complex.gif). - -```java -var graph = Graph.of(Map.of( - 'A', Map.of('B', 5, 'H', 2), - 'B', Map.of('A', 5, 'C', 7), - 'C', Map.of('B', 7, 'D', 3, 'G', 4), - 'D', Map.of('C', 20, 'E', 4), - 'E', Map.of('F', 5), - 'F', Map.of('G', 6), - 'G', Map.of('C', 4), - 'H', Map.of('G', 3) - )); -``` - -The second step is creating a search algorithm class. You can choose one of the two algorithms. - -### Example - -```java -var fastest = new DijkstrasAlgorithm(); -var shortest = new BreadthFirstSearch(); -``` - -Now we can search for the route. - -### Example - -```java -var source = 'D'; -var target = 'C'; - -var routeOne = shortest.findPath(graph, source, target); -var routeTwo = fastest.findPath(graph, source, target); -``` - -As result, you get a list with the path. - -```java -routeOne==['D','C'] - routeTwo==['D','E','F','G','C'] -``` - -## Unit Tests - -Tests are written in Groove language. For unit testing, the [Spock Framework](https://spockframework.org/) was used. To test the operation of the algorithms, the following sample graphs were created. - -## Graph Samples - -### Small Graph Sample - -```mermaid -flowchart LR - A((A)) - B((B)) - C((C)) - A -->|7| B - A -->|2| C - B -->|3| A - B -->|5| C - C -->|1| A - C -->|3| B -``` - -![Small Graph](docs/assets/small.gif) - - -### Medium Graph Sample - -```mermaid -flowchart LR - A --> |5 | B - B --> |5 | A - B --> |10| C - C --> |5 | D - C --> |20| B - D --> |5 | E - E --> |5 | B -``` - -![Medium Graph](docs/assets/medium.gif) - -### Complex Graph Sample - -```mermaid -flowchart LR - A --> |5 | B - A --> |2 | H - B --> |5 | A - B --> |7 | C - C --> |7 | B - C --> |3 | D - C --> |4 | G - D --> |20| C - D --> |4 | E - E --> |5 | F - G --> |4 | C - H --> |3 | G -``` - -![Complex Graph](docs/assets/complex.gif) \ No newline at end of file diff --git a/_config.yml b/_config.yml index e8eb639..c419263 100644 --- a/_config.yml +++ b/_config.yml @@ -1,12 +1 @@ -theme: jekyll-theme-minimal -title: Algorithms -author: Jegors Čemisovs -email: jegors.cemisovs@outlook.lv -description: > - Graph pathfinding algorithms. - -# social links -twitter_username: rabestro # DO NOT include the @ character, or else the build will fail! -github_username: rabestro # DO NOT include the @ character, or else the build will fail! - -show_excerpts: true # set to false to remove excerpts on the homepage +theme: jekyll-theme-cayman \ No newline at end of file diff --git a/algorithm/build.gradle b/algorithm/build.gradle deleted file mode 100644 index 655e701..0000000 --- a/algorithm/build.gradle +++ /dev/null @@ -1,86 +0,0 @@ -plugins { - id 'groovy' - id 'java-library' - id 'maven-publish' - id 'jacoco' - id 'org.sonarqube' version '3.4.0.2513' -} - -sonarqube { - properties { - property "sonar.projectKey", "rabestro_algorithms" - property "sonar.organization", "rabestro" - property "sonar.host.url", "https://sonarcloud.io" - } -} - -group 'lv.id.jc' -version '1.1-SNAPSHOT' - -repositories { - mavenCentral() -} - -// Configures the publishing -publishing { - repositories { - // The target repository - maven { - // Choose whatever name you want - name = "Algorithms" - // The url of the repository, where the artifacts will be published - url = "https://maven.pkg.github.com/rabestro/algorithms" - credentials { - // The credentials (described in the next section) - username = project.findProperty("gpr.user") - password = project.findProperty("gpr.key") - } - } - } - publications { - gpr(MavenPublication) { - from(components.java) - // Fixes the error with dynamic versions when using Spring Boot - versionMapping { - usage('java-api') { - fromResolutionOf('runtimeClasspath') - } - usage('java-runtime') { - fromResolutionResult(null) - } - } - } - } -} - -dependencies { - // Spock Framework - testImplementation 'org.spockframework:spock-core:2.2-groovy-3.0' - testImplementation 'org.codehaus.groovy:groovy-all:3.0.12' - - // Spock Reports - testRuntimeClasspath('com.athaydes:spock-reports:2.3.1-groovy-3.0') { - transitive = false // this avoids affecting your version of Groovy/Spock - } - // Required for spock-reports - testImplementation 'org.slf4j:slf4j-api:2.0.1' - testRuntimeClasspath 'org.slf4j:slf4j-simple:2.0.1' - - // JUnit 5 Parameterized Tests - testImplementation 'org.junit.jupiter:junit-jupiter-params:5.8.1' -} - -test { - useJUnitPlatform() - finalizedBy jacocoTestReport -} - -jacocoTestReport { - dependsOn test - - reports { - xml.required = true - csv.required = false - html.outputLocation = layout.buildDirectory.dir('jacocoHtml') - } -} diff --git a/algorithm/src/main/java/lv/id/jc/algorithm/graph/BreadthFirstSearch.java b/algorithm/src/main/java/lv/id/jc/algorithm/graph/BreadthFirstSearch.java deleted file mode 100644 index b7e927d..0000000 --- a/algorithm/src/main/java/lv/id/jc/algorithm/graph/BreadthFirstSearch.java +++ /dev/null @@ -1,49 +0,0 @@ -package lv.id.jc.algorithm.graph; - -import java.util.ArrayDeque; -import java.util.HashMap; -import java.util.HashSet; -import java.util.LinkedList; -import java.util.List; -import java.util.Objects; - -import static java.util.function.Predicate.not; -import static java.util.stream.Stream.iterate; - -/** - * Algorithm for finding the shortest paths between nodes in a graph. - *

- * The algorithm doesn't take into account the distance between nodes. - * - * @param the type of vertex - * @author Jegors Čemisovs - * @since 1.0 - */ -public class BreadthFirstSearch implements SearchAlgorithm { - - @Override - public List findPath(Graph graph, T source, T target) { - var queue = new ArrayDeque(); - var visited = new HashSet(); - var previous = new HashMap(); - queue.add(source); - - while (!queue.isEmpty()) { - var node = queue.removeFirst(); - if (target.equals(node)) { - var path = new LinkedList(); - iterate(node, Objects::nonNull, previous::get).forEach(path::addFirst); - return path; - } - visited.add(node); - graph.edges(node).keySet().stream() - .filter(not(visited::contains)) - .forEach(it -> { - previous.computeIfAbsent(it, x -> node); - queue.addLast(it); - }); - } - return List.of(); - } - -} diff --git a/algorithm/src/main/java/lv/id/jc/algorithm/graph/DijkstrasAlgorithm.java b/algorithm/src/main/java/lv/id/jc/algorithm/graph/DijkstrasAlgorithm.java deleted file mode 100644 index 41f7817..0000000 --- a/algorithm/src/main/java/lv/id/jc/algorithm/graph/DijkstrasAlgorithm.java +++ /dev/null @@ -1,49 +0,0 @@ -package lv.id.jc.algorithm.graph; - -import java.util.ArrayDeque; -import java.util.HashMap; -import java.util.LinkedList; -import java.util.List; -import java.util.Objects; - -import static java.util.stream.Stream.iterate; - -/** - * Algorithm for finding the fastest paths between nodes in a graph. - *

- * The algorithm uses information about edge's distance to find the fastest path. - * - * @param the type of vertex - * @author Jegors Čemisovs - * @since 1.0 - */ -public class DijkstrasAlgorithm implements SearchAlgorithm { - - @Override - public List findPath(Graph graph, T source, T target) { - var queue = new ArrayDeque(); - var distances = new HashMap(); - var previous = new HashMap(); - queue.add(source); - distances.put(source, .0); - - while (!queue.isEmpty()) { - var prev = queue.removeFirst(); - graph.edges(prev).forEach((node, time) -> { - var distance = distances.get(prev) + time.doubleValue(); - if (distance < distances.getOrDefault(node, Double.MAX_VALUE)) { - previous.put(node, prev); - distances.put(node, distance); - queue.addLast(node); - } - }); - } - if (previous.containsKey(target) || source.equals(target)) { - var path = new LinkedList(); - iterate(target, Objects::nonNull, previous::get).forEach(path::addFirst); - return path; - } - return List.of(); - } - -} diff --git a/algorithm/src/main/java/lv/id/jc/algorithm/graph/Graph.java b/algorithm/src/main/java/lv/id/jc/algorithm/graph/Graph.java deleted file mode 100644 index 2b4de63..0000000 --- a/algorithm/src/main/java/lv/id/jc/algorithm/graph/Graph.java +++ /dev/null @@ -1,71 +0,0 @@ -package lv.id.jc.algorithm.graph; - -import java.util.List; -import java.util.Map; -import java.util.stream.IntStream; - -/** - * An interface for weighted directed graph (network) - * - * @param the type of vertex in this graph - * @author Jegors Čemisovs - * @since 1.1 - */ -@FunctionalInterface -public interface Graph { - /** - * Creates a Graph object by given schema. - *

- * In a graph schema, each vertex is assigned an edge map. - * If the vertex has no edges, then it should be assigned an empty map. - * - * @param schema of the graph - * @param the type of vertex in this graph - * @return graph object with given schema - */ - static Graph of(Map> schema) { - return () -> schema; - } - - /** - * The schema of this graph. - *

- * In a graph schema, each vertex is assigned an edge map. - * If the vertex has no edges, then it should be assigned an empty map. - * - * @return the graph scheme - */ - Map> schema(); - - /** - * Returns the edges of the given vertex, - * or {@code null} if this graph contains no given vertex. - * - *

A return value of {@code null} does not necessarily - * indicate that the specified vertex is not present in the graph; - * it's also possible that in the graph schema, {@code null} was specified - * for the edges of this vertex instead of an empty map. - * - * @param vertex vertex - * @return all links for the given vertex - * or null if no such vertex in the graph - */ - default Map edges(T vertex) { - return schema().get(vertex); - } - - /** - * Calculate the distance for the given path - * - * @param path the list of vertices representing the path - * @return distance for the given path as double - * @throws NullPointerException if {@code path} is incorrect and contains more than one vertex - */ - default double getDistance(List path) { - return IntStream - .range(1, path.size()) - .mapToObj(i -> edges(path.get(i - 1)).get(path.get(i))) - .mapToDouble(Number::doubleValue) - .sum(); - } -} diff --git a/algorithm/src/main/java/lv/id/jc/algorithm/graph/SearchAlgorithm.java b/algorithm/src/main/java/lv/id/jc/algorithm/graph/SearchAlgorithm.java deleted file mode 100644 index cf8f54f..0000000 --- a/algorithm/src/main/java/lv/id/jc/algorithm/graph/SearchAlgorithm.java +++ /dev/null @@ -1,23 +0,0 @@ -package lv.id.jc.algorithm.graph; - -import java.util.List; - -/** - * A functional interface for graph search algorithm - * - * @param the type of vertex - * @author Jegors Čemisovs - * @since 1.0 - */ -@FunctionalInterface -public interface SearchAlgorithm { - /** - * Find the path from the source node to the target - * - * @param graph The graph in which we search for the path - * @param source Search starting point identifier - * @param target Search finish point identifier - * @return Path found or empty list if path cannot be found - */ - List findPath(Graph graph, T source, T target); -} diff --git a/algorithm/src/main/java/lv/id/jc/algorithm/graph/package-info.java b/algorithm/src/main/java/lv/id/jc/algorithm/graph/package-info.java deleted file mode 100644 index 28436e8..0000000 --- a/algorithm/src/main/java/lv/id/jc/algorithm/graph/package-info.java +++ /dev/null @@ -1,4 +0,0 @@ -/** - * This package contains graph pathfinding algorithms. - */ -package lv.id.jc.algorithm.graph; \ No newline at end of file diff --git a/algorithm/src/main/java/module-info.java b/algorithm/src/main/java/module-info.java deleted file mode 100644 index 941d8df..0000000 --- a/algorithm/src/main/java/module-info.java +++ /dev/null @@ -1,8 +0,0 @@ -/** - * The module contains an interface for a graph and an interface for a graph search algorithm. - * There is an implementation of two search algorithms: - * Dijkstra's algorithm and Breadth First Search algorithm. - */ -module lv.id.jc.algorithm.graph { - exports lv.id.jc.algorithm.graph; -} \ No newline at end of file diff --git a/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/BreadthFirstSearchSpec.groovy b/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/BreadthFirstSearchSpec.groovy deleted file mode 100644 index fba94a7..0000000 --- a/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/BreadthFirstSearchSpec.groovy +++ /dev/null @@ -1,93 +0,0 @@ -package lv.id.jc.algorithm.graph - -import spock.lang.* - -@Title("Breadth First Search Algorithm") -@See("https://en.wikipedia.org/wiki/Breadth-first_search") -@Narrative(""" -Breadth First Search algorithm for finding the shortest paths between nodes in a graph -""") -class BreadthFirstSearchSpec extends Specification { - @Subject - def algorithm = new BreadthFirstSearch() - - def 'should find a route for simple graph'() { - given: - def graph = Graph.of([ - A: [B: 7, C: 2], - B: [A: 3, C: 5], - C: [A: 1, B: 3] - ]) - - when: - def path = algorithm.findPath(graph, source, target) - - then: - path == shortest - - and: - graph.getDistance(path) == time as double - - where: - source | target || time | shortest - 'A' | 'A' || 0 | ['A'] - 'A' | 'B' || 7 | ['A', 'B'] - 'B' | 'C' || 5 | ['B', 'C'] - 'C' | 'B' || 3 | ['C', 'B'] - } - - def 'should find a route for complex graph'() { - given: - def graph = Graph.of([ - A: [B: 1], - B: [A: 1, D: 1], - C: [A: 1], - D: [C: 1, E: 1], - E: [F: 1], - F: [D: 1, E: 1]]) - - when: - def path = algorithm.findPath(graph, source, target) - - then: - path == shortest - - and: - graph.getDistance(path) == time as double - - where: - source | target || shortest - 'A' | 'A' || ['A'] - 'B' | 'B' || ['B'] - 'A' | 'B' || ['A', 'B'] - 'B' | 'A' || ['B', 'A'] - 'A' | 'C' || ['A', 'B', 'D', 'C'] - 'C' | 'A' || ['C', 'A'] - 'E' | 'B' || ['E', 'F', 'D', 'C', 'A', 'B'] - - and: - time = shortest.size() - 1 - } - - def 'should thrown an exception for an empty graph'() { - given: - def graph = Graph.of([:]) - - when: - algorithm.findPath(graph, 'A', 'B') - - then: - thrown NullPointerException - } - - def "should return an empty path if can't find a route"() { - given: 'a simple graph with no edge between nodes' - def graph = Graph.of([A: [:], B: [:]]) - - when: - def path = algorithm.findPath(graph, 'A', 'B') - - then: - path == [] - } -} diff --git a/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/DijkstrasAlgorithmSpec.groovy b/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/DijkstrasAlgorithmSpec.groovy deleted file mode 100644 index ca30c65..0000000 --- a/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/DijkstrasAlgorithmSpec.groovy +++ /dev/null @@ -1,127 +0,0 @@ -package lv.id.jc.algorithm.graph - -import spock.lang.* - -@Title("Dijkstra's Algorithm") -@See("https://en.wikipedia.org/wiki/Dijkstra%27s_algorithm") -@Narrative(""" -Dijkstra's algorithm is an algorithm for finding -the fastest paths between nodes in a graph -""") -class DijkstrasAlgorithmSpec extends Specification { - - @Subject - def algorithm = new DijkstrasAlgorithm() - - def 'should find a route for a simple graph'() { - given: - def graph = Graph.of([ - A: [B: 7, C: 2], - B: [A: 3, C: 5], - C: [A: 1, B: 3] - ]) - - when: - def path = algorithm.findPath(graph, source, target) - def time = graph.getDistance(path) - - then: - path == fastestPath - time == fastestTime - - where: - source | target || fastestPath | fastestTime - 'A' | 'A' || ['A'] | 0 - 'B' | 'A' || ['B', 'A'] | 3 - 'A' | 'B' || ['A', 'C', 'B'] | 5 - } - - def 'should find a route for a medium graph'() { - given: - def graph = Graph.of([ - A: [B: 5], - B: [A: 5, C: 10], - C: [B: 20, D: 5], - D: [E: 5], - E: [B: 5] - ]) - - when: - def path = algorithm.findPath(graph, source, target) - - then: - path == fastest - - and: - graph.getDistance(path) == time as double - - where: - source | target || time | fastest - 'A' | 'A' || 0 | ['A'] - 'B' | 'B' || 0 | ['B'] - 'A' | 'B' || 5 | ['A', 'B'] - 'B' | 'A' || 5 | ['B', 'A'] - 'A' | 'C' || 15 | ['A', 'B', 'C'] - 'C' | 'A' || 20 | ['C', 'D', 'E', 'B', 'A'] - } - - def 'should find a route for a complex graph'() { - given: - def graph = Graph.of([ - A: [B: 5, H: 2], - B: [A: 5, C: 7], - C: [B: 7, D: 3, G: 4], - D: [C: 20, E: 4], - E: [F: 5], - F: [G: 6], - G: [C: 4], - H: [G: 3] - ]) - - when: - def path = algorithm.findPath(graph, source, target) - - then: - path == fastest - - and: - graph.getDistance(path) == time as double - - where: - source | target || time | fastest - 'A' | 'A' || 0 | ['A'] - 'B' | 'B' || 0 | ['B'] - 'A' | 'B' || 5 | ['A', 'B'] - 'B' | 'A' || 5 | ['B', 'A'] - 'A' | 'C' || 9 | ['A', 'H', 'G', 'C'] - 'C' | 'A' || 12 | ['C', 'B', 'A'] - 'A' | 'G' || 5 | ['A', 'H', 'G'] - 'C' | 'D' || 3 | ['C', 'D'] - 'D' | 'C' || 19 | ['D', 'E', 'F', 'G', 'C'] - 'B' | 'D' || 10 | ['B', 'C', 'D'] - 'D' | 'B' || 26 | ['D', 'E', 'F', 'G', 'C', 'B'] - 'D' | 'H' || 33 | ['D', 'E', 'F', 'G', 'C', 'B', 'A', 'H'] - } - - def 'should thrown NPE for an empty graph'() { - given: - def graph = Graph.of([:]) - - when: - algorithm.findPath(graph, 'A', 'B') - - then: - thrown NullPointerException - } - - def "should return an empty path if can't find a route"() { - given: 'a simple graph with no edge between nodes' - def graph = Graph.of([A: [:], B: [:]]) - - when: - def path = algorithm.findPath(graph, 'A', 'B') - - then: - path == [] - } -} diff --git a/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/GraphSpec.groovy b/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/GraphSpec.groovy deleted file mode 100644 index c2b3a50..0000000 --- a/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/GraphSpec.groovy +++ /dev/null @@ -1,99 +0,0 @@ -package lv.id.jc.algorithm.graph - -import spock.lang.Narrative -import spock.lang.Specification -import spock.lang.Title - -@Title("Generic Graph") -@Narrative("A generic implementation of Graph structure") -class GraphSpec extends Specification { - - def "should return edges for a given node"() { - given: 'a simple graph with three nodes' - def graph = Graph.of([ - A: [B: 7, C: 2], - B: [A: 3, C: 5], - C: [A: 1, B: 3] - ]) - - expect: 'The method returns expected edges for given node' - graph.edges(node) == expected - - where: - node | expected - 'A' | [B: 7, C: 2] - 'B' | [A: 3, C: 5] - 'C' | [A: 1, B: 3] - } - - def 'should calculate distance for a path'() { - given: "a complex graph with eight nodes" - def graph = Graph.of([ - A: [B: 5, H: 2], - B: [A: 5, C: 7], - C: [B: 7, D: 3, G: 4], - D: [C: 20, E: 4], - E: [F: 5], - F: [G: 6], - G: [C: 4], - H: [G: 3] - ]) - - expect: 'the distance for a path correctly calculated' - graph.getDistance(path) == distance as double - - where: 'path and expected distance' - path | distance - ['A'] | 0 - ['A', 'B'] | 5 - ['B', 'A'] | 5 - ['A', 'B', 'A'] | 10 - ['A', 'B', 'A', 'B'] | 15 - ['C', 'D'] | 3 - ['D', 'C'] | 20 - ['D', 'E', 'F', 'G', 'C'] | 19 - } - - def 'should be zero distance for an empty path'() { - given: 'any graph' - def graph = Graph.of(_ as Map) - - expect: 'the distance is zero for an empty path' - graph.getDistance([]) == 0 - } - - def 'should be zero distance for any one node path'() { - given: 'any graph' - def graph = Graph.of(_ as Map) - - expect: 'the zero distance for any one-node path' - graph.getDistance(oneNodePath) == 0 - - where: 'the node may be of any type and even non-existent' - oneNodePath << [ - ['A'], ['B'], [2], ['X' as char], [12.56] - ] - } - - def 'should throw NPE for incorrect path'() { - given: "a medium graph with five nodes" - def graph = Graph.of([ - A: [B: 5], - B: [A: 5, C: 10], - C: [B: 20, D: 5], - D: [E: 5], - E: [B: 5] - ]) - - when: 'we call the method with incorrect path' - graph.getDistance(incorrectPath) - - then: 'the NPE thrown' - thrown NullPointerException - - where: 'path is more then one node' - incorrectPath << [ - ['E', 'D'], ['A', 'C'], ['A', 'B', 'D'] - ] - } -} \ No newline at end of file diff --git a/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/SearchAlgorithmsSpec.groovy b/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/SearchAlgorithmsSpec.groovy deleted file mode 100644 index 4182a97..0000000 --- a/algorithm/src/test/groovy/lv/id/jc/algorithm/graph/SearchAlgorithmsSpec.groovy +++ /dev/null @@ -1,61 +0,0 @@ -package lv.id.jc.algorithm.graph - -import spock.lang.* - -@Issue("30") -@Title("Comparison of two algorithms") -@See("https://en.wikipedia.org/wiki/Breadth-first_search") -@See("https://en.wikipedia.org/wiki/Dijkstra%27s_algorithm") -class SearchAlgorithmsSpec extends Specification { - @Subject - def bfsAlgorithm = new BreadthFirstSearch() - - @Subject - def dijkstras = new DijkstrasAlgorithm() - - def 'should find a route for a complex graph'() { - given: "a complex graph with eight nodes" - def graph = Graph.of([ - A: [B: 5, H: 2], - B: [A: 5, C: 7], - C: [B: 7, D: 3, G: 4], - D: [C: 20, E: 4], - E: [F: 5], - F: [G: 6], - G: [C: 4], - H: [G: 3] - ]) - - when: "we use Breadth First Search algorithm for the first route" - def routeOne = bfsAlgorithm.findPath(graph, source, target) - - and: "we use Dijkstra's algorithm for the second route" - def routeTwo = dijkstras.findPath(graph, source, target) - - then: "the first route is the shortest" - routeOne == shortest - - and: 'the second route is the fastest' - routeTwo == fastest - - and: 'the distance calculated correctly' - graph.getDistance(routeOne) == t1 as double - graph.getDistance(routeTwo) == t2 as double - - where: - source | target || t1 | shortest | t2 | fastest - 'A' | 'A' || 0 | ['A'] | 0 | ['A'] - 'B' | 'B' || 0 | ['B'] | 0 | ['B'] - 'A' | 'B' || 5 | ['A', 'B'] | 5 | ['A', 'B'] - 'B' | 'A' || 5 | ['B', 'A'] | 5 | ['B', 'A'] - 'A' | 'C' || 12 | ['A', 'B', 'C'] | 9 | ['A', 'H', 'G', 'C'] - 'C' | 'A' || 12 | ['C', 'B', 'A'] | 12 | ['C', 'B', 'A'] - 'A' | 'G' || 5 | ['A', 'H', 'G'] | 5 | ['A', 'H', 'G'] - 'C' | 'D' || 3 | ['C', 'D'] | 3 | ['C', 'D'] - 'D' | 'C' || 20 | ['D', 'C'] | 19 | ['D', 'E', 'F', 'G', 'C'] - 'B' | 'D' || 10 | ['B', 'C', 'D'] | 10 | ['B', 'C', 'D'] - 'D' | 'B' || 27 | ['D', 'C', 'B'] | 26 | ['D', 'E', 'F', 'G', 'C', 'B'] - 'D' | 'H' || 34 | ['D', 'C', 'B', 'A', 'H'] | 33 | ['D', 'E', 'F', 'G', 'C', 'B', 'A', 'H'] - } - -} diff --git a/algorithm/src/test/java/lv/id/jc/algorithm/graph/DijkstrasAlgorithmTest.java b/algorithm/src/test/java/lv/id/jc/algorithm/graph/DijkstrasAlgorithmTest.java deleted file mode 100644 index 6bf0c3e..0000000 --- a/algorithm/src/test/java/lv/id/jc/algorithm/graph/DijkstrasAlgorithmTest.java +++ /dev/null @@ -1,56 +0,0 @@ -package lv.id.jc.algorithm.graph; - -import org.junit.jupiter.api.DisplayName; -import org.junit.jupiter.params.ParameterizedTest; -import org.junit.jupiter.params.provider.Arguments; -import org.junit.jupiter.params.provider.MethodSource; - -import java.util.*; -import java.util.stream.Stream; - -import static org.junit.jupiter.api.Assertions.assertEquals; - -// Java 8 + JUnit 5 + Parameterized Test -class DijkstrasAlgorithmTest { - - // Subject under test - SearchAlgorithm algorithm = new DijkstrasAlgorithm<>(); - - // Sample data - private static Stream providePathTime() { - return Stream.of( - Arguments.of("A", "A", Collections.singletonList("A"), 0), - Arguments.of("B", "A", Arrays.asList("B", "A"), 3), - Arguments.of("A", "B", Arrays.asList("A", "C", "B"), 5) - ); - } - - @ParameterizedTest - @MethodSource("providePathTime") - @DisplayName("should find a route for a simple graph") - void testRouteForSimpleGraph(String source, String target, List fastestPath, double fastestTime) { - // given - Map fromA = new HashMap<>(); - fromA.put("B", 7); - fromA.put("C", 2); - Map fromB = new HashMap<>(); - fromB.put("A", 3); - fromB.put("C", 5); - Map fromC = new HashMap<>(); - fromC.put("A", 1); - fromC.put("B", 3); - Map> nodes = new HashMap<>(); - nodes.put("A", fromA); - nodes.put("B", fromB); - nodes.put("C", fromC); - Graph graph = Graph.of(nodes); - - // when - List path = algorithm.findPath(graph, source, target); - double time = graph.getDistance(path); - - // then - assertEquals(fastestPath, path); - assertEquals(fastestTime, time); - } -} \ No newline at end of file diff --git a/algorithm/src/test/java/lv/id/jc/algorithm/graph/SearchAlgorithmsTest.java b/algorithm/src/test/java/lv/id/jc/algorithm/graph/SearchAlgorithmsTest.java deleted file mode 100644 index 92f6bd0..0000000 --- a/algorithm/src/test/java/lv/id/jc/algorithm/graph/SearchAlgorithmsTest.java +++ /dev/null @@ -1,147 +0,0 @@ -package lv.id.jc.algorithm.graph; - -import org.junit.jupiter.api.AfterEach; -import org.junit.jupiter.api.BeforeEach; -import org.junit.jupiter.api.Test; - -import java.util.ArrayList; -import java.util.LinkedHashMap; -import java.util.List; -import java.util.Map; - -import static org.junit.jupiter.api.Assertions.*; - -class SearchAlgorithmsTest { - - private SearchAlgorithm bfsAlgorithm; - private SearchAlgorithm dijkstras; - private Graph graph; - - @BeforeEach - void setUp() { - LinkedHashMap fromA = new LinkedHashMap<>(); - fromA.put("B", 5); - fromA.put("H", 2); - LinkedHashMap fromB = new LinkedHashMap<>(); - fromB.put("A", 5); - fromB.put("C", 7); - LinkedHashMap fromC = new LinkedHashMap<>(); - fromC.put("B", 7); - fromC.put("D", 3); - fromC.put("G", 4); - LinkedHashMap fromD = new LinkedHashMap<>(); - fromD.put("C", 20); - fromD.put("E", 4); - LinkedHashMap fromE = new LinkedHashMap<>(); - fromE.put("F", 5); - LinkedHashMap fromF = new LinkedHashMap<>(); - fromF.put("G", 6); - LinkedHashMap fromG = new LinkedHashMap<>(); - fromG.put("C", 4); - LinkedHashMap fromH = new LinkedHashMap<>(); - fromH.put("G", 3); - - LinkedHashMap> nodes = new LinkedHashMap<>(); - nodes.put("A", fromA); - nodes.put("B", fromB); - nodes.put("C", fromC); - nodes.put("D", fromD); - nodes.put("E", fromE); - nodes.put("F", fromF); - nodes.put("G", fromG); - nodes.put("H", fromH); - - graph = Graph.of(nodes); - dijkstras = new DijkstrasAlgorithm<>(); - bfsAlgorithm = new BreadthFirstSearch<>(); - } - - @AfterEach - void tearDown() { - graph = null; - dijkstras = null; - bfsAlgorithm = null; - } - - @Test - void testFindPathAA() { - // Java 8 - - // given - String source = "A"; - String target = "A"; - - List shortest = new ArrayList<>(); - shortest.add("A"); - - List fastest = new ArrayList<>(); - fastest.add("A"); - - // when - List routeOne = bfsAlgorithm.findPath(graph, source, target); - List routeTwo = dijkstras.findPath(graph, source, target); - - // then - assertEquals(shortest, routeOne); - assertEquals(fastest, routeTwo); - - assertEquals(0, graph.getDistance(shortest)); - assertEquals(0, graph.getDistance(fastest)); - } - - @Test - void testFindPathBB() { - // Java 11 - - var source = "B"; - var target = "B"; - - var shortest = List.of("B"); - var fastest = List.of("B"); - - var routeOne = bfsAlgorithm.findPath(graph, source, target); - var routeTwo = dijkstras.findPath(graph, source, target); - - assertEquals(shortest, routeOne); - assertEquals(fastest, routeTwo); - - assertEquals(0, graph.getDistance(shortest)); - assertEquals(0, graph.getDistance(fastest)); - } - - @Test - void testFindPathCD() { - var source = "C"; - var target = "D"; - - var shortest = List.of("C", "D"); - var fastest = List.of("C", "D"); - - var routeOne = bfsAlgorithm.findPath(graph, source, target); - var routeTwo = dijkstras.findPath(graph, source, target); - - assertEquals(shortest, routeOne); - assertEquals(fastest, routeTwo); - - assertEquals(3, graph.getDistance(shortest)); - assertEquals(3, graph.getDistance(fastest)); - } - - @Test - void testFindPathDC() { - var source = "D"; - var target = "C"; - var shortest = List.of("D", "C"); - var fastest = List.of("D", "E", "F", "G", "C"); - - var routeOne = bfsAlgorithm.findPath(graph, source, target); - var routeTwo = dijkstras.findPath(graph, source, target); - - assertEquals(shortest, routeOne); - assertEquals(fastest, routeTwo); - - assertEquals(20, graph.getDistance(shortest)); - assertEquals(19, graph.getDistance(fastest)); - } - -} \ No newline at end of file diff --git a/algorithm/src/test/resources/SpockConfig.groovy b/algorithm/src/test/resources/SpockConfig.groovy deleted file mode 100644 index 9d1c0df..0000000 --- a/algorithm/src/test/resources/SpockConfig.groovy +++ /dev/null @@ -1,14 +0,0 @@ -report { - issueNamePrefix 'Issue #' - issueUrlPrefix 'https://github.com/rabestro/algorithms/issues/' -} - -spockReports { - set(['com.athaydes.spockframework.report.showCodeBlocks' : true, - 'com.athaydes.spockframework.report.outputDir' : '../docs/spock-reports', - 'com.athaydes.spockframework.report.projectName' : 'Graph search algorithms', - 'com.athaydes.spockframework.report.projectVersion' : 1.1, - 'com.athaydes.spockframework.report.internal.HtmlReportCreator.enabled': true, - 'com.athaydes.spockframework.report.IReportCreator' : 'com.athaydes.spockframework.report.internal.HtmlReportCreator' - ]) -} \ No newline at end of file diff --git a/docs/LICENSE b/docs/LICENSE deleted file mode 100644 index 244293b..0000000 --- a/docs/LICENSE +++ /dev/null @@ -1,21 +0,0 @@ -MIT License - -Copyright (c) 2022 Jegors Čemisovs - -Permission is hereby granted, free of charge, to any person obtaining a copy -of this software and associated documentation files (the "Software"), to deal -in the Software without restriction, including without limitation the rights -to use, copy, modify, merge, publish, distribute, sublicense, and/or sell -copies of the Software, and to permit persons to whom the Software is -furnished to do so, subject to the following conditions: - -The above copyright notice and this permission notice shall be included in all -copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR -IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY, -FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE -AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER -LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, -OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE -SOFTWARE. diff --git a/docs/api/allclasses-index.html b/docs/api/allclasses-index.html deleted file mode 100644 index 55a7bac..0000000 --- a/docs/api/allclasses-index.html +++ /dev/null @@ -1,87 +0,0 @@ - - - - -All Classes and Interfaces - - - - - - - - - - - - - - -

JavaScript is disabled on your browser.
- -
- -
-
-
-

All Classes and Interfaces

-
-
-
-
-
-
Class
-
Description
- -
-
Algorithm for finding the shortest paths between nodes in a graph.
-
- -
-
Algorithm for finding the fastest paths between nodes in a graph.
-
- -
-
An interface for weighted directed graph (network)
-
- -
-
A functional interface for graph search algorithm
-
-
-
-
-
-
-
- - diff --git a/docs/api/allpackages-index.html b/docs/api/allpackages-index.html deleted file mode 100644 index 199c752..0000000 --- a/docs/api/allpackages-index.html +++ /dev/null @@ -1,67 +0,0 @@ - - - - -All Packages - - - - - - - - - - - - - - - -
- -
-
-
-

All Packages

-
-
Package Summary
-
-
Package
-
Description
- -
-
This package contains graph pathfinding algorithms.
-
-
-
-
-
- - diff --git a/docs/api/element-list b/docs/api/element-list deleted file mode 100644 index 49f1120..0000000 --- a/docs/api/element-list +++ /dev/null @@ -1,2 +0,0 @@ -module:lv.id.jc.algorithm.graph -lv.id.jc.algorithm.graph diff --git a/docs/api/help-doc.html b/docs/api/help-doc.html deleted file mode 100644 index 2a1d43d..0000000 --- a/docs/api/help-doc.html +++ /dev/null @@ -1,187 +0,0 @@ - - - - -API Help - - - - - - - - - - - - - - - -
- -
-
-

JavaDoc Help

- -
-
-

Navigation

-Starting from the Overview page, you can browse the documentation using the links in each page, and in the navigation bar at the top of each page. The Index and Search box allow you to navigate to specific declarations and summary pages, including: All Packages, All Classes and Interfaces - -
-
-
-

Kinds of Pages

-The following sections describe the different kinds of pages in this collection. -
-

Module

-

Each module has a page that contains a list of its packages, dependencies on other modules, and services, with a summary for each. These pages may contain the following categories:

-
    -
  • Packages
  • -
  • Modules
  • -
  • Services
  • -
-
-
-

Package

-

Each package has a page that contains a list of its classes and interfaces, with a summary for each. These pages may contain the following categories:

-
    -
  • Interfaces
  • -
  • Classes
  • -
  • Enum Classes
  • -
  • Exceptions
  • -
  • Errors
  • -
  • Annotation Interfaces
  • -
-
-
-

Class or Interface

-

Each class, interface, nested class and nested interface has its own separate page. Each of these pages has three sections consisting of a declaration and description, member summary tables, and detailed member descriptions. Entries in each of these sections are omitted if they are empty or not applicable.

-
    -
  • Class Inheritance Diagram
  • -
  • Direct Subclasses
  • -
  • All Known Subinterfaces
  • -
  • All Known Implementing Classes
  • -
  • Class or Interface Declaration
  • -
  • Class or Interface Description
  • -
-
-
    -
  • Nested Class Summary
  • -
  • Enum Constant Summary
  • -
  • Field Summary
  • -
  • Property Summary
  • -
  • Constructor Summary
  • -
  • Method Summary
  • -
  • Required Element Summary
  • -
  • Optional Element Summary
  • -
-
-
    -
  • Enum Constant Details
  • -
  • Field Details
  • -
  • Property Details
  • -
  • Constructor Details
  • -
  • Method Details
  • -
  • Element Details
  • -
-

Note: Annotation interfaces have required and optional elements, but not methods. Only enum classes have enum constants. The components of a record class are displayed as part of the declaration of the record class. Properties are a feature of JavaFX.

-

The summary entries are alphabetical, while the detailed descriptions are in the order they appear in the source code. This preserves the logical groupings established by the programmer.

-
-
-

Other Files

-

Packages and modules may contain pages with additional information related to the declarations nearby.

-
-
-

Use

-

Each documented package, class and interface has its own Use page. This page describes what packages, classes, methods, constructors and fields use any part of the given class or package. Given a class or interface A, its Use page includes subclasses of A, fields declared as A, methods that return A, and methods and constructors with parameters of type A. You can access this page by first going to the package, class or interface, then clicking on the USE link in the navigation bar.

-
-
-

Tree (Class Hierarchy)

-

There is a Class Hierarchy page for all packages, plus a hierarchy for each package. Each hierarchy page contains a list of classes and a list of interfaces. Classes are organized by inheritance structure starting with java.lang.Object. Interfaces do not inherit from java.lang.Object.

-
    -
  • When viewing the Overview page, clicking on TREE displays the hierarchy for all packages.
  • -
  • When viewing a particular package, class or interface page, clicking on TREE displays the hierarchy for only that package.
  • -
-
-
-

All Packages

-

The All Packages page contains an alphabetic index of all packages contained in the documentation.

-
-
-

All Classes and Interfaces

-

The All Classes and Interfaces page contains an alphabetic index of all classes and interfaces contained in the documentation, including annotation interfaces, enum classes, and record classes.

-
-
-

Index

-

The Index contains an alphabetic index of all classes, interfaces, constructors, methods, and fields in the documentation, as well as summary pages such as All Packages, All Classes and Interfaces.

-
-
-
-This help file applies to API documentation generated by the standard doclet.
-
-
- - diff --git a/docs/api/index-files/index-1.html b/docs/api/index-files/index-1.html deleted file mode 100644 index daa6c34..0000000 --- a/docs/api/index-files/index-1.html +++ /dev/null @@ -1,68 +0,0 @@ - - - - -B-Index - - - - - - - - - - - - - - - -
- -
-
-
-

Index

-
-B D E F G L O S 
All Classes and Interfaces|All Packages -

B

-
-
BreadthFirstSearch<T> - Class in lv.id.jc.algorithm.graph
-
-
Algorithm for finding the shortest paths between nodes in a graph.
-
-
BreadthFirstSearch() - Constructor for class lv.id.jc.algorithm.graph.BreadthFirstSearch
-
 
-
-B D E F G L O S 
All Classes and Interfaces|All Packages
-
-
- - diff --git a/docs/api/index-files/index-2.html b/docs/api/index-files/index-2.html deleted file mode 100644 index 81a6b1e..0000000 --- a/docs/api/index-files/index-2.html +++ /dev/null @@ -1,68 +0,0 @@ - - - - -D-Index - - - - - - - - - - - - - - - -
- -
-
-
-

Index

-
-B D E F G L O S 
All Classes and Interfaces|All Packages -

D

-
-
DijkstrasAlgorithm<T> - Class in lv.id.jc.algorithm.graph
-
-
Algorithm for finding the fastest paths between nodes in a graph.
-
-
DijkstrasAlgorithm() - Constructor for class lv.id.jc.algorithm.graph.DijkstrasAlgorithm
-
 
-
-B D E F G L O S 
All Classes and Interfaces|All Packages
-
-
- - diff --git a/docs/api/index-files/index-3.html b/docs/api/index-files/index-3.html deleted file mode 100644 index 3ccac3b..0000000 --- a/docs/api/index-files/index-3.html +++ /dev/null @@ -1,67 +0,0 @@ - - - - -E-Index - - - - - - - - - - - - - - - -
- -
-
-
-

Index

-
-B D E F G L O S 
All Classes and Interfaces|All Packages -

E

-
-
edges(T) - Method in interface lv.id.jc.algorithm.graph.Graph
-
-
Returns the edges of the given vertex, - or null if this graph contains no given vertex.
-
-
-B D E F G L O S 
All Classes and Interfaces|All Packages
-
-
- - diff --git a/docs/api/index-files/index-4.html b/docs/api/index-files/index-4.html deleted file mode 100644 index 883eb9c..0000000 --- a/docs/api/index-files/index-4.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - -F-Index - - - - - - - - - - - - - - - -
- -
-
-
-

Index

-
-B D E F G L O S 
All Classes and Interfaces|All Packages -

F

-
-
findPath(Graph<T>, T, T) - Method in class lv.id.jc.algorithm.graph.BreadthFirstSearch
-
 
-
findPath(Graph<T>, T, T) - Method in class lv.id.jc.algorithm.graph.DijkstrasAlgorithm
-
 
-
findPath(Graph<T>, T, T) - Method in interface lv.id.jc.algorithm.graph.SearchAlgorithm
-
-
Find the path from the source node to the target
-
-
-B D E F G L O S 
All Classes and Interfaces|All Packages
-
-
- - diff --git a/docs/api/index-files/index-5.html b/docs/api/index-files/index-5.html deleted file mode 100644 index 8a10798..0000000 --- a/docs/api/index-files/index-5.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - -G-Index - - - - - - - - - - - - - - - -
- -
-
-
-

Index

-
-B D E F G L O S 
All Classes and Interfaces|All Packages -

G

-
-
getDistance(List<T>) - Method in interface lv.id.jc.algorithm.graph.Graph
-
-
Calculate the distance for the given path
-
-
Graph<T> - Interface in lv.id.jc.algorithm.graph
-
-
An interface for weighted directed graph (network)
-
-
-B D E F G L O S 
All Classes and Interfaces|All Packages
-
-
- - diff --git a/docs/api/index-files/index-6.html b/docs/api/index-files/index-6.html deleted file mode 100644 index 692cd3a..0000000 --- a/docs/api/index-files/index-6.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - -L-Index - - - - - - - - - - - - - - - -
- -
-
-
-

Index

-
-B D E F G L O S 
All Classes and Interfaces|All Packages -

L

-
-
lv.id.jc.algorithm.graph - module lv.id.jc.algorithm.graph
-
-
The module contains an interface for a graph and an interface for a graph search algorithm.
-
-
lv.id.jc.algorithm.graph - package lv.id.jc.algorithm.graph
-
-
This package contains graph pathfinding algorithms.
-
-
-B D E F G L O S 
All Classes and Interfaces|All Packages
-
-
- - diff --git a/docs/api/index-files/index-7.html b/docs/api/index-files/index-7.html deleted file mode 100644 index 7eb8e27..0000000 --- a/docs/api/index-files/index-7.html +++ /dev/null @@ -1,66 +0,0 @@ - - - - -O-Index - - - - - - - - - - - - - - - -
- -
-
-
-

Index

-
-B D E F G L O S 
All Classes and Interfaces|All Packages -

O

-
-
of(Map<T, Map<T, Number>>) - Static method in interface lv.id.jc.algorithm.graph.Graph
-
-
Creates a Graph object by given schema.
-
-
-B D E F G L O S 
All Classes and Interfaces|All Packages
-
-
- - diff --git a/docs/api/index-files/index-8.html b/docs/api/index-files/index-8.html deleted file mode 100644 index 9182987..0000000 --- a/docs/api/index-files/index-8.html +++ /dev/null @@ -1,70 +0,0 @@ - - - - -S-Index - - - - - - - - - - - - - - - -
- -
-
-
-

Index

-
-B D E F G L O S 
All Classes and Interfaces|All Packages -

S

-
-
schema() - Method in interface lv.id.jc.algorithm.graph.Graph
-
-
The schema of this graph.
-
-
SearchAlgorithm<T> - Interface in lv.id.jc.algorithm.graph
-
-
A functional interface for graph search algorithm
-
-
-B D E F G L O S 
All Classes and Interfaces|All Packages
-
-
- - diff --git a/docs/api/index.html b/docs/api/index.html deleted file mode 100644 index ab284f5..0000000 --- a/docs/api/index.html +++ /dev/null @@ -1,26 +0,0 @@ - - - - -Generated Documentation (Untitled) - - - - - - - - - - - -
- -

lv.id.jc.algorithm.graph/module-summary.html

-
- - diff --git a/docs/api/jquery-ui.overrides.css b/docs/api/jquery-ui.overrides.css deleted file mode 100644 index f89acb6..0000000 --- a/docs/api/jquery-ui.overrides.css +++ /dev/null @@ -1,34 +0,0 @@ -/* - * Copyright (c) 2020, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Oracle designates this - * particular file as subject to the "Classpath" exception as provided - * by Oracle in the LICENSE file that accompanied this code. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -.ui-state-active, -.ui-widget-content .ui-state-active, -.ui-widget-header .ui-state-active, -a.ui-button:active, -.ui-button:active, -.ui-button.ui-state-active:hover { - /* Overrides the color of selection used in jQuery UI */ - background: #F8981D; -} diff --git a/docs/api/legal/ADDITIONAL_LICENSE_INFO b/docs/api/legal/ADDITIONAL_LICENSE_INFO deleted file mode 100644 index b62cc3e..0000000 --- a/docs/api/legal/ADDITIONAL_LICENSE_INFO +++ /dev/null @@ -1 +0,0 @@ -Please see ..\java.base\ADDITIONAL_LICENSE_INFO diff --git a/docs/api/legal/ASSEMBLY_EXCEPTION b/docs/api/legal/ASSEMBLY_EXCEPTION deleted file mode 100644 index 0d4cfb4..0000000 --- a/docs/api/legal/ASSEMBLY_EXCEPTION +++ /dev/null @@ -1 +0,0 @@ -Please see ..\java.base\ASSEMBLY_EXCEPTION diff --git a/docs/api/legal/LICENSE b/docs/api/legal/LICENSE deleted file mode 100644 index 4ad9fe4..0000000 --- a/docs/api/legal/LICENSE +++ /dev/null @@ -1 +0,0 @@ -Please see ..\java.base\LICENSE diff --git a/docs/api/legal/jquery.md b/docs/api/legal/jquery.md deleted file mode 100644 index 8054a34..0000000 --- a/docs/api/legal/jquery.md +++ /dev/null @@ -1,72 +0,0 @@ -## jQuery v3.5.1 - -### jQuery License -``` -jQuery v 3.5.1 -Copyright JS Foundation and other contributors, https://js.foundation/ - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -****************************************** - -The jQuery JavaScript Library v3.5.1 also includes Sizzle.js - -Sizzle.js includes the following license: - -Copyright JS Foundation and other contributors, https://js.foundation/ - -This software consists of voluntary contributions made by many -individuals. For exact contribution history, see the revision history -available at https://github.com/jquery/sizzle - -The following license applies to all parts of this software except as -documented below: - -==== - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -==== - -All files located in the node_modules and external directories are -externally maintained libraries used by this software which have their -own licenses; we recommend you read them, as their terms may differ from -the terms above. - -********************* - -``` diff --git a/docs/api/legal/jqueryUI.md b/docs/api/legal/jqueryUI.md deleted file mode 100644 index 8031bdb..0000000 --- a/docs/api/legal/jqueryUI.md +++ /dev/null @@ -1,49 +0,0 @@ -## jQuery UI v1.12.1 - -### jQuery UI License -``` -Copyright jQuery Foundation and other contributors, https://jquery.org/ - -This software consists of voluntary contributions made by many -individuals. For exact contribution history, see the revision history -available at https://github.com/jquery/jquery-ui - -The following license applies to all parts of this software except as -documented below: - -==== - -Permission is hereby granted, free of charge, to any person obtaining -a copy of this software and associated documentation files (the -"Software"), to deal in the Software without restriction, including -without limitation the rights to use, copy, modify, merge, publish, -distribute, sublicense, and/or sell copies of the Software, and to -permit persons to whom the Software is furnished to do so, subject to -the following conditions: - -The above copyright notice and this permission notice shall be -included in all copies or substantial portions of the Software. - -THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, -EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF -MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND -NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE -LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION -OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION -WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE. - -==== - -Copyright and related rights for sample code are waived via CC0. Sample -code is defined as all source code contained within the demos directory. - -CC0: http://creativecommons.org/publicdomain/zero/1.0/ - -==== - -All files located in the node_modules and external directories are -externally maintained libraries used by this software which have their -own licenses; we recommend you read them, as their terms may differ from -the terms above. - -``` diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/BreadthFirstSearch.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/BreadthFirstSearch.html deleted file mode 100644 index 9786ad2..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/BreadthFirstSearch.html +++ /dev/null @@ -1,194 +0,0 @@ - - - - -BreadthFirstSearch - - - - - - - - - - - - - - - -
- -
-
- -
- - -

Class BreadthFirstSearch<T>

-
-
java.lang.Object -
lv.id.jc.algorithm.graph.BreadthFirstSearch<T>
-
-
-
-
Type Parameters:
-
T - the type of vertex
-
-
-
All Implemented Interfaces:
-
SearchAlgorithm<T>
-
-
-
public class BreadthFirstSearch<T> -extends Object -implements SearchAlgorithm<T>
-
Algorithm for finding the shortest paths between nodes in a graph. - - The algorithm doesn't take into account the distance between nodes.
-
-
Since:
-
1.0
-
-
-
- -
-
-
    - -
  • -
    -

    Constructor Details

    -
      -
    • -
      -

      BreadthFirstSearch

      -
      public BreadthFirstSearch()
      -
      -
    • -
    -
    -
  • - -
  • -
    -

    Method Details

    -
      -
    • -
      -

      findPath

      -
      public List<T> findPath(Graph<T> graph, - T source, - T target)
      -
      Description copied from interface: SearchAlgorithm
      -
      Find the path from the source node to the target
      -
      -
      Specified by:
      -
      findPath in interface SearchAlgorithm<T>
      -
      Parameters:
      -
      graph - The graph in which we search for the path
      -
      source - Search starting point identifier
      -
      target - Search finish point identifier
      -
      Returns:
      -
      Path found or empty list if path cannot be found
      -
      -
      -
    • -
    -
    -
  • -
-
- -
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/DijkstrasAlgorithm.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/DijkstrasAlgorithm.html deleted file mode 100644 index 9f18cd7..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/DijkstrasAlgorithm.html +++ /dev/null @@ -1,194 +0,0 @@ - - - - -DijkstrasAlgorithm - - - - - - - - - - - - - - - -
- -
-
- -
- - -

Class DijkstrasAlgorithm<T>

-
-
java.lang.Object -
lv.id.jc.algorithm.graph.DijkstrasAlgorithm<T>
-
-
-
-
Type Parameters:
-
T - the type of vertex
-
-
-
All Implemented Interfaces:
-
SearchAlgorithm<T>
-
-
-
public class DijkstrasAlgorithm<T> -extends Object -implements SearchAlgorithm<T>
-
Algorithm for finding the fastest paths between nodes in a graph. -

- The algorithm uses information about edge's distance to find the fastest path.

-
-
Since:
-
1.0
-
-
-
- -
-
-
    - -
  • -
    -

    Constructor Details

    -
      -
    • -
      -

      DijkstrasAlgorithm

      -
      public DijkstrasAlgorithm()
      -
      -
    • -
    -
    -
  • - -
  • -
    -

    Method Details

    -
      -
    • -
      -

      findPath

      -
      public List<T> findPath(Graph<T> graph, - T source, - T target)
      -
      Description copied from interface: SearchAlgorithm
      -
      Find the path from the source node to the target
      -
      -
      Specified by:
      -
      findPath in interface SearchAlgorithm<T>
      -
      Parameters:
      -
      graph - The graph in which we search for the path
      -
      source - Search starting point identifier
      -
      target - Search finish point identifier
      -
      Returns:
      -
      Path found or empty list if path cannot be found
      -
      -
      -
    • -
    -
    -
  • -
-
- -
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/Graph.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/Graph.html deleted file mode 100644 index 6a70d92..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/Graph.html +++ /dev/null @@ -1,219 +0,0 @@ - - - - -Graph - - - - - - - - - - - - - - - -
- -
-
- -
- - -

Interface Graph<T>

-
-
-
-
Type Parameters:
-
T - the type of vertex in this graph
-
-
-
Functional Interface:
-
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
-
-
-
@FunctionalInterface -public interface Graph<T>
-
An interface for weighted directed graph (network)
-
-
Since:
-
1.1
-
-
-
-
    - -
  • -
    -

    Method Summary

    -
    -
    -
    -
    -
    Modifier and Type
    -
    Method
    -
    Description
    -
    default Map<T,Number>
    -
    edges(T vertex)
    -
    -
    Returns the edges of the given vertex, - or null if this graph contains no given vertex.
    -
    -
    default double
    - -
    -
    Calculate the distance for the given path
    -
    -
    static <T> Graph<T>
    -
    of(Map<T,Map<T,Number>> schema)
    -
    -
    Creates a Graph object by given schema.
    -
    - - -
    -
    The schema of this graph.
    -
    -
    -
    -
    -
    -
  • -
-
-
-
    - -
  • -
    -

    Method Details

    -
      -
    • -
      -

      schema

      -
      Map<T,Map<T,Number>> schema()
      -
      The schema of this graph. - - In a graph schema, each vertex is assigned an edge map. - If the vertex has no edges, then it should be assigned an empty map.
      -
      -
      Returns:
      -
      the graph scheme
      -
      -
      -
    • -
    • -
      -

      edges

      -
      default Map<T,Number> edges(T vertex)
      -
      Returns the edges of the given vertex, - or null if this graph contains no given vertex. - -

      A return value of null does not necessarily - indicate that the specified vertex is not present in the graph; - it's also possible that in the graph schema, null was specified - for the edges of this vertex instead of an empty map.

      -
      -
      Parameters:
      -
      vertex - vertex
      -
      Returns:
      -
      all links for the given vertex - or null if no such vertex in the graph
      -
      -
      -
    • -
    • -
      -

      getDistance

      -
      default double getDistance(List<T> path)
      -
      Calculate the distance for the given path
      -
      -
      Parameters:
      -
      path - the list of vertices representing the path
      -
      Returns:
      -
      distance for the given path as double
      -
      Throws:
      -
      NullPointerException - if path is incorrect and contains more than one vertex
      -
      -
      -
    • -
    • -
      -

      of

      -
      static <T> Graph<T> of(Map<T,Map<T,Number>> schema)
      -
      Creates a Graph object by given schema. - - In a graph schema, each vertex is assigned an edge map. - If the vertex has no edges, then it should be assigned an empty map.
      -
      -
      Type Parameters:
      -
      T - the type of vertex in this graph
      -
      Parameters:
      -
      schema - of the graph
      -
      Returns:
      -
      graph object with given schema
      -
      -
      -
    • -
    -
    -
  • -
-
- -
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/SearchAlgorithm.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/SearchAlgorithm.html deleted file mode 100644 index 388faf7..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/SearchAlgorithm.html +++ /dev/null @@ -1,159 +0,0 @@ - - - - -SearchAlgorithm - - - - - - - - - - - - - - - -
- -
-
- -
- - -

Interface SearchAlgorithm<T>

-
-
-
-
Type Parameters:
-
T - the type of vertex
-
-
-
All Known Implementing Classes:
-
BreadthFirstSearch, DijkstrasAlgorithm
-
-
-
Functional Interface:
-
This is a functional interface and can therefore be used as the assignment target for a lambda expression or method reference.
-
-
-
@FunctionalInterface -public interface SearchAlgorithm<T>
-
A functional interface for graph search algorithm
-
-
Since:
-
1.0
-
-
-
-
    - -
  • -
    -

    Method Summary

    -
    -
    -
    -
    -
    Modifier and Type
    -
    Method
    -
    Description
    - -
    findPath(Graph<T> graph, - T source, - T target)
    -
    -
    Find the path from the source node to the target
    -
    -
    -
    -
    -
    -
  • -
-
-
-
    - -
  • -
    -

    Method Details

    -
      -
    • -
      -

      findPath

      -
      List<T> findPath(Graph<T> graph, - T source, - T target)
      -
      Find the path from the source node to the target
      -
      -
      Parameters:
      -
      graph - The graph in which we search for the path
      -
      source - Search starting point identifier
      -
      target - Search finish point identifier
      -
      Returns:
      -
      Path found or empty list if path cannot be found
      -
      -
      -
    • -
    -
    -
  • -
-
- -
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/BreadthFirstSearch.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/BreadthFirstSearch.html deleted file mode 100644 index 851c94d..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/BreadthFirstSearch.html +++ /dev/null @@ -1,58 +0,0 @@ - - - - -Uses of Class lv.id.jc.algorithm.graph.BreadthFirstSearch - - - - - - - - - - - - - - - -
- -
-
-
-

Uses of Class
lv.id.jc.algorithm.graph.BreadthFirstSearch

-
-No usage of lv.id.jc.algorithm.graph.BreadthFirstSearch
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/DijkstrasAlgorithm.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/DijkstrasAlgorithm.html deleted file mode 100644 index aceb338..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/DijkstrasAlgorithm.html +++ /dev/null @@ -1,58 +0,0 @@ - - - - -Uses of Class lv.id.jc.algorithm.graph.DijkstrasAlgorithm - - - - - - - - - - - - - - - -
- -
-
-
-

Uses of Class
lv.id.jc.algorithm.graph.DijkstrasAlgorithm

-
-No usage of lv.id.jc.algorithm.graph.DijkstrasAlgorithm
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/Graph.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/Graph.html deleted file mode 100644 index 9518eb0..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/Graph.html +++ /dev/null @@ -1,101 +0,0 @@ - - - - -Uses of Interface lv.id.jc.algorithm.graph.Graph - - - - - - - - - - - - - - - -
- -
-
-
-

Uses of Interface
lv.id.jc.algorithm.graph.Graph

-
-
- -
-
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/SearchAlgorithm.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/SearchAlgorithm.html deleted file mode 100644 index 943c11b..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/class-use/SearchAlgorithm.html +++ /dev/null @@ -1,83 +0,0 @@ - - - - -Uses of Interface lv.id.jc.algorithm.graph.SearchAlgorithm - - - - - - - - - - - - - - - -
- -
-
-
-

Uses of Interface
lv.id.jc.algorithm.graph.SearchAlgorithm

-
-
- -
-
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/package-summary.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/package-summary.html deleted file mode 100644 index 10bc727..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/package-summary.html +++ /dev/null @@ -1,107 +0,0 @@ - - - - -lv.id.jc.algorithm.graph - - - - - - - - - - - - - - - -
- -
-
-
- -

Package lv.id.jc.algorithm.graph

-
-
-
package lv.id.jc.algorithm.graph
-
-
This package contains graph pathfinding algorithms.
-
-
-
    -
  • -
    -
    -
    -
    -
    Class
    -
    Description
    - -
    -
    Algorithm for finding the shortest paths between nodes in a graph.
    -
    - -
    -
    Algorithm for finding the fastest paths between nodes in a graph.
    -
    - -
    -
    An interface for weighted directed graph (network)
    -
    - -
    -
    A functional interface for graph search algorithm
    -
    -
    -
    -
    -
  • -
-
-
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/package-tree.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/package-tree.html deleted file mode 100644 index 2ba5abe..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/package-tree.html +++ /dev/null @@ -1,76 +0,0 @@ - - - - -lv.id.jc.algorithm.graph Class Hierarchy - - - - - - - - - - - - - - - -
- -
-
-
-

Hierarchy For Package lv.id.jc.algorithm.graph

-
-
-

Class Hierarchy

- -
-
-

Interface Hierarchy

- -
-
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/package-use.html b/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/package-use.html deleted file mode 100644 index 96fb0db..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/lv/id/jc/algorithm/graph/package-use.html +++ /dev/null @@ -1,79 +0,0 @@ - - - - -Uses of Package lv.id.jc.algorithm.graph - - - - - - - - - - - - - - - -
- -
-
-
-

Uses of Package
lv.id.jc.algorithm.graph

-
-
- -
-
-
-
- - diff --git a/docs/api/lv.id.jc.algorithm.graph/module-summary.html b/docs/api/lv.id.jc.algorithm.graph/module-summary.html deleted file mode 100644 index 56d0c28..0000000 --- a/docs/api/lv.id.jc.algorithm.graph/module-summary.html +++ /dev/null @@ -1,96 +0,0 @@ - - - - -lv.id.jc.algorithm.graph - - - - - - - - - - - - - - - -
- -
-
-
-

Module lv.id.jc.algorithm.graph

-
-
-
module lv.id.jc.algorithm.graph
-
- -
The module contains an interface for a graph and an interface for a graph search algorithm. - There is an implementation of two search algorithms: - Dijkstra's algorithm and Breadth First Search algorithm.
-
-
-
    -
  • -
    - -

    Packages

    -
    -
    Exports
    -
    -
    Package
    -
    Description
    - -
    -
    This package contains graph pathfinding algorithms.
    -
    -
    -
    -
    -
  • -
-
-
-
-
- - diff --git a/docs/api/member-search-index.js b/docs/api/member-search-index.js deleted file mode 100644 index c918352..0000000 --- a/docs/api/member-search-index.js +++ /dev/null @@ -1 +0,0 @@ -memberSearchIndex = [{"p":"lv.id.jc.algorithm.graph","c":"BreadthFirstSearch","l":"BreadthFirstSearch()","u":"%3Cinit%3E()"},{"p":"lv.id.jc.algorithm.graph","c":"DijkstrasAlgorithm","l":"DijkstrasAlgorithm()","u":"%3Cinit%3E()"},{"p":"lv.id.jc.algorithm.graph","c":"Graph","l":"edges(T)"},{"p":"lv.id.jc.algorithm.graph","c":"BreadthFirstSearch","l":"findPath(Graph, T, T)","u":"findPath(lv.id.jc.algorithm.graph.Graph,T,T)"},{"p":"lv.id.jc.algorithm.graph","c":"DijkstrasAlgorithm","l":"findPath(Graph, T, T)","u":"findPath(lv.id.jc.algorithm.graph.Graph,T,T)"},{"p":"lv.id.jc.algorithm.graph","c":"SearchAlgorithm","l":"findPath(Graph, T, T)","u":"findPath(lv.id.jc.algorithm.graph.Graph,T,T)"},{"p":"lv.id.jc.algorithm.graph","c":"Graph","l":"getDistance(List)","u":"getDistance(java.util.List)"},{"p":"lv.id.jc.algorithm.graph","c":"Graph","l":"of(Map>)","u":"of(java.util.Map)"},{"p":"lv.id.jc.algorithm.graph","c":"Graph","l":"schema()"}];updateSearchResults(); \ No newline at end of file diff --git a/docs/api/module-search-index.js b/docs/api/module-search-index.js deleted file mode 100644 index d489326..0000000 --- a/docs/api/module-search-index.js +++ /dev/null @@ -1 +0,0 @@ -moduleSearchIndex = [{"l":"lv.id.jc.algorithm.graph"}];updateSearchResults(); \ No newline at end of file diff --git a/docs/api/overview-tree.html b/docs/api/overview-tree.html deleted file mode 100644 index 6e58db4..0000000 --- a/docs/api/overview-tree.html +++ /dev/null @@ -1,80 +0,0 @@ - - - - -Class Hierarchy - - - - - - - - - - - - - - - -
- -
-
-
-

Hierarchy For All Packages

-Package Hierarchies: - -
-
-

Class Hierarchy

- -
-
-

Interface Hierarchy

- -
-
-
-
- - diff --git a/docs/api/package-search-index.js b/docs/api/package-search-index.js deleted file mode 100644 index f0a6cda..0000000 --- a/docs/api/package-search-index.js +++ /dev/null @@ -1 +0,0 @@ -packageSearchIndex = [{"l":"All Packages","u":"allpackages-index.html"},{"m":"lv.id.jc.algorithm.graph","l":"lv.id.jc.algorithm.graph"}];updateSearchResults(); \ No newline at end of file diff --git a/docs/api/resources/glass.png b/docs/api/resources/glass.png deleted file mode 100644 index a7f591f..0000000 Binary files a/docs/api/resources/glass.png and /dev/null differ diff --git a/docs/api/resources/x.png b/docs/api/resources/x.png deleted file mode 100644 index 30548a7..0000000 Binary files a/docs/api/resources/x.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-bg_glass_55_fbf9ee_1x400.png b/docs/api/script-dir/images/ui-bg_glass_55_fbf9ee_1x400.png deleted file mode 100644 index 34abd18..0000000 Binary files a/docs/api/script-dir/images/ui-bg_glass_55_fbf9ee_1x400.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-bg_glass_65_dadada_1x400.png b/docs/api/script-dir/images/ui-bg_glass_65_dadada_1x400.png deleted file mode 100644 index f058a93..0000000 Binary files a/docs/api/script-dir/images/ui-bg_glass_65_dadada_1x400.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-bg_glass_75_dadada_1x400.png b/docs/api/script-dir/images/ui-bg_glass_75_dadada_1x400.png deleted file mode 100644 index 2ce04c1..0000000 Binary files a/docs/api/script-dir/images/ui-bg_glass_75_dadada_1x400.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-bg_glass_75_e6e6e6_1x400.png b/docs/api/script-dir/images/ui-bg_glass_75_e6e6e6_1x400.png deleted file mode 100644 index a90afb8..0000000 Binary files a/docs/api/script-dir/images/ui-bg_glass_75_e6e6e6_1x400.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-bg_glass_95_fef1ec_1x400.png b/docs/api/script-dir/images/ui-bg_glass_95_fef1ec_1x400.png deleted file mode 100644 index dbe091f..0000000 Binary files a/docs/api/script-dir/images/ui-bg_glass_95_fef1ec_1x400.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-bg_highlight-soft_75_cccccc_1x100.png b/docs/api/script-dir/images/ui-bg_highlight-soft_75_cccccc_1x100.png deleted file mode 100644 index 5dc3593..0000000 Binary files a/docs/api/script-dir/images/ui-bg_highlight-soft_75_cccccc_1x100.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-icons_222222_256x240.png b/docs/api/script-dir/images/ui-icons_222222_256x240.png deleted file mode 100644 index e723e17..0000000 Binary files a/docs/api/script-dir/images/ui-icons_222222_256x240.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-icons_2e83ff_256x240.png b/docs/api/script-dir/images/ui-icons_2e83ff_256x240.png deleted file mode 100644 index 1f5f497..0000000 Binary files a/docs/api/script-dir/images/ui-icons_2e83ff_256x240.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-icons_454545_256x240.png b/docs/api/script-dir/images/ui-icons_454545_256x240.png deleted file mode 100644 index 618f5b0..0000000 Binary files a/docs/api/script-dir/images/ui-icons_454545_256x240.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-icons_888888_256x240.png b/docs/api/script-dir/images/ui-icons_888888_256x240.png deleted file mode 100644 index ee5e33f..0000000 Binary files a/docs/api/script-dir/images/ui-icons_888888_256x240.png and /dev/null differ diff --git a/docs/api/script-dir/images/ui-icons_cd0a0a_256x240.png b/docs/api/script-dir/images/ui-icons_cd0a0a_256x240.png deleted file mode 100644 index 7e8ebc1..0000000 Binary files a/docs/api/script-dir/images/ui-icons_cd0a0a_256x240.png and /dev/null differ diff --git a/docs/api/script-dir/jquery-3.5.1.min.js b/docs/api/script-dir/jquery-3.5.1.min.js deleted file mode 100644 index b061403..0000000 --- a/docs/api/script-dir/jquery-3.5.1.min.js +++ /dev/null @@ -1,2 +0,0 @@ -/*! jQuery v3.5.1 | (c) JS Foundation and other contributors | jquery.org/license */ -!function(e,t){"use strict";"object"==typeof module&&"object"==typeof module.exports?module.exports=e.document?t(e,!0):function(e){if(!e.document)throw new Error("jQuery requires a window with a document");return t(e)}:t(e)}("undefined"!=typeof window?window:this,function(C,e){"use strict";var t=[],r=Object.getPrototypeOf,s=t.slice,g=t.flat?function(e){return t.flat.call(e)}:function(e){return t.concat.apply([],e)},u=t.push,i=t.indexOf,n={},o=n.toString,v=n.hasOwnProperty,a=v.toString,l=a.call(Object),y={},m=function(e){return"function"==typeof e&&"number"!=typeof e.nodeType},x=function(e){return null!=e&&e===e.window},E=C.document,c={type:!0,src:!0,nonce:!0,noModule:!0};function b(e,t,n){var r,i,o=(n=n||E).createElement("script");if(o.text=e,t)for(r in c)(i=t[r]||t.getAttribute&&t.getAttribute(r))&&o.setAttribute(r,i);n.head.appendChild(o).parentNode.removeChild(o)}function w(e){return null==e?e+"":"object"==typeof e||"function"==typeof e?n[o.call(e)]||"object":typeof e}var f="3.5.1",S=function(e,t){return new S.fn.init(e,t)};function p(e){var t=!!e&&"length"in e&&e.length,n=w(e);return!m(e)&&!x(e)&&("array"===n||0===t||"number"==typeof t&&0+~]|"+M+")"+M+"*"),U=new RegExp(M+"|>"),X=new RegExp(F),V=new RegExp("^"+I+"$"),G={ID:new RegExp("^#("+I+")"),CLASS:new RegExp("^\\.("+I+")"),TAG:new RegExp("^("+I+"|[*])"),ATTR:new RegExp("^"+W),PSEUDO:new RegExp("^"+F),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+M+"*(even|odd|(([+-]|)(\\d*)n|)"+M+"*(?:([+-]|)"+M+"*(\\d+)|))"+M+"*\\)|)","i"),bool:new RegExp("^(?:"+R+")$","i"),needsContext:new RegExp("^"+M+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+M+"*((?:-\\d)?\\d*)"+M+"*\\)|)(?=[^-]|$)","i")},Y=/HTML$/i,Q=/^(?:input|select|textarea|button)$/i,J=/^h\d$/i,K=/^[^{]+\{\s*\[native \w/,Z=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,ee=/[+~]/,te=new RegExp("\\\\[\\da-fA-F]{1,6}"+M+"?|\\\\([^\\r\\n\\f])","g"),ne=function(e,t){var n="0x"+e.slice(1)-65536;return t||(n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320))},re=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,ie=function(e,t){return t?"\0"===e?"\ufffd":e.slice(0,-1)+"\\"+e.charCodeAt(e.length-1).toString(16)+" ":"\\"+e},oe=function(){T()},ae=be(function(e){return!0===e.disabled&&"fieldset"===e.nodeName.toLowerCase()},{dir:"parentNode",next:"legend"});try{H.apply(t=O.call(p.childNodes),p.childNodes),t[p.childNodes.length].nodeType}catch(e){H={apply:t.length?function(e,t){L.apply(e,O.call(t))}:function(e,t){var n=e.length,r=0;while(e[n++]=t[r++]);e.length=n-1}}}function se(t,e,n,r){var i,o,a,s,u,l,c,f=e&&e.ownerDocument,p=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==p&&9!==p&&11!==p)return n;if(!r&&(T(e),e=e||C,E)){if(11!==p&&(u=Z.exec(t)))if(i=u[1]){if(9===p){if(!(a=e.getElementById(i)))return n;if(a.id===i)return n.push(a),n}else if(f&&(a=f.getElementById(i))&&y(e,a)&&a.id===i)return n.push(a),n}else{if(u[2])return H.apply(n,e.getElementsByTagName(t)),n;if((i=u[3])&&d.getElementsByClassName&&e.getElementsByClassName)return H.apply(n,e.getElementsByClassName(i)),n}if(d.qsa&&!N[t+" "]&&(!v||!v.test(t))&&(1!==p||"object"!==e.nodeName.toLowerCase())){if(c=t,f=e,1===p&&(U.test(t)||z.test(t))){(f=ee.test(t)&&ye(e.parentNode)||e)===e&&d.scope||((s=e.getAttribute("id"))?s=s.replace(re,ie):e.setAttribute("id",s=S)),o=(l=h(t)).length;while(o--)l[o]=(s?"#"+s:":scope")+" "+xe(l[o]);c=l.join(",")}try{return H.apply(n,f.querySelectorAll(c)),n}catch(e){N(t,!0)}finally{s===S&&e.removeAttribute("id")}}}return g(t.replace($,"$1"),e,n,r)}function ue(){var r=[];return function e(t,n){return r.push(t+" ")>b.cacheLength&&delete e[r.shift()],e[t+" "]=n}}function le(e){return e[S]=!0,e}function ce(e){var t=C.createElement("fieldset");try{return!!e(t)}catch(e){return!1}finally{t.parentNode&&t.parentNode.removeChild(t),t=null}}function fe(e,t){var n=e.split("|"),r=n.length;while(r--)b.attrHandle[n[r]]=t}function pe(e,t){var n=t&&e,r=n&&1===e.nodeType&&1===t.nodeType&&e.sourceIndex-t.sourceIndex;if(r)return r;if(n)while(n=n.nextSibling)if(n===t)return-1;return e?1:-1}function de(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function he(n){return function(e){var t=e.nodeName.toLowerCase();return("input"===t||"button"===t)&&e.type===n}}function ge(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&ae(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function ve(a){return le(function(o){return o=+o,le(function(e,t){var n,r=a([],e.length,o),i=r.length;while(i--)e[n=r[i]]&&(e[n]=!(t[n]=e[n]))})})}function ye(e){return e&&"undefined"!=typeof e.getElementsByTagName&&e}for(e in d=se.support={},i=se.isXML=function(e){var t=e.namespaceURI,n=(e.ownerDocument||e).documentElement;return!Y.test(t||n&&n.nodeName||"HTML")},T=se.setDocument=function(e){var t,n,r=e?e.ownerDocument||e:p;return r!=C&&9===r.nodeType&&r.documentElement&&(a=(C=r).documentElement,E=!i(C),p!=C&&(n=C.defaultView)&&n.top!==n&&(n.addEventListener?n.addEventListener("unload",oe,!1):n.attachEvent&&n.attachEvent("onunload",oe)),d.scope=ce(function(e){return a.appendChild(e).appendChild(C.createElement("div")),"undefined"!=typeof e.querySelectorAll&&!e.querySelectorAll(":scope fieldset div").length}),d.attributes=ce(function(e){return e.className="i",!e.getAttribute("className")}),d.getElementsByTagName=ce(function(e){return e.appendChild(C.createComment("")),!e.getElementsByTagName("*").length}),d.getElementsByClassName=K.test(C.getElementsByClassName),d.getById=ce(function(e){return a.appendChild(e).id=S,!C.getElementsByName||!C.getElementsByName(S).length}),d.getById?(b.filter.ID=function(e){var t=e.replace(te,ne);return function(e){return e.getAttribute("id")===t}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n=t.getElementById(e);return n?[n]:[]}}):(b.filter.ID=function(e){var n=e.replace(te,ne);return function(e){var t="undefined"!=typeof e.getAttributeNode&&e.getAttributeNode("id");return t&&t.value===n}},b.find.ID=function(e,t){if("undefined"!=typeof t.getElementById&&E){var n,r,i,o=t.getElementById(e);if(o){if((n=o.getAttributeNode("id"))&&n.value===e)return[o];i=t.getElementsByName(e),r=0;while(o=i[r++])if((n=o.getAttributeNode("id"))&&n.value===e)return[o]}return[]}}),b.find.TAG=d.getElementsByTagName?function(e,t){return"undefined"!=typeof t.getElementsByTagName?t.getElementsByTagName(e):d.qsa?t.querySelectorAll(e):void 0}:function(e,t){var n,r=[],i=0,o=t.getElementsByTagName(e);if("*"===e){while(n=o[i++])1===n.nodeType&&r.push(n);return r}return o},b.find.CLASS=d.getElementsByClassName&&function(e,t){if("undefined"!=typeof t.getElementsByClassName&&E)return t.getElementsByClassName(e)},s=[],v=[],(d.qsa=K.test(C.querySelectorAll))&&(ce(function(e){var t;a.appendChild(e).innerHTML="",e.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+M+"*(?:''|\"\")"),e.querySelectorAll("[selected]").length||v.push("\\["+M+"*(?:value|"+R+")"),e.querySelectorAll("[id~="+S+"-]").length||v.push("~="),(t=C.createElement("input")).setAttribute("name",""),e.appendChild(t),e.querySelectorAll("[name='']").length||v.push("\\["+M+"*name"+M+"*="+M+"*(?:''|\"\")"),e.querySelectorAll(":checked").length||v.push(":checked"),e.querySelectorAll("a#"+S+"+*").length||v.push(".#.+[+~]"),e.querySelectorAll("\\\f"),v.push("[\\r\\n\\f]")}),ce(function(e){e.innerHTML="";var t=C.createElement("input");t.setAttribute("type","hidden"),e.appendChild(t).setAttribute("name","D"),e.querySelectorAll("[name=d]").length&&v.push("name"+M+"*[*^$|!~]?="),2!==e.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),a.appendChild(e).disabled=!0,2!==e.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),e.querySelectorAll("*,:x"),v.push(",.*:")})),(d.matchesSelector=K.test(c=a.matches||a.webkitMatchesSelector||a.mozMatchesSelector||a.oMatchesSelector||a.msMatchesSelector))&&ce(function(e){d.disconnectedMatch=c.call(e,"*"),c.call(e,"[s!='']:x"),s.push("!=",F)}),v=v.length&&new RegExp(v.join("|")),s=s.length&&new RegExp(s.join("|")),t=K.test(a.compareDocumentPosition),y=t||K.test(a.contains)?function(e,t){var n=9===e.nodeType?e.documentElement:e,r=t&&t.parentNode;return e===r||!(!r||1!==r.nodeType||!(n.contains?n.contains(r):e.compareDocumentPosition&&16&e.compareDocumentPosition(r)))}:function(e,t){if(t)while(t=t.parentNode)if(t===e)return!0;return!1},D=t?function(e,t){if(e===t)return l=!0,0;var n=!e.compareDocumentPosition-!t.compareDocumentPosition;return n||(1&(n=(e.ownerDocument||e)==(t.ownerDocument||t)?e.compareDocumentPosition(t):1)||!d.sortDetached&&t.compareDocumentPosition(e)===n?e==C||e.ownerDocument==p&&y(p,e)?-1:t==C||t.ownerDocument==p&&y(p,t)?1:u?P(u,e)-P(u,t):0:4&n?-1:1)}:function(e,t){if(e===t)return l=!0,0;var n,r=0,i=e.parentNode,o=t.parentNode,a=[e],s=[t];if(!i||!o)return e==C?-1:t==C?1:i?-1:o?1:u?P(u,e)-P(u,t):0;if(i===o)return pe(e,t);n=e;while(n=n.parentNode)a.unshift(n);n=t;while(n=n.parentNode)s.unshift(n);while(a[r]===s[r])r++;return r?pe(a[r],s[r]):a[r]==p?-1:s[r]==p?1:0}),C},se.matches=function(e,t){return se(e,null,null,t)},se.matchesSelector=function(e,t){if(T(e),d.matchesSelector&&E&&!N[t+" "]&&(!s||!s.test(t))&&(!v||!v.test(t)))try{var n=c.call(e,t);if(n||d.disconnectedMatch||e.document&&11!==e.document.nodeType)return n}catch(e){N(t,!0)}return 0":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(e){return e[1]=e[1].replace(te,ne),e[3]=(e[3]||e[4]||e[5]||"").replace(te,ne),"~="===e[2]&&(e[3]=" "+e[3]+" "),e.slice(0,4)},CHILD:function(e){return e[1]=e[1].toLowerCase(),"nth"===e[1].slice(0,3)?(e[3]||se.error(e[0]),e[4]=+(e[4]?e[5]+(e[6]||1):2*("even"===e[3]||"odd"===e[3])),e[5]=+(e[7]+e[8]||"odd"===e[3])):e[3]&&se.error(e[0]),e},PSEUDO:function(e){var t,n=!e[6]&&e[2];return G.CHILD.test(e[0])?null:(e[3]?e[2]=e[4]||e[5]||"":n&&X.test(n)&&(t=h(n,!0))&&(t=n.indexOf(")",n.length-t)-n.length)&&(e[0]=e[0].slice(0,t),e[2]=n.slice(0,t)),e.slice(0,3))}},filter:{TAG:function(e){var t=e.replace(te,ne).toLowerCase();return"*"===e?function(){return!0}:function(e){return e.nodeName&&e.nodeName.toLowerCase()===t}},CLASS:function(e){var t=m[e+" "];return t||(t=new RegExp("(^|"+M+")"+e+"("+M+"|$)"))&&m(e,function(e){return t.test("string"==typeof e.className&&e.className||"undefined"!=typeof e.getAttribute&&e.getAttribute("class")||"")})},ATTR:function(n,r,i){return function(e){var t=se.attr(e,n);return null==t?"!="===r:!r||(t+="","="===r?t===i:"!="===r?t!==i:"^="===r?i&&0===t.indexOf(i):"*="===r?i&&-1:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function D(e,n,r){return m(n)?S.grep(e,function(e,t){return!!n.call(e,t,e)!==r}):n.nodeType?S.grep(e,function(e){return e===n!==r}):"string"!=typeof n?S.grep(e,function(e){return-1)[^>]*|#([\w-]+))$/;(S.fn.init=function(e,t,n){var r,i;if(!e)return this;if(n=n||j,"string"==typeof e){if(!(r="<"===e[0]&&">"===e[e.length-1]&&3<=e.length?[null,e,null]:q.exec(e))||!r[1]&&t)return!t||t.jquery?(t||n).find(e):this.constructor(t).find(e);if(r[1]){if(t=t instanceof S?t[0]:t,S.merge(this,S.parseHTML(r[1],t&&t.nodeType?t.ownerDocument||t:E,!0)),N.test(r[1])&&S.isPlainObject(t))for(r in t)m(this[r])?this[r](t[r]):this.attr(r,t[r]);return this}return(i=E.getElementById(r[2]))&&(this[0]=i,this.length=1),this}return e.nodeType?(this[0]=e,this.length=1,this):m(e)?void 0!==n.ready?n.ready(e):e(S):S.makeArray(e,this)}).prototype=S.fn,j=S(E);var L=/^(?:parents|prev(?:Until|All))/,H={children:!0,contents:!0,next:!0,prev:!0};function O(e,t){while((e=e[t])&&1!==e.nodeType);return e}S.fn.extend({has:function(e){var t=S(e,this),n=t.length;return this.filter(function(){for(var e=0;e\x20\t\r\n\f]*)/i,he=/^$|^module$|\/(?:java|ecma)script/i;ce=E.createDocumentFragment().appendChild(E.createElement("div")),(fe=E.createElement("input")).setAttribute("type","radio"),fe.setAttribute("checked","checked"),fe.setAttribute("name","t"),ce.appendChild(fe),y.checkClone=ce.cloneNode(!0).cloneNode(!0).lastChild.checked,ce.innerHTML="",y.noCloneChecked=!!ce.cloneNode(!0).lastChild.defaultValue,ce.innerHTML="",y.option=!!ce.lastChild;var ge={thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function ve(e,t){var n;return n="undefined"!=typeof e.getElementsByTagName?e.getElementsByTagName(t||"*"):"undefined"!=typeof e.querySelectorAll?e.querySelectorAll(t||"*"):[],void 0===t||t&&A(e,t)?S.merge([e],n):n}function ye(e,t){for(var n=0,r=e.length;n",""]);var me=/<|&#?\w+;/;function xe(e,t,n,r,i){for(var o,a,s,u,l,c,f=t.createDocumentFragment(),p=[],d=0,h=e.length;d\s*$/g;function qe(e,t){return A(e,"table")&&A(11!==t.nodeType?t:t.firstChild,"tr")&&S(e).children("tbody")[0]||e}function Le(e){return e.type=(null!==e.getAttribute("type"))+"/"+e.type,e}function He(e){return"true/"===(e.type||"").slice(0,5)?e.type=e.type.slice(5):e.removeAttribute("type"),e}function Oe(e,t){var n,r,i,o,a,s;if(1===t.nodeType){if(Y.hasData(e)&&(s=Y.get(e).events))for(i in Y.remove(t,"handle events"),s)for(n=0,r=s[i].length;n").attr(n.scriptAttrs||{}).prop({charset:n.scriptCharset,src:n.url}).on("load error",i=function(e){r.remove(),i=null,e&&t("error"===e.type?404:200,e.type)}),E.head.appendChild(r[0])},abort:function(){i&&i()}}});var Ut,Xt=[],Vt=/(=)\?(?=&|$)|\?\?/;S.ajaxSetup({jsonp:"callback",jsonpCallback:function(){var e=Xt.pop()||S.expando+"_"+Ct.guid++;return this[e]=!0,e}}),S.ajaxPrefilter("json jsonp",function(e,t,n){var r,i,o,a=!1!==e.jsonp&&(Vt.test(e.url)?"url":"string"==typeof e.data&&0===(e.contentType||"").indexOf("application/x-www-form-urlencoded")&&Vt.test(e.data)&&"data");if(a||"jsonp"===e.dataTypes[0])return r=e.jsonpCallback=m(e.jsonpCallback)?e.jsonpCallback():e.jsonpCallback,a?e[a]=e[a].replace(Vt,"$1"+r):!1!==e.jsonp&&(e.url+=(Et.test(e.url)?"&":"?")+e.jsonp+"="+r),e.converters["script json"]=function(){return o||S.error(r+" was not called"),o[0]},e.dataTypes[0]="json",i=C[r],C[r]=function(){o=arguments},n.always(function(){void 0===i?S(C).removeProp(r):C[r]=i,e[r]&&(e.jsonpCallback=t.jsonpCallback,Xt.push(r)),o&&m(i)&&i(o[0]),o=i=void 0}),"script"}),y.createHTMLDocument=((Ut=E.implementation.createHTMLDocument("").body).innerHTML="
",2===Ut.childNodes.length),S.parseHTML=function(e,t,n){return"string"!=typeof e?[]:("boolean"==typeof t&&(n=t,t=!1),t||(y.createHTMLDocument?((r=(t=E.implementation.createHTMLDocument("")).createElement("base")).href=E.location.href,t.head.appendChild(r)):t=E),o=!n&&[],(i=N.exec(e))?[t.createElement(i[1])]:(i=xe([e],t,o),o&&o.length&&S(o).remove(),S.merge([],i.childNodes)));var r,i,o},S.fn.load=function(e,t,n){var r,i,o,a=this,s=e.indexOf(" ");return-1").append(S.parseHTML(e)).find(r):e)}).always(n&&function(e,t){a.each(function(){n.apply(this,o||[e.responseText,t,e])})}),this},S.expr.pseudos.animated=function(t){return S.grep(S.timers,function(e){return t===e.elem}).length},S.offset={setOffset:function(e,t,n){var r,i,o,a,s,u,l=S.css(e,"position"),c=S(e),f={};"static"===l&&(e.style.position="relative"),s=c.offset(),o=S.css(e,"top"),u=S.css(e,"left"),("absolute"===l||"fixed"===l)&&-1<(o+u).indexOf("auto")?(a=(r=c.position()).top,i=r.left):(a=parseFloat(o)||0,i=parseFloat(u)||0),m(t)&&(t=t.call(e,n,S.extend({},s))),null!=t.top&&(f.top=t.top-s.top+a),null!=t.left&&(f.left=t.left-s.left+i),"using"in t?t.using.call(e,f):("number"==typeof f.top&&(f.top+="px"),"number"==typeof f.left&&(f.left+="px"),c.css(f))}},S.fn.extend({offset:function(t){if(arguments.length)return void 0===t?this:this.each(function(e){S.offset.setOffset(this,t,e)});var e,n,r=this[0];return r?r.getClientRects().length?(e=r.getBoundingClientRect(),n=r.ownerDocument.defaultView,{top:e.top+n.pageYOffset,left:e.left+n.pageXOffset}):{top:0,left:0}:void 0},position:function(){if(this[0]){var e,t,n,r=this[0],i={top:0,left:0};if("fixed"===S.css(r,"position"))t=r.getBoundingClientRect();else{t=this.offset(),n=r.ownerDocument,e=r.offsetParent||n.documentElement;while(e&&(e===n.body||e===n.documentElement)&&"static"===S.css(e,"position"))e=e.parentNode;e&&e!==r&&1===e.nodeType&&((i=S(e).offset()).top+=S.css(e,"borderTopWidth",!0),i.left+=S.css(e,"borderLeftWidth",!0))}return{top:t.top-i.top-S.css(r,"marginTop",!0),left:t.left-i.left-S.css(r,"marginLeft",!0)}}},offsetParent:function(){return this.map(function(){var e=this.offsetParent;while(e&&"static"===S.css(e,"position"))e=e.offsetParent;return e||re})}}),S.each({scrollLeft:"pageXOffset",scrollTop:"pageYOffset"},function(t,i){var o="pageYOffset"===i;S.fn[t]=function(e){return $(this,function(e,t,n){var r;if(x(e)?r=e:9===e.nodeType&&(r=e.defaultView),void 0===n)return r?r[i]:e[t];r?r.scrollTo(o?r.pageXOffset:n,o?n:r.pageYOffset):e[t]=n},t,e,arguments.length)}}),S.each(["top","left"],function(e,n){S.cssHooks[n]=$e(y.pixelPosition,function(e,t){if(t)return t=Be(e,n),Me.test(t)?S(e).position()[n]+"px":t})}),S.each({Height:"height",Width:"width"},function(a,s){S.each({padding:"inner"+a,content:s,"":"outer"+a},function(r,o){S.fn[o]=function(e,t){var n=arguments.length&&(r||"boolean"!=typeof e),i=r||(!0===e||!0===t?"margin":"border");return $(this,function(e,t,n){var r;return x(e)?0===o.indexOf("outer")?e["inner"+a]:e.document.documentElement["client"+a]:9===e.nodeType?(r=e.documentElement,Math.max(e.body["scroll"+a],r["scroll"+a],e.body["offset"+a],r["offset"+a],r["client"+a])):void 0===n?S.css(e,t,i):S.style(e,t,n,i)},s,n?e:void 0,n)}})}),S.each(["ajaxStart","ajaxStop","ajaxComplete","ajaxError","ajaxSuccess","ajaxSend"],function(e,t){S.fn[t]=function(e){return this.on(t,e)}}),S.fn.extend({bind:function(e,t,n){return this.on(e,null,t,n)},unbind:function(e,t){return this.off(e,null,t)},delegate:function(e,t,n,r){return this.on(t,e,n,r)},undelegate:function(e,t,n){return 1===arguments.length?this.off(e,"**"):this.off(t,e||"**",n)},hover:function(e,t){return this.mouseenter(e).mouseleave(t||e)}}),S.each("blur focus focusin focusout resize scroll click dblclick mousedown mouseup mousemove mouseover mouseout mouseenter mouseleave change select submit keydown keypress keyup contextmenu".split(" "),function(e,n){S.fn[n]=function(e,t){return 0a;a++)for(s in o[a])n=o[a][s],o[a].hasOwnProperty(s)&&void 0!==n&&(e[s]=t.isPlainObject(n)?t.isPlainObject(e[s])?t.widget.extend({},e[s],n):t.widget.extend({},n):n);return e},t.widget.bridge=function(e,s){var n=s.prototype.widgetFullName||e;t.fn[e]=function(o){var a="string"==typeof o,r=i.call(arguments,1),l=this;return a?this.length||"instance"!==o?this.each(function(){var i,s=t.data(this,n);return"instance"===o?(l=s,!1):s?t.isFunction(s[o])&&"_"!==o.charAt(0)?(i=s[o].apply(s,r),i!==s&&void 0!==i?(l=i&&i.jquery?l.pushStack(i.get()):i,!1):void 0):t.error("no such method '"+o+"' for "+e+" widget instance"):t.error("cannot call methods on "+e+" prior to initialization; "+"attempted to call method '"+o+"'")}):l=void 0:(r.length&&(o=t.widget.extend.apply(null,[o].concat(r))),this.each(function(){var e=t.data(this,n);e?(e.option(o||{}),e._init&&e._init()):t.data(this,n,new s(o,this))})),l}},t.Widget=function(){},t.Widget._childConstructors=[],t.Widget.prototype={widgetName:"widget",widgetEventPrefix:"",defaultElement:"
",options:{classes:{},disabled:!1,create:null},_createWidget:function(i,s){s=t(s||this.defaultElement||this)[0],this.element=t(s),this.uuid=e++,this.eventNamespace="."+this.widgetName+this.uuid,this.bindings=t(),this.hoverable=t(),this.focusable=t(),this.classesElementLookup={},s!==this&&(t.data(s,this.widgetFullName,this),this._on(!0,this.element,{remove:function(t){t.target===s&&this.destroy()}}),this.document=t(s.style?s.ownerDocument:s.document||s),this.window=t(this.document[0].defaultView||this.document[0].parentWindow)),this.options=t.widget.extend({},this.options,this._getCreateOptions(),i),this._create(),this.options.disabled&&this._setOptionDisabled(this.options.disabled),this._trigger("create",null,this._getCreateEventData()),this._init()},_getCreateOptions:function(){return{}},_getCreateEventData:t.noop,_create:t.noop,_init:t.noop,destroy:function(){var e=this;this._destroy(),t.each(this.classesElementLookup,function(t,i){e._removeClass(i,t)}),this.element.off(this.eventNamespace).removeData(this.widgetFullName),this.widget().off(this.eventNamespace).removeAttr("aria-disabled"),this.bindings.off(this.eventNamespace)},_destroy:t.noop,widget:function(){return this.element},option:function(e,i){var s,n,o,a=e;if(0===arguments.length)return t.widget.extend({},this.options);if("string"==typeof e)if(a={},s=e.split("."),e=s.shift(),s.length){for(n=a[e]=t.widget.extend({},this.options[e]),o=0;s.length-1>o;o++)n[s[o]]=n[s[o]]||{},n=n[s[o]];if(e=s.pop(),1===arguments.length)return void 0===n[e]?null:n[e];n[e]=i}else{if(1===arguments.length)return void 0===this.options[e]?null:this.options[e];a[e]=i}return this._setOptions(a),this},_setOptions:function(t){var e;for(e in t)this._setOption(e,t[e]);return this},_setOption:function(t,e){return"classes"===t&&this._setOptionClasses(e),this.options[t]=e,"disabled"===t&&this._setOptionDisabled(e),this},_setOptionClasses:function(e){var i,s,n;for(i in e)n=this.classesElementLookup[i],e[i]!==this.options.classes[i]&&n&&n.length&&(s=t(n.get()),this._removeClass(n,i),s.addClass(this._classes({element:s,keys:i,classes:e,add:!0})))},_setOptionDisabled:function(t){this._toggleClass(this.widget(),this.widgetFullName+"-disabled",null,!!t),t&&(this._removeClass(this.hoverable,null,"ui-state-hover"),this._removeClass(this.focusable,null,"ui-state-focus"))},enable:function(){return this._setOptions({disabled:!1})},disable:function(){return this._setOptions({disabled:!0})},_classes:function(e){function i(i,o){var a,r;for(r=0;i.length>r;r++)a=n.classesElementLookup[i[r]]||t(),a=e.add?t(t.unique(a.get().concat(e.element.get()))):t(a.not(e.element).get()),n.classesElementLookup[i[r]]=a,s.push(i[r]),o&&e.classes[i[r]]&&s.push(e.classes[i[r]])}var s=[],n=this;return e=t.extend({element:this.element,classes:this.options.classes||{}},e),this._on(e.element,{remove:"_untrackClassesElement"}),e.keys&&i(e.keys.match(/\S+/g)||[],!0),e.extra&&i(e.extra.match(/\S+/g)||[]),s.join(" ")},_untrackClassesElement:function(e){var i=this;t.each(i.classesElementLookup,function(s,n){-1!==t.inArray(e.target,n)&&(i.classesElementLookup[s]=t(n.not(e.target).get()))})},_removeClass:function(t,e,i){return this._toggleClass(t,e,i,!1)},_addClass:function(t,e,i){return this._toggleClass(t,e,i,!0)},_toggleClass:function(t,e,i,s){s="boolean"==typeof s?s:i;var n="string"==typeof t||null===t,o={extra:n?e:i,keys:n?t:e,element:n?this.element:t,add:s};return o.element.toggleClass(this._classes(o),s),this},_on:function(e,i,s){var n,o=this;"boolean"!=typeof e&&(s=i,i=e,e=!1),s?(i=n=t(i),this.bindings=this.bindings.add(i)):(s=i,i=this.element,n=this.widget()),t.each(s,function(s,a){function r(){return e||o.options.disabled!==!0&&!t(this).hasClass("ui-state-disabled")?("string"==typeof a?o[a]:a).apply(o,arguments):void 0}"string"!=typeof a&&(r.guid=a.guid=a.guid||r.guid||t.guid++);var l=s.match(/^([\w:-]*)\s*(.*)$/),h=l[1]+o.eventNamespace,c=l[2];c?n.on(h,c,r):i.on(h,r)})},_off:function(e,i){i=(i||"").split(" ").join(this.eventNamespace+" ")+this.eventNamespace,e.off(i).off(i),this.bindings=t(this.bindings.not(e).get()),this.focusable=t(this.focusable.not(e).get()),this.hoverable=t(this.hoverable.not(e).get())},_delay:function(t,e){function i(){return("string"==typeof t?s[t]:t).apply(s,arguments)}var s=this;return setTimeout(i,e||0)},_hoverable:function(e){this.hoverable=this.hoverable.add(e),this._on(e,{mouseenter:function(e){this._addClass(t(e.currentTarget),null,"ui-state-hover")},mouseleave:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-hover")}})},_focusable:function(e){this.focusable=this.focusable.add(e),this._on(e,{focusin:function(e){this._addClass(t(e.currentTarget),null,"ui-state-focus")},focusout:function(e){this._removeClass(t(e.currentTarget),null,"ui-state-focus")}})},_trigger:function(e,i,s){var n,o,a=this.options[e];if(s=s||{},i=t.Event(i),i.type=(e===this.widgetEventPrefix?e:this.widgetEventPrefix+e).toLowerCase(),i.target=this.element[0],o=i.originalEvent)for(n in o)n in i||(i[n]=o[n]);return this.element.trigger(i,s),!(t.isFunction(a)&&a.apply(this.element[0],[i].concat(s))===!1||i.isDefaultPrevented())}},t.each({show:"fadeIn",hide:"fadeOut"},function(e,i){t.Widget.prototype["_"+e]=function(s,n,o){"string"==typeof n&&(n={effect:n});var a,r=n?n===!0||"number"==typeof n?i:n.effect||i:e;n=n||{},"number"==typeof n&&(n={duration:n}),a=!t.isEmptyObject(n),n.complete=o,n.delay&&s.delay(n.delay),a&&t.effects&&t.effects.effect[r]?s[e](n):r!==e&&s[r]?s[r](n.duration,n.easing,o):s.queue(function(i){t(this)[e](),o&&o.call(s[0]),i()})}}),t.widget,function(){function e(t,e,i){return[parseFloat(t[0])*(u.test(t[0])?e/100:1),parseFloat(t[1])*(u.test(t[1])?i/100:1)]}function i(e,i){return parseInt(t.css(e,i),10)||0}function s(e){var i=e[0];return 9===i.nodeType?{width:e.width(),height:e.height(),offset:{top:0,left:0}}:t.isWindow(i)?{width:e.width(),height:e.height(),offset:{top:e.scrollTop(),left:e.scrollLeft()}}:i.preventDefault?{width:0,height:0,offset:{top:i.pageY,left:i.pageX}}:{width:e.outerWidth(),height:e.outerHeight(),offset:e.offset()}}var n,o=Math.max,a=Math.abs,r=/left|center|right/,l=/top|center|bottom/,h=/[\+\-]\d+(\.[\d]+)?%?/,c=/^\w+/,u=/%$/,d=t.fn.position;t.position={scrollbarWidth:function(){if(void 0!==n)return n;var e,i,s=t("
"),o=s.children()[0];return t("body").append(s),e=o.offsetWidth,s.css("overflow","scroll"),i=o.offsetWidth,e===i&&(i=s[0].clientWidth),s.remove(),n=e-i},getScrollInfo:function(e){var i=e.isWindow||e.isDocument?"":e.element.css("overflow-x"),s=e.isWindow||e.isDocument?"":e.element.css("overflow-y"),n="scroll"===i||"auto"===i&&e.widthi?"left":e>0?"right":"center",vertical:0>r?"top":s>0?"bottom":"middle"};h>p&&p>a(e+i)&&(u.horizontal="center"),c>f&&f>a(s+r)&&(u.vertical="middle"),u.important=o(a(e),a(i))>o(a(s),a(r))?"horizontal":"vertical",n.using.call(this,t,u)}),l.offset(t.extend(D,{using:r}))})},t.ui.position={fit:{left:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollLeft:s.offset.left,a=s.width,r=t.left-e.collisionPosition.marginLeft,l=n-r,h=r+e.collisionWidth-a-n;e.collisionWidth>a?l>0&&0>=h?(i=t.left+l+e.collisionWidth-a-n,t.left+=l-i):t.left=h>0&&0>=l?n:l>h?n+a-e.collisionWidth:n:l>0?t.left+=l:h>0?t.left-=h:t.left=o(t.left-r,t.left)},top:function(t,e){var i,s=e.within,n=s.isWindow?s.scrollTop:s.offset.top,a=e.within.height,r=t.top-e.collisionPosition.marginTop,l=n-r,h=r+e.collisionHeight-a-n;e.collisionHeight>a?l>0&&0>=h?(i=t.top+l+e.collisionHeight-a-n,t.top+=l-i):t.top=h>0&&0>=l?n:l>h?n+a-e.collisionHeight:n:l>0?t.top+=l:h>0?t.top-=h:t.top=o(t.top-r,t.top)}},flip:{left:function(t,e){var i,s,n=e.within,o=n.offset.left+n.scrollLeft,r=n.width,l=n.isWindow?n.scrollLeft:n.offset.left,h=t.left-e.collisionPosition.marginLeft,c=h-l,u=h+e.collisionWidth-r-l,d="left"===e.my[0]?-e.elemWidth:"right"===e.my[0]?e.elemWidth:0,p="left"===e.at[0]?e.targetWidth:"right"===e.at[0]?-e.targetWidth:0,f=-2*e.offset[0];0>c?(i=t.left+d+p+f+e.collisionWidth-r-o,(0>i||a(c)>i)&&(t.left+=d+p+f)):u>0&&(s=t.left-e.collisionPosition.marginLeft+d+p+f-l,(s>0||u>a(s))&&(t.left+=d+p+f))},top:function(t,e){var i,s,n=e.within,o=n.offset.top+n.scrollTop,r=n.height,l=n.isWindow?n.scrollTop:n.offset.top,h=t.top-e.collisionPosition.marginTop,c=h-l,u=h+e.collisionHeight-r-l,d="top"===e.my[1],p=d?-e.elemHeight:"bottom"===e.my[1]?e.elemHeight:0,f="top"===e.at[1]?e.targetHeight:"bottom"===e.at[1]?-e.targetHeight:0,g=-2*e.offset[1];0>c?(s=t.top+p+f+g+e.collisionHeight-r-o,(0>s||a(c)>s)&&(t.top+=p+f+g)):u>0&&(i=t.top-e.collisionPosition.marginTop+p+f+g-l,(i>0||u>a(i))&&(t.top+=p+f+g))}},flipfit:{left:function(){t.ui.position.flip.left.apply(this,arguments),t.ui.position.fit.left.apply(this,arguments)},top:function(){t.ui.position.flip.top.apply(this,arguments),t.ui.position.fit.top.apply(this,arguments)}}}}(),t.ui.position,t.ui.keyCode={BACKSPACE:8,COMMA:188,DELETE:46,DOWN:40,END:35,ENTER:13,ESCAPE:27,HOME:36,LEFT:37,PAGE_DOWN:34,PAGE_UP:33,PERIOD:190,RIGHT:39,SPACE:32,TAB:9,UP:38},t.fn.extend({uniqueId:function(){var t=0;return function(){return this.each(function(){this.id||(this.id="ui-id-"+ ++t)})}}(),removeUniqueId:function(){return this.each(function(){/^ui-id-\d+$/.test(this.id)&&t(this).removeAttr("id")})}}),t.ui.safeActiveElement=function(t){var e;try{e=t.activeElement}catch(i){e=t.body}return e||(e=t.body),e.nodeName||(e=t.body),e},t.widget("ui.menu",{version:"1.12.1",defaultElement:"
    ",delay:300,options:{icons:{submenu:"ui-icon-caret-1-e"},items:"> *",menus:"ul",position:{my:"left top",at:"right top"},role:"menu",blur:null,focus:null,select:null},_create:function(){this.activeMenu=this.element,this.mouseHandled=!1,this.element.uniqueId().attr({role:this.options.role,tabIndex:0}),this._addClass("ui-menu","ui-widget ui-widget-content"),this._on({"mousedown .ui-menu-item":function(t){t.preventDefault()},"click .ui-menu-item":function(e){var i=t(e.target),s=t(t.ui.safeActiveElement(this.document[0]));!this.mouseHandled&&i.not(".ui-state-disabled").length&&(this.select(e),e.isPropagationStopped()||(this.mouseHandled=!0),i.has(".ui-menu").length?this.expand(e):!this.element.is(":focus")&&s.closest(".ui-menu").length&&(this.element.trigger("focus",[!0]),this.active&&1===this.active.parents(".ui-menu").length&&clearTimeout(this.timer)))},"mouseenter .ui-menu-item":function(e){if(!this.previousFilter){var i=t(e.target).closest(".ui-menu-item"),s=t(e.currentTarget);i[0]===s[0]&&(this._removeClass(s.siblings().children(".ui-state-active"),null,"ui-state-active"),this.focus(e,s))}},mouseleave:"collapseAll","mouseleave .ui-menu":"collapseAll",focus:function(t,e){var i=this.active||this.element.find(this.options.items).eq(0);e||this.focus(t,i)},blur:function(e){this._delay(function(){var i=!t.contains(this.element[0],t.ui.safeActiveElement(this.document[0]));i&&this.collapseAll(e)})},keydown:"_keydown"}),this.refresh(),this._on(this.document,{click:function(t){this._closeOnDocumentClick(t)&&this.collapseAll(t),this.mouseHandled=!1}})},_destroy:function(){var e=this.element.find(".ui-menu-item").removeAttr("role aria-disabled"),i=e.children(".ui-menu-item-wrapper").removeUniqueId().removeAttr("tabIndex role aria-haspopup");this.element.removeAttr("aria-activedescendant").find(".ui-menu").addBack().removeAttr("role aria-labelledby aria-expanded aria-hidden aria-disabled tabIndex").removeUniqueId().show(),i.children().each(function(){var e=t(this);e.data("ui-menu-submenu-caret")&&e.remove()})},_keydown:function(e){var i,s,n,o,a=!0;switch(e.keyCode){case t.ui.keyCode.PAGE_UP:this.previousPage(e);break;case t.ui.keyCode.PAGE_DOWN:this.nextPage(e);break;case t.ui.keyCode.HOME:this._move("first","first",e);break;case t.ui.keyCode.END:this._move("last","last",e);break;case t.ui.keyCode.UP:this.previous(e);break;case t.ui.keyCode.DOWN:this.next(e);break;case t.ui.keyCode.LEFT:this.collapse(e);break;case t.ui.keyCode.RIGHT:this.active&&!this.active.is(".ui-state-disabled")&&this.expand(e);break;case t.ui.keyCode.ENTER:case t.ui.keyCode.SPACE:this._activate(e);break;case t.ui.keyCode.ESCAPE:this.collapse(e);break;default:a=!1,s=this.previousFilter||"",o=!1,n=e.keyCode>=96&&105>=e.keyCode?""+(e.keyCode-96):String.fromCharCode(e.keyCode),clearTimeout(this.filterTimer),n===s?o=!0:n=s+n,i=this._filterMenuItems(n),i=o&&-1!==i.index(this.active.next())?this.active.nextAll(".ui-menu-item"):i,i.length||(n=String.fromCharCode(e.keyCode),i=this._filterMenuItems(n)),i.length?(this.focus(e,i),this.previousFilter=n,this.filterTimer=this._delay(function(){delete this.previousFilter},1e3)):delete this.previousFilter}a&&e.preventDefault()},_activate:function(t){this.active&&!this.active.is(".ui-state-disabled")&&(this.active.children("[aria-haspopup='true']").length?this.expand(t):this.select(t))},refresh:function(){var e,i,s,n,o,a=this,r=this.options.icons.submenu,l=this.element.find(this.options.menus);this._toggleClass("ui-menu-icons",null,!!this.element.find(".ui-icon").length),s=l.filter(":not(.ui-menu)").hide().attr({role:this.options.role,"aria-hidden":"true","aria-expanded":"false"}).each(function(){var e=t(this),i=e.prev(),s=t("").data("ui-menu-submenu-caret",!0);a._addClass(s,"ui-menu-icon","ui-icon "+r),i.attr("aria-haspopup","true").prepend(s),e.attr("aria-labelledby",i.attr("id"))}),this._addClass(s,"ui-menu","ui-widget ui-widget-content ui-front"),e=l.add(this.element),i=e.find(this.options.items),i.not(".ui-menu-item").each(function(){var e=t(this);a._isDivider(e)&&a._addClass(e,"ui-menu-divider","ui-widget-content")}),n=i.not(".ui-menu-item, .ui-menu-divider"),o=n.children().not(".ui-menu").uniqueId().attr({tabIndex:-1,role:this._itemRole()}),this._addClass(n,"ui-menu-item")._addClass(o,"ui-menu-item-wrapper"),i.filter(".ui-state-disabled").attr("aria-disabled","true"),this.active&&!t.contains(this.element[0],this.active[0])&&this.blur()},_itemRole:function(){return{menu:"menuitem",listbox:"option"}[this.options.role]},_setOption:function(t,e){if("icons"===t){var i=this.element.find(".ui-menu-icon");this._removeClass(i,null,this.options.icons.submenu)._addClass(i,null,e.submenu)}this._super(t,e)},_setOptionDisabled:function(t){this._super(t),this.element.attr("aria-disabled",t+""),this._toggleClass(null,"ui-state-disabled",!!t)},focus:function(t,e){var i,s,n;this.blur(t,t&&"focus"===t.type),this._scrollIntoView(e),this.active=e.first(),s=this.active.children(".ui-menu-item-wrapper"),this._addClass(s,null,"ui-state-active"),this.options.role&&this.element.attr("aria-activedescendant",s.attr("id")),n=this.active.parent().closest(".ui-menu-item").children(".ui-menu-item-wrapper"),this._addClass(n,null,"ui-state-active"),t&&"keydown"===t.type?this._close():this.timer=this._delay(function(){this._close()},this.delay),i=e.children(".ui-menu"),i.length&&t&&/^mouse/.test(t.type)&&this._startOpening(i),this.activeMenu=e.parent(),this._trigger("focus",t,{item:e})},_scrollIntoView:function(e){var i,s,n,o,a,r;this._hasScroll()&&(i=parseFloat(t.css(this.activeMenu[0],"borderTopWidth"))||0,s=parseFloat(t.css(this.activeMenu[0],"paddingTop"))||0,n=e.offset().top-this.activeMenu.offset().top-i-s,o=this.activeMenu.scrollTop(),a=this.activeMenu.height(),r=e.outerHeight(),0>n?this.activeMenu.scrollTop(o+n):n+r>a&&this.activeMenu.scrollTop(o+n-a+r))},blur:function(t,e){e||clearTimeout(this.timer),this.active&&(this._removeClass(this.active.children(".ui-menu-item-wrapper"),null,"ui-state-active"),this._trigger("blur",t,{item:this.active}),this.active=null)},_startOpening:function(t){clearTimeout(this.timer),"true"===t.attr("aria-hidden")&&(this.timer=this._delay(function(){this._close(),this._open(t)},this.delay))},_open:function(e){var i=t.extend({of:this.active},this.options.position);clearTimeout(this.timer),this.element.find(".ui-menu").not(e.parents(".ui-menu")).hide().attr("aria-hidden","true"),e.show().removeAttr("aria-hidden").attr("aria-expanded","true").position(i)},collapseAll:function(e,i){clearTimeout(this.timer),this.timer=this._delay(function(){var s=i?this.element:t(e&&e.target).closest(this.element.find(".ui-menu"));s.length||(s=this.element),this._close(s),this.blur(e),this._removeClass(s.find(".ui-state-active"),null,"ui-state-active"),this.activeMenu=s},this.delay)},_close:function(t){t||(t=this.active?this.active.parent():this.element),t.find(".ui-menu").hide().attr("aria-hidden","true").attr("aria-expanded","false")},_closeOnDocumentClick:function(e){return!t(e.target).closest(".ui-menu").length},_isDivider:function(t){return!/[^\-\u2014\u2013\s]/.test(t.text())},collapse:function(t){var e=this.active&&this.active.parent().closest(".ui-menu-item",this.element);e&&e.length&&(this._close(),this.focus(t,e))},expand:function(t){var e=this.active&&this.active.children(".ui-menu ").find(this.options.items).first();e&&e.length&&(this._open(e.parent()),this._delay(function(){this.focus(t,e)}))},next:function(t){this._move("next","first",t)},previous:function(t){this._move("prev","last",t)},isFirstItem:function(){return this.active&&!this.active.prevAll(".ui-menu-item").length},isLastItem:function(){return this.active&&!this.active.nextAll(".ui-menu-item").length},_move:function(t,e,i){var s;this.active&&(s="first"===t||"last"===t?this.active["first"===t?"prevAll":"nextAll"](".ui-menu-item").eq(-1):this.active[t+"All"](".ui-menu-item").eq(0)),s&&s.length&&this.active||(s=this.activeMenu.find(this.options.items)[e]()),this.focus(i,s)},nextPage:function(e){var i,s,n;return this.active?(this.isLastItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.nextAll(".ui-menu-item").each(function(){return i=t(this),0>i.offset().top-s-n}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items)[this.active?"last":"first"]())),void 0):(this.next(e),void 0)},previousPage:function(e){var i,s,n;return this.active?(this.isFirstItem()||(this._hasScroll()?(s=this.active.offset().top,n=this.element.height(),this.active.prevAll(".ui-menu-item").each(function(){return i=t(this),i.offset().top-s+n>0}),this.focus(e,i)):this.focus(e,this.activeMenu.find(this.options.items).first())),void 0):(this.next(e),void 0)},_hasScroll:function(){return this.element.outerHeight()",options:{appendTo:null,autoFocus:!1,delay:300,minLength:1,position:{my:"left top",at:"left bottom",collision:"none"},source:null,change:null,close:null,focus:null,open:null,response:null,search:null,select:null},requestIndex:0,pending:0,_create:function(){var e,i,s,n=this.element[0].nodeName.toLowerCase(),o="textarea"===n,a="input"===n;this.isMultiLine=o||!a&&this._isContentEditable(this.element),this.valueMethod=this.element[o||a?"val":"text"],this.isNewMenu=!0,this._addClass("ui-autocomplete-input"),this.element.attr("autocomplete","off"),this._on(this.element,{keydown:function(n){if(this.element.prop("readOnly"))return e=!0,s=!0,i=!0,void 0;e=!1,s=!1,i=!1;var o=t.ui.keyCode;switch(n.keyCode){case o.PAGE_UP:e=!0,this._move("previousPage",n);break;case o.PAGE_DOWN:e=!0,this._move("nextPage",n);break;case o.UP:e=!0,this._keyEvent("previous",n);break;case o.DOWN:e=!0,this._keyEvent("next",n);break;case o.ENTER:this.menu.active&&(e=!0,n.preventDefault(),this.menu.select(n));break;case o.TAB:this.menu.active&&this.menu.select(n);break;case o.ESCAPE:this.menu.element.is(":visible")&&(this.isMultiLine||this._value(this.term),this.close(n),n.preventDefault());break;default:i=!0,this._searchTimeout(n)}},keypress:function(s){if(e)return e=!1,(!this.isMultiLine||this.menu.element.is(":visible"))&&s.preventDefault(),void 0;if(!i){var n=t.ui.keyCode;switch(s.keyCode){case n.PAGE_UP:this._move("previousPage",s);break;case n.PAGE_DOWN:this._move("nextPage",s);break;case n.UP:this._keyEvent("previous",s);break;case n.DOWN:this._keyEvent("next",s)}}},input:function(t){return s?(s=!1,t.preventDefault(),void 0):(this._searchTimeout(t),void 0)},focus:function(){this.selectedItem=null,this.previous=this._value()},blur:function(t){return this.cancelBlur?(delete this.cancelBlur,void 0):(clearTimeout(this.searching),this.close(t),this._change(t),void 0)}}),this._initSource(),this.menu=t("
      ").appendTo(this._appendTo()).menu({role:null}).hide().menu("instance"),this._addClass(this.menu.element,"ui-autocomplete","ui-front"),this._on(this.menu.element,{mousedown:function(e){e.preventDefault(),this.cancelBlur=!0,this._delay(function(){delete this.cancelBlur,this.element[0]!==t.ui.safeActiveElement(this.document[0])&&this.element.trigger("focus")})},menufocus:function(e,i){var s,n;return this.isNewMenu&&(this.isNewMenu=!1,e.originalEvent&&/^mouse/.test(e.originalEvent.type))?(this.menu.blur(),this.document.one("mousemove",function(){t(e.target).trigger(e.originalEvent)}),void 0):(n=i.item.data("ui-autocomplete-item"),!1!==this._trigger("focus",e,{item:n})&&e.originalEvent&&/^key/.test(e.originalEvent.type)&&this._value(n.value),s=i.item.attr("aria-label")||n.value,s&&t.trim(s).length&&(this.liveRegion.children().hide(),t("
      ").text(s).appendTo(this.liveRegion)),void 0)},menuselect:function(e,i){var s=i.item.data("ui-autocomplete-item"),n=this.previous;this.element[0]!==t.ui.safeActiveElement(this.document[0])&&(this.element.trigger("focus"),this.previous=n,this._delay(function(){this.previous=n,this.selectedItem=s})),!1!==this._trigger("select",e,{item:s})&&this._value(s.value),this.term=this._value(),this.close(e),this.selectedItem=s}}),this.liveRegion=t("
      ",{role:"status","aria-live":"assertive","aria-relevant":"additions"}).appendTo(this.document[0].body),this._addClass(this.liveRegion,null,"ui-helper-hidden-accessible"),this._on(this.window,{beforeunload:function(){this.element.removeAttr("autocomplete")}})},_destroy:function(){clearTimeout(this.searching),this.element.removeAttr("autocomplete"),this.menu.element.remove(),this.liveRegion.remove()},_setOption:function(t,e){this._super(t,e),"source"===t&&this._initSource(),"appendTo"===t&&this.menu.element.appendTo(this._appendTo()),"disabled"===t&&e&&this.xhr&&this.xhr.abort()},_isEventTargetInWidget:function(e){var i=this.menu.element[0];return e.target===this.element[0]||e.target===i||t.contains(i,e.target)},_closeOnClickOutside:function(t){this._isEventTargetInWidget(t)||this.close()},_appendTo:function(){var e=this.options.appendTo;return e&&(e=e.jquery||e.nodeType?t(e):this.document.find(e).eq(0)),e&&e[0]||(e=this.element.closest(".ui-front, dialog")),e.length||(e=this.document[0].body),e},_initSource:function(){var e,i,s=this;t.isArray(this.options.source)?(e=this.options.source,this.source=function(i,s){s(t.ui.autocomplete.filter(e,i.term))}):"string"==typeof this.options.source?(i=this.options.source,this.source=function(e,n){s.xhr&&s.xhr.abort(),s.xhr=t.ajax({url:i,data:e,dataType:"json",success:function(t){n(t)},error:function(){n([])}})}):this.source=this.options.source},_searchTimeout:function(t){clearTimeout(this.searching),this.searching=this._delay(function(){var e=this.term===this._value(),i=this.menu.element.is(":visible"),s=t.altKey||t.ctrlKey||t.metaKey||t.shiftKey;(!e||e&&!i&&!s)&&(this.selectedItem=null,this.search(null,t))},this.options.delay)},search:function(t,e){return t=null!=t?t:this._value(),this.term=this._value(),t.length").append(t("
      ").text(i.label)).appendTo(e)},_move:function(t,e){return this.menu.element.is(":visible")?this.menu.isFirstItem()&&/^previous/.test(t)||this.menu.isLastItem()&&/^next/.test(t)?(this.isMultiLine||this._value(this.term),this.menu.blur(),void 0):(this.menu[t](e),void 0):(this.search(null,e),void 0)},widget:function(){return this.menu.element},_value:function(){return this.valueMethod.apply(this.element,arguments)},_keyEvent:function(t,e){(!this.isMultiLine||this.menu.element.is(":visible"))&&(this._move(t,e),e.preventDefault())},_isContentEditable:function(t){if(!t.length)return!1;var e=t.prop("contentEditable");return"inherit"===e?this._isContentEditable(t.parent()):"true"===e}}),t.extend(t.ui.autocomplete,{escapeRegex:function(t){return t.replace(/[\-\[\]{}()*+?.,\\\^$|#\s]/g,"\\$&")},filter:function(e,i){var s=RegExp(t.ui.autocomplete.escapeRegex(i),"i");return t.grep(e,function(t){return s.test(t.label||t.value||t)})}}),t.widget("ui.autocomplete",t.ui.autocomplete,{options:{messages:{noResults:"No search results.",results:function(t){return t+(t>1?" results are":" result is")+" available, use up and down arrow keys to navigate."}}},__response:function(e){var i;this._superApply(arguments),this.options.disabled||this.cancelSearch||(i=e&&e.length?this.options.messages.results(e.length):this.options.messages.noResults,this.liveRegion.children().hide(),t("
      ").text(i).appendTo(this.liveRegion))}}),t.ui.autocomplete}); \ No newline at end of file diff --git a/docs/api/script-dir/jquery-ui.structure.min.css b/docs/api/script-dir/jquery-ui.structure.min.css deleted file mode 100644 index e880892..0000000 --- a/docs/api/script-dir/jquery-ui.structure.min.css +++ /dev/null @@ -1,5 +0,0 @@ -/*! jQuery UI - v1.12.1 - 2018-12-06 -* http://jqueryui.com -* Copyright jQuery Foundation and other contributors; Licensed MIT */ - -.ui-helper-hidden{display:none}.ui-helper-hidden-accessible{border:0;clip:rect(0 0 0 0);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px}.ui-helper-reset{margin:0;padding:0;border:0;outline:0;line-height:1.3;text-decoration:none;font-size:100%;list-style:none}.ui-helper-clearfix:before,.ui-helper-clearfix:after{content:"";display:table;border-collapse:collapse}.ui-helper-clearfix:after{clear:both}.ui-helper-zfix{width:100%;height:100%;top:0;left:0;position:absolute;opacity:0;filter:Alpha(Opacity=0)}.ui-front{z-index:100}.ui-state-disabled{cursor:default!important;pointer-events:none}.ui-icon{display:inline-block;vertical-align:middle;margin-top:-.25em;position:relative;text-indent:-99999px;overflow:hidden;background-repeat:no-repeat}.ui-widget-icon-block{left:50%;margin-left:-8px;display:block}.ui-widget-overlay{position:fixed;top:0;left:0;width:100%;height:100%}.ui-autocomplete{position:absolute;top:0;left:0;cursor:default}.ui-menu{list-style:none;padding:0;margin:0;display:block;outline:0}.ui-menu .ui-menu{position:absolute}.ui-menu .ui-menu-item{margin:0;cursor:pointer;list-style-image:url("data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7")}.ui-menu .ui-menu-item-wrapper{position:relative;padding:3px 1em 3px .4em}.ui-menu .ui-menu-divider{margin:5px 0;height:0;font-size:0;line-height:0;border-width:1px 0 0 0}.ui-menu .ui-state-focus,.ui-menu .ui-state-active{margin:-1px}.ui-menu-icons{position:relative}.ui-menu-icons .ui-menu-item-wrapper{padding-left:2em}.ui-menu .ui-icon{position:absolute;top:0;bottom:0;left:.2em;margin:auto 0}.ui-menu .ui-menu-icon{left:auto;right:0} \ No newline at end of file diff --git a/docs/api/script.js b/docs/api/script.js deleted file mode 100644 index 864989c..0000000 --- a/docs/api/script.js +++ /dev/null @@ -1,132 +0,0 @@ -/* - * Copyright (c) 2013, 2020, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Oracle designates this - * particular file as subject to the "Classpath" exception as provided - * by Oracle in the LICENSE file that accompanied this code. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -var moduleSearchIndex; -var packageSearchIndex; -var typeSearchIndex; -var memberSearchIndex; -var tagSearchIndex; -function loadScripts(doc, tag) { - createElem(doc, tag, 'search.js'); - - createElem(doc, tag, 'module-search-index.js'); - createElem(doc, tag, 'package-search-index.js'); - createElem(doc, tag, 'type-search-index.js'); - createElem(doc, tag, 'member-search-index.js'); - createElem(doc, tag, 'tag-search-index.js'); -} - -function createElem(doc, tag, path) { - var script = doc.createElement(tag); - var scriptElement = doc.getElementsByTagName(tag)[0]; - script.src = pathtoroot + path; - scriptElement.parentNode.insertBefore(script, scriptElement); -} - -function show(tableId, selected, columns) { - if (tableId !== selected) { - document.querySelectorAll('div.' + tableId + ':not(.' + selected + ')') - .forEach(function(elem) { - elem.style.display = 'none'; - }); - } - document.querySelectorAll('div.' + selected) - .forEach(function(elem, index) { - elem.style.display = ''; - var isEvenRow = index % (columns * 2) < columns; - elem.classList.remove(isEvenRow ? oddRowColor : evenRowColor); - elem.classList.add(isEvenRow ? evenRowColor : oddRowColor); - }); - updateTabs(tableId, selected); -} - -function updateTabs(tableId, selected) { - document.querySelector('div#' + tableId +' .summary-table') - .setAttribute('aria-labelledby', selected); - document.querySelectorAll('button[id^="' + tableId + '"]') - .forEach(function(tab, index) { - if (selected === tab.id || (tableId === selected && index === 0)) { - tab.className = activeTableTab; - tab.setAttribute('aria-selected', true); - tab.setAttribute('tabindex',0); - } else { - tab.className = tableTab; - tab.setAttribute('aria-selected', false); - tab.setAttribute('tabindex',-1); - } - }); -} - -function switchTab(e) { - var selected = document.querySelector('[aria-selected=true]'); - if (selected) { - if ((e.keyCode === 37 || e.keyCode === 38) && selected.previousSibling) { - // left or up arrow key pressed: move focus to previous tab - selected.previousSibling.click(); - selected.previousSibling.focus(); - e.preventDefault(); - } else if ((e.keyCode === 39 || e.keyCode === 40) && selected.nextSibling) { - // right or down arrow key pressed: move focus to next tab - selected.nextSibling.click(); - selected.nextSibling.focus(); - e.preventDefault(); - } - } -} - -var updateSearchResults = function() {}; - -function indexFilesLoaded() { - return moduleSearchIndex - && packageSearchIndex - && typeSearchIndex - && memberSearchIndex - && tagSearchIndex; -} - -// Workaround for scroll position not being included in browser history (8249133) -document.addEventListener("DOMContentLoaded", function(e) { - var contentDiv = document.querySelector("div.flex-content"); - window.addEventListener("popstate", function(e) { - if (e.state !== null) { - contentDiv.scrollTop = e.state; - } - }); - window.addEventListener("hashchange", function(e) { - history.replaceState(contentDiv.scrollTop, document.title); - }); - contentDiv.addEventListener("scroll", function(e) { - var timeoutID; - if (!timeoutID) { - timeoutID = setTimeout(function() { - history.replaceState(contentDiv.scrollTop, document.title); - timeoutID = null; - }, 100); - } - }); - if (!location.hash) { - history.replaceState(contentDiv.scrollTop, document.title); - } -}); diff --git a/docs/api/search.js b/docs/api/search.js deleted file mode 100644 index db3b2f4..0000000 --- a/docs/api/search.js +++ /dev/null @@ -1,354 +0,0 @@ -/* - * Copyright (c) 2015, 2020, Oracle and/or its affiliates. All rights reserved. - * DO NOT ALTER OR REMOVE COPYRIGHT NOTICES OR THIS FILE HEADER. - * - * This code is free software; you can redistribute it and/or modify it - * under the terms of the GNU General Public License version 2 only, as - * published by the Free Software Foundation. Oracle designates this - * particular file as subject to the "Classpath" exception as provided - * by Oracle in the LICENSE file that accompanied this code. - * - * This code is distributed in the hope that it will be useful, but WITHOUT - * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or - * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License - * version 2 for more details (a copy is included in the LICENSE file that - * accompanied this code). - * - * You should have received a copy of the GNU General Public License version - * 2 along with this work; if not, write to the Free Software Foundation, - * Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA. - * - * Please contact Oracle, 500 Oracle Parkway, Redwood Shores, CA 94065 USA - * or visit www.oracle.com if you need additional information or have any - * questions. - */ - -var noResult = {l: "No results found"}; -var loading = {l: "Loading search index..."}; -var catModules = "Modules"; -var catPackages = "Packages"; -var catTypes = "Classes and Interfaces"; -var catMembers = "Members"; -var catSearchTags = "Search Tags"; -var highlight = "$&"; -var searchPattern = ""; -var fallbackPattern = ""; -var RANKING_THRESHOLD = 2; -var NO_MATCH = 0xffff; -var MIN_RESULTS = 3; -var MAX_RESULTS = 500; -var UNNAMED = ""; -function escapeHtml(str) { - return str.replace(//g, ">"); -} -function getHighlightedText(item, matcher, fallbackMatcher) { - var escapedItem = escapeHtml(item); - var highlighted = escapedItem.replace(matcher, highlight); - if (highlighted === escapedItem) { - highlighted = escapedItem.replace(fallbackMatcher, highlight) - } - return highlighted; -} -function getURLPrefix(ui) { - var urlPrefix=""; - var slash = "/"; - if (ui.item.category === catModules) { - return ui.item.l + slash; - } else if (ui.item.category === catPackages && ui.item.m) { - return ui.item.m + slash; - } else if (ui.item.category === catTypes || ui.item.category === catMembers) { - if (ui.item.m) { - urlPrefix = ui.item.m + slash; - } else { - $.each(packageSearchIndex, function(index, item) { - if (item.m && ui.item.p === item.l) { - urlPrefix = item.m + slash; - } - }); - } - } - return urlPrefix; -} -function createSearchPattern(term) { - var pattern = ""; - var isWordToken = false; - term.replace(/,\s*/g, ", ").trim().split(/\s+/).forEach(function(w, index) { - if (index > 0) { - // whitespace between identifiers is significant - pattern += (isWordToken && /^\w/.test(w)) ? "\\s+" : "\\s*"; - } - var tokens = w.split(/(?=[A-Z,.()<>[\/])/); - for (var i = 0; i < tokens.length; i++) { - var s = tokens[i]; - if (s === "") { - continue; - } - pattern += $.ui.autocomplete.escapeRegex(s); - isWordToken = /\w$/.test(s); - if (isWordToken) { - pattern += "([a-z0-9_$<>\\[\\]]*?)"; - } - } - }); - return pattern; -} -function createMatcher(pattern, flags) { - var isCamelCase = /[A-Z]/.test(pattern); - return new RegExp(pattern, flags + (isCamelCase ? "" : "i")); -} -var watermark = 'Search'; -$(function() { - var search = $("#search-input"); - var reset = $("#reset-button"); - search.val(''); - search.prop("disabled", false); - reset.prop("disabled", false); - search.val(watermark).addClass('watermark'); - search.blur(function() { - if ($(this).val().length === 0) { - $(this).val(watermark).addClass('watermark'); - } - }); - search.on('click keydown paste', function() { - if ($(this).val() === watermark) { - $(this).val('').removeClass('watermark'); - } - }); - reset.click(function() { - search.val('').focus(); - }); - search.focus()[0].setSelectionRange(0, 0); -}); -$.widget("custom.catcomplete", $.ui.autocomplete, { - _create: function() { - this._super(); - this.widget().menu("option", "items", "> :not(.ui-autocomplete-category)"); - }, - _renderMenu: function(ul, items) { - var rMenu = this; - var currentCategory = ""; - rMenu.menu.bindings = $(); - $.each(items, function(index, item) { - var li; - if (item.category && item.category !== currentCategory) { - ul.append("
    • " + item.category + "
    • "); - currentCategory = item.category; - } - li = rMenu._renderItemData(ul, item); - if (item.category) { - li.attr("aria-label", item.category + " : " + item.l); - li.attr("class", "result-item"); - } else { - li.attr("aria-label", item.l); - li.attr("class", "result-item"); - } - }); - }, - _renderItem: function(ul, item) { - var label = ""; - var matcher = createMatcher(escapeHtml(searchPattern), "g"); - var fallbackMatcher = new RegExp(fallbackPattern, "gi") - if (item.category === catModules) { - label = getHighlightedText(item.l, matcher, fallbackMatcher); - } else if (item.category === catPackages) { - label = getHighlightedText(item.l, matcher, fallbackMatcher); - } else if (item.category === catTypes) { - label = (item.p && item.p !== UNNAMED) - ? getHighlightedText(item.p + "." + item.l, matcher, fallbackMatcher) - : getHighlightedText(item.l, matcher, fallbackMatcher); - } else if (item.category === catMembers) { - label = (item.p && item.p !== UNNAMED) - ? getHighlightedText(item.p + "." + item.c + "." + item.l, matcher, fallbackMatcher) - : getHighlightedText(item.c + "." + item.l, matcher, fallbackMatcher); - } else if (item.category === catSearchTags) { - label = getHighlightedText(item.l, matcher, fallbackMatcher); - } else { - label = item.l; - } - var li = $("
    • ").appendTo(ul); - var div = $("
      ").appendTo(li); - if (item.category === catSearchTags && item.h) { - if (item.d) { - div.html(label + " (" + item.h + ")
      " - + item.d + "
      "); - } else { - div.html(label + " (" + item.h + ")"); - } - } else { - if (item.m) { - div.html(item.m + "/" + label); - } else { - div.html(label); - } - } - return li; - } -}); -function rankMatch(match, category) { - if (!match) { - return NO_MATCH; - } - var index = match.index; - var input = match.input; - var leftBoundaryMatch = 2; - var periferalMatch = 0; - // make sure match is anchored on a left word boundary - if (index === 0 || /\W/.test(input[index - 1]) || "_" === input[index]) { - leftBoundaryMatch = 0; - } else if ("_" === input[index - 1] || (input[index] === input[index].toUpperCase() && !/^[A-Z0-9_$]+$/.test(input))) { - leftBoundaryMatch = 1; - } - var matchEnd = index + match[0].length; - var leftParen = input.indexOf("("); - var endOfName = leftParen > -1 ? leftParen : input.length; - // exclude peripheral matches - if (category !== catModules && category !== catSearchTags) { - var delim = category === catPackages ? "/" : "."; - if (leftParen > -1 && leftParen < index) { - periferalMatch += 2; - } else if (input.lastIndexOf(delim, endOfName) >= matchEnd) { - periferalMatch += 2; - } - } - var delta = match[0].length === endOfName ? 0 : 1; // rank full match higher than partial match - for (var i = 1; i < match.length; i++) { - // lower ranking if parts of the name are missing - if (match[i]) - delta += match[i].length; - } - if (category === catTypes) { - // lower ranking if a type name contains unmatched camel-case parts - if (/[A-Z]/.test(input.substring(matchEnd))) - delta += 5; - if (/[A-Z]/.test(input.substring(0, index))) - delta += 5; - } - return leftBoundaryMatch + periferalMatch + (delta / 200); - -} -function doSearch(request, response) { - var result = []; - searchPattern = createSearchPattern(request.term); - fallbackPattern = createSearchPattern(request.term.toLowerCase()); - if (searchPattern === "") { - return this.close(); - } - var camelCaseMatcher = createMatcher(searchPattern, ""); - var fallbackMatcher = new RegExp(fallbackPattern, "i"); - - function searchIndexWithMatcher(indexArray, matcher, category, nameFunc) { - if (indexArray) { - var newResults = []; - $.each(indexArray, function (i, item) { - item.category = category; - var ranking = rankMatch(matcher.exec(nameFunc(item)), category); - if (ranking < RANKING_THRESHOLD) { - newResults.push({ranking: ranking, item: item}); - } - return newResults.length <= MAX_RESULTS; - }); - return newResults.sort(function(e1, e2) { - return e1.ranking - e2.ranking; - }).map(function(e) { - return e.item; - }); - } - return []; - } - function searchIndex(indexArray, category, nameFunc) { - var primaryResults = searchIndexWithMatcher(indexArray, camelCaseMatcher, category, nameFunc); - result = result.concat(primaryResults); - if (primaryResults.length <= MIN_RESULTS && !camelCaseMatcher.ignoreCase) { - var secondaryResults = searchIndexWithMatcher(indexArray, fallbackMatcher, category, nameFunc); - result = result.concat(secondaryResults.filter(function (item) { - return primaryResults.indexOf(item) === -1; - })); - } - } - - searchIndex(moduleSearchIndex, catModules, function(item) { return item.l; }); - searchIndex(packageSearchIndex, catPackages, function(item) { - return (item.m && request.term.indexOf("/") > -1) - ? (item.m + "/" + item.l) : item.l; - }); - searchIndex(typeSearchIndex, catTypes, function(item) { - return request.term.indexOf(".") > -1 ? item.p + "." + item.l : item.l; - }); - searchIndex(memberSearchIndex, catMembers, function(item) { - return request.term.indexOf(".") > -1 - ? item.p + "." + item.c + "." + item.l : item.l; - }); - searchIndex(tagSearchIndex, catSearchTags, function(item) { return item.l; }); - - if (!indexFilesLoaded()) { - updateSearchResults = function() { - doSearch(request, response); - } - result.unshift(loading); - } else { - updateSearchResults = function() {}; - } - response(result); -} -$(function() { - $("#search-input").catcomplete({ - minLength: 1, - delay: 300, - source: doSearch, - response: function(event, ui) { - if (!ui.content.length) { - ui.content.push(noResult); - } else { - $("#search-input").empty(); - } - }, - autoFocus: true, - focus: function(event, ui) { - return false; - }, - position: { - collision: "flip" - }, - select: function(event, ui) { - if (ui.item.category) { - var url = getURLPrefix(ui); - if (ui.item.category === catModules) { - url += "module-summary.html"; - } else if (ui.item.category === catPackages) { - if (ui.item.u) { - url = ui.item.u; - } else { - url += ui.item.l.replace(/\./g, '/') + "/package-summary.html"; - } - } else if (ui.item.category === catTypes) { - if (ui.item.u) { - url = ui.item.u; - } else if (ui.item.p === UNNAMED) { - url += ui.item.l + ".html"; - } else { - url += ui.item.p.replace(/\./g, '/') + "/" + ui.item.l + ".html"; - } - } else if (ui.item.category === catMembers) { - if (ui.item.p === UNNAMED) { - url += ui.item.c + ".html" + "#"; - } else { - url += ui.item.p.replace(/\./g, '/') + "/" + ui.item.c + ".html" + "#"; - } - if (ui.item.u) { - url += ui.item.u; - } else { - url += ui.item.l; - } - } else if (ui.item.category === catSearchTags) { - url += ui.item.u; - } - if (top !== window) { - parent.classFrame.location = pathtoroot + url; - } else { - window.location.href = pathtoroot + url; - } - $("#search-input").focus(); - } - } - }); -}); diff --git a/docs/api/stylesheet.css b/docs/api/stylesheet.css deleted file mode 100644 index 836c62d..0000000 --- a/docs/api/stylesheet.css +++ /dev/null @@ -1,865 +0,0 @@ -/* - * Javadoc style sheet - */ - -@import url('resources/fonts/dejavu.css'); - -/* - * Styles for individual HTML elements. - * - * These are styles that are specific to individual HTML elements. Changing them affects the style of a particular - * HTML element throughout the page. - */ - -body { - background-color:#ffffff; - color:#353833; - font-family:'DejaVu Sans', Arial, Helvetica, sans-serif; - font-size:14px; - margin:0; - padding:0; - height:100%; - width:100%; -} -iframe { - margin:0; - padding:0; - height:100%; - width:100%; - overflow-y:scroll; - border:none; -} -a:link, a:visited { - text-decoration:none; - color:#4A6782; -} -a[href]:hover, a[href]:focus { - text-decoration:none; - color:#bb7a2a; -} -a[name] { - color:#353833; -} -pre { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; -} -h1 { - font-size:20px; -} -h2 { - font-size:18px; -} -h3 { - font-size:16px; -} -h4 { - font-size:15px; -} -h5 { - font-size:14px; -} -h6 { - font-size:13px; -} -ul { - list-style-type:disc; -} -code, tt { - font-family:'DejaVu Sans Mono', monospace; -} -:not(h1, h2, h3, h4, h5, h6) > code, -:not(h1, h2, h3, h4, h5, h6) > tt { - font-size:14px; - padding-top:4px; - margin-top:8px; - line-height:1.4em; -} -dt code { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - padding-top:4px; -} -.summary-table dt code { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - vertical-align:top; - padding-top:4px; -} -sup { - font-size:8px; -} -button { - font-family: 'DejaVu Sans', Arial, Helvetica, sans-serif; - font-size: 14px; -} -/* - * Styles for HTML generated by javadoc. - * - * These are style classes that are used by the standard doclet to generate HTML documentation. - */ - -/* - * Styles for document title and copyright. - */ -.clear { - clear:both; - height:0; - overflow:hidden; -} -.about-language { - float:right; - padding:0 21px 8px 8px; - font-size:11px; - margin-top:-9px; - height:2.9em; -} -.legal-copy { - margin-left:.5em; -} -.tab { - background-color:#0066FF; - color:#ffffff; - padding:8px; - width:5em; - font-weight:bold; -} -/* - * Styles for navigation bar. - */ -@media screen { - .flex-box { - position:fixed; - display:flex; - flex-direction:column; - height: 100%; - width: 100%; - } - .flex-header { - flex: 0 0 auto; - } - .flex-content { - flex: 1 1 auto; - overflow-y: auto; - } -} -.top-nav { - background-color:#4D7A97; - color:#FFFFFF; - float:left; - padding:0; - width:100%; - clear:right; - min-height:2.8em; - padding-top:10px; - overflow:hidden; - font-size:12px; -} -.sub-nav { - background-color:#dee3e9; - float:left; - width:100%; - overflow:hidden; - font-size:12px; -} -.sub-nav div { - clear:left; - float:left; - padding:0 0 5px 6px; - text-transform:uppercase; -} -.sub-nav .nav-list { - padding-top:5px; -} -ul.nav-list { - display:block; - margin:0 25px 0 0; - padding:0; -} -ul.sub-nav-list { - float:left; - margin:0 25px 0 0; - padding:0; -} -ul.nav-list li { - list-style:none; - float:left; - padding: 5px 6px; - text-transform:uppercase; -} -.sub-nav .nav-list-search { - float:right; - margin:0 0 0 0; - padding:5px 6px; - clear:none; -} -.nav-list-search label { - position:relative; - right:-16px; -} -ul.sub-nav-list li { - list-style:none; - float:left; - padding-top:10px; -} -.top-nav a:link, .top-nav a:active, .top-nav a:visited { - color:#FFFFFF; - text-decoration:none; - text-transform:uppercase; -} -.top-nav a:hover { - text-decoration:none; - color:#bb7a2a; - text-transform:uppercase; -} -.nav-bar-cell1-rev { - background-color:#F8981D; - color:#253441; - margin: auto 5px; -} -.skip-nav { - position:absolute; - top:auto; - left:-9999px; - overflow:hidden; -} -/* - * Hide navigation links and search box in print layout - */ -@media print { - ul.nav-list, div.sub-nav { - display:none; - } -} -/* - * Styles for page header and footer. - */ -.title { - color:#2c4557; - margin:10px 0; -} -.sub-title { - margin:5px 0 0 0; -} -.header ul { - margin:0 0 15px 0; - padding:0; -} -.header ul li, .footer ul li { - list-style:none; - font-size:13px; -} -/* - * Styles for headings. - */ -body.class-declaration-page .summary h2, -body.class-declaration-page .details h2, -body.class-use-page h2, -body.module-declaration-page .block-list h2 { - font-style: italic; - padding:0; - margin:15px 0; -} -body.class-declaration-page .summary h3, -body.class-declaration-page .details h3, -body.class-declaration-page .summary .inherited-list h2 { - background-color:#dee3e9; - border:1px solid #d0d9e0; - margin:0 0 6px -8px; - padding:7px 5px; -} -/* - * Styles for page layout containers. - */ -main { - clear:both; - padding:10px 20px; - position:relative; -} -dl.notes > dt { - font-family: 'DejaVu Sans', Arial, Helvetica, sans-serif; - font-size:12px; - font-weight:bold; - margin:10px 0 0 0; - color:#4E4E4E; -} -dl.notes > dd { - margin:5px 10px 10px 0; - font-size:14px; - font-family:'DejaVu Serif', Georgia, "Times New Roman", Times, serif; -} -dl.name-value > dt { - margin-left:1px; - font-size:1.1em; - display:inline; - font-weight:bold; -} -dl.name-value > dd { - margin:0 0 0 1px; - font-size:1.1em; - display:inline; -} -/* - * Styles for lists. - */ -li.circle { - list-style:circle; -} -ul.horizontal li { - display:inline; - font-size:0.9em; -} -div.inheritance { - margin:0; - padding:0; -} -div.inheritance div.inheritance { - margin-left:2em; -} -ul.block-list, -ul.details-list, -ul.member-list, -ul.summary-list { - margin:10px 0 10px 0; - padding:0; -} -ul.block-list > li, -ul.details-list > li, -ul.member-list > li, -ul.summary-list > li { - list-style:none; - margin-bottom:15px; - line-height:1.4; -} -.summary-table dl, .summary-table dl dt, .summary-table dl dd { - margin-top:0; - margin-bottom:1px; -} -ul.see-list, ul.see-list-long { - padding-left: 0; - list-style: none; -} -ul.see-list li { - display: inline; -} -ul.see-list li:not(:last-child):after, -ul.see-list-long li:not(:last-child):after { - content: ", "; - white-space: pre-wrap; -} -/* - * Styles for tables. - */ -.summary-table, .details-table { - width:100%; - border-spacing:0; - border-left:1px solid #EEE; - border-right:1px solid #EEE; - border-bottom:1px solid #EEE; - padding:0; -} -.caption { - position:relative; - text-align:left; - background-repeat:no-repeat; - color:#253441; - font-weight:bold; - clear:none; - overflow:hidden; - padding:0; - padding-top:10px; - padding-left:1px; - margin:0; - white-space:pre; -} -.caption a:link, .caption a:visited { - color:#1f389c; -} -.caption a:hover, -.caption a:active { - color:#FFFFFF; -} -.caption span { - white-space:nowrap; - padding-top:5px; - padding-left:12px; - padding-right:12px; - padding-bottom:7px; - display:inline-block; - float:left; - background-color:#F8981D; - border: none; - height:16px; -} -div.table-tabs { - padding:10px 0 0 1px; - margin:0; -} -div.table-tabs > button { - border: none; - cursor: pointer; - padding: 5px 12px 7px 12px; - font-weight: bold; - margin-right: 3px; -} -div.table-tabs > button.active-table-tab { - background: #F8981D; - color: #253441; -} -div.table-tabs > button.table-tab { - background: #4D7A97; - color: #FFFFFF; -} -.two-column-summary { - display: grid; - grid-template-columns: minmax(15%, max-content) minmax(15%, auto); -} -.three-column-summary { - display: grid; - grid-template-columns: minmax(10%, max-content) minmax(15%, max-content) minmax(15%, auto); -} -.four-column-summary { - display: grid; - grid-template-columns: minmax(10%, max-content) minmax(10%, max-content) minmax(10%, max-content) minmax(10%, auto); -} -@media screen and (max-width: 600px) { - .two-column-summary { - display: grid; - grid-template-columns: 1fr; - } -} -@media screen and (max-width: 800px) { - .three-column-summary { - display: grid; - grid-template-columns: minmax(10%, max-content) minmax(25%, auto); - } - .three-column-summary .col-last { - grid-column-end: span 2; - } -} -@media screen and (max-width: 1000px) { - .four-column-summary { - display: grid; - grid-template-columns: minmax(15%, max-content) minmax(15%, auto); - } -} -.summary-table > div, .details-table > div { - text-align:left; - padding: 8px 3px 3px 7px; -} -.col-first, .col-second, .col-last, .col-constructor-name, .col-summary-item-name { - vertical-align:top; - padding-right:0; - padding-top:8px; - padding-bottom:3px; -} -.table-header { - background:#dee3e9; - font-weight: bold; -} -.col-first, .col-first { - font-size:13px; -} -.col-second, .col-second, .col-last, .col-constructor-name, .col-summary-item-name, .col-last { - font-size:13px; -} -.col-first, .col-second, .col-constructor-name { - vertical-align:top; - overflow: auto; -} -.col-last { - white-space:normal; -} -.col-first a:link, .col-first a:visited, -.col-second a:link, .col-second a:visited, -.col-first a:link, .col-first a:visited, -.col-second a:link, .col-second a:visited, -.col-constructor-name a:link, .col-constructor-name a:visited, -.col-summary-item-name a:link, .col-summary-item-name a:visited, -.constant-values-container a:link, .constant-values-container a:visited, -.all-classes-container a:link, .all-classes-container a:visited, -.all-packages-container a:link, .all-packages-container a:visited { - font-weight:bold; -} -.table-sub-heading-color { - background-color:#EEEEFF; -} -.even-row-color, .even-row-color .table-header { - background-color:#FFFFFF; -} -.odd-row-color, .odd-row-color .table-header { - background-color:#EEEEEF; -} -/* - * Styles for contents. - */ -.deprecated-content { - margin:0; - padding:10px 0; -} -div.block { - font-size:14px; - font-family:'DejaVu Serif', Georgia, "Times New Roman", Times, serif; -} -.col-last div { - padding-top:0; -} -.col-last a { - padding-bottom:3px; -} -.module-signature, -.package-signature, -.type-signature, -.member-signature { - font-family:'DejaVu Sans Mono', monospace; - font-size:14px; - margin:14px 0; - white-space: pre-wrap; -} -.module-signature, -.package-signature, -.type-signature { - margin-top: 0; -} -.member-signature .type-parameters-long, -.member-signature .parameters, -.member-signature .exceptions { - display: inline-block; - vertical-align: top; - white-space: pre; -} -.member-signature .type-parameters { - white-space: normal; -} -/* - * Styles for formatting effect. - */ -.source-line-no { - color:green; - padding:0 30px 0 0; -} -h1.hidden { - visibility:hidden; - overflow:hidden; - font-size:10px; -} -.block { - display:block; - margin:0 10px 5px 0; - color:#474747; -} -.deprecated-label, .descfrm-type-label, .implementation-label, .member-name-label, .member-name-link, -.module-label-in-package, .module-label-in-type, .override-specify-label, .package-label-in-type, -.package-hierarchy-label, .type-name-label, .type-name-link, .search-tag-link, .preview-label { - font-weight:bold; -} -.deprecation-comment, .help-footnote, .preview-comment { - font-style:italic; -} -.deprecation-block { - font-size:14px; - font-family:'DejaVu Serif', Georgia, "Times New Roman", Times, serif; - border-style:solid; - border-width:thin; - border-radius:10px; - padding:10px; - margin-bottom:10px; - margin-right:10px; - display:inline-block; -} -.preview-block { - font-size:14px; - font-family:'DejaVu Serif', Georgia, "Times New Roman", Times, serif; - border-style:solid; - border-width:thin; - border-radius:10px; - padding:10px; - margin-bottom:10px; - margin-right:10px; - display:inline-block; -} -div.block div.deprecation-comment { - font-style:normal; -} -/* - * Styles specific to HTML5 elements. - */ -main, nav, header, footer, section { - display:block; -} -/* - * Styles for javadoc search. - */ -.ui-autocomplete-category { - font-weight:bold; - font-size:15px; - padding:7px 0 7px 3px; - background-color:#4D7A97; - color:#FFFFFF; -} -.result-item { - font-size:13px; -} -.ui-autocomplete { - max-height:85%; - max-width:65%; - overflow-y:scroll; - overflow-x:scroll; - white-space:nowrap; - box-shadow: 0 3px 6px rgba(0,0,0,0.16), 0 3px 6px rgba(0,0,0,0.23); -} -ul.ui-autocomplete { - position:fixed; - z-index:999999; -} -ul.ui-autocomplete li { - float:left; - clear:both; - width:100%; -} -.result-highlight { - font-weight:bold; -} -#search-input { - background-image:url('resources/glass.png'); - background-size:13px; - background-repeat:no-repeat; - background-position:2px 3px; - padding-left:20px; - position:relative; - right:-18px; - width:400px; -} -#reset-button { - background-color: rgb(255,255,255); - background-image:url('resources/x.png'); - background-position:center; - background-repeat:no-repeat; - background-size:12px; - border:0 none; - width:16px; - height:16px; - position:relative; - left:-4px; - top:-4px; - font-size:0px; -} -.watermark { - color:#545454; -} -.search-tag-desc-result { - font-style:italic; - font-size:11px; -} -.search-tag-holder-result { - font-style:italic; - font-size:12px; -} -.search-tag-result:target { - background-color:yellow; -} -.module-graph span { - display:none; - position:absolute; -} -.module-graph:hover span { - display:block; - margin: -100px 0 0 100px; - z-index: 1; -} -.inherited-list { - margin: 10px 0 10px 0; -} -section.class-description { - line-height: 1.4; -} -.summary section[class$="-summary"], .details section[class$="-details"], -.class-uses .detail, .serialized-class-details { - padding: 0px 20px 5px 10px; - border: 1px solid #ededed; - background-color: #f8f8f8; -} -.inherited-list, section[class$="-details"] .detail { - padding:0 0 5px 8px; - background-color:#ffffff; - border:none; -} -.vertical-separator { - padding: 0 5px; -} -ul.help-section-list { - margin: 0; -} -ul.help-subtoc > li { - display: inline-block; - padding-right: 5px; - font-size: smaller; -} -ul.help-subtoc > li::before { - content: "\2022" ; - padding-right:2px; -} -span.help-note { - font-style: italic; -} -/* - * Indicator icon for external links. - */ -main a[href*="://"]::after { - content:""; - display:inline-block; - background-image:url('data:image/svg+xml; utf8, \ - \ - \ - '); - background-size:100% 100%; - width:7px; - height:7px; - margin-left:2px; - margin-bottom:4px; -} -main a[href*="://"]:hover::after, -main a[href*="://"]:focus::after { - background-image:url('data:image/svg+xml; utf8, \ - \ - \ - '); -} - -/* - * Styles for user-provided tables. - * - * borderless: - * No borders, vertical margins, styled caption. - * This style is provided for use with existing doc comments. - * In general, borderless tables should not be used for layout purposes. - * - * plain: - * Plain borders around table and cells, vertical margins, styled caption. - * Best for small tables or for complex tables for tables with cells that span - * rows and columns, when the "striped" style does not work well. - * - * striped: - * Borders around the table and vertical borders between cells, striped rows, - * vertical margins, styled caption. - * Best for tables that have a header row, and a body containing a series of simple rows. - */ - -table.borderless, -table.plain, -table.striped { - margin-top: 10px; - margin-bottom: 10px; -} -table.borderless > caption, -table.plain > caption, -table.striped > caption { - font-weight: bold; - font-size: smaller; -} -table.borderless th, table.borderless td, -table.plain th, table.plain td, -table.striped th, table.striped td { - padding: 2px 5px; -} -table.borderless, -table.borderless > thead > tr > th, table.borderless > tbody > tr > th, table.borderless > tr > th, -table.borderless > thead > tr > td, table.borderless > tbody > tr > td, table.borderless > tr > td { - border: none; -} -table.borderless > thead > tr, table.borderless > tbody > tr, table.borderless > tr { - background-color: transparent; -} -table.plain { - border-collapse: collapse; - border: 1px solid black; -} -table.plain > thead > tr, table.plain > tbody tr, table.plain > tr { - background-color: transparent; -} -table.plain > thead > tr > th, table.plain > tbody > tr > th, table.plain > tr > th, -table.plain > thead > tr > td, table.plain > tbody > tr > td, table.plain > tr > td { - border: 1px solid black; -} -table.striped { - border-collapse: collapse; - border: 1px solid black; -} -table.striped > thead { - background-color: #E3E3E3; -} -table.striped > thead > tr > th, table.striped > thead > tr > td { - border: 1px solid black; -} -table.striped > tbody > tr:nth-child(even) { - background-color: #EEE -} -table.striped > tbody > tr:nth-child(odd) { - background-color: #FFF -} -table.striped > tbody > tr > th, table.striped > tbody > tr > td { - border-left: 1px solid black; - border-right: 1px solid black; -} -table.striped > tbody > tr > th { - font-weight: normal; -} -/** - * Tweak font sizes and paddings for small screens. - */ -@media screen and (max-width: 1050px) { - #search-input { - width: 300px; - } -} -@media screen and (max-width: 800px) { - #search-input { - width: 200px; - } - .top-nav, - .bottom-nav { - font-size: 11px; - padding-top: 6px; - } - .sub-nav { - font-size: 11px; - } - .about-language { - padding-right: 16px; - } - ul.nav-list li, - .sub-nav .nav-list-search { - padding: 6px; - } - ul.sub-nav-list li { - padding-top: 5px; - } - main { - padding: 10px; - } - .summary section[class$="-summary"], .details section[class$="-details"], - .class-uses .detail, .serialized-class-details { - padding: 0 8px 5px 8px; - } - body { - -webkit-text-size-adjust: none; - } -} -@media screen and (max-width: 500px) { - #search-input { - width: 150px; - } - .top-nav, - .bottom-nav { - font-size: 10px; - } - .sub-nav { - font-size: 10px; - } - .about-language { - font-size: 10px; - padding-right: 12px; - } -} diff --git a/docs/api/tag-search-index.js b/docs/api/tag-search-index.js deleted file mode 100644 index 0367dae..0000000 --- a/docs/api/tag-search-index.js +++ /dev/null @@ -1 +0,0 @@ -tagSearchIndex = [];updateSearchResults(); \ No newline at end of file diff --git a/docs/api/type-search-index.js b/docs/api/type-search-index.js deleted file mode 100644 index 400282f..0000000 --- a/docs/api/type-search-index.js +++ /dev/null @@ -1 +0,0 @@ -typeSearchIndex = [{"l":"All Classes and Interfaces","u":"allclasses-index.html"},{"p":"lv.id.jc.algorithm.graph","l":"BreadthFirstSearch"},{"p":"lv.id.jc.algorithm.graph","l":"DijkstrasAlgorithm"},{"p":"lv.id.jc.algorithm.graph","l":"Graph"},{"p":"lv.id.jc.algorithm.graph","l":"SearchAlgorithm"}];updateSearchResults(); \ No newline at end of file diff --git a/docs/assets/Graphs.pptx b/docs/assets/Graphs.pptx deleted file mode 100644 index 72e38ec..0000000 Binary files a/docs/assets/Graphs.pptx and /dev/null differ diff --git a/docs/assets/complex.gif b/docs/assets/complex.gif deleted file mode 100644 index 49f1520..0000000 Binary files a/docs/assets/complex.gif and /dev/null differ diff --git a/docs/assets/medium.gif b/docs/assets/medium.gif deleted file mode 100644 index 7ab27ff..0000000 Binary files a/docs/assets/medium.gif and /dev/null differ diff --git a/docs/assets/small.gif b/docs/assets/small.gif deleted file mode 100644 index f84bc00..0000000 Binary files a/docs/assets/small.gif and /dev/null differ diff --git a/docs/assets/uml/graph.png b/docs/assets/uml/graph.png deleted file mode 100644 index cea38d7..0000000 Binary files a/docs/assets/uml/graph.png and /dev/null differ diff --git a/docs/assets/uml/graph.uml b/docs/assets/uml/graph.uml deleted file mode 100644 index 127a3da..0000000 --- a/docs/assets/uml/graph.uml +++ /dev/null @@ -1,39 +0,0 @@ - - - JAVA - lv.id.jc.algorithm.graph - - lv.id.jc.algorithm.graph.SearchAlgorithm - lv.id.jc.algorithm.graph.DijkstrasAlgorithm - lv.id.jc.algorithm.graph.BreadthFirstSearch - lv.id.jc.algorithm.graph.Graph - - - - - - - - - - - - - - - - - - - lv.id.jc.algorithm.graph.Graph - - - Fields - Inner Classes - Methods - Properties - - All - private - - diff --git a/docs/coverage/css/coverage.css b/docs/coverage/css/coverage.css deleted file mode 100644 index b7b9e2a..0000000 --- a/docs/coverage/css/coverage.css +++ /dev/null @@ -1,168 +0,0 @@ -/* - * Copyright 2000-2021 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -* { - margin: 0; - padding: 0; -} - -body { - background-color: #fff; - font-family: helvetica neue, tahoma, arial, sans-serif; - font-size: 82%; - color: #151515; -} - -h1 { - margin: 0.5em 0; - color: #010101; - font-weight: normal; - font-size: 18px; -} - -h2 { - margin: 0.5em 0; - color: #010101; - font-weight: normal; - font-size: 16px; -} - -a { - color: #1564C2; - text-decoration: none; -} - -a:hover { - text-decoration: underline; -} - -i { - background-color: #eee; -} - -span.separator { - color: #9BA9BA; - padding-left: 5px; - padding-right: 5px; -} - -div.content { - width: 99%; -} - -table.coverageStats { - width: 100%; - border-collapse: collapse; -} - -table.overallStats { - width: 20%; -} - -table.coverageStats td, table.coverageStats th { - padding: 4px 2px; - border-bottom: 1px solid #ccc; -} - -table.coverageStats th { - background-color: #959BA4; - border: none; - font-weight: bold; - text-align: left; - color: #FFF; -} - -table.coverageStats th.coverageStat { - width: 20%; -} - -table.coverageStats th a { - color: #FFF; -} - -table.coverageStats th a:hover { - text-decoration: none; -} - -table.coverageStats th.sortedDesc a { - background: url(../img/arrowDown.gif) no-repeat 100% 2px; - padding-right: 20px; -} - -table.coverageStats th.sortedAsc a { - background: url(../img/arrowUp.gif) no-repeat 100% 2px; - padding-right: 20px; -} - -div.footer { - margin: 2em .5em; - font-size: 85%; - text-align: left; - line-height: 140%; -} - -div.sourceCode { - width: 100%; - border: 1px solid #ccc; - font: normal 12px 'Menlo', 'Bitstream Vera Sans Mono', 'Courier New', 'Courier', monospace; - white-space: pre; -} - -div.sourceCode b { - font-weight: normal; -} - -div.sourceCode i { - display: block; - float: left; - width: 3em; - padding-right: 3px; - border-right: 1px solid #ccc; - font-style: normal; - text-align: right; -} - -div.sourceCode i.no-highlight span.number { - color: #151515; -} - -div.sourceCode .fc, div.sourceCode .fc i { - background-color: #cfc; -} - -div.sourceCode .pc, div.sourceCode .pc i { - background-color: #ffc; -} - -div.sourceCode .nc, div.sourceCode .nc i { - background-color: #fcc; -} - -.percent, .absValue { - font-size: 90%; -} - -.percent .green, .absValue .green { - color: #32cc32; -} - -.percent .red, .absValue .red { - color: #f00; -} - -.percent .totalDiff { - color: #3f3f3f; -} diff --git a/docs/coverage/css/highlight-idea.css b/docs/coverage/css/highlight-idea.css deleted file mode 100644 index 1d1fa10..0000000 --- a/docs/coverage/css/highlight-idea.css +++ /dev/null @@ -1,153 +0,0 @@ -/* - * Copyright 2000-2021 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the "License"); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an "AS IS" BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ - -/* - -Intellij Idea-like styling (c) Vasily Polovnyov - -*/ - -pre code { - display: block; padding: 0.5em; - color: #000; - background: #fff; -} - -pre .subst, -pre .title { - font-weight: normal; - color: #000; -} - -pre .comment, -pre .template_comment, -pre .javadoc, -pre .diff .header { - color: #808080; - font-style: italic; -} - -pre .annotation, -pre .decorator, -pre .preprocessor, -pre .doctype, -pre .pi, -pre .chunk, -pre .shebang, -pre .apache .cbracket, -pre .input_number, -pre .http .title { - color: #808000; -} - -pre .tag, -pre .pi { - background: #efefef; -} - -/* leonid.khachaturov: redefine background as it conflicts with change highlighting we apply on top of source highlighting */ -pre .changeAdded .tag, -pre .changeRemoved .tag, -pre .changeAdded .pi, -pre .changeRemoved .pi { - background: transparent; -} - -/* leonid.khachaturov: redefine .comment from main.css */ -pre .comment { - margin: 0; - padding: 0; - font-size: 100%; -} - -pre .tag .title, -pre .id, -pre .attr_selector, -pre .pseudo, -pre .literal, -pre .keyword, -pre .hexcolor, -pre .css .function, -pre .ini .title, -pre .css .class, -pre .list .title, -pre .nginx .title, -pre .tex .command, -pre .request, -pre .status { - font-weight: bold; - color: #000080; -} - -pre .attribute, -pre .rules .keyword, -pre .number, -pre .date, -pre .regexp, -pre .tex .special { - font-weight: bold; - color: #0000ff; -} - -pre .number, -pre .regexp { - font-weight: normal; -} - -pre .string, -pre .value, -pre .filter .argument, -pre .css .function .params, -pre .apache .tag { - color: #008000; - font-weight: bold; -} - -pre .symbol, -pre .ruby .symbol .string, -pre .ruby .symbol .keyword, -pre .ruby .symbol .keymethods, -pre .char, -pre .tex .formula { - color: #000; - background: #d0eded; - font-style: italic; -} - -pre .phpdoc, -pre .yardoctag, -pre .javadoctag { - text-decoration: underline; -} - -pre .variable, -pre .envvar, -pre .apache .sqbracket, -pre .nginx .built_in { - color: #660e7a; -} - -pre .addition { - background: #baeeba; -} - -pre .deletion { - background: #ffc8bd; -} - -pre .diff .change { - background: #bccff9; -} diff --git a/docs/coverage/img/arrowDown.gif b/docs/coverage/img/arrowDown.gif deleted file mode 100644 index a4ac9b4..0000000 Binary files a/docs/coverage/img/arrowDown.gif and /dev/null differ diff --git a/docs/coverage/img/arrowUp.gif b/docs/coverage/img/arrowUp.gif deleted file mode 100644 index d488db0..0000000 Binary files a/docs/coverage/img/arrowUp.gif and /dev/null differ diff --git a/docs/coverage/index.html b/docs/coverage/index.html deleted file mode 100644 index 356b158..0000000 --- a/docs/coverage/index.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/index_SORT_BY_BLOCK.html b/docs/coverage/index_SORT_BY_BLOCK.html deleted file mode 100644 index 2bb220c..0000000 --- a/docs/coverage/index_SORT_BY_BLOCK.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/index_SORT_BY_BLOCK_DESC.html b/docs/coverage/index_SORT_BY_BLOCK_DESC.html deleted file mode 100644 index f4e0eb6..0000000 --- a/docs/coverage/index_SORT_BY_BLOCK_DESC.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/index_SORT_BY_CLASS.html b/docs/coverage/index_SORT_BY_CLASS.html deleted file mode 100644 index e4b1f20..0000000 --- a/docs/coverage/index_SORT_BY_CLASS.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/index_SORT_BY_CLASS_DESC.html b/docs/coverage/index_SORT_BY_CLASS_DESC.html deleted file mode 100644 index 479c3f3..0000000 --- a/docs/coverage/index_SORT_BY_CLASS_DESC.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/index_SORT_BY_LINE.html b/docs/coverage/index_SORT_BY_LINE.html deleted file mode 100644 index 8e8079c..0000000 --- a/docs/coverage/index_SORT_BY_LINE.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/index_SORT_BY_LINE_DESC.html b/docs/coverage/index_SORT_BY_LINE_DESC.html deleted file mode 100644 index 417cb2d..0000000 --- a/docs/coverage/index_SORT_BY_LINE_DESC.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/index_SORT_BY_METHOD.html b/docs/coverage/index_SORT_BY_METHOD.html deleted file mode 100644 index b7b1443..0000000 --- a/docs/coverage/index_SORT_BY_METHOD.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/index_SORT_BY_METHOD_DESC.html b/docs/coverage/index_SORT_BY_METHOD_DESC.html deleted file mode 100644 index 3cb8fd7..0000000 --- a/docs/coverage/index_SORT_BY_METHOD_DESC.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/index_SORT_BY_NAME_DESC.html b/docs/coverage/index_SORT_BY_NAME_DESC.html deleted file mode 100644 index bd45b4e..0000000 --- a/docs/coverage/index_SORT_BY_NAME_DESC.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - - Coverage Report > Summary - - - - - -
      - - -

      Overall Coverage Summary

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      all classes - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -

      Coverage Breakdown

      - - - - - - - - - - - - - - -
      -Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      -
      - - - - - - - diff --git a/docs/coverage/js/highlight.pack.js b/docs/coverage/js/highlight.pack.js deleted file mode 100644 index 9d27897..0000000 --- a/docs/coverage/js/highlight.pack.js +++ /dev/null @@ -1 +0,0 @@ -var hljs=new function(){function l(o){return o.replace(/&/gm,"&").replace(//gm,">")}function b(p){for(var o=p.firstChild;o;o=o.nextSibling){if(o.nodeName=="CODE"){return o}if(!(o.nodeType==3&&o.nodeValue.match(/\s+/))){break}}}function h(p,o){return Array.prototype.map.call(p.childNodes,function(q){if(q.nodeType==3){return o?q.nodeValue.replace(/\n/g,""):q.nodeValue}if(q.nodeName=="BR"){return"\n"}return h(q,o)}).join("")}function a(q){var p=(q.className+" "+q.parentNode.className).split(/\s+/);p=p.map(function(r){return r.replace(/^language-/,"")});for(var o=0;o"}while(x.length||v.length){var u=t().splice(0,1)[0];y+=l(w.substr(p,u.offset-p));p=u.offset;if(u.event=="start"){y+=s(u.node);r.push(u.node)}else{if(u.event=="stop"){var o,q=r.length;do{q--;o=r[q];y+=("")}while(o!=u.node);r.splice(q,1);while(q'+L[0]+""}else{r+=L[0]}N=A.lR.lastIndex;L=A.lR.exec(K)}return r+K.substr(N)}function z(){if(A.sL&&!e[A.sL]){return l(w)}var r=A.sL?d(A.sL,w):g(w);if(A.r>0){v+=r.keyword_count;B+=r.r}return''+r.value+""}function J(){return A.sL!==undefined?z():G()}function I(L,r){var K=L.cN?'':"";if(L.rB){x+=K;w=""}else{if(L.eB){x+=l(r)+K;w=""}else{x+=K;w=r}}A=Object.create(L,{parent:{value:A}});B+=L.r}function C(K,r){w+=K;if(r===undefined){x+=J();return 0}var L=o(r,A);if(L){x+=J();I(L,r);return L.rB?0:r.length}var M=s(A,r);if(M){if(!(M.rE||M.eE)){w+=r}x+=J();do{if(A.cN){x+=""}A=A.parent}while(A!=M.parent);if(M.eE){x+=l(r)}w="";if(M.starts){I(M.starts,"")}return M.rE?0:r.length}if(t(r,A)){throw"Illegal"}w+=r;return r.length||1}var F=e[D];f(F);var A=F;var w="";var B=0;var v=0;var x="";try{var u,q,p=0;while(true){A.t.lastIndex=p;u=A.t.exec(E);if(!u){break}q=C(E.substr(p,u.index-p),u[0]);p=u.index+q}C(E.substr(p));return{r:B,keyword_count:v,value:x,language:D}}catch(H){if(H=="Illegal"){return{r:0,keyword_count:0,value:l(E)}}else{throw H}}}function g(s){var o={keyword_count:0,r:0,value:l(s)};var q=o;for(var p in e){if(!e.hasOwnProperty(p)){continue}var r=d(p,s);r.language=p;if(r.keyword_count+r.r>q.keyword_count+q.r){q=r}if(r.keyword_count+r.r>o.keyword_count+o.r){q=o;o=r}}if(q.language){o.second_best=q}return o}function i(q,p,o){if(p){q=q.replace(/^((<[^>]+>|\t)+)/gm,function(r,v,u,t){return v.replace(/\t/g,p)})}if(o){q=q.replace(/\n/g,"
      ")}return q}function m(r,u,p){var v=h(r,p);var t=a(r);if(t=="no-highlight"){return}var w=t?d(t,v):g(v);t=w.language;var o=c(r);if(o.length){var q=document.createElement("pre");q.innerHTML=w.value;w.value=j(o,c(q),v)}w.value=i(w.value,u,p);var s=r.className;if(!s.match("(\\s|^)(language-)?"+t+"(\\s|$)")){s=s?(s+" "+t):t}r.innerHTML=w.value;r.className=s;r.result={language:t,kw:w.keyword_count,re:w.r};if(w.second_best){r.second_best={language:w.second_best.language,kw:w.second_best.keyword_count,re:w.second_best.r}}}function n(){if(n.called){return}n.called=true;Array.prototype.map.call(document.getElementsByTagName("pre"),b).filter(Boolean).forEach(function(o){m(o,hljs.tabReplace)})}function k(){window.addEventListener("DOMContentLoaded",n,false);window.addEventListener("load",n,false)}var e={};this.LANGUAGES=e;this.highlight=d;this.highlightAuto=g;this.fixMarkup=i;this.highlightBlock=m;this.initHighlighting=n;this.initHighlightingOnLoad=k;this.IR="[a-zA-Z][a-zA-Z0-9_]*";this.UIR="[a-zA-Z_][a-zA-Z0-9_]*";this.NR="\\b\\d+(\\.\\d+)?";this.CNR="(\\b0[xX][a-fA-F0-9]+|(\\b\\d+(\\.\\d*)?|\\.\\d+)([eE][-+]?\\d+)?)";this.BNR="\\b(0b[01]+)";this.RSR="!|!=|!==|%|%=|&|&&|&=|\\*|\\*=|\\+|\\+=|,|\\.|-|-=|/|/=|:|;|<|<<|<<=|<=|=|==|===|>|>=|>>|>>=|>>>|>>>=|\\?|\\[|\\{|\\(|\\^|\\^=|\\||\\|=|\\|\\||~";this.BE={b:"\\\\[\\s\\S]",r:0};this.ASM={cN:"string",b:"'",e:"'",i:"\\n",c:[this.BE],r:0};this.QSM={cN:"string",b:'"',e:'"',i:"\\n",c:[this.BE],r:0};this.CLCM={cN:"comment",b:"//",e:"$"};this.CBLCLM={cN:"comment",b:"/\\*",e:"\\*/"};this.HCM={cN:"comment",b:"#",e:"$"};this.NM={cN:"number",b:this.NR,r:0};this.CNM={cN:"number",b:this.CNR,r:0};this.BNM={cN:"number",b:this.BNR,r:0};this.inherit=function(q,r){var o={};for(var p in q){o[p]=q[p]}if(r){for(var p in r){o[p]=r[p]}}return o}}();hljs.LANGUAGES.actionscript=function(a){var d="[a-zA-Z_$][a-zA-Z0-9_$]*";var c="([*]|[a-zA-Z_$][a-zA-Z0-9_$]*)";var e={cN:"rest_arg",b:"[.]{3}",e:d,r:10};var b={cN:"title",b:d};return{k:{keyword:"as break case catch class const continue default delete do dynamic each else extends final finally for function get if implements import in include instanceof interface internal is namespace native new override package private protected public return set static super switch this throw try typeof use var void while with",literal:"true false null undefined"},c:[a.ASM,a.QSM,a.CLCM,a.CBLCLM,a.CNM,{cN:"package",bWK:true,e:"{",k:"package",c:[b]},{cN:"class",bWK:true,e:"{",k:"class interface",c:[{bWK:true,k:"extends implements"},b]},{cN:"preprocessor",bWK:true,e:";",k:"import include"},{cN:"function",bWK:true,e:"[{;]",k:"function",i:"\\S",c:[b,{cN:"params",b:"\\(",e:"\\)",c:[a.ASM,a.QSM,a.CLCM,a.CBLCLM,e]},{cN:"type",b:":",e:c,r:10}]}]}}(hljs);hljs.LANGUAGES.bash=function(a){var g="true false";var e="if then else elif fi for break continue while in do done echo exit return set declare";var c={cN:"variable",b:"\\$[a-zA-Z0-9_#]+"};var b={cN:"variable",b:"\\${([^}]|\\\\})+}"};var h={cN:"string",b:'"',e:'"',i:"\\n",c:[a.BE,c,b],r:0};var d={cN:"string",b:"'",e:"'",c:[{b:"''"}],r:0};var f={cN:"test_condition",b:"",e:"",c:[h,d,c,b],k:{literal:g},r:0};return{k:{keyword:e,literal:g},c:[{cN:"shebang",b:"(#!\\/bin\\/bash)|(#!\\/bin\\/sh)",r:10},c,b,a.HCM,h,d,a.inherit(f,{b:"\\[ ",e:" \\]",r:0}),a.inherit(f,{b:"\\[\\[ ",e:" \\]\\]"})]}}(hljs);hljs.LANGUAGES.coffeescript=function(c){var b={keyword:"in if for while finally new do return else break catch instanceof throw try this switch continue typeof delete debugger super then unless until loop of by when and or is isnt not",literal:"true false null undefined yes no on off ",reserved:"case default function var void with const let enum export import native __hasProp __extends __slice __bind __indexOf"};var a="[A-Za-z$_][0-9A-Za-z$_]*";var e={cN:"title",b:a};var d={cN:"subst",b:"#\\{",e:"}",k:b,c:[c.BNM,c.CNM]};return{k:b,c:[c.BNM,c.CNM,c.ASM,{cN:"string",b:'"""',e:'"""',c:[c.BE,d]},{cN:"string",b:'"',e:'"',c:[c.BE,d],r:0},{cN:"comment",b:"###",e:"###"},c.HCM,{cN:"regexp",b:"///",e:"///",c:[c.HCM]},{cN:"regexp",b:"//[gim]*"},{cN:"regexp",b:"/\\S(\\\\.|[^\\n])*/[gim]*"},{b:"`",e:"`",eB:true,eE:true,sL:"javascript"},{cN:"function",b:a+"\\s*=\\s*(\\(.+\\))?\\s*[-=]>",rB:true,c:[e,{cN:"params",b:"\\(",e:"\\)"}]},{cN:"class",bWK:true,k:"class",e:"$",i:":",c:[{bWK:true,k:"extends",eW:true,i:":",c:[e]},e]},{cN:"property",b:"@"+a}]}}(hljs);hljs.LANGUAGES.cpp=function(a){var b={keyword:"false int float while private char catch export virtual operator sizeof dynamic_cast|10 typedef const_cast|10 const struct for static_cast|10 union namespace unsigned long throw volatile static protected bool template mutable if public friend do return goto auto void enum else break new extern using true class asm case typeid short reinterpret_cast|10 default double register explicit signed typename try this switch continue wchar_t inline delete alignof char16_t char32_t constexpr decltype noexcept nullptr static_assert thread_local restrict _Bool complex",built_in:"std string cin cout cerr clog stringstream istringstream ostringstream auto_ptr deque list queue stack vector map set bitset multiset multimap unordered_set unordered_map unordered_multiset unordered_multimap array shared_ptr"};return{k:b,i:"",k:b,r:10,c:["self"]}]}}(hljs);hljs.LANGUAGES.cs=function(a){return{k:"abstract as base bool break byte case catch char checked class const continue decimal default delegate do double else enum event explicit extern false finally fixed float for foreach goto if implicit in int interface internal is lock long namespace new null object operator out override params private protected public readonly ref return sbyte sealed short sizeof stackalloc static string struct switch this throw true try typeof uint ulong unchecked unsafe ushort using virtual volatile void while ascending descending from get group into join let orderby partial select set value var where yield",c:[{cN:"comment",b:"///",e:"$",rB:true,c:[{cN:"xmlDocTag",b:"///|"},{cN:"xmlDocTag",b:""}]},a.CLCM,a.CBLCLM,{cN:"preprocessor",b:"#",e:"$",k:"if else elif endif define undef warning error line region endregion pragma checksum"},{cN:"string",b:'@"',e:'"',c:[{b:'""'}]},a.ASM,a.QSM,a.CNM]}}(hljs);hljs.LANGUAGES.css=function(a){var b={cN:"function",b:a.IR+"\\(",e:"\\)",c:[a.NM,a.ASM,a.QSM]};return{cI:true,i:"[=/|']",c:[a.CBLCLM,{cN:"id",b:"\\#[A-Za-z0-9_-]+"},{cN:"class",b:"\\.[A-Za-z0-9_-]+",r:0},{cN:"attr_selector",b:"\\[",e:"\\]",i:"$"},{cN:"pseudo",b:":(:)?[a-zA-Z0-9\\_\\-\\+\\(\\)\\\"\\']+"},{cN:"at_rule",b:"@(font-face|page)",l:"[a-z-]+",k:"font-face page"},{cN:"at_rule",b:"@",e:"[{;]",eE:true,k:"import page media charset",c:[b,a.ASM,a.QSM,a.NM]},{cN:"tag",b:a.IR,r:0},{cN:"rules",b:"{",e:"}",i:"[^\\s]",r:0,c:[a.CBLCLM,{cN:"rule",b:"[^\\s]",rB:true,e:";",eW:true,c:[{cN:"attribute",b:"[A-Z\\_\\.\\-]+",e:":",eE:true,i:"[^\\s]",starts:{cN:"value",eW:true,eE:true,c:[b,a.NM,a.QSM,a.ASM,a.CBLCLM,{cN:"hexcolor",b:"\\#[0-9A-F]+"},{cN:"important",b:"!important"}]}}]}]}]}}(hljs);hljs.LANGUAGES.diff=function(a){return{c:[{cN:"chunk",b:"^\\@\\@ +\\-\\d+,\\d+ +\\+\\d+,\\d+ +\\@\\@$",r:10},{cN:"chunk",b:"^\\*\\*\\* +\\d+,\\d+ +\\*\\*\\*\\*$",r:10},{cN:"chunk",b:"^\\-\\-\\- +\\d+,\\d+ +\\-\\-\\-\\-$",r:10},{cN:"header",b:"Index: ",e:"$"},{cN:"header",b:"=====",e:"=====$"},{cN:"header",b:"^\\-\\-\\-",e:"$"},{cN:"header",b:"^\\*{3} ",e:"$"},{cN:"header",b:"^\\+\\+\\+",e:"$"},{cN:"header",b:"\\*{5}",e:"\\*{5}$"},{cN:"addition",b:"^\\+",e:"$"},{cN:"deletion",b:"^\\-",e:"$"},{cN:"change",b:"^\\!",e:"$"}]}}(hljs);hljs.LANGUAGES.http=function(a){return{i:"\\S",c:[{cN:"status",b:"^HTTP/[0-9\\.]+",e:"$",c:[{cN:"number",b:"\\b\\d{3}\\b"}]},{cN:"request",b:"^[A-Z]+ (.*?) HTTP/[0-9\\.]+$",rB:true,e:"$",c:[{cN:"string",b:" ",e:" ",eB:true,eE:true}]},{cN:"attribute",b:"^\\w",e:": ",eE:true,i:"\\n|\\s|=",starts:{cN:"string",e:"$"}},{b:"\\n\\n",starts:{sL:"",eW:true}}]}}(hljs);hljs.LANGUAGES.ini=function(a){return{cI:true,i:"[^\\s]",c:[{cN:"comment",b:";",e:"$"},{cN:"title",b:"^\\[",e:"\\]"},{cN:"setting",b:"^[a-z0-9\\[\\]_-]+[ \\t]*=[ \\t]*",e:"$",c:[{cN:"value",eW:true,k:"on off true false yes no",c:[a.QSM,a.NM]}]}]}}(hljs);hljs.LANGUAGES.java=function(a){return{k:"false synchronized int abstract float private char boolean static null if const for true while long throw strictfp finally protected import native final return void enum else break transient new catch instanceof byte super volatile case assert short package default double public try this switch continue throws",c:[{cN:"javadoc",b:"/\\*\\*",e:"\\*/",c:[{cN:"javadoctag",b:"@[A-Za-z]+"}],r:10},a.CLCM,a.CBLCLM,a.ASM,a.QSM,{cN:"class",bWK:true,e:"{",k:"class interface",i:":",c:[{bWK:true,k:"extends implements",r:10},{cN:"title",b:a.UIR}]},a.CNM,{cN:"annotation",b:"@[A-Za-z]+"}]}}(hljs);hljs.LANGUAGES.javascript=function(a){return{k:{keyword:"in if for while finally var new function do return void else break catch instanceof with throw case default try this switch continue typeof delete let yield const",literal:"true false null undefined NaN Infinity"},c:[a.ASM,a.QSM,a.CLCM,a.CBLCLM,a.CNM,{b:"("+a.RSR+"|\\b(case|return|throw)\\b)\\s*",k:"return throw case",c:[a.CLCM,a.CBLCLM,{cN:"regexp",b:"/",e:"/[gim]*",i:"\\n",c:[{b:"\\\\/"}]},{b:"<",e:">;",sL:"xml"}],r:0},{cN:"function",bWK:true,e:"{",k:"function",c:[{cN:"title",b:"[A-Za-z$_][0-9A-Za-z$_]*"},{cN:"params",b:"\\(",e:"\\)",c:[a.CLCM,a.CBLCLM],i:"[\"'\\(]"}],i:"\\[|%"}]}}(hljs);hljs.LANGUAGES.json=function(a){var e={literal:"true false null"};var d=[a.QSM,a.CNM];var c={cN:"value",e:",",eW:true,eE:true,c:d,k:e};var b={b:"{",e:"}",c:[{cN:"attribute",b:'\\s*"',e:'"\\s*:\\s*',eB:true,eE:true,c:[a.BE],i:"\\n",starts:c}],i:"\\S"};var f={b:"\\[",e:"\\]",c:[a.inherit(c,{cN:null})],i:"\\S"};d.splice(d.length,0,b,f);return{c:d,k:e,i:"\\S"}}(hljs);hljs.LANGUAGES.kotlin=function(a){var b={cN:"string",b:'u?r?"""',e:'"""',r:10};return{defaultMode:{k:"package import as type class trait by where object this val var fun get set namespace if else try catch finally for while do super is throw return continue break when in abstract final enum open attribute override private protected public internal out lazy ref",c:[{cN:"javadoc",b:"/\\*\\*",e:"\\*/",c:[{cN:"javadoctag",b:"@[A-Za-z]+"}],r:10},a.CLCM,a.CBLCLM,a.ASM,a.QSM,b,{cN:"class",b:"((annotation )?class |trait )",e:"({|$)",k:"class trait",c:[{cN:"title",b:a.UIR},{cN:"params",b:"\\(",e:"\\)",c:[a.ASM,a.QSM,b]}]},a.CNM]}}}(hljs);hljs.LANGUAGES.xml=function(a){var c="[A-Za-z0-9\\._:-]+";var b={eW:true,c:[{cN:"attribute",b:c,r:0},{b:'="',rB:true,e:'"',c:[{cN:"value",b:'"',eW:true}]},{b:"='",rB:true,e:"'",c:[{cN:"value",b:"'",eW:true}]},{b:"=",c:[{cN:"value",b:"[^\\s/>]+"}]}]};return{cI:true,c:[{cN:"pi",b:"<\\?",e:"\\?>",r:10},{cN:"doctype",b:"",r:10,c:[{b:"\\[",e:"\\]"}]},{cN:"comment",b:"",r:10},{cN:"cdata",b:"<\\!\\[CDATA\\[",e:"\\]\\]>",r:10},{cN:"tag",b:"|$)",e:">",k:{title:"style"},c:[b],starts:{e:"",rE:true,sL:"css"}},{cN:"tag",b:"|$)",e:">",k:{title:"script"},c:[b],starts:{e:"<\/script>",rE:true,sL:"javascript"}},{b:"<%",e:"%>",sL:"vbscript"},{cN:"tag",b:"",c:[{cN:"title",b:"[^ />]+"},b]}]}}(hljs);hljs.LANGUAGES.markdown=function(a){return{c:[{cN:"header",b:"^#{1,3}",e:"$"},{cN:"header",b:"^.+?\\n[=-]{2,}$"},{b:"<",e:">",sL:"xml",r:0},{cN:"bullet",b:"^([*+-]|(\\d+\\.))\\s+"},{cN:"strong",b:"[*_]{2}.+?[*_]{2}"},{cN:"emphasis",b:"\\*.+?\\*"},{cN:"emphasis",b:"_.+?_",r:0},{cN:"blockquote",b:"^>\\s+",e:"$"},{cN:"code",b:"`.+?`"},{cN:"code",b:"^ ",e:"$",r:0},{cN:"horizontal_rule",b:"^-{3,}",e:"$"},{b:"\\[.+?\\]\\(.+?\\)",rB:true,c:[{cN:"link_label",b:"\\[.+\\]"},{cN:"link_url",b:"\\(",e:"\\)",eB:true,eE:true}]}]}}(hljs);hljs.LANGUAGES.objectivec=function(a){var b={keyword:"int float while private char catch export sizeof typedef const struct for union unsigned long volatile static protected bool mutable if public do return goto void enum else break extern class asm case short default double throw register explicit signed typename try this switch continue wchar_t inline readonly assign property protocol self synchronized end synthesize id optional required implementation nonatomic interface super unichar finally dynamic IBOutlet IBAction selector strong weak readonly",literal:"false true FALSE TRUE nil YES NO NULL",built_in:"NSString NSDictionary CGRect CGPoint UIButton UILabel UITextView UIWebView MKMapView UISegmentedControl NSObject UITableViewDelegate UITableViewDataSource NSThread UIActivityIndicator UITabbar UIToolBar UIBarButtonItem UIImageView NSAutoreleasePool UITableView BOOL NSInteger CGFloat NSException NSLog NSMutableString NSMutableArray NSMutableDictionary NSURL NSIndexPath CGSize UITableViewCell UIView UIViewController UINavigationBar UINavigationController UITabBarController UIPopoverController UIPopoverControllerDelegate UIImage NSNumber UISearchBar NSFetchedResultsController NSFetchedResultsChangeType UIScrollView UIScrollViewDelegate UIEdgeInsets UIColor UIFont UIApplication NSNotFound NSNotificationCenter NSNotification UILocalNotification NSBundle NSFileManager NSTimeInterval NSDate NSCalendar NSUserDefaults UIWindow NSRange NSArray NSError NSURLRequest NSURLConnection class UIInterfaceOrientation MPMoviePlayerController dispatch_once_t dispatch_queue_t dispatch_sync dispatch_async dispatch_once"};return{k:b,i:""}]},{cN:"preprocessor",b:"#",e:"$"},{cN:"class",bWK:true,e:"({|$)",k:"interface class protocol implementation",c:[{cN:"id",b:a.UIR}]},{cN:"variable",b:"\\."+a.UIR}]}}(hljs);hljs.LANGUAGES.perl=function(e){var a="getpwent getservent quotemeta msgrcv scalar kill dbmclose undef lc ma syswrite tr send umask sysopen shmwrite vec qx utime local oct semctl localtime readpipe do return format read sprintf dbmopen pop getpgrp not getpwnam rewinddir qqfileno qw endprotoent wait sethostent bless s|0 opendir continue each sleep endgrent shutdown dump chomp connect getsockname die socketpair close flock exists index shmgetsub for endpwent redo lstat msgctl setpgrp abs exit select print ref gethostbyaddr unshift fcntl syscall goto getnetbyaddr join gmtime symlink semget splice x|0 getpeername recv log setsockopt cos last reverse gethostbyname getgrnam study formline endhostent times chop length gethostent getnetent pack getprotoent getservbyname rand mkdir pos chmod y|0 substr endnetent printf next open msgsnd readdir use unlink getsockopt getpriority rindex wantarray hex system getservbyport endservent int chr untie rmdir prototype tell listen fork shmread ucfirst setprotoent else sysseek link getgrgid shmctl waitpid unpack getnetbyname reset chdir grep split require caller lcfirst until warn while values shift telldir getpwuid my getprotobynumber delete and sort uc defined srand accept package seekdir getprotobyname semop our rename seek if q|0 chroot sysread setpwent no crypt getc chown sqrt write setnetent setpriority foreach tie sin msgget map stat getlogin unless elsif truncate exec keys glob tied closedirioctl socket readlink eval xor readline binmode setservent eof ord bind alarm pipe atan2 getgrent exp time push setgrent gt lt or ne m|0 break given say state when";var d={cN:"subst",b:"[$@]\\{",e:"\\}",k:a,r:10};var b={cN:"variable",b:"\\$\\d"};var i={cN:"variable",b:"[\\$\\%\\@\\*](\\^\\w\\b|#\\w+(\\:\\:\\w+)*|[^\\s\\w{]|{\\w+}|\\w+(\\:\\:\\w*)*)"};var f=[e.BE,d,b,i];var h={b:"->",c:[{b:e.IR},{b:"{",e:"}"}]};var g={cN:"comment",b:"^(__END__|__DATA__)",e:"\\n$",r:5};var c=[b,i,e.HCM,g,{cN:"comment",b:"^\\=\\w",e:"\\=cut",eW:true},h,{cN:"string",b:"q[qwxr]?\\s*\\(",e:"\\)",c:f,r:5},{cN:"string",b:"q[qwxr]?\\s*\\[",e:"\\]",c:f,r:5},{cN:"string",b:"q[qwxr]?\\s*\\{",e:"\\}",c:f,r:5},{cN:"string",b:"q[qwxr]?\\s*\\|",e:"\\|",c:f,r:5},{cN:"string",b:"q[qwxr]?\\s*\\<",e:"\\>",c:f,r:5},{cN:"string",b:"qw\\s+q",e:"q",c:f,r:5},{cN:"string",b:"'",e:"'",c:[e.BE],r:0},{cN:"string",b:'"',e:'"',c:f,r:0},{cN:"string",b:"`",e:"`",c:[e.BE]},{cN:"string",b:"{\\w+}",r:0},{cN:"string",b:"-?\\w+\\s*\\=\\>",r:0},{cN:"number",b:"(\\b0[0-7_]+)|(\\b0x[0-9a-fA-F_]+)|(\\b[1-9][0-9_]*(\\.[0-9_]+)?)|[0_]\\b",r:0},{b:"("+e.RSR+"|\\b(split|return|print|reverse|grep)\\b)\\s*",k:"split return print reverse grep",r:0,c:[e.HCM,g,{cN:"regexp",b:"(s|tr|y)/(\\\\.|[^/])*/(\\\\.|[^/])*/[a-z]*",r:10},{cN:"regexp",b:"(m|qr)?/",e:"/[a-z]*",c:[e.BE],r:0}]},{cN:"sub",bWK:true,e:"(\\s*\\(.*?\\))?[;{]",k:"sub",r:5},{cN:"operator",b:"-\\w\\b",r:0}];d.c=c;h.c[1].c=c;return{k:a,c:c}}(hljs);hljs.LANGUAGES.php=function(a){var e={cN:"variable",b:"\\$+[a-zA-Z_\x7f-\xff][a-zA-Z0-9_\x7f-\xff]*"};var b=[a.inherit(a.ASM,{i:null}),a.inherit(a.QSM,{i:null}),{cN:"string",b:'b"',e:'"',c:[a.BE]},{cN:"string",b:"b'",e:"'",c:[a.BE]}];var c=[a.BNM,a.CNM];var d={cN:"title",b:a.UIR};return{cI:true,k:"and include_once list abstract global private echo interface as static endswitch array null if endwhile or const for endforeach self var while isset public protected exit foreach throw elseif include __FILE__ empty require_once do xor return implements parent clone use __CLASS__ __LINE__ else break print eval new catch __METHOD__ case exception php_user_filter default die require __FUNCTION__ enddeclare final try this switch continue endfor endif declare unset true false namespace trait goto instanceof insteadof __DIR__ __NAMESPACE__ __halt_compiler",c:[a.CLCM,a.HCM,{cN:"comment",b:"/\\*",e:"\\*/",c:[{cN:"phpdoc",b:"\\s@[A-Za-z]+"}]},{cN:"comment",eB:true,b:"__halt_compiler.+?;",eW:true},{cN:"string",b:"<<<['\"]?\\w+['\"]?$",e:"^\\w+;",c:[a.BE]},{cN:"preprocessor",b:"<\\?php",r:10},{cN:"preprocessor",b:"\\?>"},e,{cN:"function",bWK:true,e:"{",k:"function",i:"\\$|\\[|%",c:[d,{cN:"params",b:"\\(",e:"\\)",c:["self",e,a.CBLCLM].concat(b).concat(c)}]},{cN:"class",bWK:true,e:"{",k:"class",i:"[:\\(\\$]",c:[{bWK:true,eW:true,k:"extends",c:[d]},d]},{b:"=>"}].concat(b).concat(c)}}(hljs);hljs.LANGUAGES.python=function(a){var f={cN:"prompt",b:"^(>>>|\\.\\.\\.) "};var c=[{cN:"string",b:"(u|b)?r?'''",e:"'''",c:[f],r:10},{cN:"string",b:'(u|b)?r?"""',e:'"""',c:[f],r:10},{cN:"string",b:"(u|r|ur)'",e:"'",c:[a.BE],r:10},{cN:"string",b:'(u|r|ur)"',e:'"',c:[a.BE],r:10},{cN:"string",b:"(b|br)'",e:"'",c:[a.BE]},{cN:"string",b:'(b|br)"',e:'"',c:[a.BE]}].concat([a.ASM,a.QSM]);var e={cN:"title",b:a.UIR};var d={cN:"params",b:"\\(",e:"\\)",c:["self",a.CNM,f].concat(c)};var b={bWK:true,e:":",i:"[${=;\\n]",c:[e,d],r:10};return{k:{keyword:"and elif is global as in if from raise for except finally print import pass return exec else break not with class assert yield try while continue del or def lambda nonlocal|10",built_in:"None True False Ellipsis NotImplemented"},i:"(|\\?)",c:c.concat([f,a.HCM,a.inherit(b,{cN:"function",k:"def"}),a.inherit(b,{cN:"class",k:"class"}),a.CNM,{cN:"decorator",b:"@",e:"$"},{b:"\\b(print|exec)\\("}])}}(hljs);hljs.LANGUAGES.ruby=function(e){var a="[a-zA-Z_][a-zA-Z0-9_]*(\\!|\\?)?";var j="[a-zA-Z_]\\w*[!?=]?|[-+~]\\@|<<|>>|=~|===?|<=>|[<>]=?|\\*\\*|[-/+%^&*~`|]|\\[\\]=?";var g={keyword:"and false then defined module in return redo if BEGIN retry end for true self when next until do begin unless END rescue nil else break undef not super class case require yield alias while ensure elsif or include"};var c={cN:"yardoctag",b:"@[A-Za-z]+"};var k=[{cN:"comment",b:"#",e:"$",c:[c]},{cN:"comment",b:"^\\=begin",e:"^\\=end",c:[c],r:10},{cN:"comment",b:"^__END__",e:"\\n$"}];var d={cN:"subst",b:"#\\{",e:"}",l:a,k:g};var i=[e.BE,d];var b=[{cN:"string",b:"'",e:"'",c:i,r:0},{cN:"string",b:'"',e:'"',c:i,r:0},{cN:"string",b:"%[qw]?\\(",e:"\\)",c:i},{cN:"string",b:"%[qw]?\\[",e:"\\]",c:i},{cN:"string",b:"%[qw]?{",e:"}",c:i},{cN:"string",b:"%[qw]?<",e:">",c:i,r:10},{cN:"string",b:"%[qw]?/",e:"/",c:i,r:10},{cN:"string",b:"%[qw]?%",e:"%",c:i,r:10},{cN:"string",b:"%[qw]?-",e:"-",c:i,r:10},{cN:"string",b:"%[qw]?\\|",e:"\\|",c:i,r:10}];var h={cN:"function",bWK:true,e:" |$|;",k:"def",c:[{cN:"title",b:j,l:a,k:g},{cN:"params",b:"\\(",e:"\\)",l:a,k:g}].concat(k)};var f=k.concat(b.concat([{cN:"class",bWK:true,e:"$|;",k:"class module",c:[{cN:"title",b:"[A-Za-z_]\\w*(::\\w+)*(\\?|\\!)?",r:0},{cN:"inheritance",b:"<\\s*",c:[{cN:"parent",b:"("+e.IR+"::)?"+e.IR}]}].concat(k)},h,{cN:"constant",b:"(::)?(\\b[A-Z]\\w*(::)?)+",r:0},{cN:"symbol",b:":",c:b.concat([{b:j}]),r:0},{cN:"symbol",b:a+":",r:0},{cN:"number",b:"(\\b0[0-7_]+)|(\\b0x[0-9a-fA-F_]+)|(\\b[1-9][0-9_]*(\\.[0-9_]+)?)|[0_]\\b",r:0},{cN:"number",b:"\\?\\w"},{cN:"variable",b:"(\\$\\W)|((\\$|\\@\\@?)(\\w+))"},{b:"("+e.RSR+")\\s*",c:k.concat([{cN:"regexp",b:"/",e:"/[a-z]*",i:"\\n",c:[e.BE,d]}]),r:0}]));d.c=f;h.c[1].c=f;return{l:a,k:g,c:f}}(hljs);hljs.LANGUAGES.scss=function(a){var b="[a-zA-Z-][a-zA-Z0-9_-]*";var c={cN:"function",b:b+"\\(",e:"\\)",c:["self",a.NM,a.ASM,a.QSM]};var d={cN:"attribute",b:"[A-Z\\_\\.\\-]+",e:":",eE:true,i:"[^\\s]",starts:{cN:"value",eW:true,eE:true,c:[c,a.NM,a.QSM,a.ASM,a.CBLCLM,{cN:"hexcolor",b:"\\#[0-9A-F]+"},{cN:"important",b:"!important"}]}};return{cI:true,i:"[=/|']",c:[a.CLCM,a.CBLCLM,{cN:"function",b:b+"\\(",e:"\\)",c:["self",a.NM,a.ASM,a.QSM]},{cN:"id",b:"\\#[A-Za-z0-9_-]+",r:0},{cN:"class",b:"\\.[A-Za-z0-9_-]+",r:0},{cN:"attr_selector",b:"\\[",e:"\\]",i:"$"},{cN:"tag",b:"\\b(a|abbr|acronym|address|area|article|aside|audio|b|base|big|blockquote|body|br|button|canvas|caption|cite|code|col|colgroup|command|datalist|dd|del|details|dfn|div|dl|dt|em|embed|fieldset|figcaption|figure|footer|form|frame|frameset|(h[1-6])|head|header|hgroup|hr|html|i|iframe|img|input|ins|kbd|keygen|label|legend|li|link|map|mark|meta|meter|nav|noframes|noscript|object|ol|optgroup|option|output|p|param|pre|progress|q|rp|rt|ruby|samp|script|section|select|small|span|strike|strong|style|sub|sup|table|tbody|td|textarea|tfoot|th|thead|time|title|tr|tt|ul|var|video)\\b",r:0},{cN:"pseudo",b:":(visited|valid|root|right|required|read-write|read-only|out-range|optional|only-of-type|only-child|nth-of-type|nth-last-of-type|nth-last-child|nth-child|not|link|left|last-of-type|last-child|lang|invalid|indeterminate|in-range|hover|focus|first-of-type|first-line|first-letter|first-child|first|enabled|empty|disabled|default|checked|before|after|active)"},{cN:"pseudo",b:"::(after|before|choices|first-letter|first-line|repeat-index|repeat-item|selection|value)"},{cN:"attribute",b:"\\b(z-index|word-wrap|word-spacing|word-break|width|widows|white-space|visibility|vertical-align|unicode-bidi|transition-timing-function|transition-property|transition-duration|transition-delay|transition|transform-style|transform-origin|transform|top|text-underline-position|text-transform|text-shadow|text-rendering|text-overflow|text-indent|text-decoration-style|text-decoration-line|text-decoration-color|text-decoration|text-align-last|text-align|tab-size|table-layout|right|resize|quotes|position|pointer-events|perspective-origin|perspective|page-break-inside|page-break-before|page-break-after|padding-top|padding-right|padding-left|padding-bottom|padding|overflow-y|overflow-x|overflow-wrap|overflow|outline-width|outline-style|outline-offset|outline-color|outline|orphans|order|opacity|object-position|object-fit|normal|none|nav-up|nav-right|nav-left|nav-index|nav-down|min-width|min-height|max-width|max-height|mask|marks|margin-top|margin-right|margin-left|margin-bottom|margin|list-style-type|list-style-position|list-style-image|list-style|line-height|letter-spacing|left|justify-content|initial|inherit|ime-mode|image-orientation|image-resolution|image-rendering|icon|hyphens|height|font-weight|font-variant-ligatures|font-variant|font-style|font-stretch|font-size-adjust|font-size|font-language-override|font-kerning|font-feature-settings|font-family|font|float|flex-wrap|flex-shrink|flex-grow|flex-flow|flex-direction|flex-basis|flex|filter|empty-cells|display|direction|cursor|counter-reset|counter-increment|content|column-width|column-span|column-rule-width|column-rule-style|column-rule-color|column-rule|column-gap|column-fill|column-count|columns|color|clip-path|clip|clear|caption-side|break-inside|break-before|break-after|box-sizing|box-shadow|box-decoration-break|bottom|border-width|border-top-width|border-top-style|border-top-right-radius|border-top-left-radius|border-top-color|border-top|border-style|border-spacing|border-right-width|border-right-style|border-right-color|border-right|border-radius|border-left-width|border-left-style|border-left-color|border-left|border-image-width|border-image-source|border-image-slice|border-image-repeat|border-image-outset|border-image|border-color|border-collapse|border-bottom-width|border-bottom-style|border-bottom-right-radius|border-bottom-left-radius|border-bottom-color|border-bottom|border|background-size|background-repeat|background-position|background-origin|background-image|background-color|background-clip|background-attachment|background|backface-visibility|auto|animation-timing-function|animation-play-state|animation-name|animation-iteration-count|animation-fill-mode|animation-duration|animation-direction|animation-delay|animation|align-self|align-items|align-content)\\b",i:"[^\\s]"},{cN:"value",b:"\\b(whitespace|wait|w-resize|visible|vertical-text|vertical-ideographic|uppercase|upper-roman|upper-alpha|underline|transparent|top|thin|thick|text|text-top|text-bottom|tb-rl|table-header-group|table-footer-group|sw-resize|super|strict|static|square|solid|small-caps|separate|se-resize|scroll|s-resize|rtl|row-resize|ridge|right|repeat|repeat-y|repeat-x|relative|progress|pointer|overline|outside|outset|oblique|nowrap|not-allowed|normal|none|nw-resize|no-repeat|no-drop|newspaper|ne-resize|n-resize|move|middle|medium|ltr|lr-tb|lowercase|lower-roman|lower-alpha|loose|list-item|line|line-through|line-edge|lighter|left|keep-all|justify|italic|inter-word|inter-ideograph|inside|inset|inline|inline-block|inherit|inactive|ideograph-space|ideograph-parenthesis|ideograph-numeric|ideograph-alpha|horizontal|hidden|help|hand|groove|fixed|ellipsis|e-resize|double|dotted|distribute|distribute-space|distribute-letter|distribute-all-lines|disc|disabled|default|decimal|dashed|crosshair|collapse|col-resize|circle|char|center|capitalize|break-word|break-all|bottom|both|bolder|bold|block|bidi-override|below|baseline|auto|always|all-scroll|absolute|table|table-cell)\\b"},{cN:"value",b:":",e:";",c:[a.NM,a.QSM,a.ASM,{cN:"hexcolor",b:"\\#[0-9A-F]+"},{cN:"important",b:"!important"}]},{cN:"at_rule",b:"@",e:"[{;]",k:"mixin include for extend charset import media page font-face namespace",c:[c,a.QSM,a.ASM,a.NM,{cN:"preprocessor",b:"\\s[A-Za-z0-9_.-]+"}]}]}}(hljs);hljs.LANGUAGES.sql=function(a){return{cI:true,c:[{cN:"operator",b:"(begin|start|commit|rollback|savepoint|lock|alter|create|drop|rename|call|delete|do|handler|insert|load|replace|select|truncate|update|set|show|pragma|grant)\\b(?!:)",e:";",eW:true,k:{keyword:"all partial global month current_timestamp using go revoke smallint indicator end-exec disconnect zone with character assertion to add current_user usage input local alter match collate real then rollback get read timestamp session_user not integer bit unique day minute desc insert execute like ilike|2 level decimal drop continue isolation found where constraints domain right national some module transaction relative second connect escape close system_user for deferred section cast current sqlstate allocate intersect deallocate numeric public preserve full goto initially asc no key output collation group by union session both last language constraint column of space foreign deferrable prior connection unknown action commit view or first into float year primary cascaded except restrict set references names table outer open select size are rows from prepare distinct leading create only next inner authorization schema corresponding option declare precision immediate else timezone_minute external varying translation true case exception join hour default double scroll value cursor descriptor values dec fetch procedure delete and false int is describe char as at in varchar null trailing any absolute current_time end grant privileges when cross check write current_date pad begin temporary exec time update catalog user sql date on identity timezone_hour natural whenever interval work order cascade diagnostics nchar having left call do handler load replace truncate start lock show pragma exists number",aggregate:"count sum min max avg"},c:[{cN:"string",b:"'",e:"'",c:[a.BE,{b:"''"}],r:0},{cN:"string",b:'"',e:'"',c:[a.BE,{b:'""'}],r:0},{cN:"string",b:"`",e:"`",c:[a.BE]},a.CNM]},a.CBLCLM,{cN:"comment",b:"--",e:"$"}]}}(hljs); \ No newline at end of file diff --git a/docs/coverage/ns-1/index.html b/docs/coverage/ns-1/index.html deleted file mode 100644 index fcdd0df..0000000 --- a/docs/coverage/ns-1/index.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/index_SORT_BY_BLOCK.html b/docs/coverage/ns-1/index_SORT_BY_BLOCK.html deleted file mode 100644 index 0372b35..0000000 --- a/docs/coverage/ns-1/index_SORT_BY_BLOCK.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/index_SORT_BY_BLOCK_DESC.html b/docs/coverage/ns-1/index_SORT_BY_BLOCK_DESC.html deleted file mode 100644 index 7f00dd5..0000000 --- a/docs/coverage/ns-1/index_SORT_BY_BLOCK_DESC.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/index_SORT_BY_CLASS.html b/docs/coverage/ns-1/index_SORT_BY_CLASS.html deleted file mode 100644 index 177cfc3..0000000 --- a/docs/coverage/ns-1/index_SORT_BY_CLASS.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/index_SORT_BY_CLASS_DESC.html b/docs/coverage/ns-1/index_SORT_BY_CLASS_DESC.html deleted file mode 100644 index b324c6e..0000000 --- a/docs/coverage/ns-1/index_SORT_BY_CLASS_DESC.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/index_SORT_BY_LINE.html b/docs/coverage/ns-1/index_SORT_BY_LINE.html deleted file mode 100644 index aeaa32d..0000000 --- a/docs/coverage/ns-1/index_SORT_BY_LINE.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/index_SORT_BY_LINE_DESC.html b/docs/coverage/ns-1/index_SORT_BY_LINE_DESC.html deleted file mode 100644 index e987992..0000000 --- a/docs/coverage/ns-1/index_SORT_BY_LINE_DESC.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/index_SORT_BY_METHOD.html b/docs/coverage/ns-1/index_SORT_BY_METHOD.html deleted file mode 100644 index 717428c..0000000 --- a/docs/coverage/ns-1/index_SORT_BY_METHOD.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/index_SORT_BY_METHOD_DESC.html b/docs/coverage/ns-1/index_SORT_BY_METHOD_DESC.html deleted file mode 100644 index 412bebc..0000000 --- a/docs/coverage/ns-1/index_SORT_BY_METHOD_DESC.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/index_SORT_BY_NAME_DESC.html b/docs/coverage/ns-1/index_SORT_BY_NAME_DESC.html deleted file mode 100644 index bfea1c0..0000000 --- a/docs/coverage/ns-1/index_SORT_BY_NAME_DESC.html +++ /dev/null @@ -1,198 +0,0 @@ - - - - - Coverage Report > lv.id.jc.algorithm.graph - - - - - -
      - - - -

      Coverage Summary for Package: lv.id.jc.algorithm.graph

      - - - - - - - - - - - - - -
      Package - Class, % - - Method, % - - Line, % -
      lv.id.jc.algorithm.graph - - 100% - - - (3/3) - - - - 100% - - - (9/9) - - - - 100% - - - (46/46) - -
      - -
      -
      - - - - - - - - - - - - - - - - - - - - - - - - - - -
      -Class - Class, % - - Method, % - - Line, % -
      Graph - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      - -
      - - - - - - diff --git a/docs/coverage/ns-1/sources/source-1.html b/docs/coverage/ns-1/sources/source-1.html deleted file mode 100644 index b805217..0000000 --- a/docs/coverage/ns-1/sources/source-1.html +++ /dev/null @@ -1,153 +0,0 @@ - - - - - - - Coverage Report > BreadthFirstSearch - - - - - -
      - - -

      Coverage Summary for Class: BreadthFirstSearch (lv.id.jc.algorithm.graph)

      - - - - - - - - - - - - - - - -
      Class - Class, % - - Method, % - - Line, % -
      BreadthFirstSearch - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (19/19) - -
      - -
      -
      - - -
      -
      1 package lv.id.jc.algorithm.graph; -2  -3 import java.util.HashMap; -4 import java.util.HashSet; -5 import java.util.LinkedList; -6 import java.util.List; -7 import java.util.Objects; -8  -9 import static java.util.function.Predicate.not; -10 import static java.util.stream.Stream.iterate; -11  -12 /** -13  * Algorithm for finding the shortest paths between nodes in a graph. -14  * -15  * The algorithm doesn't take into account the distance between nodes. -16  * -17  * @author Jegors Čemisovs -18  * @param <T> the type of vertex -19  * @since 1.0 -20  */ -21 public class BreadthFirstSearch<T> implements SearchAlgorithm<T> { -22  -23  @Override -24  public List<T> findPath(Graph<T> graph, T source, T target) { -25  var queue = new LinkedList<T>(); -26  var visited = new HashSet<T>(); -27  var previous = new HashMap<T, T>(); -28  queue.add(source); -29  -30  while (!queue.isEmpty()) { -31  var node = queue.removeFirst(); -32  if (target.equals(node)) { -33  var path = new LinkedList<T>(); -34  iterate(node, Objects::nonNull, previous::get).forEach(path::addFirst); -35  return path; -36  } -37  visited.add(node); -38  graph.edges(node).keySet().stream() -39  .filter(not(visited::contains)) -40  .forEach(it -> { -41  previous.computeIfAbsent(it, x -> node); -42  queue.addLast(it); -43  }); -44  } -45  return List.of(); -46  } -47  -48 } -
      -
      -
      - - - - - - diff --git a/docs/coverage/ns-1/sources/source-2.html b/docs/coverage/ns-1/sources/source-2.html deleted file mode 100644 index 1659e05..0000000 --- a/docs/coverage/ns-1/sources/source-2.html +++ /dev/null @@ -1,153 +0,0 @@ - - - - - - - Coverage Report > DijkstrasAlgorithm - - - - - -
      - - -

      Coverage Summary for Class: DijkstrasAlgorithm (lv.id.jc.algorithm.graph)

      - - - - - - - - - - - - - - - -
      Class - Class, % - - Method, % - - Line, % -
      DijkstrasAlgorithm - - 100% - - - (1/1) - - - - 100% - - - (3/3) - - - - 100% - - - (20/20) - -
      - -
      -
      - - -
      -
      1 package lv.id.jc.algorithm.graph; -2  -3 import java.util.HashMap; -4 import java.util.LinkedList; -5 import java.util.List; -6 import java.util.Objects; -7  -8 import static java.util.stream.Stream.iterate; -9  -10 /** -11  * Algorithm for finding the fastest paths between nodes in a graph. -12  * <p> -13  * The algorithm uses information about edge's distance to find the fastest path. -14  * -15  * @author Jegors Čemisovs -16  * @param <T> the type of vertex -17  * @since 1.0 -18  */ -19 public class DijkstrasAlgorithm<T> implements SearchAlgorithm<T> { -20  -21  @Override -22  public List<T> findPath(Graph<T> graph, T source, T target) { -23  var queue = new LinkedList<T>(); -24  var distances = new HashMap<T, Double>(); -25  var previous = new HashMap<T, T>(); -26  queue.add(source); -27  distances.put(source, .0); -28  -29  while (!queue.isEmpty()) { -30  var prev = queue.removeFirst(); -31  graph.edges(prev).forEach((node, time) -> { -32  var distance = distances.get(prev) + time.doubleValue(); -33  if (distance < distances.getOrDefault(node, Double.MAX_VALUE)) { -34  previous.put(node, prev); -35  distances.put(node, distance); -36  queue.addLast(node); -37  } -38  }); -39  } -40  if (previous.containsKey(target) || source.equals(target)) { -41  var path = new LinkedList<T>(); -42  iterate(target, Objects::nonNull, previous::get).forEach(path::addFirst); -43  return path; -44  } -45  return List.of(); -46  } -47  -48 } -
      -
      -
      - - - - - - diff --git a/docs/coverage/ns-1/sources/source-3.html b/docs/coverage/ns-1/sources/source-3.html deleted file mode 100644 index 9cdcae1..0000000 --- a/docs/coverage/ns-1/sources/source-3.html +++ /dev/null @@ -1,186 +0,0 @@ - - - - - - - Coverage Report > Graph - - - - - -
      - - -

      Coverage Summary for Class: Graph (lv.id.jc.algorithm.graph)

      - - - - - - - - - - - - - - - - - - - - - - - - -
      Class - Method, % - - Line, % -
      Graph - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      Graph$getDistance$0
      Graph$of
      Total - - 100% - - - (3/3) - - - - 100% - - - (7/7) - -
      - -
      -
      - - -
      -
      1 package lv.id.jc.algorithm.graph; -2  -3 import java.util.List; -4 import java.util.Map; -5 import java.util.stream.IntStream; -6  -7 /** -8  * An interface for weighted directed graph (network) -9  * -10  * @param <T> the type of vertex in this graph -11  * @author Jegors Čemisovs -12  * @since 1.1 -13  */ -14 @FunctionalInterface -15 public interface Graph<T> { -16  /** -17  * Schema of the graph. -18  * -19  * @return the graph scheme -20  */ -21  Map<T, Map<T, Number>> schema(); -22  -23  /** -24  * Returns the edges of the given vertex, -25  * or {@code null} if this graph contains no given vertex. -26  * -27  * <p>A return value of {@code null} does not <i>necessarily</i> -28  * indicate that the specified vertex is not present in the graph; -29  * it's also possible that in the graph schema, {@code null} was specified -30  * for the edges of this vertex instead of an empty map. -31  * -32  * @param vertex vertex -33  * @return all links for the given vertex -34  * or null if no such vertex in the graph -35  */ -36  default Map<T, Number> edges(T vertex) { -37  return schema().get(vertex); -38  } -39  -40  /** -41  * Calculate the distance for the given path -42  * -43  * @param path the list of vertices representing the path -44  * @return distance for the given path as double -45  * @throws NullPointerException if {@code path} is incorrect and contains more than one vertex -46  */ -47  default double getDistance(List<T> path) { -48  return IntStream -49  .range(1, path.size()) -50  .mapToObj(i -> edges(path.get(i - 1)).get(path.get(i))) -51  .mapToDouble(Number::doubleValue) -52  .sum(); -53  } -54  -55  /** -56  * Creates a Graph object by given schema. -57  * -58  * In a graph schema, each vertex is assigned an edge map. -59  * If the vertex has no edges, then it should be assigned an empty map. -60  * -61  * @param schema of the graph -62  * @param <T> the type of vertex in this graph -63  * @return graph object with given schema -64  */ -65  static <T> Graph<T> of(Map<T, Map<T, Number>> schema) { -66  return () -> schema; -67  } -68 } -
      -
      -
      - - - - - - diff --git a/docs/coverage/ns-1/sources/source-4.html b/docs/coverage/ns-1/sources/source-4.html deleted file mode 100644 index 790b89a..0000000 --- a/docs/coverage/ns-1/sources/source-4.html +++ /dev/null @@ -1,95 +0,0 @@ - - - - - - - Coverage Report > SearchAlgorithm - - - - - -
      - - -

      Coverage Summary for Class: SearchAlgorithm (lv.id.jc.algorithm.graph)

      - - - - - - - - - - - - -
      Class
      SearchAlgorithm$findPath
      Total
      - -
      -
      - - -
      -
      1 package lv.id.jc.algorithm.graph; -2  -3 import java.util.List; -4  -5 /** -6  * A functional interface for graph search algorithm -7  * -8  * @author Jegors Čemisovs -9  * @param <T> the type of vertex -10  * @since 1.0 -11  */ -12 @FunctionalInterface -13 public interface SearchAlgorithm<T> { -14  /** -15  * Find the path from the source node to the target -16  * -17  * @param graph The graph in which we search for the path -18  * @param source Search starting point identifier -19  * @param target Search finish point identifier -20  * @return Path found or empty list if path cannot be found -21  */ -22  List<T> findPath(Graph<T> graph, T source, T target); -23 } -
      -
      -
      - - - - - - diff --git a/docs/graph-shell.cast b/docs/graph-shell.cast deleted file mode 100644 index 753a32a..0000000 --- a/docs/graph-shell.cast +++ /dev/null @@ -1,274 +0,0 @@ -{"version": 2, "width": 88, "height": 26, "timestamp": 1644485038, "idle_time_limit": 1.0, "env": {"SHELL": "/bin/bash", "TERM": "xterm-256color", "USER": "jegors"}, "title": "Demonstration of search algorithms in the graph."} -[0.027911, "o", "\u001b]0;jegors@X570UD:~/IdeaProjects/algorithms/graph-shell\u001b\\"] -[0.028901, "o", "\u001b]7;file://X570UD/home/jegors/IdeaProjects/algorithms/graph-shell\u001b\\"] -[0.029197, "o", "\u001b[?2004h\u001b]0;jegors@X570UD: ~/IdeaProjects/algorithms/graph-shell\u0007\u001b[01;32mjegors@X570UD\u001b[00m:\u001b[01;34m~/IdeaProjects/algorithms/graph-shell\u001b[00m$ "] -[3.275319, "i", "P"] -[3.276018, "o", "P"] -[3.73843, "i", "S"] -[3.738876, "o", "S"] -[4.077115, "i", "1"] -[4.07771, "o", "1"] -[5.065595, "i", "="] -[5.066169, "o", "="] -[5.763939, "i", "'"] -[5.764437, "o", "'"] -[9.132534, "i", "$"] -[9.133041, "o", "$"] -[10.221373, "i", "'"] -[10.22185, "o", "'"] -[10.511622, "i", "\r"] -[10.512049, "o", "\r\n\u001b[?2004l\r"] -[10.512759, "o", "\u001b]0;jegors@X570UD:~/IdeaProjects/algorithms/graph-shell\u001b\\"] -[10.517421, "o", "\u001b]7;file://X570UD/home/jegors/IdeaProjects/algorithms/graph-shell\u001b\\"] -[10.517884, "o", "\u001b[?2004h$"] -[34.358936, "i", "\u001b[200~# Demonstration of search algorithms in the graph \u001b[201~"] -[34.359826, "o", "\u001b[7m# Demonstration of search algorithms in the graph \u001b[27m"] -[35.595588, "i", "\r"] -[35.595964, "o", "\r\u001b[C# Demonstration of search algorithms in the graph \r\n\u001b[?2004l\r"] -[35.596517, "o", "\u001b]0;jegors@X570UD:~/IdeaProjects/algorithms/graph-shell\u001b\\"] -[35.601127, "o", "\u001b]7;file://X570UD/home/jegors/IdeaProjects/algorithms/graph-shell\u001b\\"] -[35.601558, "o", "\u001b[?2004h$"] -[45.781354, "i", "\u001b[200~# Graph Shell has build-in three graph schemes: simple, medium and comlex \u001b[201~"] -[45.78281, "o", "\u001b[7m# Graph Shell has build-in three graph schemes: simple, medium and comlex \u001b[27m"] -[47.041434, "i", "\r"] -[47.041939, "o", "\r\u001b[C# Graph Shell has build-in three graph schemes: simple, medium and comlex \r\n\u001b[?2004l\r"] -[47.042432, "o", "\u001b]0;jegors@X570UD:~/IdeaProjects/algorithms/graph-shell\u001b\\"] -[47.047454, "o", "\u001b]7;file://X570UD/home/jegors/IdeaProjects/algorithms/graph-shell\u001b\\"] -[47.047905, "o", "\u001b[?2004h$"] -[59.584057, "i", "\u001b[200~# If no specified the complex schema is loaded \u001b[201~"] -[59.5849, "o", "\u001b[7m# If no specified the complex schema is loaded \u001b[27m"] -[60.595809, "i", "\r"] -[60.596267, "o", "\r\u001b[C# If no specified the complex schema is loaded \r\n\u001b[?2004l\r"] -[60.596787, "o", "\u001b]0;jegors@X570UD:~/IdeaProjects/algorithms/graph-shell\u001b\\"] -[60.601613, "o", "\u001b]7;file://X570UD/home/jegors/IdeaProjects/algorithms/graph-shell\u001b\\"] -[60.602046, "o", "\u001b[?2004h$"] -[74.76556, "i", "\u001b[200~# Now we start the program with simple schema \r\r \u001b[201~"] -[74.76645, "o", "\u001b[7m# Now we start the program with simple schema \u001b[27m\r\n\r\n\r\u001b[7m \u001b[27m"] -[75.943562, "i", "\r"] -[75.944137, "o", "\u001b[A\u001b[A# Now we start the program with simple schema \r\n\r\n\r \r\n\u001b[?2004l\r"] -[75.944824, "o", "\u001b]0;jegors@X570UD:~/IdeaProjects/algorithms/graph-shell\u001b\\"] -[75.94987, "o", "\u001b]7;file://X570UD/home/jegors/IdeaProjects/algorithms/graph-shell\u001b\\"] -[75.950312, "o", "\u001b[?2004h$"] -[84.204334, "i", "\u001b[A"] -[84.204874, "o", "\r\u001b[C./build/libs/graph-shell-1.0-SNAPSHOT.jar --graph=simple"] -[88.633742, "i", "\r"] -[88.634162, "o", "\r\n\u001b[?2004l\r"] -[89.558375, "o", "\r\n _____ _ _____ _ _ _\r\n / ____| | | / ____| | | | | | |\r\n | | __ _ __ __ _ _ __ | |__ | (___ | |__ ___ | | | |\r\n | | |_ | | '__| / _` | | '_ \\ | '_ \\ \\___ \\ | '_ \\ / _ \\ | | | |\r\n | |__| | | | | (_| | | |_) | | | | | ____) | | | | | | __/ | | | |\r\n \\_____| |_| \\__,_| | .__/ |_| |_| |_____/ |_| |_| \\___| |_| |_|\r\n | |\r\n |_|\r\n\r\n"] -[90.786446, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[105.948456, "i", "\u001b[200~// The prompt indicated that the simple graph schema is successfully loaded\u001b[201~"] -[105.964575, "o", "\u001b[31m// The prompt indicated that the simple graph schema is successfully loa\u001b[0m\u001b[31md\u001b[0m\u001b[31med\u001b[0m"] -[107.400048, "i", "\r"] -[107.408447, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l\u001b[?2004l"] -[107.413548, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[112.46835, "i", "h"] -[112.47101, "o", "\u001b[31mh\u001b[0m"] -[112.957856, "i", "e"] -[112.959463, "o", "\u001b[31me\u001b[0m"] -[113.134811, "i", "l"] -[113.136597, "o", "\u001b[31ml\u001b[0m"] -[113.198879, "i", "p"] -[113.202315, "o", "\b\b\b\u001b[1mhelp\u001b[0m\u001b[K"] -[113.513679, "i", "\r"] -[113.517016, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l\u001b[?2004l"] -[113.586739, "o", "\u001b[1mAVAILABLE COMMANDS\r\n\r\nBuilt-In Commands\u001b[0m\r\n \u001b[1mclear\u001b[0m: Clear the shell screen.\r\n \u001b[1mexit, quit\u001b[0m: Exit the shell.\r\n \u001b[1mhelp\u001b[0m: Display help about available commands.\r\n \u001b[1mhistory\u001b[0m: Display or save the history of previously run commands\r\n \u001b[1mscript\u001b[0m: Read and execute commands from a file.\r\n \u001b[1mstacktrace\u001b[0m: Display the full stacktrace of the last error.\r\n\r\n\u001b[1mCommands\u001b[0m\r\n \u001b[1mdistance\u001b[0m: prints distance for the path\r\n \u001b[1mfastest\u001b[0m: finds the fastest path by using Dijkstra's Algorithm\r\n \u001b[1mschema\u001b[0m: prints schema of the graph\r\n \u001b[1mshortest\u001b[0m: finds the shortest path by using Breadth First Search Algorithm\r\n\r\n\r\n"] -[113.589229, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[130.723183, "i", "h"] -[130.724868, "o", "\u001b[31mh\u001b[0m"] -[131.142742, "i", "e"] -[131.14419, "o", "\u001b[31me\u001b[0m"] -[131.541978, "i", "l"] -[131.543541, "o", "\u001b[31ml\u001b[0m"] -[131.605809, "i", "p"] -[131.607528, "o", "\b\b\b\u001b[1mhelp\u001b[0m\u001b[K"] -[132.042382, "i", " "] -[132.043141, "o", " "] -[132.816931, "i", "s"] -[132.818416, "o", "s"] -[133.078999, "i", "c"] -[133.080476, "o", "c"] -[133.279177, "i", "h"] -[133.28056, "o", "h"] -[133.538538, "i", "e"] -[133.540024, "o", "e"] -[133.882552, "i", "m"] -[133.884249, "o", "m"] -[134.013943, "i", "a"] -[134.015444, "o", "a"] -[134.590303, "i", "\r"] -[134.593702, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l\u001b[?2004l"] -[134.59937, "o", "\r\n\r\n\u001b[1mNAME\u001b[0m\r\n\tschema - prints schema of the graph\r\n\r\n\u001b[1mSYNOPSYS\u001b[0m\r\n\t\u001b[1mschema\u001b[0m \r\n\r\n\r\n\r\n"] -[134.601154, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[136.658136, "i", "s"] -[136.659362, "o", "\u001b[31ms\u001b[0m"] -[136.931108, "i", "c"] -[136.931513, "o", "\u001b[31mc\u001b[0m"] -[137.153947, "i", "h"] -[137.15528, "o", "\u001b[31mh\u001b[0m"] -[137.346398, "i", "e"] -[137.347806, "o", "\u001b[31me\u001b[0m"] -[137.69991, "i", "m"] -[137.701216, "o", "\u001b[31mm\u001b[0m"] -[137.827094, "i", "a"] -[137.828995, "o", "\u001b[5D\u001b[1mschema\u001b[0m\u001b[K"] -[138.329619, "i", "\r"] -[138.331188, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l\u001b[?2004l"] -[138.369868, "o", "{A={B=7, C=2}, B={A=3, C=5}, C={A=1, B=3}}\r\n"] -[138.371489, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[141.02055, "i", "h"] -[141.021908, "o", "\u001b[31mh\u001b[0m"] -[141.332122, "i", "e"] -[141.333501, "o", "\u001b[31me\u001b[0m"] -[141.659468, "i", "l"] -[141.660874, "o", "\u001b[31ml\u001b[0m"] -[141.734046, "i", "p"] -[141.735516, "o", "\b\b\b\u001b[1mhelp\u001b[0m\u001b[K"] -[142.038872, "i", " "] -[142.040258, "o", " "] -[142.642315, "i", "s"] -[142.643816, "o", "s"] -[142.917715, "i", "h"] -[142.918972, "o", "h"] -[143.282957, "i", "o"] -[143.284416, "o", "o"] -[144.002742, "i", "r"] -[144.0042, "o", "r"] -[144.362211, "i", "\t"] -[144.37681, "o", "test "] -[145.046361, "i", "\r"] -[145.049781, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l\u001b[?2004l"] -[145.063814, "o", "\r\n\r\n\u001b[1mNAME\u001b[0m\r\n\tshortest - finds the shortest path by using Breadth First Search Algorithm\r\n\r\n\u001b[1mSYNOPSYS\u001b[0m\r\n\t\u001b[1mshortest\u001b[0m [\u001b[1m--source\u001b[0m] \u001b[4mstring\u001b[0m [\u001b[1m--target\u001b[0m] \u001b[4mstring\u001b[0m \r\n\r\n\u001b[1mOPTIONS\u001b[0m\r\n\t\u001b[1m--source\u001b[0m \u001b[4mstring\u001b[0m\r\n\t\t\r\n\u001b[1m\t\t[Mandatory]\u001b[0m\r\n\u001b[1m\t\t[this vertex was not found in the graph diagram]\r\n\u001b[0m\r\n\t\u001b[1m--target\u001b[0m \u001b[4mstring\u001b[0m\r\n\t\t\r\n\u001b[1m\t\t[Mandatory]\u001b[0m\r\n\u001b[1m\t\t[this vertex was not found in the graph diagram]\r\n\u001b[0m\r\n\r\n\r\n"] -[145.065425, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[148.174946, "i", "s"] -[148.176352, "o", "\u001b[31ms\u001b[0m"] -[148.463, "i", "h"] -[148.464354, "o", "\u001b[31mh\u001b[0m"] -[148.725134, "i", "o"] -[148.726502, "o", "\u001b[31mo\u001b[0m"] -[149.191574, "i", "r"] -[149.192938, "o", "\u001b[31mr\u001b[0m"] -[149.448136, "i", "t"] -[149.449474, "o", "\u001b[31mt\u001b[0m"] -[149.562626, "i", "e"] -[149.563938, "o", "\u001b[31me\u001b[0m"] -[149.79337, "i", "s"] -[149.794596, "o", "\u001b[31ms\u001b[0m"] -[149.968465, "i", "t"] -[149.970017, "o", "\u001b[7D\u001b[1mshortest\u001b[0m\u001b[K"] -[150.086341, "i", " "] -[150.087842, "o", " "] -[152.02721, "i", "A"] -[152.027777, "o", "A"] -[152.386667, "i", " "] -[152.388223, "o", " "] -[152.863147, "i", "B"] -[152.864792, "o", "B"] -[153.547433, "i", "\r"] -[153.551276, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l\u001b[?2004l"] -[153.576091, "o", "A\r\n"] -[153.576241, "o", "B\r\n"] -[153.577833, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[155.099248, "i", "f"] -[155.100625, "o", "\u001b[31mf\u001b[0m"] -[155.28906, "i", "a"] -[155.290648, "o", "\u001b[31ma\u001b[0m"] -[155.489145, "i", "s"] -[155.490408, "o", "\u001b[31ms\u001b[0m"] -[155.700639, "i", "t"] -[155.701924, "o", "\u001b[31mt\u001b[0m"] -[155.840851, "i", "e"] -[155.842168, "o", "\u001b[31me\u001b[0m"] -[156.060851, "i", "s"] -[156.062212, "o", "\u001b[31ms\u001b[0m"] -[156.241384, "i", "t"] -[156.242799, "o", "\u001b[6D\u001b[1mfastest\u001b[0m\u001b[K"] -[157.018753, "i", " "] -[157.020548, "o", " "] -[157.710521, "i", "A"] -[157.711946, "o", "A"] -[158.076379, "i", " "] -[158.077927, "o", " "] -[158.484749, "i", "B"] -[158.486046, "o", "B"] -[159.085469, "i", "\r"] -[159.089298, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l"] -[159.089867, "o", "\u001b[?2004l"] -[159.097297, "o", "A\r\n"] -[159.097549, "o", "C\r\n"] -[159.097919, "o", "B\r\n"] -[159.100224, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[161.645849, "i", "d"] -[161.64745, "o", "\u001b[31md\u001b[0m"] -[161.920218, "i", "i"] -[161.921585, "o", "\u001b[31mi\u001b[0m"] -[162.026591, "i", "s"] -[162.027786, "o", "\u001b[31ms\u001b[0m"] -[162.27677, "i", "t"] -[162.277951, "o", "\u001b[31mt\u001b[0m"] -[162.392453, "i", "a"] -[162.393652, "o", "\u001b[31ma\u001b[0m"] -[162.656308, "i", "n"] -[162.657468, "o", "\u001b[31mn\u001b[0m"] -[163.026019, "i", "c"] -[163.027184, "o", "\u001b[31mc\u001b[0m"] -[163.159787, "i", "e"] -[163.161196, "o", "\u001b[7D\u001b[1mdistance\u001b[0m\u001b[K"] -[163.277562, "i", " "] -[163.278724, "o", " "] -[165.12354, "i", "A"] -[165.124874, "o", "A"] -[165.392194, "i", ","] -[165.393639, "o", ","] -[166.289455, "i", "B"] -[166.290743, "o", "B"] -[167.695998, "i", "\r"] -[167.699265, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l\u001b[?2004l"] -[167.712049, "o", "7.0\r\n"] -[167.713493, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[168.918752, "i", "d"] -[168.920167, "o", "\u001b[31md\u001b[0m"] -[169.152257, "i", "i"] -[169.153494, "o", "\u001b[31mi\u001b[0m"] -[169.328078, "i", "s"] -[169.329273, "o", "\u001b[31ms\u001b[0m"] -[169.558415, "i", "t"] -[169.559776, "o", "\u001b[31mt\u001b[0m"] -[169.754554, "i", "a"] -[169.756045, "o", "\u001b[31ma\u001b[0m"] -[169.971121, "i", "n"] -[169.972599, "o", "\u001b[31mn\u001b[0m"] -[170.3032, "i", "c"] -[170.304408, "o", "\u001b[31mc\u001b[0m"] -[170.441556, "i", "e"] -[170.442935, "o", "\u001b[7D\u001b[1mdistance\u001b[0m\u001b[K"] -[170.570542, "i", " "] -[170.571772, "o", " "] -[172.203523, "i", "A"] -[172.20466, "o", "A"] -[172.552722, "i", ","] -[172.554059, "o", ","] -[172.902159, "i", "C"] -[172.903843, "o", "C"] -[173.924009, "i", ","] -[173.925262, "o", ","] -[175.304144, "i", "B"] -[175.305116, "o", "B"] -[175.962629, "i", "\r"] -[175.965594, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l\u001b[?2004l"] -[175.969572, "o", "5.0\r\n"] -[175.970947, "o", "\u001b[?1h\u001b=\u001b[?2004h\u001b[33msimple:> \u001b[0m"] -[177.668678, "i", "e"] -[177.670133, "o", "\u001b[31me\u001b[0m"] -[178.077727, "i", "x"] -[178.078942, "o", "\u001b[31mx\u001b[0m"] -[178.243986, "i", "i"] -[178.245137, "o", "\u001b[31mi\u001b[0m"] -[178.479066, "i", "t"] -[178.4805, "o", "\b\b\b\u001b[1mexit\u001b[0m\u001b[K"] -[179.035113, "i", "\r"] -[179.038028, "o", "\r\r\n\u001b[?1l\u001b>\u001b[?1000l\u001b[?2004l"] -[179.072935, "o", "\u001b]0;jegors@X570UD:~/IdeaProjects/algorithms/graph-shell\u001b\\"] -[179.074759, "o", "\u001b]7;file://X570UD/home/jegors/IdeaProjects/algorithms/graph-shell\u001b\\"] -[179.074989, "o", "\u001b[?2004h$"] -[180.52887, "i", "\u0004"] -[180.529318, "o", "\u001b[?2004l\r\r\n"] -[180.529984, "o", "logout\r\n"] diff --git a/docs/inspection/index.html b/docs/inspection/index.html deleted file mode 100644 index f6d64d7..0000000 --- a/docs/inspection/index.html +++ /dev/null @@ -1 +0,0 @@ -IntelliJ IDEA inspection report

      IntelliJ IDEA inspection report:

      Inspection tree:

                              1. Problem description:

                                Select a problem element in tree
                                \ No newline at end of file diff --git a/docs/inspection/script.js b/docs/inspection/script.js deleted file mode 100644 index 9a267ef..0000000 --- a/docs/inspection/script.js +++ /dev/null @@ -1,23 +0,0 @@ -/* - * Copyright 2000-2016 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the License); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an AS IS BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -/** - * @author: Dmitry Batkovich - */ -function navigate(an_id) { - problem_div = document.getElementById("d" + an_id); - preview_div = document.getElementById("preview"); - preview_div.innerHTML = problem_div != null ? problem_div.innerHTML : "Select a problem element in tree"; -} \ No newline at end of file diff --git a/docs/inspection/styles.css b/docs/inspection/styles.css deleted file mode 100644 index 41cc324..0000000 --- a/docs/inspection/styles.css +++ /dev/null @@ -1,98 +0,0 @@ -/* - * Copyright 2000-2016 JetBrains s.r.o. - * - * Licensed under the Apache License, Version 2.0 (the License); - * you may not use this file except in compliance with the License. - * You may obtain a copy of the License at - * - * http://www.apache.org/licenses/LICENSE-2.0 - * - * Unless required by applicable law or agreed to in writing, software - * distributed under the License is distributed on an AS IS BASIS, - * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. - * See the License for the specific language governing permissions and - * limitations under the License. - */ -html { - font-family: \Helvetica Neue\, Helvetica, Arial, \Lucida Grande\, sans-serif; -} - -body { - color: #4C4C4C; - margin: 60px 60px 0 60px; -} - -p { - font-size: 1em; - margin: 0 0 1em 0; -} - -.grayout { - opacity: 0.6; -} - -body, input, select, textarea, th, td { - font-size: 1em; -} - -li { - position: relative; - list-style: none; -} - -label:hover { - color: #0C479D; - text-decoration: underline; -} - -li::before { - content: "\23FA"; - margin: 0; -} - -li input { - position: absolute; - left: 0; - margin-left: 0; - background: none; - opacity: 0; - z-index: 2; - cursor: pointer; - height: 1em; - width: 1em; - top: 0; -} - -li input + ol { - margin: -15px 0 0 -44px; - height: 1em; -} - -li input + ol > li { - display: none; - margin-left: -14px !important; - padding-left: 1px; -} - -li label { - padding-left: 5px; -} - -li input:checked + ol { - margin: -20px 0 0 -44px; - padding: 25px 0 0 80px; - height: auto; -} - -li input:checked + ol > li { - display: block; - margin: 0 0 2px; -} - -li input:checked + ol > li:last-child { - margin: 0 0 1px; -} - -div.location { - margin-left: 40px; -} \ No newline at end of file diff --git a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.BreadthFirstSearchSpec.html b/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.BreadthFirstSearchSpec.html deleted file mode 100644 index ea86c69..0000000 --- a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.BreadthFirstSearchSpec.html +++ /dev/null @@ -1,156 +0,0 @@ - - - - - -Test results - BreadthFirstSearchSpec - - - - - -
                                -

                                BreadthFirstSearchSpec

                                - -
                                - - - - - -
                                -
                                - - - - - - - -
                                -
                                -
                                13
                                -

                                tests

                                -
                                -
                                -
                                -
                                0
                                -

                                failures

                                -
                                -
                                -
                                -
                                0
                                -

                                ignored

                                -
                                -
                                -
                                -
                                0.010s
                                -

                                duration

                                -
                                -
                                -
                                -
                                -
                                -
                                100%
                                -

                                successful

                                -
                                -
                                -
                                -
                                - -
                                -

                                Tests

                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                TestDurationResult
                                should find a route for complex graph [source: A, target: A, shortest: [A], time: 0, #0]0.001spassed
                                should find a route for complex graph [source: A, target: B, shortest: [A, B], time: 1, #2]0spassed
                                should find a route for complex graph [source: A, target: C, shortest: [A, B, D, C], time: 3, #4]0.001spassed
                                should find a route for complex graph [source: B, target: A, shortest: [B, A], time: 1, #3]0spassed
                                should find a route for complex graph [source: B, target: B, shortest: [B], time: 0, #1]0.001spassed
                                should find a route for complex graph [source: C, target: A, shortest: [C, A], time: 1, #5]0.001spassed
                                should find a route for complex graph [source: E, target: B, shortest: [E, F, D, C, A, B], time: 5, #6]0.001spassed
                                should find a route for simple graph [source: A, target: A, time: 0, shortest: [A], #0]0.001spassed
                                should find a route for simple graph [source: A, target: B, time: 7, shortest: [A, B], #1]0.001spassed
                                should find a route for simple graph [source: B, target: C, time: 5, shortest: [B, C], #2]0spassed
                                should find a route for simple graph [source: C, target: B, time: 3, shortest: [C, B], #3]0.001spassed
                                should return an empty path if can't find a route0.001spassed
                                should thrown NPE path for an empty graph0.001spassed
                                -
                                -
                                - -
                                - - diff --git a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec.html b/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec.html deleted file mode 100644 index f30bad8..0000000 --- a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec.html +++ /dev/null @@ -1,211 +0,0 @@ - - - - - -Test results - DijkstrasAlgorithmSpec - - - - - -
                                -

                                DijkstrasAlgorithmSpec

                                - -
                                - - - - - -
                                -
                                - - - - - - - -
                                -
                                -
                                24
                                -

                                tests

                                -
                                -
                                -
                                -
                                0
                                -

                                failures

                                -
                                -
                                -
                                -
                                0
                                -

                                ignored

                                -
                                -
                                -
                                -
                                0.015s
                                -

                                duration

                                -
                                -
                                -
                                -
                                -
                                -
                                100%
                                -

                                successful

                                -
                                -
                                -
                                -
                                - -
                                -

                                Tests

                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                TestDurationResult
                                should find a route for a complex graph [source: A, target: A, time: 0, fastest: [A], #0]0spassed
                                should find a route for a complex graph [source: A, target: B, time: 5, fastest: [A, B], #2]0spassed
                                should find a route for a complex graph [source: A, target: C, time: 9, fastest: [A, H, G, C], #4]0.001spassed
                                should find a route for a complex graph [source: A, target: G, time: 5, fastest: [A, H, G], #6]0spassed
                                should find a route for a complex graph [source: B, target: A, time: 5, fastest: [B, A], #3]0spassed
                                should find a route for a complex graph [source: B, target: B, time: 0, fastest: [B], #1]0spassed
                                should find a route for a complex graph [source: B, target: D, time: 10, fastest: [B, C, D], #9]0.002spassed
                                should find a route for a complex graph [source: C, target: A, time: 12, fastest: [C, B, A], #5]0.001spassed
                                should find a route for a complex graph [source: C, target: D, time: 3, fastest: [C, D], #7]0.001spassed
                                should find a route for a complex graph [source: D, target: B, time: 26, fastest: [D, E, F, G, C, B], #10]0spassed
                                should find a route for a complex graph [source: D, target: C, time: 19, fastest: [D, E, F, G, C], #8]0spassed
                                should find a route for a complex graph [source: D, target: H, time: 33, fastest: [D, E, F, G, C, B, A, H], #11]0.001spassed
                                should find a route for a medium graph [source: A, target: A, time: 0, fastest: [A], #0]0.001spassed
                                should find a route for a medium graph [source: A, target: B, time: 5, fastest: [A, B], #2]0.001spassed
                                should find a route for a medium graph [source: A, target: C, time: 15, fastest: [A, B, C], #4]0.001spassed
                                should find a route for a medium graph [source: B, target: A, time: 5, fastest: [B, A], #3]0.001spassed
                                should find a route for a medium graph [source: B, target: B, time: 0, fastest: [B], #1]0.001spassed
                                should find a route for a medium graph [source: C, target: A, time: 20, fastest: [C, D, E, B, A], #5]0.001spassed
                                should find a route for a simple graph [source: A, target: A, time: 0, fastest: [A], #0]0spassed
                                should find a route for a simple graph [source: A, target: B, time: 5, fastest: [A, C, B], #3]0.001spassed
                                should find a route for a simple graph [source: B, target: B, time: 0, fastest: [B], #1]0spassed
                                should find a route for a simple graph [source: C, target: C, time: 0, fastest: [C], #2]0spassed
                                should return an empty path if can't find a route0.001spassed
                                should thrown NPE for an empty graph0.001spassed
                                -
                                -
                                - -
                                - - diff --git a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.GraphSpec.html b/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.GraphSpec.html deleted file mode 100644 index fa28987..0000000 --- a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.GraphSpec.html +++ /dev/null @@ -1,191 +0,0 @@ - - - - - -Test results - GraphSpec - - - - - -
                                -

                                GraphSpec

                                - -
                                - - - - - -
                                -
                                - - - - - - - -
                                -
                                -
                                20
                                -

                                tests

                                -
                                -
                                -
                                -
                                0
                                -

                                failures

                                -
                                -
                                -
                                -
                                0
                                -

                                ignored

                                -
                                -
                                -
                                -
                                0.050s
                                -

                                duration

                                -
                                -
                                -
                                -
                                -
                                -
                                100%
                                -

                                successful

                                -
                                -
                                -
                                -
                                - -
                                -

                                Tests

                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                TestDurationResult
                                should be zero distance for an empty path0.033spassed
                                should be zero distance for any one node path [oneNodePath: [12.56], #4]0.001spassed
                                should be zero distance for any one node path [oneNodePath: [2], #2]0.001spassed
                                should be zero distance for any one node path [oneNodePath: [A], #0]0.001spassed
                                should be zero distance for any one node path [oneNodePath: [B], #1]0.001spassed
                                should be zero distance for any one node path [oneNodePath: [X], #3]0.001spassed
                                should calculate distance for a path [path: [A, B, A, B], distance: 15, #4]0.001spassed
                                should calculate distance for a path [path: [A, B, A], distance: 10, #3]0spassed
                                should calculate distance for a path [path: [A, B], distance: 5, #1]0.001spassed
                                should calculate distance for a path [path: [A], distance: 0, #0]0.001spassed
                                should calculate distance for a path [path: [B, A], distance: 5, #2]0spassed
                                should calculate distance for a path [path: [C, D], distance: 3, #5]0.002spassed
                                should calculate distance for a path [path: [D, C], distance: 20, #6]0spassed
                                should calculate distance for a path [path: [D, E, F, G, C], distance: 19, #7]0spassed
                                should return edges for a given node [node: A, expected: [B:7, C:2], #0]0.001spassed
                                should return edges for a given node [node: B, expected: [A:3, C:5], #1]0.001spassed
                                should return edges for a given node [node: C, expected: [A:1, B:3], #2]0spassed
                                should throw NPE for incorrect path [incorrectPath: [A, B, D], #2]0.001spassed
                                should throw NPE for incorrect path [incorrectPath: [A, C], #1]0.002spassed
                                should throw NPE for incorrect path [incorrectPath: [E, D], #0]0.002spassed
                                -
                                -
                                - -
                                - - diff --git a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.SearchAlgorithmsSpec.html b/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.SearchAlgorithmsSpec.html deleted file mode 100644 index fa9ea3c..0000000 --- a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.SearchAlgorithmsSpec.html +++ /dev/null @@ -1,151 +0,0 @@ - - - - - -Test results - SearchAlgorithmsSpec - - - - - -
                                -

                                SearchAlgorithmsSpec

                                - -
                                - - - - - -
                                -
                                - - - - - - - -
                                -
                                -
                                12
                                -

                                tests

                                -
                                -
                                -
                                -
                                0
                                -

                                failures

                                -
                                -
                                -
                                -
                                0
                                -

                                ignored

                                -
                                -
                                -
                                -
                                0.028s
                                -

                                duration

                                -
                                -
                                -
                                -
                                -
                                -
                                100%
                                -

                                successful

                                -
                                -
                                -
                                -
                                - -
                                -

                                Tests

                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                TestDurationResult
                                should find a route for a complex graph [source: A, target: A, t1: 0, shortest: [A], t2: 0, fastest: [A], #0]0.022spassed
                                should find a route for a complex graph [source: A, target: B, t1: 5, shortest: [A, B], t2: 5, fastest: [A, B], #2]0.001spassed
                                should find a route for a complex graph [source: A, target: C, t1: 12, shortest: [A, B, C], t2: 9, fastest: [A, H, G, C], #4]0spassed
                                should find a route for a complex graph [source: A, target: G, t1: 5, shortest: [A, H, G], t2: 5, fastest: [A, H, G], #6]0spassed
                                should find a route for a complex graph [source: B, target: A, t1: 5, shortest: [B, A], t2: 5, fastest: [B, A], #3]0spassed
                                should find a route for a complex graph [source: B, target: B, t1: 0, shortest: [B], t2: 0, fastest: [B], #1]0.001spassed
                                should find a route for a complex graph [source: B, target: D, t1: 10, shortest: [B, C, D], t2: 10, fastest: [B, C, D], #9]0spassed
                                should find a route for a complex graph [source: C, target: A, t1: 12, shortest: [C, B, A], t2: 12, fastest: [C, B, A], #5]0spassed
                                should find a route for a complex graph [source: C, target: D, t1: 3, shortest: [C, D], t2: 3, fastest: [C, D], #7]0.003spassed
                                should find a route for a complex graph [source: D, target: B, t1: 27, shortest: [D, C, B], t2: 26, fastest: [D, E, F, G, C, B], #10]0spassed
                                should find a route for a complex graph [source: D, target: C, t1: 20, shortest: [D, C], t2: 19, fastest: [D, E, F, G, C], #8]0spassed
                                should find a route for a complex graph [source: D, target: H, t1: 34, shortest: [D, C, B, A, H], t2: 33, fastest: [D, E, F, G, C, B, A, H], #11]0.001spassed
                                -
                                -
                                - -
                                - - diff --git a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.SearchAlgorithmsTest.html b/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.SearchAlgorithmsTest.html deleted file mode 100644 index 1b76b78..0000000 --- a/docs/reports/tests/test/classes/lv.id.jc.algorithm.graph.SearchAlgorithmsTest.html +++ /dev/null @@ -1,111 +0,0 @@ - - - - - -Test results - SearchAlgorithmsTest - - - - - -
                                -

                                SearchAlgorithmsTest

                                - -
                                - - - - - -
                                -
                                - - - - - - - -
                                -
                                -
                                4
                                -

                                tests

                                -
                                -
                                -
                                -
                                0
                                -

                                failures

                                -
                                -
                                -
                                -
                                0
                                -

                                ignored

                                -
                                -
                                -
                                -
                                0.021s
                                -

                                duration

                                -
                                -
                                -
                                -
                                -
                                -
                                100%
                                -

                                successful

                                -
                                -
                                -
                                -
                                - -
                                -

                                Tests

                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                TestDurationResult
                                testFindPathAA()0.018spassed
                                testFindPathBB()0.001spassed
                                testFindPathCD()0.001spassed
                                testFindPathDC()0.001spassed
                                -
                                -
                                - -
                                - - diff --git a/docs/reports/tests/test/css/base-style.css b/docs/reports/tests/test/css/base-style.css deleted file mode 100644 index 4afa73e..0000000 --- a/docs/reports/tests/test/css/base-style.css +++ /dev/null @@ -1,179 +0,0 @@ - -body { - margin: 0; - padding: 0; - font-family: sans-serif; - font-size: 12pt; -} - -body, a, a:visited { - color: #303030; -} - -#content { - padding-left: 50px; - padding-right: 50px; - padding-top: 30px; - padding-bottom: 30px; -} - -#content h1 { - font-size: 160%; - margin-bottom: 10px; -} - -#footer { - margin-top: 100px; - font-size: 80%; - white-space: nowrap; -} - -#footer, #footer a { - color: #a0a0a0; -} - -#line-wrapping-toggle { - vertical-align: middle; -} - -#label-for-line-wrapping-toggle { - vertical-align: middle; -} - -ul { - margin-left: 0; -} - -h1, h2, h3 { - white-space: nowrap; -} - -h2 { - font-size: 120%; -} - -ul.tabLinks { - padding-left: 0; - padding-top: 10px; - padding-bottom: 10px; - overflow: auto; - min-width: 800px; - width: auto !important; - width: 800px; -} - -ul.tabLinks li { - float: left; - height: 100%; - list-style: none; - padding-left: 10px; - padding-right: 10px; - padding-top: 5px; - padding-bottom: 5px; - margin-bottom: 0; - -moz-border-radius: 7px; - border-radius: 7px; - margin-right: 25px; - border: solid 1px #d4d4d4; - background-color: #f0f0f0; -} - -ul.tabLinks li:hover { - background-color: #fafafa; -} - -ul.tabLinks li.selected { - background-color: #c5f0f5; - border-color: #c5f0f5; -} - -ul.tabLinks a { - font-size: 120%; - display: block; - outline: none; - text-decoration: none; - margin: 0; - padding: 0; -} - -ul.tabLinks li h2 { - margin: 0; - padding: 0; -} - -div.tab { -} - -div.selected { - display: block; -} - -div.deselected { - display: none; -} - -div.tab table { - min-width: 350px; - width: auto !important; - width: 350px; - border-collapse: collapse; -} - -div.tab th, div.tab table { - border-bottom: solid #d0d0d0 1px; -} - -div.tab th { - text-align: left; - white-space: nowrap; - padding-left: 6em; -} - -div.tab th:first-child { - padding-left: 0; -} - -div.tab td { - white-space: nowrap; - padding-left: 6em; - padding-top: 5px; - padding-bottom: 5px; -} - -div.tab td:first-child { - padding-left: 0; -} - -div.tab td.numeric, div.tab th.numeric { - text-align: right; -} - -span.code { - display: inline-block; - margin-top: 0em; - margin-bottom: 1em; -} - -span.code pre { - font-size: 11pt; - padding-top: 10px; - padding-bottom: 10px; - padding-left: 10px; - padding-right: 10px; - margin: 0; - background-color: #f7f7f7; - border: solid 1px #d0d0d0; - min-width: 700px; - width: auto !important; - width: 700px; -} - -span.wrapped pre { - word-wrap: break-word; - white-space: pre-wrap; - word-break: break-all; -} - -label.hidden { - display: none; -} \ No newline at end of file diff --git a/docs/reports/tests/test/css/style.css b/docs/reports/tests/test/css/style.css deleted file mode 100644 index 3dc4913..0000000 --- a/docs/reports/tests/test/css/style.css +++ /dev/null @@ -1,84 +0,0 @@ - -#summary { - margin-top: 30px; - margin-bottom: 40px; -} - -#summary table { - border-collapse: collapse; -} - -#summary td { - vertical-align: top; -} - -.breadcrumbs, .breadcrumbs a { - color: #606060; -} - -.infoBox { - width: 110px; - padding-top: 15px; - padding-bottom: 15px; - text-align: center; -} - -.infoBox p { - margin: 0; -} - -.counter, .percent { - font-size: 120%; - font-weight: bold; - margin-bottom: 8px; -} - -#duration { - width: 125px; -} - -#successRate, .summaryGroup { - border: solid 2px #d0d0d0; - -moz-border-radius: 10px; - border-radius: 10px; -} - -#successRate { - width: 140px; - margin-left: 35px; -} - -#successRate .percent { - font-size: 180%; -} - -.success, .success a { - color: #008000; -} - -div.success, #successRate.success { - background-color: #bbd9bb; - border-color: #008000; -} - -.failures, .failures a { - color: #b60808; -} - -.skipped, .skipped a { - color: #c09853; -} - -div.failures, #successRate.failures { - background-color: #ecdada; - border-color: #b60808; -} - -ul.linkList { - padding-left: 0; -} - -ul.linkList li { - list-style: none; - margin-bottom: 5px; -} diff --git a/docs/reports/tests/test/index.html b/docs/reports/tests/test/index.html deleted file mode 100644 index 62f8620..0000000 --- a/docs/reports/tests/test/index.html +++ /dev/null @@ -1,173 +0,0 @@ - - - - - -Test results - Test Summary - - - - - -
                                -

                                Test Summary

                                -
                                - - - - - -
                                -
                                - - - - - - - -
                                -
                                -
                                73
                                -

                                tests

                                -
                                -
                                -
                                -
                                0
                                -

                                failures

                                -
                                -
                                -
                                -
                                0
                                -

                                ignored

                                -
                                -
                                -
                                -
                                0.124s
                                -

                                duration

                                -
                                -
                                -
                                -
                                -
                                -
                                100%
                                -

                                successful

                                -
                                -
                                -
                                -
                                - -
                                -

                                Packages

                                - - - - - - - - - - - - - - - - - - - - - -
                                PackageTestsFailuresIgnoredDurationSuccess rate
                                -lv.id.jc.algorithm.graph -73000.124s100%
                                -
                                -
                                -

                                Classes

                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                ClassTestsFailuresIgnoredDurationSuccess rate
                                -lv.id.jc.algorithm.graph.BreadthFirstSearchSpec -13000.010s100%
                                -lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec -24000.015s100%
                                -lv.id.jc.algorithm.graph.GraphSpec -20000.050s100%
                                -lv.id.jc.algorithm.graph.SearchAlgorithmsSpec -12000.028s100%
                                -lv.id.jc.algorithm.graph.SearchAlgorithmsTest -4000.021s100%
                                -
                                -
                                - -
                                - - diff --git a/docs/reports/tests/test/js/report.js b/docs/reports/tests/test/js/report.js deleted file mode 100644 index 83bab4a..0000000 --- a/docs/reports/tests/test/js/report.js +++ /dev/null @@ -1,194 +0,0 @@ -(function (window, document) { - "use strict"; - - var tabs = {}; - - function changeElementClass(element, classValue) { - if (element.getAttribute("className")) { - element.setAttribute("className", classValue); - } else { - element.setAttribute("class", classValue); - } - } - - function getClassAttribute(element) { - if (element.getAttribute("className")) { - return element.getAttribute("className"); - } else { - return element.getAttribute("class"); - } - } - - function addClass(element, classValue) { - changeElementClass(element, getClassAttribute(element) + " " + classValue); - } - - function removeClass(element, classValue) { - changeElementClass(element, getClassAttribute(element).replace(classValue, "")); - } - - function initTabs() { - var container = document.getElementById("tabs"); - - tabs.tabs = findTabs(container); - tabs.titles = findTitles(tabs.tabs); - tabs.headers = findHeaders(container); - tabs.select = select; - tabs.deselectAll = deselectAll; - tabs.select(0); - - return true; - } - - function getCheckBox() { - return document.getElementById("line-wrapping-toggle"); - } - - function getLabelForCheckBox() { - return document.getElementById("label-for-line-wrapping-toggle"); - } - - function findCodeBlocks() { - var spans = document.getElementById("tabs").getElementsByTagName("span"); - var codeBlocks = []; - for (var i = 0; i < spans.length; ++i) { - if (spans[i].className.indexOf("code") >= 0) { - codeBlocks.push(spans[i]); - } - } - return codeBlocks; - } - - function forAllCodeBlocks(operation) { - var codeBlocks = findCodeBlocks(); - - for (var i = 0; i < codeBlocks.length; ++i) { - operation(codeBlocks[i], "wrapped"); - } - } - - function toggleLineWrapping() { - var checkBox = getCheckBox(); - - if (checkBox.checked) { - forAllCodeBlocks(addClass); - } else { - forAllCodeBlocks(removeClass); - } - } - - function initControls() { - if (findCodeBlocks().length > 0) { - var checkBox = getCheckBox(); - var label = getLabelForCheckBox(); - - checkBox.onclick = toggleLineWrapping; - checkBox.checked = false; - - removeClass(label, "hidden"); - } - } - - function switchTab() { - var id = this.id.substr(1); - - for (var i = 0; i < tabs.tabs.length; i++) { - if (tabs.tabs[i].id === id) { - tabs.select(i); - break; - } - } - - return false; - } - - function select(i) { - this.deselectAll(); - - changeElementClass(this.tabs[i], "tab selected"); - changeElementClass(this.headers[i], "selected"); - - while (this.headers[i].firstChild) { - this.headers[i].removeChild(this.headers[i].firstChild); - } - - var h2 = document.createElement("H2"); - - h2.appendChild(document.createTextNode(this.titles[i])); - this.headers[i].appendChild(h2); - } - - function deselectAll() { - for (var i = 0; i < this.tabs.length; i++) { - changeElementClass(this.tabs[i], "tab deselected"); - changeElementClass(this.headers[i], "deselected"); - - while (this.headers[i].firstChild) { - this.headers[i].removeChild(this.headers[i].firstChild); - } - - var a = document.createElement("A"); - - a.setAttribute("id", "ltab" + i); - a.setAttribute("href", "#tab" + i); - a.onclick = switchTab; - a.appendChild(document.createTextNode(this.titles[i])); - - this.headers[i].appendChild(a); - } - } - - function findTabs(container) { - return findChildElements(container, "DIV", "tab"); - } - - function findHeaders(container) { - var owner = findChildElements(container, "UL", "tabLinks"); - return findChildElements(owner[0], "LI", null); - } - - function findTitles(tabs) { - var titles = []; - - for (var i = 0; i < tabs.length; i++) { - var tab = tabs[i]; - var header = findChildElements(tab, "H2", null)[0]; - - header.parentNode.removeChild(header); - - if (header.innerText) { - titles.push(header.innerText); - } else { - titles.push(header.textContent); - } - } - - return titles; - } - - function findChildElements(container, name, targetClass) { - var elements = []; - var children = container.childNodes; - - for (var i = 0; i < children.length; i++) { - var child = children.item(i); - - if (child.nodeType === 1 && child.nodeName === name) { - if (targetClass && child.className.indexOf(targetClass) < 0) { - continue; - } - - elements.push(child); - } - } - - return elements; - } - - // Entry point. - - window.onload = function() { - initTabs(); - initControls(); - }; -} (window, window.document)); \ No newline at end of file diff --git a/docs/reports/tests/test/packages/lv.id.jc.algorithm.graph.html b/docs/reports/tests/test/packages/lv.id.jc.algorithm.graph.html deleted file mode 100644 index af30033..0000000 --- a/docs/reports/tests/test/packages/lv.id.jc.algorithm.graph.html +++ /dev/null @@ -1,143 +0,0 @@ - - - - - -Test results - Package lv.id.jc.algorithm.graph - - - - - -
                                -

                                Package lv.id.jc.algorithm.graph

                                - -
                                - - - - - -
                                -
                                - - - - - - - -
                                -
                                -
                                73
                                -

                                tests

                                -
                                -
                                -
                                -
                                0
                                -

                                failures

                                -
                                -
                                -
                                -
                                0
                                -

                                ignored

                                -
                                -
                                -
                                -
                                0.124s
                                -

                                duration

                                -
                                -
                                -
                                -
                                -
                                -
                                100%
                                -

                                successful

                                -
                                -
                                -
                                -
                                - -
                                -

                                Classes

                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                ClassTestsFailuresIgnoredDurationSuccess rate
                                -BreadthFirstSearchSpec -13000.010s100%
                                -DijkstrasAlgorithmSpec -24000.015s100%
                                -GraphSpec -20000.050s100%
                                -SearchAlgorithmsSpec -12000.028s100%
                                -SearchAlgorithmsTest -4000.021s100%
                                -
                                -
                                - -
                                - - diff --git a/docs/spock-reports/aggregated_report.json b/docs/spock-reports/aggregated_report.json deleted file mode 100644 index 0ebfefb..0000000 --- a/docs/spock-reports/aggregated_report.json +++ /dev/null @@ -1 +0,0 @@ -{"lv.id.jc.algorithm.graph.SearchAlgorithmsSpec":{"executedFeatures":["should find a route for a complex graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":1,"totalFeatures":1,"passed":1,"successRate":1.0,"time":46},"title":"Comparison of two algorithms","narrative":""},"lv.id.jc.algorithm.graph.BreadthFirstSearchSpec":{"executedFeatures":["should find a route for complex graph","should find a route for simple graph","should return an empty path if can't find a route","should thrown NPE path for an empty graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":4,"totalFeatures":4,"passed":4,"successRate":1.0,"time":16},"title":"Breadth First Search Algorithm","narrative":"Breadth First Search algorithm for finding the shortest paths between nodes in a graph"},"lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec":{"executedFeatures":["should find a route for a complex graph","should find a route for a medium graph","should find a route for a simple graph","should return an empty path if can't find a route","should thrown NPE for an empty graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":5,"totalFeatures":5,"passed":5,"successRate":1.0,"time":45},"title":"Dijkstra's Algorithm","narrative":"Dijkstra's algorithm is an algorithm for finding the fastest paths between nodes in a graph"},"lv.id.jc.algorithm.graph.GraphSpec":{"executedFeatures":["should be zero distance for an empty path","should be zero distance for any one node path","should calculate distance for a path","should return edges for a given node","should throw NPE for incorrect path"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":5,"totalFeatures":5,"passed":5,"successRate":1.0,"time":47},"title":"Generic Graph","narrative":"A generic implementation of Graph structure"},"lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec":{"executedFeatures":["should find a route for a complex graph","should find a route for a medium graph","should find a route for a simple graph","should return an empty path if can't find a route","should thrown NPE for an empty graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":5,"totalFeatures":5,"passed":5,"successRate":1.0,"time":46},"title":"Dijkstra's Algorithm","narrative":"Dijkstra's algorithm is an algorithm for finding the fastest paths between nodes in a graph"},"lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec":{"executedFeatures":["should find a route for a complex graph","should find a route for a medium graph","should find a route for a simple graph","should return an empty path if can't find a route","should thrown NPE for an empty graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":1,"totalFeatures":5,"passed":1,"successRate":1.0,"time":29},"title":"Dijkstra's Algorithm","narrative":"Dijkstra's algorithm is an algorithm for finding the fastest paths between nodes in a graph"},"lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec":{"executedFeatures":["should find a route for a complex graph","should find a route for a medium graph","should find a route for a simple graph","should return an empty path if can't find a route","should thrown NPE for an empty graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":1,"totalFeatures":5,"passed":1,"successRate":1.0,"time":32},"title":"Dijkstra's Algorithm","narrative":"Dijkstra's algorithm is an algorithm for finding the fastest paths between nodes in a graph"},"lv.id.jc.algorithm.graph.BreadthFirstSearchSpec":{"executedFeatures":["should find a route for complex graph","should find a route for simple graph","should return an empty path if can't find a route","should thrown an exception for an empty graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":4,"totalFeatures":4,"passed":4,"successRate":1.0,"time":37},"title":"Breadth First Search Algorithm","narrative":"Breadth First Search algorithm for finding the shortest paths between nodes in a graph"},"lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec":{"executedFeatures":["should find a route for a complex graph","should find a route for a medium graph","should find a route for a simple graph","should return an empty path if can't find a route","should thrown NPE for an empty graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":5,"totalFeatures":5,"passed":5,"successRate":1.0,"time":15},"title":"Dijkstra's Algorithm","narrative":"Dijkstra's algorithm is an algorithm for finding the fastest paths between nodes in a graph"},"lv.id.jc.algorithm.graph.GraphSpec":{"executedFeatures":["should be zero distance for an empty path","should be zero distance for any one node path","should calculate distance for a path","should return edges for a given node","should throw NPE for incorrect path"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":5,"totalFeatures":5,"passed":5,"successRate":1.0,"time":32},"title":"Generic Graph","narrative":"A generic implementation of Graph structure"},"lv.id.jc.algorithm.graph.SearchAlgorithmsSpec":{"executedFeatures":["should find a route for a complex graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":1,"totalFeatures":1,"passed":1,"successRate":1.0,"time":5},"title":"Comparison of two algorithms","narrative":""},"lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec":{"executedFeatures":["should find a route for a complex graph","should find a route for a medium graph","should find a route for a simple graph","should return an empty path if can't find a route","should thrown NPE for an empty graph"],"ignoredFeatures":[],"stats":{"failures":0,"errors":0,"skipped":0,"totalRuns":5,"totalFeatures":5,"passed":5,"successRate":1.0,"time":44},"title":"Dijkstra's Algorithm","narrative":"Dijkstra's algorithm is an algorithm for finding \nthe fastest paths between nodes in a graph"},"lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec":{"executedFeatures":["should find a route for a complex graph","should find a route for a medium graph","should find a route for a simple graph","should return an empty path if can't find a route","should thrown NPE for an empty graph"],"ignoredFeatures":[],"stats":{"failures":1,"errors":0,"skipped":0,"totalRuns":1,"totalFeatures":5,"passed":0,"successRate":0.0,"time":37},"title":"Dijkstra's Algorithm","narrative":"Dijkstra's algorithm is an algorithm for finding \nthe fastest paths between nodes in a graph"}} \ No newline at end of file diff --git a/docs/spock-reports/index.html b/docs/spock-reports/index.html deleted file mode 100644 index 3176661..0000000 --- a/docs/spock-reports/index.html +++ /dev/null @@ -1,191 +0,0 @@ - - - - - - -

                                Specification run results

                                -
                                -
                                -Project: Graph search algorithms -Version: 1.1 -
                                -
                                -

                                Specifications summary:

                                -
                                Created on Mon Oct 17 14:40:08 EEST 2022 by jegors
                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                TotalPassedFailedSkippedFt TotalFt PassedFt FailedFt SkippedSuccess rateTotal time
                                431015101075.0%0.111 seconds
                                -
                                -

                                Specifications:

                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                NameFeaturesIterationsFailedErrorsSkippedSuccess rateTime
                                -lv.id.jc.algorithm.graph.BreadthFirstSearchSpec -
                                Breadth First Search Algorithm
                                -
                                44000100.0%0.037 seconds
                                -lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec -
                                Dijkstra's Algorithm
                                -
                                511000.0%0.037 seconds
                                -lv.id.jc.algorithm.graph.GraphSpec -
                                Generic Graph
                                -
                                55000100.0%0.032 seconds
                                -lv.id.jc.algorithm.graph.SearchAlgorithmsSpec -
                                Comparison of two algorithms
                                -
                                11000100.0%0.005 seconds
                                -
                                - - - \ No newline at end of file diff --git a/docs/spock-reports/lv.id.jc.algorithm.graph.BreadthFirstSearchSpec.html b/docs/spock-reports/lv.id.jc.algorithm.graph.BreadthFirstSearchSpec.html deleted file mode 100644 index e90c676..0000000 --- a/docs/spock-reports/lv.id.jc.algorithm.graph.BreadthFirstSearchSpec.html +++ /dev/null @@ -1,663 +0,0 @@ - - - - - - -

                                Report for lv.id.jc.algorithm.graph.BreadthFirstSearchSpec

                                -
                                - -
                                -

                                Summary:

                                -
                                Created on Sun Oct 16 12:33:47 EEST 2022 by jegors
                                - - - - - - - - - - - - - - - - - - - - - - - -
                                Executed featuresPassedFailuresErrorsSkippedSuccess rateTime
                                44000100.0%0.037 seconds
                                -
                                -
                                Breadth First Search Algorithm
                                -
                                Breadth First Search algorithm for finding the shortest paths between nodes in a graph
                                - -

                                Features:

                                - ---- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                -
                                -should find a route for simple graph - -Return -
                                (0.006 seconds)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                def graph = Graph.of([
                                -        A: [B: 7, C: 2],
                                -        B: [A: 3, C: 5],
                                -        C: [A: 1, B: 3]
                                -])
                                -
                                -
                                When:
                                -
                                -
                                def path = algorithm.findPath(graph, source, target)
                                -
                                -
                                Then:
                                -
                                -
                                path == shortest
                                -
                                -
                                And:
                                -
                                -
                                graph.getDistance(path) == time as double
                                -
                                -
                                Examples:
                                -
                                -
                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                sourcetargettimeshortest
                                AA0[A] -OK -(0.006 seconds) -
                                AB7[A, B] -OK -(0) -
                                BC5[B, C] -OK -(0) -
                                CB3[C, B] -OK -(0) -
                                -
                                -
                                -
                                4/4 passed
                                -
                                -
                                -should find a route for complex graph - -Return -
                                (0)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                def graph = Graph.of([
                                -A: [B: 1],
                                -B: [A: 1, D: 1],
                                -C: [A: 1],
                                -D: [C: 1, E: 1],
                                -E: [F: 1],
                                -F: [D: 1, E: 1]])
                                -
                                -
                                When:
                                -
                                -
                                def path = algorithm.findPath(graph, source, target)
                                -
                                -
                                Then:
                                -
                                -
                                path == shortest
                                -
                                -
                                And:
                                -
                                -
                                graph.getDistance(path) == time as double
                                -
                                -
                                And:
                                -
                                -
                                time = shortest.size() - 1
                                -
                                -
                                Examples:
                                -
                                -
                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                sourcetargetshortesttime
                                AA[A]0 -OK -(0) -
                                BB[B]0 -OK -(0) -
                                AB[A, B]1 -OK -(0) -
                                BA[B, A]1 -OK -(0) -
                                AC[A, B, D, C]3 -OK -(0) -
                                CA[C, A]1 -OK -(0) -
                                EB[E, F, D, C, A, B]5 -OK -(0) -
                                -
                                -
                                -
                                7/7 passed
                                -
                                -
                                -should thrown an exception for an empty graph - -Return -
                                (0)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                def graph = Graph.of([:])
                                -
                                -
                                When:
                                -
                                -
                                algorithm.findPath(graph, 'A', 'B')
                                -
                                -
                                Then:
                                -
                                -
                                thrown NullPointerException
                                -
                                -
                                -should return an empty path if can't find a route - -Return -
                                (0)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                a simple graph with no edge between nodes
                                -
                                -
                                def graph = Graph.of([A: [:], B: [:]])
                                -
                                -
                                When:
                                -
                                -
                                def path = algorithm.findPath(graph, 'A', 'B')
                                -
                                -
                                Then:
                                -
                                -
                                path == []
                                -
                                -
                                - - - \ No newline at end of file diff --git a/docs/spock-reports/lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec.html b/docs/spock-reports/lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec.html deleted file mode 100644 index 6112fea..0000000 --- a/docs/spock-reports/lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec.html +++ /dev/null @@ -1,616 +0,0 @@ - - - - - - -

                                Report for lv.id.jc.algorithm.graph.DijkstrasAlgorithmSpec

                                -
                                - -
                                -

                                Summary:

                                -
                                Created on Sun Oct 16 16:27:44 EEST 2022 by jegors
                                - - - - - - - - - - - - - - - - - - - - - - - -
                                Executed featuresPassedFailuresErrorsSkippedSuccess rateTime
                                101000.0%0.037 seconds
                                -
                                -
                                Dijkstra's Algorithm
                                -
                                Dijkstra's algorithm is an algorithm for finding 
                                -the fastest paths between nodes in a graph
                                - -

                                Features:

                                - ---- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                -
                                -should find a route for a simple graph - -Return -
                                (0.016 seconds)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                def graph = Graph.of([
                                -        A: [B: 7, C: 2],
                                -        B: [A: 3, C: 5],
                                -        C: [A: 1, B: 3]
                                -])
                                -
                                -
                                When:
                                -
                                -
                                def path = algorithm.findPath(graph, source, target)
                                -def time = graph.getDistance(path)
                                -
                                -
                                Then:
                                -
                                -
                                path == fastestPath // line 29
                                -
                                time == fastestTime
                                -
                                -
                                Examples:
                                -
                                -
                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                sourcetargetfastestPathfastestTime
                                AA[A]0 -OK -(0.005 seconds) -
                                BA[B, A]3 -OK -(0) -
                                AB[A, B]5 -FAIL -(0.011 seconds) -
                                -
                                -
                                -
                                2/3 passed
                                -
                                -
                                -
                                The following problems occurred:
                                -
                                -
                                  -
                                • -
                                  [A, B, [A, B], 5]
                                  -
                                    -
                                  • -
                                    Condition not satisfied:

                                    path == fastestPath
                                    | | |
                                    | | [A, B]
                                    | false
                                    [A, C, B]
                                    -
                                  • -
                                  -
                                • -
                                -
                                -
                                -
                                -
                                -should find a route for a medium graph - -Return - -
                                -
                                -
                                Given:
                                -
                                -
                                def graph = Graph.of([
                                -        A: [B: 5],
                                -        B: [A: 5, C: 10],
                                -        C: [B: 20, D: 5],
                                -        D: [E: 5],
                                -        E: [B: 5]
                                -])
                                -
                                -
                                When:
                                -
                                -
                                def path = algorithm.findPath(graph, source, target)
                                -
                                -
                                Then:
                                -
                                -
                                path == fastest
                                -
                                -
                                And:
                                -
                                -
                                graph.getDistance(path) == time as double
                                -
                                -
                                -should find a route for a complex graph - -Return - -
                                -
                                -
                                Given:
                                -
                                -
                                def graph = Graph.of([
                                -        A: [B: 5, H: 2],
                                -        B: [A: 5, C: 7],
                                -        C: [B: 7, D: 3, G: 4],
                                -        D: [C: 20, E: 4],
                                -        E: [F: 5],
                                -        F: [G: 6],
                                -        G: [C: 4],
                                -        H: [G: 3]
                                -])
                                -
                                -
                                When:
                                -
                                -
                                def path = algorithm.findPath(graph, source, target)
                                -
                                -
                                Then:
                                -
                                -
                                path == fastest
                                -
                                -
                                And:
                                -
                                -
                                graph.getDistance(path) == time as double
                                -
                                -
                                -should thrown NPE for an empty graph - -Return - -
                                -
                                -
                                Given:
                                -
                                -
                                def graph = Graph.of([:])
                                -
                                -
                                When:
                                -
                                -
                                algorithm.findPath(graph, 'A', 'B')
                                -
                                -
                                Then:
                                -
                                -
                                thrown NullPointerException
                                -
                                -
                                -should return an empty path if can't find a route - -Return - -
                                -
                                -
                                Given:
                                -
                                -
                                a simple graph with no edge between nodes
                                -
                                -
                                def graph = Graph.of([A: [:], B: [:]])
                                -
                                -
                                When:
                                -
                                -
                                def path = algorithm.findPath(graph, 'A', 'B')
                                -
                                -
                                Then:
                                -
                                -
                                path == []
                                -
                                -
                                - - - \ No newline at end of file diff --git a/docs/spock-reports/lv.id.jc.algorithm.graph.GraphSpec.html b/docs/spock-reports/lv.id.jc.algorithm.graph.GraphSpec.html deleted file mode 100644 index f83fed4..0000000 --- a/docs/spock-reports/lv.id.jc.algorithm.graph.GraphSpec.html +++ /dev/null @@ -1,802 +0,0 @@ - - - - - - -

                                Report for lv.id.jc.algorithm.graph.GraphSpec

                                -
                                - -
                                -

                                Summary:

                                -
                                Created on Sun Oct 16 12:33:47 EEST 2022 by jegors
                                - - - - - - - - - - - - - - - - - - - - - - - -
                                Executed featuresPassedFailuresErrorsSkippedSuccess rateTime
                                55000100.0%0.032 seconds
                                -
                                -
                                Generic Graph
                                -
                                A generic implementation of Graph structure
                                -

                                Features:

                                - ---- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                -
                                -should return edges for a given node - -Return -
                                (0)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                a simple graph with three nodes
                                -
                                -
                                def graph = Graph.of([
                                -        A: [B: 7, C: 2],
                                -        B: [A: 3, C: 5],
                                -        C: [A: 1, B: 3]
                                -])
                                -
                                -
                                Expect:
                                -
                                -
                                The method returns expected edges for given node
                                -
                                -
                                graph.edges(node) == expected
                                -
                                -
                                Examples:
                                -
                                -
                                - - - - - - - - - - - - - - - - - - - - - - - - -
                                nodeexpected
                                A[B:7, C:2] -OK -(0) -
                                B[A:3, C:5] -OK -(0) -
                                C[A:1, B:3] -OK -(0) -
                                -
                                -
                                -
                                3/3 passed
                                -
                                -
                                -should calculate distance for a path - -Return -
                                (0)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                a complex graph with eight nodes
                                -
                                -
                                def graph = Graph.of([
                                -        A: [B: 5, H: 2],
                                -        B: [A: 5, C: 7],
                                -        C: [B: 7, D: 3, G: 4],
                                -        D: [C: 20, E: 4],
                                -        E: [F: 5],
                                -        F: [G: 6],
                                -        G: [C: 4],
                                -        H: [G: 3]
                                -])
                                -
                                -
                                Expect:
                                -
                                -
                                the distance for a path correctly calculated
                                -
                                -
                                graph.getDistance(path) == distance as double
                                -
                                -
                                Where:
                                -
                                -
                                path and expected distance
                                -
                                -
                                Examples:
                                -
                                -
                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                pathdistance
                                [A]0 -OK -(0) -
                                [A, B]5 -OK -(0) -
                                [B, A]5 -OK -(0) -
                                [A, B, A]10 -OK -(0) -
                                [A, B, A, B]15 -OK -(0) -
                                [C, D]3 -OK -(0) -
                                [D, C]20 -OK -(0) -
                                [D, E, F, G, C]19 -OK -(0) -
                                -
                                -
                                -
                                8/8 passed
                                -
                                -
                                -should be zero distance for an empty path - -Return -
                                (0.020 seconds)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                any graph
                                -
                                -
                                def graph = Graph.of(_ as Map)
                                -
                                -
                                Expect:
                                -
                                -
                                the distance is zero for an empty path
                                -
                                -
                                graph.getDistance([]) == 0
                                -
                                -
                                -should be zero distance for any one node path - -Return -
                                (0)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                any graph
                                -
                                -
                                def graph = Graph.of(_ as Map)
                                -
                                -
                                Expect:
                                -
                                -
                                the zero distance for any one-node path
                                -
                                -
                                graph.getDistance(oneNodePath) == 0
                                -
                                -
                                Where:
                                -
                                -
                                the node may be of any type and even non-existent
                                -
                                -
                                Examples:
                                -
                                -
                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                oneNodePath
                                [A] -OK -(0) -
                                [B] -OK -(0) -
                                [2] -OK -(0) -
                                [X] -OK -(0) -
                                [12.56] -OK -(0) -
                                -
                                -
                                -
                                5/5 passed
                                -
                                -
                                -should throw NPE for incorrect path - -Return -
                                (0)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                a medium graph with five nodes
                                -
                                -
                                def graph = Graph.of([
                                -        A: [B: 5],
                                -        B: [A: 5, C: 10],
                                -        C: [B: 20, D: 5],
                                -        D: [E: 5],
                                -        E: [B: 5]
                                -])
                                -
                                -
                                When:
                                -
                                -
                                we call the method with incorrect path
                                -
                                -
                                graph.getDistance(incorrectPath)
                                -
                                -
                                Then:
                                -
                                -
                                the NPE thrown
                                -
                                -
                                thrown NullPointerException
                                -
                                -
                                Where:
                                -
                                -
                                path is more then one node
                                -
                                -
                                Examples:
                                -
                                -
                                - - - - - - - - - - - - - - - - - - - - -
                                incorrectPath
                                [E, D] -OK -(0) -
                                [A, C] -OK -(0) -
                                [A, B, D] -OK -(0) -
                                -
                                -
                                -
                                3/3 passed
                                -
                                -
                                - - - \ No newline at end of file diff --git a/docs/spock-reports/lv.id.jc.algorithm.graph.SearchAlgorithmsSpec.html b/docs/spock-reports/lv.id.jc.algorithm.graph.SearchAlgorithmsSpec.html deleted file mode 100644 index 3210ffe..0000000 --- a/docs/spock-reports/lv.id.jc.algorithm.graph.SearchAlgorithmsSpec.html +++ /dev/null @@ -1,599 +0,0 @@ - - - - - - -

                                Report for lv.id.jc.algorithm.graph.SearchAlgorithmsSpec

                                -
                                - -
                                -

                                Summary:

                                -
                                Created on Sun Oct 16 12:33:47 EEST 2022 by jegors
                                - - - - - - - - - - - - - - - - - - - - - - - -
                                Executed featuresPassedFailuresErrorsSkippedSuccess rateTime
                                11000100.0%0.005 seconds
                                -
                                -
                                Comparison of two algorithms
                                - -

                                Features:

                                - ---- - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                -
                                -should find a route for a complex graph - -Return -
                                (0)
                                -
                                -
                                -
                                -
                                Given:
                                -
                                -
                                a complex graph with eight nodes
                                -
                                -
                                def graph = Graph.of([
                                -        A: [B: 5, H: 2],
                                -        B: [A: 5, C: 7],
                                -        C: [B: 7, D: 3, G: 4],
                                -        D: [C: 20, E: 4],
                                -        E: [F: 5],
                                -        F: [G: 6],
                                -        G: [C: 4],
                                -        H: [G: 3]
                                -])
                                -
                                -
                                When:
                                -
                                -
                                we use Breadth First Search algorithm for the first route
                                -
                                -
                                def routeOne = bfsAlgorithm.findPath(graph, source, target)
                                -
                                -
                                And:
                                -
                                -
                                we use Dijkstra's algorithm for the second route
                                -
                                -
                                def routeTwo = dijkstras.findPath(graph, source, target)
                                -
                                -
                                Then:
                                -
                                -
                                the first route is the shortest
                                -
                                -
                                routeOne == shortest
                                -
                                -
                                And:
                                -
                                -
                                the second route is the fastest
                                -
                                -
                                routeTwo == fastest
                                -
                                -
                                And:
                                -
                                -
                                the distance calculated correctly
                                -
                                -
                                graph.getDistance(routeOne) == t1 as double
                                -graph.getDistance(routeTwo) == t2 as double
                                -
                                -
                                Examples:
                                -
                                -
                                - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - - -
                                sourcetargett1shortestt2fastest
                                AA0[A]0[A] -OK -(0) -
                                BB0[B]0[B] -OK -(0) -
                                AB5[A, B]5[A, B] -OK -(0) -
                                BA5[B, A]5[B, A] -OK -(0) -
                                AC12[A, B, C]9[A, H, G, C] -OK -(0) -
                                CA12[C, B, A]12[C, B, A] -OK -(0) -
                                AG5[A, H, G]5[A, H, G] -OK -(0) -
                                CD3[C, D]3[C, D] -OK -(0) -
                                DC20[D, C]19[D, E, F, G, C] -OK -(0) -
                                BD10[B, C, D]10[B, C, D] -OK -(0) -
                                DB27[D, C, B]26[D, E, F, G, C, B] -OK -(0) -
                                DH34[D, C, B, A, H]33[D, E, F, G, C, B, A, H] -OK -(0) -
                                -
                                -
                                -
                                12/12 passed
                                -
                                -
                                - - - \ No newline at end of file diff --git a/gradle/wrapper/gradle-wrapper.jar b/gradle/wrapper/gradle-wrapper.jar deleted file mode 100644 index 7454180..0000000 Binary files a/gradle/wrapper/gradle-wrapper.jar and /dev/null differ diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties deleted file mode 100644 index ae04661..0000000 --- a/gradle/wrapper/gradle-wrapper.properties +++ /dev/null @@ -1,5 +0,0 @@ -distributionBase=GRADLE_USER_HOME -distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.5.1-bin.zip -zipStoreBase=GRADLE_USER_HOME -zipStorePath=wrapper/dists diff --git a/gradlew b/gradlew deleted file mode 100755 index 1b6c787..0000000 --- a/gradlew +++ /dev/null @@ -1,234 +0,0 @@ -#!/bin/sh - -# -# Copyright © 2015-2021 the original authors. -# -# Licensed under the Apache License, Version 2.0 (the "License"); -# you may not use this file except in compliance with the License. -# You may obtain a copy of the License at -# -# https://www.apache.org/licenses/LICENSE-2.0 -# -# Unless required by applicable law or agreed to in writing, software -# distributed under the License is distributed on an "AS IS" BASIS, -# WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -# See the License for the specific language governing permissions and -# limitations under the License. -# - -############################################################################## -# -# Gradle start up script for POSIX generated by Gradle. -# -# Important for running: -# -# (1) You need a POSIX-compliant shell to run this script. If your /bin/sh is -# noncompliant, but you have some other compliant shell such as ksh or -# bash, then to run this script, type that shell name before the whole -# command line, like: -# -# ksh Gradle -# -# Busybox and similar reduced shells will NOT work, because this script -# requires all of these POSIX shell features: -# * functions; -# * expansions «$var», «${var}», «${var:-default}», «${var+SET}», -# «${var#prefix}», «${var%suffix}», and «$( cmd )»; -# * compound commands having a testable exit status, especially «case»; -# * various built-in commands including «command», «set», and «ulimit». -# -# Important for patching: -# -# (2) This script targets any POSIX shell, so it avoids extensions provided -# by Bash, Ksh, etc; in particular arrays are avoided. -# -# The "traditional" practice of packing multiple parameters into a -# space-separated string is a well documented source of bugs and security -# problems, so this is (mostly) avoided, by progressively accumulating -# options in "$@", and eventually passing that to Java. -# -# Where the inherited environment variables (DEFAULT_JVM_OPTS, JAVA_OPTS, -# and GRADLE_OPTS) rely on word-splitting, this is performed explicitly; -# see the in-line comments for details. -# -# There are tweaks for specific operating systems such as AIX, CygWin, -# Darwin, MinGW, and NonStop. -# -# (3) This script is generated from the Groovy template -# https://github.com/gradle/gradle/blob/master/subprojects/plugins/src/main/resources/org/gradle/api/internal/plugins/unixStartScript.txt -# within the Gradle project. -# -# You can find Gradle at https://github.com/gradle/gradle/. -# -############################################################################## - -# Attempt to set APP_HOME - -# Resolve links: $0 may be a link -app_path=$0 - -# Need this for daisy-chained symlinks. -while - APP_HOME=${app_path%"${app_path##*/}"} # leaves a trailing /; empty if no leading path - [ -h "$app_path" ] -do - ls=$( ls -ld "$app_path" ) - link=${ls#*' -> '} - case $link in #( - /*) app_path=$link ;; #( - *) app_path=$APP_HOME$link ;; - esac -done - -APP_HOME=$( cd "${APP_HOME:-./}" && pwd -P ) || exit - -APP_NAME="Gradle" -APP_BASE_NAME=${0##*/} - -# Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -DEFAULT_JVM_OPTS='"-Xmx64m" "-Xms64m"' - -# Use the maximum available, or set MAX_FD != -1 to use that value. -MAX_FD=maximum - -warn () { - echo "$*" -} >&2 - -die () { - echo - echo "$*" - echo - exit 1 -} >&2 - -# OS specific support (must be 'true' or 'false'). -cygwin=false -msys=false -darwin=false -nonstop=false -case "$( uname )" in #( - CYGWIN* ) cygwin=true ;; #( - Darwin* ) darwin=true ;; #( - MSYS* | MINGW* ) msys=true ;; #( - NONSTOP* ) nonstop=true ;; -esac - -CLASSPATH=$APP_HOME/gradle/wrapper/gradle-wrapper.jar - - -# Determine the Java command to use to start the JVM. -if [ -n "$JAVA_HOME" ] ; then - if [ -x "$JAVA_HOME/jre/sh/java" ] ; then - # IBM's JDK on AIX uses strange locations for the executables - JAVACMD=$JAVA_HOME/jre/sh/java - else - JAVACMD=$JAVA_HOME/bin/java - fi - if [ ! -x "$JAVACMD" ] ; then - die "ERROR: JAVA_HOME is set to an invalid directory: $JAVA_HOME - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." - fi -else - JAVACMD=java - which java >/dev/null 2>&1 || die "ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. - -Please set the JAVA_HOME variable in your environment to match the -location of your Java installation." -fi - -# Increase the maximum file descriptors if we can. -if ! "$cygwin" && ! "$darwin" && ! "$nonstop" ; then - case $MAX_FD in #( - max*) - MAX_FD=$( ulimit -H -n ) || - warn "Could not query maximum file descriptor limit" - esac - case $MAX_FD in #( - '' | soft) :;; #( - *) - ulimit -n "$MAX_FD" || - warn "Could not set maximum file descriptor limit to $MAX_FD" - esac -fi - -# Collect all arguments for the java command, stacking in reverse order: -# * args from the command line -# * the main class name -# * -classpath -# * -D...appname settings -# * --module-path (only if needed) -# * DEFAULT_JVM_OPTS, JAVA_OPTS, and GRADLE_OPTS environment variables. - -# For Cygwin or MSYS, switch paths to Windows format before running java -if "$cygwin" || "$msys" ; then - APP_HOME=$( cygpath --path --mixed "$APP_HOME" ) - CLASSPATH=$( cygpath --path --mixed "$CLASSPATH" ) - - JAVACMD=$( cygpath --unix "$JAVACMD" ) - - # Now convert the arguments - kludge to limit ourselves to /bin/sh - for arg do - if - case $arg in #( - -*) false ;; # don't mess with options #( - /?*) t=${arg#/} t=/${t%%/*} # looks like a POSIX filepath - [ -e "$t" ] ;; #( - *) false ;; - esac - then - arg=$( cygpath --path --ignore --mixed "$arg" ) - fi - # Roll the args list around exactly as many times as the number of - # args, so each arg winds up back in the position where it started, but - # possibly modified. - # - # NB: a `for` loop captures its iteration list before it begins, so - # changing the positional parameters here affects neither the number of - # iterations, nor the values presented in `arg`. - shift # remove old arg - set -- "$@" "$arg" # push replacement arg - done -fi - -# Collect all arguments for the java command; -# * $DEFAULT_JVM_OPTS, $JAVA_OPTS, and $GRADLE_OPTS can contain fragments of -# shell script including quotes and variable substitutions, so put them in -# double quotes to make sure that they get re-expanded; and -# * put everything else in single quotes, so that it's not re-expanded. - -set -- \ - "-Dorg.gradle.appname=$APP_BASE_NAME" \ - -classpath "$CLASSPATH" \ - org.gradle.wrapper.GradleWrapperMain \ - "$@" - -# Use "xargs" to parse quoted args. -# -# With -n1 it outputs one arg per line, with the quotes and backslashes removed. -# -# In Bash we could simply go: -# -# readarray ARGS < <( xargs -n1 <<<"$var" ) && -# set -- "${ARGS[@]}" "$@" -# -# but POSIX shell has neither arrays nor command substitution, so instead we -# post-process each arg (as a line of input to sed) to backslash-escape any -# character that might be a shell metacharacter, then use eval to reverse -# that process (while maintaining the separation between arguments), and wrap -# the whole thing up as a single "set" statement. -# -# This will of course break if any of these variables contains a newline or -# an unmatched quote. -# - -eval "set -- $( - printf '%s\n' "$DEFAULT_JVM_OPTS $JAVA_OPTS $GRADLE_OPTS" | - xargs -n1 | - sed ' s~[^-[:alnum:]+,./:=@_]~\\&~g; ' | - tr '\n' ' ' - )" '"$@"' - -exec "$JAVACMD" "$@" diff --git a/gradlew.bat b/gradlew.bat deleted file mode 100644 index 107acd3..0000000 --- a/gradlew.bat +++ /dev/null @@ -1,89 +0,0 @@ -@rem -@rem Copyright 2015 the original author or authors. -@rem -@rem Licensed under the Apache License, Version 2.0 (the "License"); -@rem you may not use this file except in compliance with the License. -@rem You may obtain a copy of the License at -@rem -@rem https://www.apache.org/licenses/LICENSE-2.0 -@rem -@rem Unless required by applicable law or agreed to in writing, software -@rem distributed under the License is distributed on an "AS IS" BASIS, -@rem WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. -@rem See the License for the specific language governing permissions and -@rem limitations under the License. -@rem - -@if "%DEBUG%" == "" @echo off -@rem ########################################################################## -@rem -@rem Gradle startup script for Windows -@rem -@rem ########################################################################## - -@rem Set local scope for the variables with windows NT shell -if "%OS%"=="Windows_NT" setlocal - -set DIRNAME=%~dp0 -if "%DIRNAME%" == "" set DIRNAME=. -set APP_BASE_NAME=%~n0 -set APP_HOME=%DIRNAME% - -@rem Resolve any "." and ".." in APP_HOME to make it shorter. -for %%i in ("%APP_HOME%") do set APP_HOME=%%~fi - -@rem Add default JVM options here. You can also use JAVA_OPTS and GRADLE_OPTS to pass JVM options to this script. -set DEFAULT_JVM_OPTS="-Xmx64m" "-Xms64m" - -@rem Find java.exe -if defined JAVA_HOME goto findJavaFromJavaHome - -set JAVA_EXE=java.exe -%JAVA_EXE% -version >NUL 2>&1 -if "%ERRORLEVEL%" == "0" goto execute - -echo. -echo ERROR: JAVA_HOME is not set and no 'java' command could be found in your PATH. -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:findJavaFromJavaHome -set JAVA_HOME=%JAVA_HOME:"=% -set JAVA_EXE=%JAVA_HOME%/bin/java.exe - -if exist "%JAVA_EXE%" goto execute - -echo. -echo ERROR: JAVA_HOME is set to an invalid directory: %JAVA_HOME% -echo. -echo Please set the JAVA_HOME variable in your environment to match the -echo location of your Java installation. - -goto fail - -:execute -@rem Setup the command line - -set CLASSPATH=%APP_HOME%\gradle\wrapper\gradle-wrapper.jar - - -@rem Execute Gradle -"%JAVA_EXE%" %DEFAULT_JVM_OPTS% %JAVA_OPTS% %GRADLE_OPTS% "-Dorg.gradle.appname=%APP_BASE_NAME%" -classpath "%CLASSPATH%" org.gradle.wrapper.GradleWrapperMain %* - -:end -@rem End local scope for the variables with windows NT shell -if "%ERRORLEVEL%"=="0" goto mainEnd - -:fail -rem Set variable GRADLE_EXIT_CONSOLE if you need the _script_ return code instead of -rem the _cmd.exe /c_ return code! -if not "" == "%GRADLE_EXIT_CONSOLE%" exit 1 -exit /b 1 - -:mainEnd -if "%OS%"=="Windows_NT" endlocal - -:omega diff --git a/graph-shell/README.md b/graph-shell/README.md deleted file mode 100644 index ee363c1..0000000 --- a/graph-shell/README.md +++ /dev/null @@ -1,109 +0,0 @@ ---- -title: "Sample application: Graph Shell" ---- - -## About - -To demonstrate the work of search algorithms, I made a small console program. The program allows you to select one of three graph samples and search for a path using two algorithms. The source code of the program is located in `graph-shell` module. - -## Build & Run - -To compile the program, use the command: - -```shell -$ gradle assemble -``` - -This command will create an executable jar, so in Linux or macOS you may run the application by - -```shell -$ ./build/libs/graph-shell-1.0-SNAPSHOT.jar -``` - -On the Windows machine you should run the application using java: - -```shell -$ java -jar ./build/libs/graph-shell-1.0-SNAPSHOT.jar -``` - -## Using Graph Shell - -The application has build-in three graph schemas: `simple`, `medium`, `complex`. By default the `complex` scheme is loaded. You may specify the schema in the `application.properties` file: - -```properties -graph=simple -``` - -Alternatively you may specify the command line parameter when you run the application: - -```shell -$ ./build/libs/graph-shell-1.0-SNAPSHOT.jar --graph=medium -``` - -After starting the program you will see the banner and the prompt indicating the current graph scheme. - -```shell -$ ./build/libs/graph-shell-1.0-SNAPSHOT.jar - - _____ _ _____ _ _ _ - / ____| | | / ____| | | | | | | - | | __ _ __ __ _ _ __ | |__ | (___ | |__ ___ | | | | - | | |_ | | '__| / _` | | '_ \ | '_ \ \___ \ | '_ \ / _ \ | | | | - | |__| | | | | (_| | | |_) | | | | | ____) | | | | | | __/ | | | | - \_____| |_| \__,_| | .__/ |_| |_| |_____/ |_| |_| \___| |_| |_| - | | - |_| - -complex:> -``` - -The command help will show all available commands with short description. - -```shell -complex:> help -AVAILABLE COMMANDS - -Built-In Commands - clear: Clear the shell screen. - exit, quit: Exit the shell. - help: Display help about available commands. - history: Display or save the history of previously run commands - script: Read and execute commands from a file. - stacktrace: Display the full stacktrace of the last error. - -Commands - distance: prints distance for the path - fastest: finds the fastest path by using Dijkstra's Algorithm - schema: prints schema of the graph - shortest: finds the shortest path by using Breadth First Search Algorithm -``` - -Typing `help ` you will get more detailed information about each command. - -```shell -complex:> help fastest - - -NAME - fastest - finds the fastest path by using Dijkstra's Algorithm - -SYNOPSYS - fastest [--source] string [--target] string - -OPTIONS - --source string - - [Mandatory] - [this vertex was not found in the graph diagram] - - --target string - - [Mandatory] - [this vertex was not found in the graph diagram] -``` - -The program supports scripts. I provide one script `test1.script` to demonstrate the difference between two algorithms. - - - - diff --git a/graph-shell/build.gradle b/graph-shell/build.gradle deleted file mode 100644 index dbba16f..0000000 --- a/graph-shell/build.gradle +++ /dev/null @@ -1,30 +0,0 @@ -plugins { - id 'java' - id 'org.springframework.boot' version '2.7.1' - id 'io.spring.dependency-management' version '1.0.11.RELEASE' -} - -repositories { - mavenCentral() - maven { url 'https://repo.spring.io/release' } - maven { url 'https://repo.spring.io/libs-snapshot-local' } - maven { url 'https://repo.spring.io/libs-milestone-local' } -} - -dependencies { - implementation project(':algorithm') - implementation 'org.springframework.boot:spring-boot-starter' - implementation 'org.springframework.shell:spring-shell-starter:2.1.3' - - // YAML - implementation 'com.fasterxml.jackson.core:jackson-databind:2.13.4.2' - implementation 'com.fasterxml.jackson.dataformat:jackson-dataformat-yaml:2.13.4' -} - -bootJar { - launchScript() -} - -group 'lv.id.jc' -version '1.0-SNAPSHOT' - diff --git a/graph-shell/docs/complex.png b/graph-shell/docs/complex.png deleted file mode 100644 index ba793eb..0000000 Binary files a/graph-shell/docs/complex.png and /dev/null differ diff --git a/graph-shell/docs/complex.puml b/graph-shell/docs/complex.puml deleted file mode 100644 index 759f9ce..0000000 --- a/graph-shell/docs/complex.puml +++ /dev/null @@ -1,29 +0,0 @@ -@startdot -digraph complex { -fontname="Helvetica,Arial,sans-serif" -node [fontname="Helvetica,Arial,sans-serif"] -edge [fontname="Helvetica,Arial,sans-serif"] -node [color=lightblue2, style=filled, shape=circle]; -A -A -> B [label=5]; -A -> H [label=2]; -B -B -> A [label=5]; -B -> C [label=7]; -C -C -> B [label=7]; -C -> D [label=3]; -C -> G [label=4]; -D -D -> C [label=20]; -D -> E [label=4]; -E -E -> F [label=5]; -F -F -> G [label=6]; -G -G -> C [label=4]; -H -H -> G [label=3]; -} -@enddot diff --git a/graph-shell/docs/medium.puml b/graph-shell/docs/medium.puml deleted file mode 100644 index 4e53de8..0000000 --- a/graph-shell/docs/medium.puml +++ /dev/null @@ -1,20 +0,0 @@ -@startdot -digraph medium { -fontname="Helvetica,Arial,sans-serif" -node [fontname="Helvetica,Arial,sans-serif"] -edge [fontname="Helvetica,Arial,sans-serif"] -node [color=lightblue2, style=filled, shape=circle]; -A -A -> B [label=5]; -B -B -> A [label=5]; -B -> C [label=10]; -C -C -> B [label=20]; -C -> D [label=5]; -D -D -> E [label=5]; -E -E -> B [label=5]; -} -@enddot diff --git a/graph-shell/docs/simple.puml b/graph-shell/docs/simple.puml deleted file mode 100644 index 5205658..0000000 --- a/graph-shell/docs/simple.puml +++ /dev/null @@ -1,17 +0,0 @@ -@startdot -digraph simple { -fontname="Helvetica,Arial,sans-serif" -node [fontname="Helvetica,Arial,sans-serif"] -edge [fontname="Helvetica,Arial,sans-serif"] -node [color=lightblue2, style=filled, shape=circle]; -A -A -> B [label=7]; -A -> C [label=2]; -B -B -> A [label=3]; -B -> C [label=5]; -C -C -> A [label=1]; -C -> B [label=3]; -} -@enddot diff --git a/graph-shell/src/main/java/lv/id/jc/graph/cli/Commands.java b/graph-shell/src/main/java/lv/id/jc/graph/cli/Commands.java deleted file mode 100644 index 17bb0bf..0000000 --- a/graph-shell/src/main/java/lv/id/jc/graph/cli/Commands.java +++ /dev/null @@ -1,76 +0,0 @@ -package lv.id.jc.graph.cli; - -import com.fasterxml.jackson.dataformat.yaml.YAMLMapper; -import lv.id.jc.algorithm.graph.BreadthFirstSearch; -import lv.id.jc.algorithm.graph.DijkstrasAlgorithm; -import lv.id.jc.algorithm.graph.Graph; -import lv.id.jc.algorithm.graph.SearchAlgorithm; -import org.jline.utils.AttributedString; -import org.jline.utils.AttributedStyle; -import org.springframework.beans.factory.annotation.Value; -import org.springframework.core.io.ClassPathResource; -import org.springframework.shell.jline.PromptProvider; -import org.springframework.shell.standard.ShellComponent; -import org.springframework.shell.standard.ShellMethod; - -import javax.annotation.PostConstruct; -import javax.validation.ConstraintValidator; -import javax.validation.ConstraintValidatorContext; -import javax.validation.constraints.NotEmpty; -import java.io.IOException; -import java.util.List; -import java.util.Map; - -@ShellComponent -public class Commands implements PromptProvider, ConstraintValidator { - private final SearchAlgorithm bfgAlgorithm = new BreadthFirstSearch<>(); - private final SearchAlgorithm dijkstrasAlgorithm = new DijkstrasAlgorithm<>(); - - @Value("${graph:complex}") - private String graphName; - - private Graph graph; - - @PostConstruct - public void loadGraph() throws IOException { - var resource = new ClassPathResource(graphName + ".yaml"); - var schema = new YAMLMapper().readValue(resource.getInputStream(), Map.class); - graph = Graph.of(schema); - } - - @Override - public AttributedString getPrompt() { - return new AttributedString(graphName + ":> ", AttributedStyle.DEFAULT.foreground(AttributedStyle.YELLOW)); - } - - @Override - public boolean isValid(String vertex, ConstraintValidatorContext context) { - return graph.schema().containsKey(vertex); - } - - @ShellMethod("Find the shortest path by using Breadth First Search Algorithm.") - public List shortest(@Vertex String source, @Vertex String target) { - return bfgAlgorithm.findPath(graph, source, target); - } - - @ShellMethod("Find the fastest path by using Dijkstra's Algorithm.") - public List fastest(@Vertex String source, @Vertex String target) { - return dijkstrasAlgorithm.findPath(graph, source, target); - } - - @ShellMethod("Print the edges of the given vertex.") - public Map edges(@Vertex String vertex) { - return graph.edges(vertex); - } - - @ShellMethod("Print schema of the graph.") - public Map> schema() { - return graph.schema(); - } - - @ShellMethod("Calculate the distance for the given path.") - public double distance(@NotEmpty List path) { - return graph.getDistance(path); - } - -} diff --git a/graph-shell/src/main/java/lv/id/jc/graph/cli/GraphShell.java b/graph-shell/src/main/java/lv/id/jc/graph/cli/GraphShell.java deleted file mode 100644 index ef9b391..0000000 --- a/graph-shell/src/main/java/lv/id/jc/graph/cli/GraphShell.java +++ /dev/null @@ -1,12 +0,0 @@ -package lv.id.jc.graph.cli; - -import org.springframework.boot.SpringApplication; -import org.springframework.boot.autoconfigure.SpringBootApplication; - -@SpringBootApplication -public class GraphShell { - - public static void main(String[] args) { - SpringApplication.run(GraphShell.class, args); - } -} diff --git a/graph-shell/src/main/java/lv/id/jc/graph/cli/Vertex.java b/graph-shell/src/main/java/lv/id/jc/graph/cli/Vertex.java deleted file mode 100644 index bd7511d..0000000 --- a/graph-shell/src/main/java/lv/id/jc/graph/cli/Vertex.java +++ /dev/null @@ -1,20 +0,0 @@ -package lv.id.jc.graph.cli; - -import javax.validation.Constraint; -import javax.validation.Payload; -import java.lang.annotation.Retention; -import java.lang.annotation.RetentionPolicy; -import java.lang.annotation.Target; - -import static java.lang.annotation.ElementType.PARAMETER; - -@Target({PARAMETER}) -@Retention(RetentionPolicy.RUNTIME) -@Constraint(validatedBy = {Commands.class}) -public @interface Vertex { - String message() default "must be present in the graph scheme"; - - Class[] groups() default {}; - - Class[] payload() default {}; -} diff --git a/graph-shell/src/main/java/lv/id/jc/graph/cli/package-info.java b/graph-shell/src/main/java/lv/id/jc/graph/cli/package-info.java deleted file mode 100644 index d0b00b7..0000000 --- a/graph-shell/src/main/java/lv/id/jc/graph/cli/package-info.java +++ /dev/null @@ -1,4 +0,0 @@ -/** - * The package contains a simple shell program to demonstrate the work of search algorithms. - */ -package lv.id.jc.graph.cli; \ No newline at end of file diff --git a/graph-shell/src/main/resources/application.properties b/graph-shell/src/main/resources/application.properties deleted file mode 100644 index c080813..0000000 --- a/graph-shell/src/main/resources/application.properties +++ /dev/null @@ -1,2 +0,0 @@ -spring.main.allow-circular-references=true -logging.level.root=WARN diff --git a/graph-shell/src/main/resources/banner.txt b/graph-shell/src/main/resources/banner.txt deleted file mode 100644 index c51d47b..0000000 --- a/graph-shell/src/main/resources/banner.txt +++ /dev/null @@ -1,9 +0,0 @@ - - _____ _ _____ _ _ _ - / ____| | | / ____| | | | | | | - | | __ _ __ __ _ _ __ | |__ | (___ | |__ ___ | | | | - | | |_ | | '__| / _` | | '_ \ | '_ \ \___ \ | '_ \ / _ \ | | | | - | |__| | | | | (_| | | |_) | | | | | ____) | | | | | | __/ | | | | - \_____| |_| \__,_| | .__/ |_| |_| |_____/ |_| |_| \___| |_| |_| - | | - |_| diff --git a/graph-shell/src/main/resources/complex.yaml b/graph-shell/src/main/resources/complex.yaml deleted file mode 100644 index 64332c4..0000000 --- a/graph-shell/src/main/resources/complex.yaml +++ /dev/null @@ -1,8 +0,0 @@ -A: { B: 5, H: 2 } -B: { A: 5, C: 7 } -C: { B: 7, D: 3, G: 4 } -D: { C: 20, E: 4 } -E: { F: 5 } -F: { G: 6 } -G: { C: 4 } -H: { G: 3 } diff --git a/graph-shell/src/main/resources/medium.yaml b/graph-shell/src/main/resources/medium.yaml deleted file mode 100644 index 5c95ddf..0000000 --- a/graph-shell/src/main/resources/medium.yaml +++ /dev/null @@ -1,5 +0,0 @@ -A: { B: 5 } -B: { A: 5, C: 10 } -C: { B: 20, D: 5 } -D: { E: 5 } -E: { B: 5 } diff --git a/graph-shell/src/main/resources/simple.yaml b/graph-shell/src/main/resources/simple.yaml deleted file mode 100644 index b22e0b0..0000000 --- a/graph-shell/src/main/resources/simple.yaml +++ /dev/null @@ -1,3 +0,0 @@ -A: { B: 7, C: 2 } -B: { A: 3, C: 5 } -C: { A: 1, B: 3 } diff --git a/graph-shell/src/script/graph2mermaid.awk b/graph-shell/src/script/graph2mermaid.awk deleted file mode 100644 index 32d8aef..0000000 --- a/graph-shell/src/script/graph2mermaid.awk +++ /dev/null @@ -1,17 +0,0 @@ -#!/usr/bin/env gawk --exec -# -# Copyright (c) 2023 Jegors Čemisovs -# License: MIT License -# Repository: https://github.com/rabestro/graph-pathfinding-algorithms -# -BEGIN { - FS = "[ :,{}]+" - print "flowchart LR" -} -{ - node = $1 - print node "((" node "))" - - for (i = 2; i < NF; i += 2) - printf "%s --> |%2d| %s\n", node, $(i + 1), $i -} \ No newline at end of file diff --git a/graph-shell/src/script/graph2puml.awk b/graph-shell/src/script/graph2puml.awk deleted file mode 100644 index 8f7da75..0000000 --- a/graph-shell/src/script/graph2puml.awk +++ /dev/null @@ -1,26 +0,0 @@ -#!/usr/bin/env gawk --exec -# -# Copyright (c) 2023 Jegors Čemisovs -# License: MIT License -# Repository: https://github.com/rabestro/graph-pathfinding-algorithms -# -BEGIN { - FS = "[ :,{}]+" - - match(FILENAME, /([^/]+)\.yaml/, GraphName) - print "@startdot" - print "digraph", GraphName[1], "{" - print "fontname=\"Helvetica,Arial,sans-serif\"" - print "node [fontname=\"Helvetica,Arial,sans-serif\"]" - print "edge [fontname=\"Helvetica,Arial,sans-serif\"]" - print "node [color=lightblue2, style=filled, shape=circle];" -} -{ - print $1 - for (i = 2; i < NF; i += 2) - print $1, "->", $i, "[label=" $(i + 1) "];" -} -END { - print "}" - print "@enddot" -} \ No newline at end of file diff --git a/graph-shell/test1.script b/graph-shell/test1.script deleted file mode 100644 index a150925..0000000 --- a/graph-shell/test1.script +++ /dev/null @@ -1,14 +0,0 @@ -// The simple test is demonstrate the difference between two algorithms -// By default the application loads the complex graph - -// We make a search by using Breadth First Search algorithm -shortest D B - -// The path is shortest and we check the distance/time -distance D,C,B - -// For second search we use Dijkstras algorithm -fastest D B - -// For the same source and target the path is longer but it requires less time -distance D,E,F,G,C,B diff --git a/index.md b/index.md new file mode 100644 index 0000000..a1be8e7 --- /dev/null +++ b/index.md @@ -0,0 +1,37 @@ +## Welcome to GitHub Pages + +You can use the [editor on GitHub](https://github.com/rabestro/graph-algorithms/edit/gh-pages/index.md) to maintain and preview the content for your website in Markdown files. + +Whenever you commit to this repository, GitHub Pages will run [Jekyll](https://jekyllrb.com/) to rebuild the pages in your site, from the content in your Markdown files. + +### Markdown + +Markdown is a lightweight and easy-to-use syntax for styling your writing. It includes conventions for + +```markdown +Syntax highlighted code block + +# Header 1 +## Header 2 +### Header 3 + +- Bulleted +- List + +1. Numbered +2. List + +**Bold** and _Italic_ and `Code` text + +[Link](url) and ![Image](src) +``` + +For more details see [Basic writing and formatting syntax](https://docs.github.com/en/github/writing-on-github/getting-started-with-writing-and-formatting-on-github/basic-writing-and-formatting-syntax). + +### Jekyll Themes + +Your Pages site will use the layout and styles from the Jekyll theme you have selected in your [repository settings](https://github.com/rabestro/graph-algorithms/settings/pages). The name of this theme is saved in the Jekyll `_config.yml` configuration file. + +### Support or Contact + +Having trouble with Pages? Check out our [documentation](https://docs.github.com/categories/github-pages-basics/) or [contact support](https://support.github.com/contact) and we’ll help you sort it out. diff --git a/sample-groovy/build.gradle b/sample-groovy/build.gradle deleted file mode 100644 index 18b78ad..0000000 --- a/sample-groovy/build.gradle +++ /dev/null @@ -1,17 +0,0 @@ -plugins { - id 'groovy' -} - -java { - sourceCompatibility = JavaVersion.VERSION_17 -} - -repositories { - mavenCentral() -} - -dependencies { - implementation 'org.codehaus.groovy:groovy-all:3.0.12' - implementation project(':algorithm') -} - diff --git a/sample-groovy/src/main/groovy/lv/id/jc/sample/Sample.groovy b/sample-groovy/src/main/groovy/lv/id/jc/sample/Sample.groovy deleted file mode 100644 index 2c4a058..0000000 --- a/sample-groovy/src/main/groovy/lv/id/jc/sample/Sample.groovy +++ /dev/null @@ -1,43 +0,0 @@ -package lv.id.jc.sample - -import lv.id.jc.algorithm.graph.BreadthFirstSearch -import lv.id.jc.algorithm.graph.DijkstrasAlgorithm -import lv.id.jc.algorithm.graph.Graph - -def complexGraph = Graph.of([ - A: [B: 5, H: 2], - B: [A: 5, C: 7], - C: [B: 7, D: 3, G: 4], - D: [C: 20, E: 4], - E: [F: 5], - F: [G: 6], - G: [C: 4], - H: [G: 3] -]) - -def app = new SampleApp(complexGraph) - -app.printRoute('D', 'C'); -app.printRoute('A', 'G'); -app.printRoute('D', 'H'); - -class SampleApp { - final fastest = new DijkstrasAlgorithm(); - final shortest = new BreadthFirstSearch(); - final graph - - SampleApp(graph) { - this.graph = graph - } - - def printRoute(source, target) { - var routeOne = shortest.findPath(graph, source, target); - var routeTwo = fastest.findPath(graph, source, target); - - println """Find the path from $source to $target - - the shortest take ${graph.getDistance(routeOne)} min and the path is ${routeOne} - - the fastest take ${graph.getDistance(routeTwo)} min and the path is ${routeTwo} - """ - } - -} diff --git a/sample-java/build.gradle b/sample-java/build.gradle deleted file mode 100644 index 3fe74e7..0000000 --- a/sample-java/build.gradle +++ /dev/null @@ -1,24 +0,0 @@ -plugins { - id 'application' -} - -java { - sourceCompatibility = JavaVersion.VERSION_17 -} - -repositories { - mavenCentral() -} - -dependencies { - implementation project(':algorithm') -} - -application { - mainModule = 'lv.id.jc.sample' - mainClass = 'lv.id.jc.sample.GraphApp' -} - -run { - standardInput = System.in -} \ No newline at end of file diff --git a/sample-java/src/main/java/lv/id/jc/sample/GraphApp.java b/sample-java/src/main/java/lv/id/jc/sample/GraphApp.java deleted file mode 100644 index f0fbd40..0000000 --- a/sample-java/src/main/java/lv/id/jc/sample/GraphApp.java +++ /dev/null @@ -1,46 +0,0 @@ -package lv.id.jc.sample; - -import lv.id.jc.algorithm.graph.BreadthFirstSearch; -import lv.id.jc.algorithm.graph.DijkstrasAlgorithm; -import lv.id.jc.algorithm.graph.Graph; -import lv.id.jc.algorithm.graph.SearchAlgorithm; - -import java.util.Map; - -public class GraphApp { - private static final Graph graph = Graph.of(Map.of( - 'A', Map.of('B', 5, 'H', 2), - 'B', Map.of('A', 5, 'C', 7), - 'C', Map.of('B', 7, 'D', 3, 'G', 4), - 'D', Map.of('C', 20, 'E', 4), - 'E', Map.of('F', 5), - 'F', Map.of('G', 6), - 'G', Map.of('C', 4), - 'H', Map.of('G', 3) - )); - private static final SearchAlgorithm fastest = new DijkstrasAlgorithm<>(); - private static final SearchAlgorithm shortest = new BreadthFirstSearch<>(); - - public static void main(String[] args) { - printRoute('D', 'C'); - printRoute('A', 'G'); - printRoute('D', 'H'); - } - - @SuppressWarnings("squid:S106") - private static void printRoute(Character source, Character target) { - var routeOne = shortest.findPath(graph, source, target); - var routeTwo = fastest.findPath(graph, source, target); - var message = """ - - Find the path from %s to %s - - the shortest take %.0f min and the path is %s - - the fastest take %.0f min and the path is %s""" - .formatted( - source, target, - graph.getDistance(routeOne), routeOne, - graph.getDistance(routeTwo), routeTwo); - - System.out.println(message); - } -} diff --git a/sample-java/src/main/java/module-info.java b/sample-java/src/main/java/module-info.java deleted file mode 100644 index b69bc56..0000000 --- a/sample-java/src/main/java/module-info.java +++ /dev/null @@ -1,4 +0,0 @@ -module lv.id.jc.sample { - requires lv.id.jc.algorithm.graph; - exports lv.id.jc.sample; -} \ No newline at end of file diff --git a/settings.gradle b/settings.gradle deleted file mode 100644 index 2daba11..0000000 --- a/settings.gradle +++ /dev/null @@ -1,2 +0,0 @@ -rootProject.name = 'algorithms' -include 'algorithm', 'sample-java', 'sample-groovy', 'graph-shell'