rroonga 4.0.8-x64-mingw32 → 5.0.0-x64-mingw32
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +8 -8
 - data/README.md +2 -2
 - data/doc/text/news.textile +19 -0
 - data/ext/groonga/rb-grn-exception.c +35 -1
 - data/ext/groonga/rb-grn-normalizer.c +37 -7
 - data/ext/groonga/rb-grn-table.c +106 -35
 - data/ext/groonga/rb-grn.h +3 -2
 - data/lib/1.9/groonga.so +0 -0
 - data/lib/2.0/groonga.so +0 -0
 - data/lib/2.1/groonga.so +0 -0
 - data/lib/groonga/record.rb +45 -1
 - data/rroonga-build.rb +6 -5
 - data/test/groonga-test-utils.rb +9 -0
 - data/test/test-array.rb +11 -0
 - data/test/test-exception.rb +3 -1
 - data/test/test-normalizer.rb +28 -0
 - data/test/test-record.rb +34 -0
 - data/test/test-table-group.rb +366 -0
 - data/test/test-table.rb +0 -182
 - data/vendor/local/bin/grndb.exe +0 -0
 - data/vendor/local/bin/groonga-benchmark.exe +0 -0
 - data/vendor/local/bin/groonga.exe +0 -0
 - data/vendor/local/bin/libgcc_s_seh-1.dll +0 -0
 - data/vendor/local/bin/libgroonga-0.dll +0 -0
 - data/vendor/local/bin/libmecab-1.dll +0 -0
 - data/vendor/local/bin/libmsgpack-3.dll +0 -0
 - data/vendor/local/bin/libmsgpackc-2.dll +0 -0
 - data/vendor/local/bin/libonig-5.dll +0 -0
 - data/vendor/local/bin/libstdc++-6.dll +0 -0
 - data/vendor/local/bin/lz4.exe +0 -0
 - data/vendor/local/bin/lz4c.exe +0 -0
 - data/vendor/local/bin/lz4cat +0 -0
 - data/vendor/local/bin/mecab-config +2 -2
 - data/vendor/local/bin/mecab.exe +0 -0
 - data/vendor/local/bin/onig-config +1 -1
 - data/vendor/local/bin/zlib1.dll +0 -0
 - data/vendor/local/etc/groonga/httpd/groonga-httpd.conf +2 -2
 - data/vendor/local/include/groonga/groonga.h +2 -1
 - data/vendor/local/include/groonga/groonga/command.h +79 -0
 - data/vendor/local/include/groonga/groonga/groonga.h +32 -74
 - data/vendor/local/include/groonga/groonga/output.h +108 -0
 - data/vendor/local/include/groonga/groonga/plugin.h +18 -3
 - data/vendor/local/lib/groonga/plugins/query_expanders/tsv.a +0 -0
 - data/vendor/local/lib/groonga/plugins/query_expanders/tsv.dll +0 -0
 - data/vendor/local/lib/groonga/plugins/query_expanders/tsv.dll.a +0 -0
 - data/vendor/local/lib/groonga/plugins/query_expanders/tsv.la +3 -3
 - data/vendor/local/lib/groonga/plugins/ruby/eval.a +0 -0
 - data/vendor/local/lib/groonga/plugins/ruby/eval.dll +0 -0
 - data/vendor/local/lib/groonga/plugins/ruby/eval.dll.a +0 -0
 - data/vendor/local/lib/groonga/plugins/ruby/eval.la +3 -3
 - data/vendor/local/lib/groonga/plugins/ruby/load.a +0 -0
 - data/vendor/local/lib/groonga/plugins/ruby/load.dll +0 -0
 - data/vendor/local/lib/groonga/plugins/ruby/load.dll.a +0 -0
 - data/vendor/local/lib/groonga/plugins/ruby/load.la +3 -3
 - data/vendor/local/lib/groonga/plugins/sharding.rb +3 -0
 - data/vendor/local/lib/groonga/plugins/sharding/logical_count.rb +157 -0
 - data/vendor/local/lib/groonga/plugins/sharding/logical_enumerator.rb +170 -0
 - data/vendor/local/lib/groonga/plugins/sharding/logical_range_filter.rb +50 -0
 - data/vendor/local/lib/groonga/plugins/suggest/suggest.a +0 -0
 - data/vendor/local/lib/groonga/plugins/suggest/suggest.dll +0 -0
 - data/vendor/local/lib/groonga/plugins/suggest/suggest.dll.a +0 -0
 - data/vendor/local/lib/groonga/plugins/suggest/suggest.la +3 -3
 - data/vendor/local/lib/groonga/plugins/table/table.a +0 -0
 - data/vendor/local/lib/groonga/plugins/table/table.dll +0 -0
 - data/vendor/local/lib/groonga/plugins/table/table.dll.a +0 -0
 - data/vendor/local/lib/groonga/plugins/table/table.la +3 -3
 - data/vendor/local/lib/groonga/plugins/token_filters/stop_word.a +0 -0
 - data/vendor/local/lib/groonga/plugins/token_filters/stop_word.dll +0 -0
 - data/vendor/local/lib/groonga/plugins/token_filters/stop_word.dll.a +0 -0
 - data/vendor/local/lib/groonga/plugins/token_filters/stop_word.la +3 -3
 - data/vendor/local/lib/groonga/plugins/tokenizers/mecab.a +0 -0
 - data/vendor/local/lib/groonga/plugins/tokenizers/mecab.dll +0 -0
 - data/vendor/local/lib/groonga/plugins/tokenizers/mecab.dll.a +0 -0
 - data/vendor/local/lib/groonga/plugins/tokenizers/mecab.la +3 -3
 - data/vendor/local/lib/groonga/scripts/ruby/command.rb +35 -0
 - data/vendor/local/lib/groonga/scripts/ruby/{command → command_line}/grndb.rb +1 -1
 - data/vendor/local/lib/groonga/scripts/ruby/context.rb +29 -8
 - data/vendor/local/lib/groonga/scripts/ruby/context/rc.rb +166 -76
 - data/vendor/local/lib/groonga/scripts/ruby/database.rb +16 -4
 - data/vendor/local/lib/groonga/scripts/ruby/error.rb +16 -0
 - data/vendor/local/lib/groonga/scripts/ruby/index_cursor.rb +18 -0
 - data/vendor/local/lib/groonga/scripts/ruby/initialize/post.rb +10 -0
 - data/vendor/local/lib/groonga/scripts/ruby/logger.rb +5 -1
 - data/vendor/local/lib/groonga/scripts/ruby/plugin_loader.rb +14 -0
 - data/vendor/local/lib/groonga/scripts/ruby/require.rb +1 -1
 - data/vendor/local/lib/groonga/scripts/ruby/scan_info_builder.rb +3 -3
 - data/vendor/local/lib/groonga/scripts/ruby/scan_info_data.rb +4 -2
 - data/vendor/local/lib/groonga/scripts/ruby/table_cursor.rb +15 -0
 - data/vendor/local/lib/groonga/scripts/ruby/writer.rb +21 -0
 - data/vendor/local/lib/libgroonga.a +0 -0
 - data/vendor/local/lib/libgroonga.dll.a +0 -0
 - data/vendor/local/lib/libgroonga.la +3 -3
 - data/vendor/local/lib/liblz4.a +0 -0
 - data/vendor/local/lib/liblz4.dll +0 -0
 - data/vendor/local/lib/liblz4.dll.1 +0 -0
 - data/vendor/local/lib/liblz4.dll.1.5.0 +0 -0
 - data/vendor/local/lib/libmecab.a +0 -0
 - data/vendor/local/lib/libmecab.dll.a +0 -0
 - data/vendor/local/lib/libmecab.la +2 -2
 - data/vendor/local/lib/libmsgpack.a +0 -0
 - data/vendor/local/lib/libmsgpack.dll.a +0 -0
 - data/vendor/local/lib/libmsgpack.la +2 -2
 - data/vendor/local/lib/libmsgpackc.a +0 -0
 - data/vendor/local/lib/libmsgpackc.dll.a +0 -0
 - data/vendor/local/lib/libmsgpackc.la +2 -2
 - data/vendor/local/lib/libonig.a +0 -0
 - data/vendor/local/lib/libonig.dll.a +0 -0
 - data/vendor/local/lib/libonig.la +2 -2
 - data/vendor/local/lib/libz.a +0 -0
 - data/vendor/local/lib/libz.dll.a +0 -0
 - data/vendor/local/lib/pkgconfig/groonga.pc +3 -3
 - data/vendor/local/lib/pkgconfig/liblz4.pc +5 -5
 - data/vendor/local/lib/pkgconfig/msgpack.pc +1 -1
 - data/vendor/local/lib/pkgconfig/oniguruma.pc +6 -6
 - data/vendor/local/lib/pkgconfig/zlib.pc +3 -3
 - data/vendor/local/libexec/mecab/mecab-cost-train.exe +0 -0
 - data/vendor/local/libexec/mecab/mecab-dict-gen.exe +0 -0
 - data/vendor/local/libexec/mecab/mecab-dict-index.exe +0 -0
 - data/vendor/local/libexec/mecab/mecab-system-eval.exe +0 -0
 - data/vendor/local/libexec/mecab/mecab-test-gen.exe +0 -0
 - data/vendor/local/sbin/groonga-httpd-restart +1 -1
 - data/vendor/local/sbin/groonga-httpd.exe +0 -0
 - data/vendor/local/share/doc/groonga/en/html/.buildinfo +1 -1
 - data/vendor/local/share/doc/groonga/en/html/_sources/install/centos.txt +3 -3
 - data/vendor/local/share/doc/groonga/en/html/_sources/install/debian.txt +4 -4
 - data/vendor/local/share/doc/groonga/en/html/_sources/install/fedora.txt +3 -3
 - data/vendor/local/share/doc/groonga/en/html/_sources/install/mac_os_x.txt +5 -5
 - data/vendor/local/share/doc/groonga/en/html/_sources/install/others.txt +3 -3
 - data/vendor/local/share/doc/groonga/en/html/_sources/install/solaris.txt +3 -3
 - data/vendor/local/share/doc/groonga/en/html/_sources/install/ubuntu.txt +4 -4
 - data/vendor/local/share/doc/groonga/en/html/_sources/install/windows.txt +9 -9
 - data/vendor/local/share/doc/groonga/en/html/_sources/news.txt +16 -570
 - data/vendor/local/share/doc/groonga/en/html/_sources/news/2.x.txt +5 -4
 - data/vendor/local/share/doc/groonga/en/html/_sources/news/3.x.txt +1 -1
 - data/vendor/local/share/doc/groonga/en/html/_sources/news/4.x.txt +686 -0
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference.txt +0 -1
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/api/grn_ctx.txt +3 -1
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/column.txt +12 -4
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/columns/index.txt +19 -0
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/columns/pseudo.txt +2 -2
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/columns/scalar.txt +19 -0
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/commands/select.txt +734 -29
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/functions/html_untag.txt +2 -1
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/grn_expr/query_syntax.txt +8 -7
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/grn_expr/script_syntax.txt +50 -0
 - data/vendor/local/share/doc/groonga/en/html/_sources/reference/suggest/completion.txt +25 -23
 - data/vendor/local/share/doc/groonga/en/html/_sources/server/http.txt +1 -1
 - data/vendor/local/share/doc/groonga/en/html/_static/basic.css +68 -6
 - data/vendor/local/share/doc/groonga/en/html/_static/doctools.js +26 -1
 - data/vendor/local/share/doc/groonga/en/html/_static/down-pressed.png +0 -0
 - data/vendor/local/share/doc/groonga/en/html/_static/down.png +0 -0
 - data/vendor/local/share/doc/groonga/en/html/_static/file.png +0 -0
 - data/vendor/local/share/doc/groonga/en/html/_static/jquery-1.11.1.js +10308 -0
 - data/vendor/local/share/doc/groonga/en/html/_static/jquery.js +4 -2
 - data/vendor/local/share/doc/groonga/en/html/_static/minus.png +0 -0
 - data/vendor/local/share/doc/groonga/en/html/_static/plus.png +0 -0
 - data/vendor/local/share/doc/groonga/en/html/_static/searchtools.js +2 -2
 - data/vendor/local/share/doc/groonga/en/html/_static/underscore-1.3.1.js +999 -0
 - data/vendor/local/share/doc/groonga/en/html/_static/up-pressed.png +0 -0
 - data/vendor/local/share/doc/groonga/en/html/_static/up.png +0 -0
 - data/vendor/local/share/doc/groonga/en/html/_static/websupport.js +15 -15
 - data/vendor/local/share/doc/groonga/en/html/characteristic.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/client.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/community.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution.html +21 -19
 - data/vendor/local/share/doc/groonga/en/html/contribution/development.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/development/com.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/development/cooperation.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/development/query.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/development/release.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/development/repository.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/development/test.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/documentation.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/documentation/c-api.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/documentation/i18n.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/contribution/documentation/introduction.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/contribution/report.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/development.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/development/travis-ci.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/genindex.html +13 -13
 - data/vendor/local/share/doc/groonga/en/html/index.html +86 -78
 - data/vendor/local/share/doc/groonga/en/html/install.html +36 -34
 - data/vendor/local/share/doc/groonga/en/html/install/centos.html +31 -29
 - data/vendor/local/share/doc/groonga/en/html/install/debian.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/install/fedora.html +28 -26
 - data/vendor/local/share/doc/groonga/en/html/install/mac_os_x.html +33 -30
 - data/vendor/local/share/doc/groonga/en/html/install/others.html +90 -88
 - data/vendor/local/share/doc/groonga/en/html/install/solaris.html +25 -23
 - data/vendor/local/share/doc/groonga/en/html/install/ubuntu.html +28 -26
 - data/vendor/local/share/doc/groonga/en/html/install/windows.html +33 -31
 - data/vendor/local/share/doc/groonga/en/html/limitations.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/news.html +99 -641
 - data/vendor/local/share/doc/groonga/en/html/news/0.x.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/news/1.0.x.html +21 -19
 - data/vendor/local/share/doc/groonga/en/html/news/1.1.x.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/news/1.2.x.html +35 -33
 - data/vendor/local/share/doc/groonga/en/html/news/1.3.x.html +30 -28
 - data/vendor/local/share/doc/groonga/en/html/news/2.x.html +103 -100
 - data/vendor/local/share/doc/groonga/en/html/news/3.x.html +72 -70
 - data/vendor/local/share/doc/groonga/en/html/news/4.x.html +873 -0
 - data/vendor/local/share/doc/groonga/en/html/news/senna.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/objects.inv +0 -0
 - data/vendor/local/share/doc/groonga/en/html/reference.html +83 -75
 - data/vendor/local/share/doc/groonga/en/html/reference/api.html +40 -38
 - data/vendor/local/share/doc/groonga/en/html/reference/api/global_configurations.html +34 -32
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_cache.html +46 -44
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_column.html +68 -66
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_command_version.html +30 -28
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_content_type.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_ctx.html +66 -62
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_db.html +36 -34
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_encoding.html +31 -29
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_expr.html +67 -65
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_geo.html +29 -27
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_hook.html +32 -30
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_ii.html +30 -28
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_index_cursor.html +29 -27
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_info.html +29 -27
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_match_escalation.html +28 -26
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_obj.html +77 -75
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_proc.html +32 -30
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_search.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_table.html +63 -61
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_table_cursor.html +52 -50
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_type.html +28 -26
 - data/vendor/local/share/doc/groonga/en/html/reference/api/grn_user_data.html +25 -23
 - data/vendor/local/share/doc/groonga/en/html/reference/api/plugin.html +43 -41
 - data/vendor/local/share/doc/groonga/en/html/reference/cast.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/column.html +35 -33
 - data/vendor/local/share/doc/groonga/en/html/reference/columns/index.html +152 -0
 - data/vendor/local/share/doc/groonga/en/html/reference/columns/pseudo.html +56 -29
 - data/vendor/local/share/doc/groonga/en/html/reference/columns/scalar.html +152 -0
 - data/vendor/local/share/doc/groonga/en/html/reference/columns/vector.html +121 -94
 - data/vendor/local/share/doc/groonga/en/html/reference/command.html +55 -53
 - data/vendor/local/share/doc/groonga/en/html/reference/command/command_version.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/command/output_format.html +56 -54
 - data/vendor/local/share/doc/groonga/en/html/reference/command/request_id.html +25 -23
 - data/vendor/local/share/doc/groonga/en/html/reference/command/return_code.html +97 -95
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/cache_limit.html +41 -39
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/check.html +46 -44
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/clearlock.html +26 -24
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/column_create.html +42 -40
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/column_list.html +74 -72
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/column_remove.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/column_rename.html +44 -42
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/define_selector.html +40 -38
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/defrag.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/delete.html +36 -34
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/dump.html +25 -23
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/load.html +43 -41
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/lock_clear.html +34 -32
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/log_level.html +26 -24
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/log_put.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/log_reopen.html +25 -23
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/normalize.html +62 -60
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/normalizer_list.html +32 -30
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/quit.html +24 -22
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/range_filter.html +24 -22
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/register.html +37 -35
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/request_cancel.html +54 -52
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/ruby_eval.html +38 -36
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/ruby_load.html +38 -36
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/select.html +3069 -567
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/shutdown.html +24 -22
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/status.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/suggest.html +66 -64
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/table_create.html +123 -121
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/table_list.html +36 -34
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/table_remove.html +26 -24
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/table_tokenize.html +46 -44
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/tokenize.html +82 -80
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/tokenizer_list.html +32 -30
 - data/vendor/local/share/doc/groonga/en/html/reference/commands/truncate.html +39 -37
 - data/vendor/local/share/doc/groonga/en/html/reference/executables.html +22 -20
 - data/vendor/local/share/doc/groonga/en/html/reference/executables/grndb.html +38 -36
 - data/vendor/local/share/doc/groonga/en/html/reference/executables/grnslap.html +24 -22
 - data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-benchmark.html +29 -27
 - data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-httpd.html +76 -74
 - data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-server-http.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-suggest-create-dataset.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-suggest-httpd.html +45 -43
 - data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga-suggest-learner.html +37 -35
 - data/vendor/local/share/doc/groonga/en/html/reference/executables/groonga.html +58 -56
 - data/vendor/local/share/doc/groonga/en/html/reference/function.html +21 -19
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/between.html +43 -41
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/edit_distance.html +22 -20
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/geo_distance.html +82 -80
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/geo_in_circle.html +33 -31
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/geo_in_rectangle.html +23 -21
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/highlight_full.html +54 -52
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/highlight_html.html +42 -40
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/html_untag.html +32 -29
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/in_values.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/now.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/query.html +49 -47
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/rand.html +21 -19
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/snippet_html.html +45 -43
 - data/vendor/local/share/doc/groonga/en/html/reference/functions/sub_filter.html +42 -40
 - data/vendor/local/share/doc/groonga/en/html/reference/grn_expr.html +27 -25
 - data/vendor/local/share/doc/groonga/en/html/reference/grn_expr/query_syntax.html +219 -216
 - data/vendor/local/share/doc/groonga/en/html/reference/grn_expr/script_syntax.html +430 -381
 - data/vendor/local/share/doc/groonga/en/html/reference/indexing.html +22 -20
 - data/vendor/local/share/doc/groonga/en/html/reference/log.html +23 -21
 - data/vendor/local/share/doc/groonga/en/html/reference/normalizers.html +52 -50
 - data/vendor/local/share/doc/groonga/en/html/reference/operations.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/operations/geolocation_search.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/output.html +35 -33
 - data/vendor/local/share/doc/groonga/en/html/reference/query_expanders.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/query_expanders/tsv.html +58 -56
 - data/vendor/local/share/doc/groonga/en/html/reference/suggest.html +21 -19
 - data/vendor/local/share/doc/groonga/en/html/reference/suggest/completion.html +46 -41
 - data/vendor/local/share/doc/groonga/en/html/reference/suggest/correction.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/suggest/introduction.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/suggest/suggestion.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/tables.html +55 -53
 - data/vendor/local/share/doc/groonga/en/html/reference/token_filters.html +39 -37
 - data/vendor/local/share/doc/groonga/en/html/reference/tokenizers.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/reference/tuning.html +30 -28
 - data/vendor/local/share/doc/groonga/en/html/reference/types.html +38 -36
 - data/vendor/local/share/doc/groonga/en/html/search.html +12 -12
 - data/vendor/local/share/doc/groonga/en/html/searchindex.js +1 -1
 - data/vendor/local/share/doc/groonga/en/html/server.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/server/gqtp.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/server/http.html +21 -19
 - data/vendor/local/share/doc/groonga/en/html/server/http/comparison.html +34 -32
 - data/vendor/local/share/doc/groonga/en/html/server/http/groonga-httpd.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/server/http/groonga.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/server/package.html +34 -32
 - data/vendor/local/share/doc/groonga/en/html/spec.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/spec/gqtp.html +128 -126
 - data/vendor/local/share/doc/groonga/en/html/spec/search.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/troubleshooting.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/troubleshooting/different_results_with_the_same_keyword.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/troubleshooting/mmap_cannot_allocate_memory.html +21 -19
 - data/vendor/local/share/doc/groonga/en/html/tutorial.html +21 -19
 - data/vendor/local/share/doc/groonga/en/html/tutorial/data.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/tutorial/drilldown.html +34 -32
 - data/vendor/local/share/doc/groonga/en/html/tutorial/index.html +23 -21
 - data/vendor/local/share/doc/groonga/en/html/tutorial/introduction.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/tutorial/lexicon.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/tutorial/match_columns.html +24 -22
 - data/vendor/local/share/doc/groonga/en/html/tutorial/micro_blog.html +53 -51
 - data/vendor/local/share/doc/groonga/en/html/tutorial/network.html +20 -18
 - data/vendor/local/share/doc/groonga/en/html/tutorial/patricia_trie.html +21 -19
 - data/vendor/local/share/doc/groonga/en/html/tutorial/query_expansion.html +23 -21
 - data/vendor/local/share/doc/groonga/en/html/tutorial/search.html +37 -35
 - data/vendor/local/share/doc/groonga/ja/html/.buildinfo +1 -1
 - data/vendor/local/share/doc/groonga/ja/html/_sources/install/centos.txt +3 -3
 - data/vendor/local/share/doc/groonga/ja/html/_sources/install/debian.txt +4 -4
 - data/vendor/local/share/doc/groonga/ja/html/_sources/install/fedora.txt +3 -3
 - data/vendor/local/share/doc/groonga/ja/html/_sources/install/mac_os_x.txt +5 -5
 - data/vendor/local/share/doc/groonga/ja/html/_sources/install/others.txt +3 -3
 - data/vendor/local/share/doc/groonga/ja/html/_sources/install/solaris.txt +3 -3
 - data/vendor/local/share/doc/groonga/ja/html/_sources/install/ubuntu.txt +4 -4
 - data/vendor/local/share/doc/groonga/ja/html/_sources/install/windows.txt +9 -9
 - data/vendor/local/share/doc/groonga/ja/html/_sources/news.txt +16 -570
 - data/vendor/local/share/doc/groonga/ja/html/_sources/news/2.x.txt +5 -4
 - data/vendor/local/share/doc/groonga/ja/html/_sources/news/3.x.txt +1 -1
 - data/vendor/local/share/doc/groonga/ja/html/_sources/news/4.x.txt +686 -0
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference.txt +0 -1
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/api/grn_ctx.txt +3 -1
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/column.txt +12 -4
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/columns/index.txt +19 -0
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/columns/pseudo.txt +2 -2
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/columns/scalar.txt +19 -0
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/commands/select.txt +734 -29
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/functions/html_untag.txt +2 -1
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/grn_expr/query_syntax.txt +8 -7
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/grn_expr/script_syntax.txt +50 -0
 - data/vendor/local/share/doc/groonga/ja/html/_sources/reference/suggest/completion.txt +25 -23
 - data/vendor/local/share/doc/groonga/ja/html/_sources/server/http.txt +1 -1
 - data/vendor/local/share/doc/groonga/ja/html/_static/basic.css +68 -6
 - data/vendor/local/share/doc/groonga/ja/html/_static/doctools.js +26 -1
 - data/vendor/local/share/doc/groonga/ja/html/_static/down-pressed.png +0 -0
 - data/vendor/local/share/doc/groonga/ja/html/_static/down.png +0 -0
 - data/vendor/local/share/doc/groonga/ja/html/_static/file.png +0 -0
 - data/vendor/local/share/doc/groonga/ja/html/_static/jquery-1.11.1.js +10308 -0
 - data/vendor/local/share/doc/groonga/ja/html/_static/jquery.js +4 -2
 - data/vendor/local/share/doc/groonga/ja/html/_static/minus.png +0 -0
 - data/vendor/local/share/doc/groonga/ja/html/_static/plus.png +0 -0
 - data/vendor/local/share/doc/groonga/ja/html/_static/searchtools.js +2 -2
 - data/vendor/local/share/doc/groonga/ja/html/_static/underscore-1.3.1.js +999 -0
 - data/vendor/local/share/doc/groonga/ja/html/_static/up-pressed.png +0 -0
 - data/vendor/local/share/doc/groonga/ja/html/_static/up.png +0 -0
 - data/vendor/local/share/doc/groonga/ja/html/_static/websupport.js +15 -15
 - data/vendor/local/share/doc/groonga/ja/html/characteristic.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/client.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/community.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/contribution.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/contribution/development.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/contribution/development/com.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/contribution/development/cooperation.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/contribution/development/query.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/contribution/development/release.html +23 -21
 - data/vendor/local/share/doc/groonga/ja/html/contribution/development/repository.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/contribution/development/test.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/contribution/documentation.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/contribution/documentation/c-api.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/contribution/documentation/i18n.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/contribution/documentation/introduction.html +27 -25
 - data/vendor/local/share/doc/groonga/ja/html/contribution/report.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/development.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/development/travis-ci.html +23 -21
 - data/vendor/local/share/doc/groonga/ja/html/genindex.html +17 -17
 - data/vendor/local/share/doc/groonga/ja/html/index.html +88 -80
 - data/vendor/local/share/doc/groonga/ja/html/install.html +36 -34
 - data/vendor/local/share/doc/groonga/ja/html/install/centos.html +40 -38
 - data/vendor/local/share/doc/groonga/ja/html/install/debian.html +30 -29
 - data/vendor/local/share/doc/groonga/ja/html/install/fedora.html +31 -29
 - data/vendor/local/share/doc/groonga/ja/html/install/mac_os_x.html +31 -29
 - data/vendor/local/share/doc/groonga/ja/html/install/others.html +81 -79
 - data/vendor/local/share/doc/groonga/ja/html/install/solaris.html +24 -22
 - data/vendor/local/share/doc/groonga/ja/html/install/ubuntu.html +31 -30
 - data/vendor/local/share/doc/groonga/ja/html/install/windows.html +32 -30
 - data/vendor/local/share/doc/groonga/ja/html/limitations.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/news.html +85 -677
 - data/vendor/local/share/doc/groonga/ja/html/news/0.x.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/news/1.0.x.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/news/1.1.x.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/news/1.2.x.html +36 -34
 - data/vendor/local/share/doc/groonga/ja/html/news/1.3.x.html +30 -28
 - data/vendor/local/share/doc/groonga/ja/html/news/2.x.html +94 -92
 - data/vendor/local/share/doc/groonga/ja/html/news/3.x.html +62 -60
 - data/vendor/local/share/doc/groonga/ja/html/news/4.x.html +911 -0
 - data/vendor/local/share/doc/groonga/ja/html/news/senna.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/objects.inv +0 -0
 - data/vendor/local/share/doc/groonga/ja/html/reference.html +85 -77
 - data/vendor/local/share/doc/groonga/ja/html/reference/api.html +40 -38
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/global_configurations.html +34 -32
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_cache.html +42 -40
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_column.html +70 -68
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_command_version.html +30 -28
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_content_type.html +27 -25
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_ctx.html +62 -60
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_db.html +42 -40
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_encoding.html +31 -29
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_expr.html +62 -60
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_geo.html +29 -27
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_hook.html +32 -30
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_ii.html +30 -28
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_index_cursor.html +29 -27
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_info.html +29 -27
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_match_escalation.html +28 -26
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_obj.html +78 -76
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_proc.html +32 -30
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_search.html +27 -25
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_table.html +63 -61
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_table_cursor.html +52 -50
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_type.html +28 -26
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/grn_user_data.html +25 -23
 - data/vendor/local/share/doc/groonga/ja/html/reference/api/plugin.html +43 -41
 - data/vendor/local/share/doc/groonga/ja/html/reference/cast.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/column.html +35 -33
 - data/vendor/local/share/doc/groonga/ja/html/reference/columns/index.html +153 -0
 - data/vendor/local/share/doc/groonga/ja/html/reference/columns/pseudo.html +56 -29
 - data/vendor/local/share/doc/groonga/ja/html/reference/columns/scalar.html +153 -0
 - data/vendor/local/share/doc/groonga/ja/html/reference/columns/vector.html +111 -84
 - data/vendor/local/share/doc/groonga/ja/html/reference/command.html +56 -54
 - data/vendor/local/share/doc/groonga/ja/html/reference/command/command_version.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/command/output_format.html +50 -48
 - data/vendor/local/share/doc/groonga/ja/html/reference/command/request_id.html +27 -25
 - data/vendor/local/share/doc/groonga/ja/html/reference/command/return_code.html +100 -98
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/cache_limit.html +38 -36
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/check.html +46 -44
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/clearlock.html +26 -24
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_create.html +42 -40
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_list.html +66 -64
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_remove.html +27 -25
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/column_rename.html +41 -39
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/define_selector.html +40 -38
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/defrag.html +27 -25
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/delete.html +35 -33
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/dump.html +25 -23
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/load.html +36 -34
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/lock_clear.html +38 -37
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/log_level.html +26 -24
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/log_put.html +27 -25
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/log_reopen.html +25 -23
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/normalize.html +57 -55
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/normalizer_list.html +32 -30
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/quit.html +24 -22
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/range_filter.html +24 -22
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/register.html +34 -32
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/request_cancel.html +59 -57
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/ruby_eval.html +38 -36
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/ruby_load.html +38 -36
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/select.html +2832 -427
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/shutdown.html +24 -22
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/status.html +25 -23
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/suggest.html +64 -62
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_create.html +99 -97
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_list.html +36 -34
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_remove.html +26 -24
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/table_tokenize.html +41 -39
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/tokenize.html +67 -65
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/tokenizer_list.html +32 -30
 - data/vendor/local/share/doc/groonga/ja/html/reference/commands/truncate.html +40 -39
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables.html +22 -20
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables/grndb.html +50 -45
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables/grnslap.html +24 -22
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-benchmark.html +29 -27
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-httpd.html +64 -62
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-server-http.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-suggest-create-dataset.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-suggest-httpd.html +45 -43
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga-suggest-learner.html +37 -35
 - data/vendor/local/share/doc/groonga/ja/html/reference/executables/groonga.html +58 -56
 - data/vendor/local/share/doc/groonga/ja/html/reference/function.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/between.html +43 -41
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/edit_distance.html +22 -20
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/geo_distance.html +70 -68
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/geo_in_circle.html +33 -31
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/geo_in_rectangle.html +23 -21
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/highlight_full.html +44 -42
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/highlight_html.html +33 -31
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/html_untag.html +31 -29
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/in_values.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/now.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/query.html +42 -40
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/rand.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/snippet_html.html +31 -29
 - data/vendor/local/share/doc/groonga/ja/html/reference/functions/sub_filter.html +34 -32
 - data/vendor/local/share/doc/groonga/ja/html/reference/grn_expr.html +24 -22
 - data/vendor/local/share/doc/groonga/ja/html/reference/grn_expr/query_syntax.html +119 -117
 - data/vendor/local/share/doc/groonga/ja/html/reference/grn_expr/script_syntax.html +341 -301
 - data/vendor/local/share/doc/groonga/ja/html/reference/indexing.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/reference/log.html +23 -21
 - data/vendor/local/share/doc/groonga/ja/html/reference/normalizers.html +46 -44
 - data/vendor/local/share/doc/groonga/ja/html/reference/operations.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/operations/geolocation_search.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/output.html +31 -29
 - data/vendor/local/share/doc/groonga/ja/html/reference/query_expanders.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/query_expanders/tsv.html +37 -35
 - data/vendor/local/share/doc/groonga/ja/html/reference/suggest.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/reference/suggest/completion.html +35 -43
 - data/vendor/local/share/doc/groonga/ja/html/reference/suggest/correction.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/suggest/introduction.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/suggest/suggestion.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/tables.html +45 -43
 - data/vendor/local/share/doc/groonga/ja/html/reference/token_filters.html +36 -34
 - data/vendor/local/share/doc/groonga/ja/html/reference/tokenizers.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/reference/tuning.html +30 -28
 - data/vendor/local/share/doc/groonga/ja/html/reference/types.html +38 -36
 - data/vendor/local/share/doc/groonga/ja/html/search.html +12 -12
 - data/vendor/local/share/doc/groonga/ja/html/searchindex.js +1 -1
 - data/vendor/local/share/doc/groonga/ja/html/server.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/server/gqtp.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/server/http.html +22 -20
 - data/vendor/local/share/doc/groonga/ja/html/server/http/comparison.html +28 -26
 - data/vendor/local/share/doc/groonga/ja/html/server/http/groonga-httpd.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/server/http/groonga.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/server/package.html +35 -33
 - data/vendor/local/share/doc/groonga/ja/html/spec.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/spec/gqtp.html +127 -125
 - data/vendor/local/share/doc/groonga/ja/html/spec/search.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/troubleshooting.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/troubleshooting/different_results_with_the_same_keyword.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/troubleshooting/mmap_cannot_allocate_memory.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/tutorial.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/data.html +25 -23
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/drilldown.html +33 -31
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/index.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/introduction.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/lexicon.html +20 -18
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/match_columns.html +27 -25
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/micro_blog.html +50 -48
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/network.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/patricia_trie.html +21 -19
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/query_expansion.html +23 -21
 - data/vendor/local/share/doc/groonga/ja/html/tutorial/search.html +35 -33
 - data/vendor/local/share/man/ja/man1/groonga.1 +6711 -3135
 - data/vendor/local/share/man/man1/groonga.1 +7192 -3297
 - metadata +33 -4
 
    
        data/rroonga-build.rb
    CHANGED
    
    | 
         @@ -1,5 +1,6 @@ 
     | 
|
| 
       1 
1 
     | 
    
         
             
            #!/usr/bin/env ruby
         
     | 
| 
       2 
2 
     | 
    
         
             
            #
         
     | 
| 
      
 3 
     | 
    
         
            +
            # Copyright (C) 2015  Masafumi Yokoyama <yokoyama@clear-code.com>
         
     | 
| 
       3 
4 
     | 
    
         
             
            # Copyright (C) 2009-2014  Kouhei Sutou <kou@clear-code.com>
         
     | 
| 
       4 
5 
     | 
    
         
             
            #
         
     | 
| 
       5 
6 
     | 
    
         
             
            # This library is free software; you can redistribute it and/or
         
     | 
| 
         @@ -17,17 +18,17 @@ 
     | 
|
| 
       17 
18 
     | 
    
         | 
| 
       18 
19 
     | 
    
         
             
            module RroongaBuild
         
     | 
| 
       19 
20 
     | 
    
         
             
              module RequiredGroongaVersion
         
     | 
| 
       20 
     | 
    
         
            -
                MAJOR =  
     | 
| 
      
 21 
     | 
    
         
            +
                MAJOR = 5
         
     | 
| 
       21 
22 
     | 
    
         
             
                MINOR = 0
         
     | 
| 
       22 
     | 
    
         
            -
                MICRO =  
     | 
| 
      
 23 
     | 
    
         
            +
                MICRO = 0
         
     | 
| 
       23 
24 
     | 
    
         
             
                VERSION = [MAJOR, MINOR, MICRO]
         
     | 
| 
       24 
     | 
    
         
            -
                RELEASED_DATE = Time.utc( 
     | 
| 
      
 25 
     | 
    
         
            +
                RELEASED_DATE = Time.utc(2015, 2, 9)
         
     | 
| 
       25 
26 
     | 
    
         
             
              end
         
     | 
| 
       26 
27 
     | 
    
         | 
| 
       27 
28 
     | 
    
         
             
              module LatestGroongaVersion
         
     | 
| 
       28 
     | 
    
         
            -
                MAJOR =  
     | 
| 
      
 29 
     | 
    
         
            +
                MAJOR = 5
         
     | 
| 
       29 
30 
     | 
    
         
             
                MINOR = 0
         
     | 
| 
       30 
     | 
    
         
            -
                MICRO =  
     | 
| 
      
 31 
     | 
    
         
            +
                MICRO = 0
         
     | 
| 
       31 
32 
     | 
    
         
             
                VERSION = [MAJOR, MINOR, MICRO]
         
     | 
| 
       32 
33 
     | 
    
         
             
              end
         
     | 
| 
       33 
34 
     | 
    
         | 
    
        data/test/groonga-test-utils.rb
    CHANGED
    
    | 
         @@ -1,3 +1,4 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            # Copyright (C) 2015  Masafumi Yokoyama <yokoyama@clear-code.com>
         
     | 
| 
       1 
2 
     | 
    
         
             
            # Copyright (C) 2009-2014  Kouhei Sutou <kou@clear-code.com>
         
     | 
| 
       2 
3 
     | 
    
         
             
            #
         
     | 
| 
       3 
4 
     | 
    
         
             
            # This library is free software; you can redistribute it and/or
         
     | 
| 
         @@ -165,6 +166,14 @@ module GroongaTestUtils 
     | 
|
| 
       165 
166 
     | 
    
         
             
                omit("Ruby 1.9 is needed.") unless ruby19?
         
     | 
| 
       166 
167 
     | 
    
         
             
              end
         
     | 
| 
       167 
168 
     | 
    
         | 
| 
      
 169 
     | 
    
         
            +
              def linux?
         
     | 
| 
      
 170 
     | 
    
         
            +
                /linux/ =~ RUBY_PLATFORM
         
     | 
| 
      
 171 
     | 
    
         
            +
              end
         
     | 
| 
      
 172 
     | 
    
         
            +
             
     | 
| 
      
 173 
     | 
    
         
            +
              def only_linux
         
     | 
| 
      
 174 
     | 
    
         
            +
                omit("This test is only for Linux system.") unless linux?
         
     | 
| 
      
 175 
     | 
    
         
            +
              end
         
     | 
| 
      
 176 
     | 
    
         
            +
             
     | 
| 
       168 
177 
     | 
    
         
             
              def support_self_recursive_equal?
         
     | 
| 
       169 
178 
     | 
    
         
             
                self_recursive_hash1 = {}
         
     | 
| 
       170 
179 
     | 
    
         
             
                self_recursive_hash1["next"] = self_recursive_hash1
         
     | 
    
        data/test/test-array.rb
    CHANGED
    
    | 
         @@ -242,6 +242,17 @@ EXPECTED_OUTPUT 
     | 
|
| 
       242 
242 
     | 
    
         
             
            $stdout.sync = true
         
     | 
| 
       243 
243 
     | 
    
         | 
| 
       244 
244 
     | 
    
         
             
            base_dir = #{base_dir.dump}
         
     | 
| 
      
 245 
     | 
    
         
            +
             
     | 
| 
      
 246 
     | 
    
         
            +
            groonga_command_dir = File.join(base_dir, "..", "groonga-command")
         
     | 
| 
      
 247 
     | 
    
         
            +
            if File.exist?(groonga_command_dir)
         
     | 
| 
      
 248 
     | 
    
         
            +
              $LOAD_PATH.unshift(File.join(groonga_command_dir, "lib"))
         
     | 
| 
      
 249 
     | 
    
         
            +
            end
         
     | 
| 
      
 250 
     | 
    
         
            +
             
     | 
| 
      
 251 
     | 
    
         
            +
            groonga_client_dir = File.join(base_dir, "..", "groonga-client")
         
     | 
| 
      
 252 
     | 
    
         
            +
            if File.exist?(groonga_client_dir)
         
     | 
| 
      
 253 
     | 
    
         
            +
              $LOAD_PATH.unshift(File.join(groonga_client_dir, "lib"))
         
     | 
| 
      
 254 
     | 
    
         
            +
            end
         
     | 
| 
      
 255 
     | 
    
         
            +
             
     | 
| 
       245 
256 
     | 
    
         
             
            ext_dir = File.join(base_dir, "ext", "groonga")
         
     | 
| 
       246 
257 
     | 
    
         
             
            lib_dir = File.join(base_dir, "lib")
         
     | 
| 
       247 
258 
     | 
    
         | 
    
        data/test/test-exception.rb
    CHANGED
    
    | 
         @@ -1,5 +1,5 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            # Copyright (C) 2014-2015  Masafumi Yokoyama <yokoyama@clear-code.com>
         
     | 
| 
       1 
2 
     | 
    
         
             
            # Copyright (C) 2009-2014  Kouhei Sutou <kou@clear-code.com>
         
     | 
| 
       2 
     | 
    
         
            -
            # Copyright (C) 2014  Masafumi Yokoyama <myokoym@gmail.com>
         
     | 
| 
       3 
3 
     | 
    
         
             
            #
         
     | 
| 
       4 
4 
     | 
    
         
             
            # This library is free software; you can redistribute it and/or
         
     | 
| 
       5 
5 
     | 
    
         
             
            # modify it under the terms of the GNU Lesser General Public
         
     | 
| 
         @@ -97,6 +97,8 @@ class ExceptionTest < Test::Unit::TestCase 
     | 
|
| 
       97 
97 
     | 
    
         
             
                assert_const_defined(Groonga, :UnsupportedCommandVersion)
         
     | 
| 
       98 
98 
     | 
    
         
             
                assert_const_defined(Groonga, :NormalizerError)
         
     | 
| 
       99 
99 
     | 
    
         
             
                assert_const_defined(Groonga, :TokenFilterError)
         
     | 
| 
      
 100 
     | 
    
         
            +
                assert_const_defined(Groonga, :CommandError)
         
     | 
| 
      
 101 
     | 
    
         
            +
                assert_const_defined(Groonga, :PluginError)
         
     | 
| 
       100 
102 
     | 
    
         
             
              end
         
     | 
| 
       101 
103 
     | 
    
         
             
            end
         
     | 
| 
       102 
104 
     | 
    
         | 
    
        data/test/test-normalizer.rb
    CHANGED
    
    | 
         @@ -1,3 +1,5 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            # -*- coding: utf-8 -*-
         
     | 
| 
      
 2 
     | 
    
         
            +
            #
         
     | 
| 
       1 
3 
     | 
    
         
             
            # Copyright (C) 2012  Kouhei Sutou <kou@clear-code.com>
         
     | 
| 
       2 
4 
     | 
    
         
             
            #
         
     | 
| 
       3 
5 
     | 
    
         
             
            # This library is free software; you can redistribute it and/or
         
     | 
| 
         @@ -21,4 +23,30 @@ class NormalizerTest < Test::Unit::TestCase 
     | 
|
| 
       21 
23 
     | 
    
         
             
              def test_normalize
         
     | 
| 
       22 
24 
     | 
    
         
             
                assert_equal("abc", Groonga::Normalizer.normalize("AbC"))
         
     | 
| 
       23 
25 
     | 
    
         
             
              end
         
     | 
| 
      
 26 
     | 
    
         
            +
             
     | 
| 
      
 27 
     | 
    
         
            +
              def test_normalize_with_space
         
     | 
| 
      
 28 
     | 
    
         
            +
                assert_equal("abcdefgh", Groonga::Normalizer.normalize("AbC Def gh"))
         
     | 
| 
      
 29 
     | 
    
         
            +
              end
         
     | 
| 
      
 30 
     | 
    
         
            +
             
     | 
| 
      
 31 
     | 
    
         
            +
              def test_normalize_with_space_explicitly
         
     | 
| 
      
 32 
     | 
    
         
            +
                assert_equal("abcdefgh",
         
     | 
| 
      
 33 
     | 
    
         
            +
                             Groonga::Normalizer.normalize("AbC Def gh",
         
     | 
| 
      
 34 
     | 
    
         
            +
                                                           :remove_blank => true))
         
     | 
| 
      
 35 
     | 
    
         
            +
              end
         
     | 
| 
      
 36 
     | 
    
         
            +
             
     | 
| 
      
 37 
     | 
    
         
            +
              def test_normalize_group_text
         
     | 
| 
      
 38 
     | 
    
         
            +
                assert_equal("キロメートルキロメートルキロメートルキロメートル",
         
     | 
| 
      
 39 
     | 
    
         
            +
                             Groonga::Normalizer.normalize("㌖㌖㌖㌖"));
         
     | 
| 
      
 40 
     | 
    
         
            +
              end
         
     | 
| 
      
 41 
     | 
    
         
            +
             
     | 
| 
      
 42 
     | 
    
         
            +
              def test_normalize_keep_space
         
     | 
| 
      
 43 
     | 
    
         
            +
                # full width space => half width space
         
     | 
| 
      
 44 
     | 
    
         
            +
                assert_equal("abc def gh",
         
     | 
| 
      
 45 
     | 
    
         
            +
                             Groonga::Normalizer.normalize("AbC Def gh",
         
     | 
| 
      
 46 
     | 
    
         
            +
                                                           :remove_blank => false))
         
     | 
| 
      
 47 
     | 
    
         
            +
              end
         
     | 
| 
      
 48 
     | 
    
         
            +
             
     | 
| 
      
 49 
     | 
    
         
            +
              def test_normalize_tilda
         
     | 
| 
      
 50 
     | 
    
         
            +
                assert_equal("~~~", Groonga::Normalizer.normalize("~~〜"))
         
     | 
| 
      
 51 
     | 
    
         
            +
              end
         
     | 
| 
       24 
52 
     | 
    
         
             
            end
         
     | 
    
        data/test/test-record.rb
    CHANGED
    
    | 
         @@ -619,6 +619,11 @@ class RecordTest < Test::Unit::TestCase 
     | 
|
| 
       619 
619 
     | 
    
         
             
                def setup
         
     | 
| 
       620 
620 
     | 
    
         
             
                  setup_database
         
     | 
| 
       621 
621 
     | 
    
         
             
                  setup_schema
         
     | 
| 
      
 622 
     | 
    
         
            +
                  setup_tz
         
     | 
| 
      
 623 
     | 
    
         
            +
                end
         
     | 
| 
      
 624 
     | 
    
         
            +
             
     | 
| 
      
 625 
     | 
    
         
            +
                def teardown
         
     | 
| 
      
 626 
     | 
    
         
            +
                  teardown_tz
         
     | 
| 
       622 
627 
     | 
    
         
             
                end
         
     | 
| 
       623 
628 
     | 
    
         | 
| 
       624 
629 
     | 
    
         
             
                def setup_schema
         
     | 
| 
         @@ -633,6 +638,14 @@ class RecordTest < Test::Unit::TestCase 
     | 
|
| 
       633 
638 
     | 
    
         
             
                  @bookmarks = Groonga["Bookmarks"]
         
     | 
| 
       634 
639 
     | 
    
         
             
                end
         
     | 
| 
       635 
640 
     | 
    
         | 
| 
      
 641 
     | 
    
         
            +
                def setup_tz
         
     | 
| 
      
 642 
     | 
    
         
            +
                  @tz_original = ENV["TZ"]
         
     | 
| 
      
 643 
     | 
    
         
            +
                end
         
     | 
| 
      
 644 
     | 
    
         
            +
             
     | 
| 
      
 645 
     | 
    
         
            +
                def teardown_tz
         
     | 
| 
      
 646 
     | 
    
         
            +
                  ENV["TZ"] = @tz_original
         
     | 
| 
      
 647 
     | 
    
         
            +
                end
         
     | 
| 
      
 648 
     | 
    
         
            +
             
     | 
| 
       636 
649 
     | 
    
         
             
                def test_to_json
         
     | 
| 
       637 
650 
     | 
    
         
             
                  ENV["TZ"] = "Japan"
         
     | 
| 
       638 
651 
     | 
    
         
             
                  created_at = Time.parse("2013-05-16T16:57:34+09:00")
         
     | 
| 
         @@ -652,5 +665,26 @@ class RecordTest < Test::Unit::TestCase 
     | 
|
| 
       652 
665 
     | 
    
         
             
                  }.to_json
         
     | 
| 
       653 
666 
     | 
    
         
             
                  assert_equal(expected, groonga.to_json)
         
     | 
| 
       654 
667 
     | 
    
         
             
                end
         
     | 
| 
      
 668 
     | 
    
         
            +
             
     | 
| 
      
 669 
     | 
    
         
            +
                def test_to_json_with_leap_second
         
     | 
| 
      
 670 
     | 
    
         
            +
                  only_linux
         
     | 
| 
      
 671 
     | 
    
         
            +
                  ENV["TZ"] = "right/Japan"
         
     | 
| 
      
 672 
     | 
    
         
            +
                  created_at = Time.parse("2012-07-01T08:59:60+09:00")
         
     | 
| 
      
 673 
     | 
    
         
            +
                  values = {
         
     | 
| 
      
 674 
     | 
    
         
            +
                    "uri"        => "http://groonga.org/",
         
     | 
| 
      
 675 
     | 
    
         
            +
                    "rate"       => 5,
         
     | 
| 
      
 676 
     | 
    
         
            +
                    "comment"    => "Great!",
         
     | 
| 
      
 677 
     | 
    
         
            +
                    "created_at" => created_at,
         
     | 
| 
      
 678 
     | 
    
         
            +
                  }
         
     | 
| 
      
 679 
     | 
    
         
            +
                  groonga = @bookmarks.add(values)
         
     | 
| 
      
 680 
     | 
    
         
            +
                  expected = {
         
     | 
| 
      
 681 
     | 
    
         
            +
                    "_id"        => groonga.id,
         
     | 
| 
      
 682 
     | 
    
         
            +
                    "comment"    => values["comment"],
         
     | 
| 
      
 683 
     | 
    
         
            +
                    "created_at" => created_at.iso8601,
         
     | 
| 
      
 684 
     | 
    
         
            +
                    "rate"       => values["rate"],
         
     | 
| 
      
 685 
     | 
    
         
            +
                    "uri"        => values["uri"],
         
     | 
| 
      
 686 
     | 
    
         
            +
                  }.to_json
         
     | 
| 
      
 687 
     | 
    
         
            +
                  assert_equal(expected, groonga.to_json)
         
     | 
| 
      
 688 
     | 
    
         
            +
                end
         
     | 
| 
       655 
689 
     | 
    
         
             
              end
         
     | 
| 
       656 
690 
     | 
    
         
             
            end
         
     | 
| 
         @@ -0,0 +1,366 @@ 
     | 
|
| 
      
 1 
     | 
    
         
            +
            # Copyright (C) 2015  Masafumi Yokoyama <yokoyama@clear-code.com>
         
     | 
| 
      
 2 
     | 
    
         
            +
            # Copyright (C) 2009-2013  Kouhei Sutou <kou@clear-code.com>
         
     | 
| 
      
 3 
     | 
    
         
            +
            #
         
     | 
| 
      
 4 
     | 
    
         
            +
            # This library is free software; you can redistribute it and/or
         
     | 
| 
      
 5 
     | 
    
         
            +
            # modify it under the terms of the GNU Lesser General Public
         
     | 
| 
      
 6 
     | 
    
         
            +
            # License version 2.1 as published by the Free Software Foundation.
         
     | 
| 
      
 7 
     | 
    
         
            +
            #
         
     | 
| 
      
 8 
     | 
    
         
            +
            # This library is distributed in the hope that it will be useful,
         
     | 
| 
      
 9 
     | 
    
         
            +
            # but WITHOUT ANY WARRANTY; without even the implied warranty of
         
     | 
| 
      
 10 
     | 
    
         
            +
            # MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
         
     | 
| 
      
 11 
     | 
    
         
            +
            # Lesser General Public License for more details.
         
     | 
| 
      
 12 
     | 
    
         
            +
            #
         
     | 
| 
      
 13 
     | 
    
         
            +
            # You should have received a copy of the GNU Lesser General Public
         
     | 
| 
      
 14 
     | 
    
         
            +
            # License along with this library; if not, write to the Free Software
         
     | 
| 
      
 15 
     | 
    
         
            +
            # Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA  02110-1301  USA
         
     | 
| 
      
 16 
     | 
    
         
            +
             
     | 
| 
      
 17 
     | 
    
         
            +
            class TableGroupTest < Test::Unit::TestCase
         
     | 
| 
      
 18 
     | 
    
         
            +
              include GroongaTestUtils
         
     | 
| 
      
 19 
     | 
    
         
            +
             
     | 
| 
      
 20 
     | 
    
         
            +
              setup :setup_database
         
     | 
| 
      
 21 
     | 
    
         
            +
             
     | 
| 
      
 22 
     | 
    
         
            +
              class MaxNSubRecordsTest < self
         
     | 
| 
      
 23 
     | 
    
         
            +
                setup
         
     | 
| 
      
 24 
     | 
    
         
            +
                def setup_schema
         
     | 
| 
      
 25 
     | 
    
         
            +
                  Groonga::Schema.define do |schema|
         
     | 
| 
      
 26 
     | 
    
         
            +
                    schema.create_table("Bookmarks", :type => :hash) do |table|
         
     | 
| 
      
 27 
     | 
    
         
            +
                      table.text("title")
         
     | 
| 
      
 28 
     | 
    
         
            +
                    end
         
     | 
| 
      
 29 
     | 
    
         
            +
             
     | 
| 
      
 30 
     | 
    
         
            +
                    schema.create_table("Comments", :type => :array) do |table|
         
     | 
| 
      
 31 
     | 
    
         
            +
                      table.reference("bookmark")
         
     | 
| 
      
 32 
     | 
    
         
            +
                      table.text("content")
         
     | 
| 
      
 33 
     | 
    
         
            +
                      table.int32("rank")
         
     | 
| 
      
 34 
     | 
    
         
            +
                    end
         
     | 
| 
      
 35 
     | 
    
         
            +
                  end
         
     | 
| 
      
 36 
     | 
    
         
            +
                end
         
     | 
| 
      
 37 
     | 
    
         
            +
             
     | 
| 
      
 38 
     | 
    
         
            +
                setup
         
     | 
| 
      
 39 
     | 
    
         
            +
                def setup_data
         
     | 
| 
      
 40 
     | 
    
         
            +
                  setup_bookmarks
         
     | 
| 
      
 41 
     | 
    
         
            +
                  setup_comments
         
     | 
| 
      
 42 
     | 
    
         
            +
                end
         
     | 
| 
      
 43 
     | 
    
         
            +
             
     | 
| 
      
 44 
     | 
    
         
            +
                def setup_bookmarks
         
     | 
| 
      
 45 
     | 
    
         
            +
                  @bookmarks = Groonga["Bookmarks"]
         
     | 
| 
      
 46 
     | 
    
         
            +
                  @groonga = @bookmarks.add("http://groonga.org/", :title => "groonga")
         
     | 
| 
      
 47 
     | 
    
         
            +
                  @ruby = @bookmarks.add("http://ruby-lang.org/", :title => "Ruby")
         
     | 
| 
      
 48 
     | 
    
         
            +
                end
         
     | 
| 
      
 49 
     | 
    
         
            +
             
     | 
| 
      
 50 
     | 
    
         
            +
                def setup_comments
         
     | 
| 
      
 51 
     | 
    
         
            +
                  @comments = Groonga["Comments"]
         
     | 
| 
      
 52 
     | 
    
         
            +
                  @comments.add(:bookmark => @groonga,
         
     | 
| 
      
 53 
     | 
    
         
            +
                                :content => "garbage comment1",
         
     | 
| 
      
 54 
     | 
    
         
            +
                                :rank => 0)
         
     | 
| 
      
 55 
     | 
    
         
            +
                  @comments.add(:bookmark => @groonga,
         
     | 
| 
      
 56 
     | 
    
         
            +
                                :content => "garbage comment2",
         
     | 
| 
      
 57 
     | 
    
         
            +
                                :rank => 0)
         
     | 
| 
      
 58 
     | 
    
         
            +
                  @comments.add(:bookmark => @groonga,
         
     | 
| 
      
 59 
     | 
    
         
            +
                                :content => "full-text search",
         
     | 
| 
      
 60 
     | 
    
         
            +
                                :rank => 1)
         
     | 
| 
      
 61 
     | 
    
         
            +
                  @comments.add(:bookmark => @groonga,
         
     | 
| 
      
 62 
     | 
    
         
            +
                                :content => "column store",
         
     | 
| 
      
 63 
     | 
    
         
            +
                                :rank => 5)
         
     | 
| 
      
 64 
     | 
    
         
            +
                  @comments.add(:bookmark => @ruby,
         
     | 
| 
      
 65 
     | 
    
         
            +
                                :content => "object oriented script language",
         
     | 
| 
      
 66 
     | 
    
         
            +
                                :rank => 100)
         
     | 
| 
      
 67 
     | 
    
         
            +
                  @comments.add(:bookmark => @ruby,
         
     | 
| 
      
 68 
     | 
    
         
            +
                                :content => "multi paradigm programming language",
         
     | 
| 
      
 69 
     | 
    
         
            +
                                :rank => 80)
         
     | 
| 
      
 70 
     | 
    
         
            +
                end
         
     | 
| 
      
 71 
     | 
    
         
            +
             
     | 
| 
      
 72 
     | 
    
         
            +
                setup
         
     | 
| 
      
 73 
     | 
    
         
            +
                def setup_searched
         
     | 
| 
      
 74 
     | 
    
         
            +
                  @records = @comments.select do |record|
         
     | 
| 
      
 75 
     | 
    
         
            +
                    record.rank > 0
         
     | 
| 
      
 76 
     | 
    
         
            +
                  end
         
     | 
| 
      
 77 
     | 
    
         
            +
                end
         
     | 
| 
      
 78 
     | 
    
         
            +
             
     | 
| 
      
 79 
     | 
    
         
            +
                def test_upper_limit
         
     | 
| 
      
 80 
     | 
    
         
            +
                  grouped_records = @records.group("bookmark", :max_n_sub_records => 2)
         
     | 
| 
      
 81 
     | 
    
         
            +
                  groups = grouped_records.collect do |record|
         
     | 
| 
      
 82 
     | 
    
         
            +
                    sub_record_contents = record.sub_records.collect do |sub_record|
         
     | 
| 
      
 83 
     | 
    
         
            +
                      sub_record.content
         
     | 
| 
      
 84 
     | 
    
         
            +
                    end
         
     | 
| 
      
 85 
     | 
    
         
            +
                    [record.title, sub_record_contents]
         
     | 
| 
      
 86 
     | 
    
         
            +
                  end
         
     | 
| 
      
 87 
     | 
    
         
            +
                  assert_equal([
         
     | 
| 
      
 88 
     | 
    
         
            +
                                 [
         
     | 
| 
      
 89 
     | 
    
         
            +
                                   "groonga",
         
     | 
| 
      
 90 
     | 
    
         
            +
                                   [
         
     | 
| 
      
 91 
     | 
    
         
            +
                                     "full-text search",
         
     | 
| 
      
 92 
     | 
    
         
            +
                                     "column store",
         
     | 
| 
      
 93 
     | 
    
         
            +
                                   ],
         
     | 
| 
      
 94 
     | 
    
         
            +
                                 ],
         
     | 
| 
      
 95 
     | 
    
         
            +
                                 [
         
     | 
| 
      
 96 
     | 
    
         
            +
                                   "Ruby",
         
     | 
| 
      
 97 
     | 
    
         
            +
                                   [
         
     | 
| 
      
 98 
     | 
    
         
            +
                                     "object oriented script language",
         
     | 
| 
      
 99 
     | 
    
         
            +
                                     "multi paradigm programming language",
         
     | 
| 
      
 100 
     | 
    
         
            +
                                   ],
         
     | 
| 
      
 101 
     | 
    
         
            +
                                 ],
         
     | 
| 
      
 102 
     | 
    
         
            +
                               ],
         
     | 
| 
      
 103 
     | 
    
         
            +
                               groups)
         
     | 
| 
      
 104 
     | 
    
         
            +
                end
         
     | 
| 
      
 105 
     | 
    
         
            +
             
     | 
| 
      
 106 
     | 
    
         
            +
                def test_less_than_limit
         
     | 
| 
      
 107 
     | 
    
         
            +
                  sorted = @records.sort([{:key => "rank", :order => :descending}],
         
     | 
| 
      
 108 
     | 
    
         
            +
                                         :limit => 3, :offset => 0)
         
     | 
| 
      
 109 
     | 
    
         
            +
                  grouped_records = sorted.group("bookmark", :max_n_sub_records => 2)
         
     | 
| 
      
 110 
     | 
    
         
            +
                  groups = grouped_records.collect do |record|
         
     | 
| 
      
 111 
     | 
    
         
            +
                    sub_record_ranks = record.sub_records.collect do |sub_record|
         
     | 
| 
      
 112 
     | 
    
         
            +
                      sub_record.rank
         
     | 
| 
      
 113 
     | 
    
         
            +
                    end
         
     | 
| 
      
 114 
     | 
    
         
            +
                    [record.title, sub_record_ranks]
         
     | 
| 
      
 115 
     | 
    
         
            +
                  end
         
     | 
| 
      
 116 
     | 
    
         
            +
                  assert_equal([
         
     | 
| 
      
 117 
     | 
    
         
            +
                                 ["Ruby", [100, 80]],
         
     | 
| 
      
 118 
     | 
    
         
            +
                                 ["groonga", [5]]
         
     | 
| 
      
 119 
     | 
    
         
            +
                               ],
         
     | 
| 
      
 120 
     | 
    
         
            +
                               groups)
         
     | 
| 
      
 121 
     | 
    
         
            +
                end
         
     | 
| 
      
 122 
     | 
    
         
            +
              end
         
     | 
| 
      
 123 
     | 
    
         
            +
             
     | 
| 
      
 124 
     | 
    
         
            +
              class KeyTest < self
         
     | 
| 
      
 125 
     | 
    
         
            +
                setup
         
     | 
| 
      
 126 
     | 
    
         
            +
                def setup_schema
         
     | 
| 
      
 127 
     | 
    
         
            +
                  Groonga::Schema.define do |schema|
         
     | 
| 
      
 128 
     | 
    
         
            +
                    schema.create_table("Bookmarks", :type => :hash) do |table|
         
     | 
| 
      
 129 
     | 
    
         
            +
                      table.text("title")
         
     | 
| 
      
 130 
     | 
    
         
            +
                    end
         
     | 
| 
      
 131 
     | 
    
         
            +
             
     | 
| 
      
 132 
     | 
    
         
            +
                    schema.create_table("Comments", :type => :array) do |table|
         
     | 
| 
      
 133 
     | 
    
         
            +
                      table.reference("bookmark")
         
     | 
| 
      
 134 
     | 
    
         
            +
                      table.text("content")
         
     | 
| 
      
 135 
     | 
    
         
            +
                      table.int32("rank")
         
     | 
| 
      
 136 
     | 
    
         
            +
                    end
         
     | 
| 
      
 137 
     | 
    
         
            +
                  end
         
     | 
| 
      
 138 
     | 
    
         
            +
                end
         
     | 
| 
      
 139 
     | 
    
         
            +
             
     | 
| 
      
 140 
     | 
    
         
            +
                setup
         
     | 
| 
      
 141 
     | 
    
         
            +
                def setup_data
         
     | 
| 
      
 142 
     | 
    
         
            +
                  setup_bookmarks
         
     | 
| 
      
 143 
     | 
    
         
            +
                  setup_comments
         
     | 
| 
      
 144 
     | 
    
         
            +
                end
         
     | 
| 
      
 145 
     | 
    
         
            +
             
     | 
| 
      
 146 
     | 
    
         
            +
                def setup_bookmarks
         
     | 
| 
      
 147 
     | 
    
         
            +
                  @bookmarks = Groonga["Bookmarks"]
         
     | 
| 
      
 148 
     | 
    
         
            +
                  @groonga = @bookmarks.add("http://groonga.org/", :title => "groonga")
         
     | 
| 
      
 149 
     | 
    
         
            +
                  @ruby = @bookmarks.add("http://ruby-lang.org/", :title => "Ruby")
         
     | 
| 
      
 150 
     | 
    
         
            +
                end
         
     | 
| 
      
 151 
     | 
    
         
            +
             
     | 
| 
      
 152 
     | 
    
         
            +
                def setup_comments
         
     | 
| 
      
 153 
     | 
    
         
            +
                  @comments = Groonga["Comments"]
         
     | 
| 
      
 154 
     | 
    
         
            +
                  @comments.add(:bookmark => @groonga,
         
     | 
| 
      
 155 
     | 
    
         
            +
                                :content => "full-text search")
         
     | 
| 
      
 156 
     | 
    
         
            +
                  @comments.add(:bookmark => @groonga,
         
     | 
| 
      
 157 
     | 
    
         
            +
                                :content => "column store")
         
     | 
| 
      
 158 
     | 
    
         
            +
                  @comments.add(:bookmark => @ruby,
         
     | 
| 
      
 159 
     | 
    
         
            +
                                :content => "object oriented script language")
         
     | 
| 
      
 160 
     | 
    
         
            +
                end
         
     | 
| 
      
 161 
     | 
    
         
            +
             
     | 
| 
      
 162 
     | 
    
         
            +
                def test_string
         
     | 
| 
      
 163 
     | 
    
         
            +
                  grouped_records = @comments.group("bookmark").collect do |record|
         
     | 
| 
      
 164 
     | 
    
         
            +
                    bookmark = record.key
         
     | 
| 
      
 165 
     | 
    
         
            +
                    [
         
     | 
| 
      
 166 
     | 
    
         
            +
                      record.n_sub_records,
         
     | 
| 
      
 167 
     | 
    
         
            +
                      bookmark["title"],
         
     | 
| 
      
 168 
     | 
    
         
            +
                      bookmark.key,
         
     | 
| 
      
 169 
     | 
    
         
            +
                    ]
         
     | 
| 
      
 170 
     | 
    
         
            +
                  end
         
     | 
| 
      
 171 
     | 
    
         
            +
                  assert_equal([
         
     | 
| 
      
 172 
     | 
    
         
            +
                                 [2, "groonga", "http://groonga.org/"],
         
     | 
| 
      
 173 
     | 
    
         
            +
                                 [1, "Ruby", "http://ruby-lang.org/"],
         
     | 
| 
      
 174 
     | 
    
         
            +
                               ],
         
     | 
| 
      
 175 
     | 
    
         
            +
                               grouped_records)
         
     | 
| 
      
 176 
     | 
    
         
            +
                end
         
     | 
| 
      
 177 
     | 
    
         
            +
             
     | 
| 
      
 178 
     | 
    
         
            +
                def test_array
         
     | 
| 
      
 179 
     | 
    
         
            +
                  grouped_records = @comments.group(["bookmark"]).collect do |record|
         
     | 
| 
      
 180 
     | 
    
         
            +
                    bookmark = record.key
         
     | 
| 
      
 181 
     | 
    
         
            +
                    [
         
     | 
| 
      
 182 
     | 
    
         
            +
                      record.n_sub_records,
         
     | 
| 
      
 183 
     | 
    
         
            +
                      bookmark["title"],
         
     | 
| 
      
 184 
     | 
    
         
            +
                      bookmark.key,
         
     | 
| 
      
 185 
     | 
    
         
            +
                    ]
         
     | 
| 
      
 186 
     | 
    
         
            +
                  end
         
     | 
| 
      
 187 
     | 
    
         
            +
                  assert_equal([
         
     | 
| 
      
 188 
     | 
    
         
            +
                                 [2, "groonga", "http://groonga.org/"],
         
     | 
| 
      
 189 
     | 
    
         
            +
                                 [1, "Ruby", "http://ruby-lang.org/"],
         
     | 
| 
      
 190 
     | 
    
         
            +
                               ],
         
     | 
| 
      
 191 
     | 
    
         
            +
                               grouped_records)
         
     | 
| 
      
 192 
     | 
    
         
            +
                end
         
     | 
| 
      
 193 
     | 
    
         
            +
             
     | 
| 
      
 194 
     | 
    
         
            +
                def test_accessor
         
     | 
| 
      
 195 
     | 
    
         
            +
                  grouped_records = @comments.group("bookmark._key").collect do |record|
         
     | 
| 
      
 196 
     | 
    
         
            +
                    [
         
     | 
| 
      
 197 
     | 
    
         
            +
                      record.n_sub_records,
         
     | 
| 
      
 198 
     | 
    
         
            +
                      record.key
         
     | 
| 
      
 199 
     | 
    
         
            +
                    ]
         
     | 
| 
      
 200 
     | 
    
         
            +
                  end
         
     | 
| 
      
 201 
     | 
    
         
            +
                  assert_equal([
         
     | 
| 
      
 202 
     | 
    
         
            +
                                 [2, "http://groonga.org/"],
         
     | 
| 
      
 203 
     | 
    
         
            +
                                 [1, "http://ruby-lang.org/"],
         
     | 
| 
      
 204 
     | 
    
         
            +
                               ],
         
     | 
| 
      
 205 
     | 
    
         
            +
                               grouped_records)
         
     | 
| 
      
 206 
     | 
    
         
            +
                end
         
     | 
| 
      
 207 
     | 
    
         
            +
             
     | 
| 
      
 208 
     | 
    
         
            +
                def test_nonexistent
         
     | 
| 
      
 209 
     | 
    
         
            +
                  message = "unknown group key: <\"nonexistent\">: <#{@comments.inspect}>"
         
     | 
| 
      
 210 
     | 
    
         
            +
                  assert_raise(ArgumentError.new(message)) do
         
     | 
| 
      
 211 
     | 
    
         
            +
                    @comments.group("nonexistent")
         
     | 
| 
      
 212 
     | 
    
         
            +
                  end
         
     | 
| 
      
 213 
     | 
    
         
            +
                end
         
     | 
| 
      
 214 
     | 
    
         
            +
              end
         
     | 
| 
      
 215 
     | 
    
         
            +
             
     | 
| 
      
 216 
     | 
    
         
            +
              class MultipleKeyTest < self
         
     | 
| 
      
 217 
     | 
    
         
            +
                setup
         
     | 
| 
      
 218 
     | 
    
         
            +
                def setup_schema
         
     | 
| 
      
 219 
     | 
    
         
            +
                  Groonga::Schema.define do |schema|
         
     | 
| 
      
 220 
     | 
    
         
            +
                    schema.create_table("Memos", :type => :hash) do |table|
         
     | 
| 
      
 221 
     | 
    
         
            +
                      table.short_text("tag")
         
     | 
| 
      
 222 
     | 
    
         
            +
                      table.int64("priority")
         
     | 
| 
      
 223 
     | 
    
         
            +
                    end
         
     | 
| 
      
 224 
     | 
    
         
            +
                  end
         
     | 
| 
      
 225 
     | 
    
         
            +
                end
         
     | 
| 
      
 226 
     | 
    
         
            +
             
     | 
| 
      
 227 
     | 
    
         
            +
                setup
         
     | 
| 
      
 228 
     | 
    
         
            +
                def setup_data
         
     | 
| 
      
 229 
     | 
    
         
            +
                  setup_memos
         
     | 
| 
      
 230 
     | 
    
         
            +
                end
         
     | 
| 
      
 231 
     | 
    
         
            +
             
     | 
| 
      
 232 
     | 
    
         
            +
                def setup_memos
         
     | 
| 
      
 233 
     | 
    
         
            +
                  @memos = Groonga["Memos"]
         
     | 
| 
      
 234 
     | 
    
         
            +
                  @memos.add("Groonga1",
         
     | 
| 
      
 235 
     | 
    
         
            +
                             :tag => "Groonga",
         
     | 
| 
      
 236 
     | 
    
         
            +
                             :priority => 10)
         
     | 
| 
      
 237 
     | 
    
         
            +
                  @memos.add("Groonga2",
         
     | 
| 
      
 238 
     | 
    
         
            +
                             :tag => "Groonga",
         
     | 
| 
      
 239 
     | 
    
         
            +
                             :priority => 20)
         
     | 
| 
      
 240 
     | 
    
         
            +
                  @memos.add("Mroonga1",
         
     | 
| 
      
 241 
     | 
    
         
            +
                             :tag => "Mroonga",
         
     | 
| 
      
 242 
     | 
    
         
            +
                             :priority => 10)
         
     | 
| 
      
 243 
     | 
    
         
            +
                  @memos.add("Mroonga2",
         
     | 
| 
      
 244 
     | 
    
         
            +
                             :tag => "Mroonga",
         
     | 
| 
      
 245 
     | 
    
         
            +
                             :priority => 10)
         
     | 
| 
      
 246 
     | 
    
         
            +
                end
         
     | 
| 
      
 247 
     | 
    
         
            +
             
     | 
| 
      
 248 
     | 
    
         
            +
                def test_two_keys
         
     | 
| 
      
 249 
     | 
    
         
            +
                  keys = ["tag", "priority"]
         
     | 
| 
      
 250 
     | 
    
         
            +
                  grouped_records = @memos.group(keys).collect do |record|
         
     | 
| 
      
 251 
     | 
    
         
            +
                    sub_record = record.sub_records.first
         
     | 
| 
      
 252 
     | 
    
         
            +
                    [
         
     | 
| 
      
 253 
     | 
    
         
            +
                      record.n_sub_records,
         
     | 
| 
      
 254 
     | 
    
         
            +
                      sub_record.tag,
         
     | 
| 
      
 255 
     | 
    
         
            +
                      sub_record.priority,
         
     | 
| 
      
 256 
     | 
    
         
            +
                    ]
         
     | 
| 
      
 257 
     | 
    
         
            +
                  end
         
     | 
| 
      
 258 
     | 
    
         
            +
             
     | 
| 
      
 259 
     | 
    
         
            +
                  assert_equal([
         
     | 
| 
      
 260 
     | 
    
         
            +
                                 [1, "Groonga", 10],
         
     | 
| 
      
 261 
     | 
    
         
            +
                                 [1, "Groonga", 20],
         
     | 
| 
      
 262 
     | 
    
         
            +
                                 [2, "Mroonga", 10],
         
     | 
| 
      
 263 
     | 
    
         
            +
                               ],
         
     | 
| 
      
 264 
     | 
    
         
            +
                               grouped_records)
         
     | 
| 
      
 265 
     | 
    
         
            +
                end
         
     | 
| 
      
 266 
     | 
    
         
            +
              end
         
     | 
| 
      
 267 
     | 
    
         
            +
             
     | 
| 
      
 268 
     | 
    
         
            +
              class CalculationTest < self
         
     | 
| 
      
 269 
     | 
    
         
            +
                setup
         
     | 
| 
      
 270 
     | 
    
         
            +
                def setup_schema
         
     | 
| 
      
 271 
     | 
    
         
            +
                  Groonga::Schema.define do |schema|
         
     | 
| 
      
 272 
     | 
    
         
            +
                    schema.create_table("Tags", :type => :hash)
         
     | 
| 
      
 273 
     | 
    
         
            +
             
     | 
| 
      
 274 
     | 
    
         
            +
                    schema.create_table("Memos", :type => :hash) do |table|
         
     | 
| 
      
 275 
     | 
    
         
            +
                      table.reference("tag")
         
     | 
| 
      
 276 
     | 
    
         
            +
                      table.int64("priority")
         
     | 
| 
      
 277 
     | 
    
         
            +
                    end
         
     | 
| 
      
 278 
     | 
    
         
            +
                  end
         
     | 
| 
      
 279 
     | 
    
         
            +
                end
         
     | 
| 
      
 280 
     | 
    
         
            +
             
     | 
| 
      
 281 
     | 
    
         
            +
                setup
         
     | 
| 
      
 282 
     | 
    
         
            +
                def setup_data
         
     | 
| 
      
 283 
     | 
    
         
            +
                  setup_tags
         
     | 
| 
      
 284 
     | 
    
         
            +
                  setup_memos
         
     | 
| 
      
 285 
     | 
    
         
            +
                end
         
     | 
| 
      
 286 
     | 
    
         
            +
             
     | 
| 
      
 287 
     | 
    
         
            +
                def setup_tags
         
     | 
| 
      
 288 
     | 
    
         
            +
                  @tags = Groonga["Tags"]
         
     | 
| 
      
 289 
     | 
    
         
            +
                  @groonga = @tags.add("Groonga")
         
     | 
| 
      
 290 
     | 
    
         
            +
                  @mroonga = @tags.add("Mroonga")
         
     | 
| 
      
 291 
     | 
    
         
            +
                  @rroonga = @tags.add("Rroonga")
         
     | 
| 
      
 292 
     | 
    
         
            +
                end
         
     | 
| 
      
 293 
     | 
    
         
            +
             
     | 
| 
      
 294 
     | 
    
         
            +
                def setup_memos
         
     | 
| 
      
 295 
     | 
    
         
            +
                  @memos = Groonga["Memos"]
         
     | 
| 
      
 296 
     | 
    
         
            +
                  @memos.add("Groonga1",
         
     | 
| 
      
 297 
     | 
    
         
            +
                             :tag => @groonga,
         
     | 
| 
      
 298 
     | 
    
         
            +
                             :priority => 10)
         
     | 
| 
      
 299 
     | 
    
         
            +
                  @memos.add("Groonga2",
         
     | 
| 
      
 300 
     | 
    
         
            +
                             :tag => @groonga,
         
     | 
| 
      
 301 
     | 
    
         
            +
                             :priority => 20)
         
     | 
| 
      
 302 
     | 
    
         
            +
                  @memos.add("Groonga3",
         
     | 
| 
      
 303 
     | 
    
         
            +
                             :tag => @groonga,
         
     | 
| 
      
 304 
     | 
    
         
            +
                             :priority => 40)
         
     | 
| 
      
 305 
     | 
    
         
            +
                  @memos.add("Mroonga1",
         
     | 
| 
      
 306 
     | 
    
         
            +
                             :tag => @mroonga,
         
     | 
| 
      
 307 
     | 
    
         
            +
                             :priority => 50)
         
     | 
| 
      
 308 
     | 
    
         
            +
                  @memos.add("Mroonga2",
         
     | 
| 
      
 309 
     | 
    
         
            +
                             :tag => @mroonga,
         
     | 
| 
      
 310 
     | 
    
         
            +
                             :priority => 25)
         
     | 
| 
      
 311 
     | 
    
         
            +
                  @memos.add("Mroonga3",
         
     | 
| 
      
 312 
     | 
    
         
            +
                             :tag => @mroonga,
         
     | 
| 
      
 313 
     | 
    
         
            +
                             :priority => 10)
         
     | 
| 
      
 314 
     | 
    
         
            +
                  @memos.add("Rroonga1",
         
     | 
| 
      
 315 
     | 
    
         
            +
                             :tag => @rroonga,
         
     | 
| 
      
 316 
     | 
    
         
            +
                             :priority => 25)
         
     | 
| 
      
 317 
     | 
    
         
            +
                  @memos.add("Rroonga2",
         
     | 
| 
      
 318 
     | 
    
         
            +
                             :tag => @rroonga,
         
     | 
| 
      
 319 
     | 
    
         
            +
                             :priority => -25)
         
     | 
| 
      
 320 
     | 
    
         
            +
                  @memos.add("Rroonga3",
         
     | 
| 
      
 321 
     | 
    
         
            +
                             :tag => @rroonga,
         
     | 
| 
      
 322 
     | 
    
         
            +
                             :priority => 0)
         
     | 
| 
      
 323 
     | 
    
         
            +
                end
         
     | 
| 
      
 324 
     | 
    
         
            +
             
     | 
| 
      
 325 
     | 
    
         
            +
                def test_max
         
     | 
| 
      
 326 
     | 
    
         
            +
                  grouped_records = @memos.group("tag",
         
     | 
| 
      
 327 
     | 
    
         
            +
                                                 :calc_target => "priority",
         
     | 
| 
      
 328 
     | 
    
         
            +
                                                 :calc_types => [:max]).collect do |group|
         
     | 
| 
      
 329 
     | 
    
         
            +
                    tag = group.key
         
     | 
| 
      
 330 
     | 
    
         
            +
                    [
         
     | 
| 
      
 331 
     | 
    
         
            +
                      tag.key,
         
     | 
| 
      
 332 
     | 
    
         
            +
                      group.max,
         
     | 
| 
      
 333 
     | 
    
         
            +
                    ]
         
     | 
| 
      
 334 
     | 
    
         
            +
                  end
         
     | 
| 
      
 335 
     | 
    
         
            +
             
     | 
| 
      
 336 
     | 
    
         
            +
                  assert_equal([
         
     | 
| 
      
 337 
     | 
    
         
            +
                                 ["Groonga", 40],
         
     | 
| 
      
 338 
     | 
    
         
            +
                                 ["Mroonga", 50],
         
     | 
| 
      
 339 
     | 
    
         
            +
                                 ["Rroonga", 25],
         
     | 
| 
      
 340 
     | 
    
         
            +
                               ],
         
     | 
| 
      
 341 
     | 
    
         
            +
                               grouped_records)
         
     | 
| 
      
 342 
     | 
    
         
            +
                end
         
     | 
| 
      
 343 
     | 
    
         
            +
             
     | 
| 
      
 344 
     | 
    
         
            +
                def test_all_types
         
     | 
| 
      
 345 
     | 
    
         
            +
                  grouped_records = @memos.group("tag",
         
     | 
| 
      
 346 
     | 
    
         
            +
                                                 :calc_target => "priority",
         
     | 
| 
      
 347 
     | 
    
         
            +
                                                 :calc_types => [:max, :min, :sum, :average]).collect do |group|
         
     | 
| 
      
 348 
     | 
    
         
            +
                    tag = group.key
         
     | 
| 
      
 349 
     | 
    
         
            +
                    [
         
     | 
| 
      
 350 
     | 
    
         
            +
                      tag.key,
         
     | 
| 
      
 351 
     | 
    
         
            +
                      group.max,
         
     | 
| 
      
 352 
     | 
    
         
            +
                      group.min,
         
     | 
| 
      
 353 
     | 
    
         
            +
                      group.sum,
         
     | 
| 
      
 354 
     | 
    
         
            +
                      group.average.round(3),
         
     | 
| 
      
 355 
     | 
    
         
            +
                    ]
         
     | 
| 
      
 356 
     | 
    
         
            +
                  end
         
     | 
| 
      
 357 
     | 
    
         
            +
             
     | 
| 
      
 358 
     | 
    
         
            +
                  assert_equal([
         
     | 
| 
      
 359 
     | 
    
         
            +
                                 ["Groonga", 40, 10, 70, 23.333],
         
     | 
| 
      
 360 
     | 
    
         
            +
                                 ["Mroonga", 50, 10, 85, 28.333],
         
     | 
| 
      
 361 
     | 
    
         
            +
                                 ["Rroonga", 25, -25, 0, 0.0],
         
     | 
| 
      
 362 
     | 
    
         
            +
                               ],
         
     | 
| 
      
 363 
     | 
    
         
            +
                               grouped_records)
         
     | 
| 
      
 364 
     | 
    
         
            +
                end
         
     | 
| 
      
 365 
     | 
    
         
            +
              end
         
     | 
| 
      
 366 
     | 
    
         
            +
            end
         
     |