gfdnavi 1.3.0.0
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.
- data/ChangeLog +10949 -0
- data/LICENCE.txt +57 -0
- data/Makefile +18 -0
- data/TODO +132 -0
- data/app/controllers/analysis_controller.rb +700 -0
- data/app/controllers/application.rb +41 -0
- data/app/controllers/draw_method_controller.rb +172 -0
- data/app/controllers/explorer_controller.rb +197 -0
- data/app/controllers/finder_controller.rb +331 -0
- data/app/controllers/function_controller.rb +204 -0
- data/app/controllers/group_controller.rb +115 -0
- data/app/controllers/keyword_attributes_controller.rb +52 -0
- data/app/controllers/knowledge_controller.rb +928 -0
- data/app/controllers/nodes_controller.rb +515 -0
- data/app/controllers/search_controller.rb +341 -0
- data/app/controllers/user_controller.rb +337 -0
- data/app/helpers/analysis_helper.rb +2 -0
- data/app/helpers/application_helper.rb +105 -0
- data/app/helpers/description_helper.rb +2 -0
- data/app/helpers/function_helper.rb +2 -0
- data/app/helpers/group_helper.rb +2 -0
- data/app/helpers/search_helper.rb +3 -0
- data/app/helpers/user_helper.rb +2 -0
- data/app/helpers/work_flow_helper.rb +92 -0
- data/app/models/actual_file.rb +3 -0
- data/app/models/analysis.rb +715 -0
- data/app/models/analysis_history.rb +42 -0
- data/app/models/cross_array.rb +22 -0
- data/app/models/cross_result.rb +254 -0
- data/app/models/derived_spatial_attribute.rb +3 -0
- data/app/models/diagram_cache.rb +16 -0
- data/app/models/diagram_cache_datum.rb +4 -0
- data/app/models/diagram_cache_session.rb +8 -0
- data/app/models/directory.rb +21 -0
- data/app/models/draw_method.rb +48 -0
- data/app/models/draw_method_attribute.rb +8 -0
- data/app/models/draw_parameter.rb +12 -0
- data/app/models/explorer_query.rb +354 -0
- data/app/models/explorer_result.rb +312 -0
- data/app/models/function.rb +75 -0
- data/app/models/function_argument.rb +6 -0
- data/app/models/function_output.rb +4 -0
- data/app/models/group.rb +153 -0
- data/app/models/image.rb +20 -0
- data/app/models/keyword_attribute.rb +179 -0
- data/app/models/knowledge.rb +94 -0
- data/app/models/knowledge_backup.rb +32 -0
- data/app/models/knowledge_figure.rb +16 -0
- data/app/models/knowledge_figure_backup.rb +16 -0
- data/app/models/knowledge_parser.rb +392 -0
- data/app/models/node.rb +605 -0
- data/app/models/node_entity_abstract.rb +112 -0
- data/app/models/node_lineage.rb +6 -0
- data/app/models/node_relation.rb +4 -0
- data/app/models/path_node.rb +60 -0
- data/app/models/query.rb +193 -0
- data/app/models/query_history.rb +12 -0
- data/app/models/results.rb +48 -0
- data/app/models/sign_up_user.rb +25 -0
- data/app/models/spatial_and_time_attribute.rb +11 -0
- data/app/models/user.rb +115 -0
- data/app/models/user_mailer.rb +48 -0
- data/app/models/value_type.rb +3 -0
- data/app/models/variable.rb +70 -0
- data/app/models/virtual_node.rb +457 -0
- data/app/views/analysis/__help_analysis_tab.en.html +57 -0
- data/app/views/analysis/__help_draw_share.en.html +12 -0
- data/app/views/analysis/__help_draw_tab.en.html +6 -0
- data/app/views/analysis/_analysis_function_settings.rhtml +61 -0
- data/app/views/analysis/_analysis_settings.rhtml +28 -0
- data/app/views/analysis/_diagram.rhtml +70 -0
- data/app/views/analysis/_dimension_option.rhtml +59 -0
- data/app/views/analysis/_draw_general_settings.rhtml +217 -0
- data/app/views/analysis/_draw_settings.rhtml +73 -0
- data/app/views/analysis/_history.rhtml +19 -0
- data/app/views/analysis/_popular_diagrams.rhtml +42 -0
- data/app/views/analysis/_save_form.rhtml +44 -0
- data/app/views/analysis/_variables.rhtml +66 -0
- data/app/views/analysis/_variables_order.rhtml +56 -0
- data/app/views/analysis/index.rhtml +195 -0
- data/app/views/analysis/preview.rhtml +3 -0
- data/app/views/analysis/save.rhtml +73 -0
- data/app/views/analysis/show_diagram.rhtml +42 -0
- data/app/views/cross/_display_map.rhtml +201 -0
- data/app/views/cross/_result.rhtml +205 -0
- data/app/views/cross/_show_result_tree.rhtml +40 -0
- data/app/views/cross/_show_results.rhtml +80 -0
- data/app/views/cross/_style.rhtml +21 -0
- data/app/views/cross/index.rhtml +271 -0
- data/app/views/draw_method/_edit_form.rhtml +110 -0
- data/app/views/draw_method/create.rhtml +8 -0
- data/app/views/draw_method/details.rhtml +113 -0
- data/app/views/draw_method/edit.rhtml +8 -0
- data/app/views/draw_method/list.rhtml +80 -0
- data/app/views/explorer/_display_map.rhtml +199 -0
- data/app/views/explorer/_show_result_tree.rhtml +40 -0
- data/app/views/explorer/_show_results.rhtml +101 -0
- data/app/views/explorer/_style.rhtml +21 -0
- data/app/views/explorer/index.rhtml +214 -0
- data/app/views/finder/_children.html.erb +84 -0
- data/app/views/finder/_children_details.html.erb +74 -0
- data/app/views/finder/_children_details_tr.html.erb +196 -0
- data/app/views/finder/create_tree.html.erb +15 -0
- data/app/views/finder/flex.html.erb +52 -0
- data/app/views/finder/index.html.erb +47 -0
- data/app/views/finder/show_details.html.erb +3 -0
- data/app/views/finder/show_images.html.erb +3 -0
- data/app/views/function/_edit_form.rhtml +106 -0
- data/app/views/function/create.rhtml +8 -0
- data/app/views/function/details.rhtml +96 -0
- data/app/views/function/edit.rhtml +8 -0
- data/app/views/function/list.rhtml +80 -0
- data/app/views/group/add_member.rhtml +13 -0
- data/app/views/group/change_owner.rhtml +15 -0
- data/app/views/group/create.rhtml +11 -0
- data/app/views/group/delete_member.rhtml +14 -0
- data/app/views/group/list.rhtml +63 -0
- data/app/views/knowledge/_backup.rhtml +135 -0
- data/app/views/knowledge/_category.rhtml +58 -0
- data/app/views/knowledge/_category_list.rhtml +34 -0
- data/app/views/knowledge/_category_table.rhtml +23 -0
- data/app/views/knowledge/_comment.rhtml +64 -0
- data/app/views/knowledge/_comment_input_form.rhtml +19 -0
- data/app/views/knowledge/_comments.rhtml +84 -0
- data/app/views/knowledge/_form.rhtml +139 -0
- data/app/views/knowledge/_group_figure_form.rhtml +187 -0
- data/app/views/knowledge/_layout_figure.rhtml +61 -0
- data/app/views/knowledge/_layout_figures_in_a_row_above_text.rhtml +42 -0
- data/app/views/knowledge/_layout_figures_under_text.rhtml +45 -0
- data/app/views/knowledge/_layout_one_figure_above_text.rhtml +28 -0
- data/app/views/knowledge/_summary.rhtml +21 -0
- data/app/views/knowledge/edit.rhtml +37 -0
- data/app/views/knowledge/list.rhtml +287 -0
- data/app/views/knowledge/new.rhtml +23 -0
- data/app/views/knowledge/new_from_analysis.rhtml +21 -0
- data/app/views/knowledge/show.rhtml +196 -0
- data/app/views/layouts/gfdnavi.rhtml +105 -0
- data/app/views/nodes/_ancestors.html.erb +89 -0
- data/app/views/nodes/_description_methods_table.html.erb +75 -0
- data/app/views/nodes/_mode.html.erb +16 -0
- data/app/views/nodes/description.html.erb +181 -0
- data/app/views/nodes/description_methods.html.erb +1 -0
- data/app/views/nodes/edit.html.erb +73 -0
- data/app/views/nodes/index.html.erb +25 -0
- data/app/views/nodes/show.html.erb +20 -0
- data/app/views/search/_children_details_mapsearch.rhtml +68 -0
- data/app/views/search/_children_details_tr.rhtml +205 -0
- data/app/views/search/_show_grouplist.rhtml +74 -0
- data/app/views/search/_show_results.rhtml +43 -0
- data/app/views/search/_show_results_global.rhtml +36 -0
- data/app/views/search/_show_results_partial.rhtml +39 -0
- data/app/views/search/_show_results_partial_groupbyfile.rhtml +50 -0
- data/app/views/search/_show_variablelist.rhtml +28 -0
- data/app/views/search/mapsearch.rhtml +176 -0
- data/app/views/search/remapsearch.rjs +18 -0
- data/app/views/search/show_details.rhtml +3 -0
- data/app/views/user/add_user.rhtml +30 -0
- data/app/views/user/change_password.rhtml +25 -0
- data/app/views/user/edit.html.erb +50 -0
- data/app/views/user/index.rhtml +162 -0
- data/app/views/user/login.rhtml +41 -0
- data/app/views/user/logout.rhtml +4 -0
- data/app/views/user/signup.rhtml +36 -0
- data/app/views/user/signup_succeeded.rhtml +36 -0
- data/app/views/user_mailer/authorization_inform.rhtml +15 -0
- data/app/views/user_mailer/signup_accepted.rhtml +12 -0
- data/app/views/user_mailer/signup_confirm.rhtml +14 -0
- data/app/views/user_mailer/signup_inform.rhtml +13 -0
- data/app/views/user_mailer/signup_rejected.rhtml +11 -0
- data/app/views/work_flow/_push_wsdls.rhtml +55 -0
- data/app/views/work_flow/index.rhtml +46 -0
- data/config/database.yml.example +35 -0
- data/config/environment.rb +68 -0
- data/config/gfdnavi.yml.example +95 -0
- data/config/load_config.rb +151 -0
- data/config/routes.rb +35 -0
- data/consistency_checker.rb +129 -0
- data/data/gfdnavi_docs/how_to_draw_multiple_images.knlge +68 -0
- data/data/gfdnavi_docs/how_to_knowledge.knlge +138 -0
- data/data/gfdnavi_docs/how_to_write_document_about_Gfdnavi.knlge +30 -0
- data/data/samples/jmadata.SIGEN +8 -0
- data/data/samples/jmadata.yml +6 -0
- data/data/samples/jmadata/MSM-P/2006.nc.yml +2 -0
- data/data/samples/jmadata/MSM-P/2006.yml +17 -0
- data/data/samples/jmadata/MSM-P/2006/0101.nc +0 -0
- data/data/samples/jmadata/MSM-P/2006/0101.nc.yml +13 -0
- data/data/samples/jmadata/MSM-P/2006/0102.nc +0 -0
- data/data/samples/jmadata/MSM-P/2006/0103.nc +0 -0
- data/data/samples/jmadata/MSM-P/2006/0104.nc +0 -0
- data/data/samples/jmadata/MSM-P/2006/0105.nc +0 -0
- data/data/samples/jmadata/MSM-P/2006/010[1-3].nc.yml +2 -0
- data/data/samples/jmadata/MSM-P/2006/skip_data.rb +96 -0
- data/data/samples/jmadata/MSM-P/2006/skip_data.sh +6 -0
- data/data/samples/reanalysis.SIGEN +8 -0
- data/data/samples/reanalysis/era40.SIGEN +8 -0
- data/data/samples/reanalysis/era40.yml +2 -0
- data/data/samples/reanalysis/era40/t.jan.nc +0 -0
- data/data/samples/reanalysis/era40/t.jan.nc.yml +1 -0
- data/data/samples/reanalysis/ncep.SIGEN +9 -0
- data/data/samples/reanalysis/ncep/T.jan.100hPa.png +0 -0
- data/data/samples/reanalysis/ncep/T.jan.100hPa.png.yml +43 -0
- data/data/samples/reanalysis/ncep/T.jan.nc +0 -0
- data/data/samples/reanalysis/ncep/T.jan.zonal_mean.nc +0 -0
- data/data/samples/reanalysis/ncep/T.jan.zonal_mean.nc.yml +8 -0
- data/data/samples/reanalysis/ncep/T.jan_only_root.nc +0 -0
- data/data/samples/reanalysis/ncep/T.jan_only_root.nc.yml +4 -0
- data/data/samples/reanalysis/ncep/UV.jan.nc +0 -0
- data/data/samples/reanalysis/ncep/UV.jan.nc.yml +10 -0
- data/data/samples/reanalysis/ncep/UV.jan.nc.yml.ja +11 -0
- data/data/samples/sonde_operational.yml +5 -0
- data/data/samples/sonde_operational/std_plev.yml +12 -0
- data/data/samples/sonde_operational/std_plev/41256.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/42410.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/43333.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/43346.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/48698.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/61641.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/63741.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/67083.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/72261.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/76805.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/82193.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/91165.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/91610.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/91948.spl.nc +0 -0
- data/data/samples/sonde_operational/std_plev/94294.spl.nc +0 -0
- data/db/NetCDFparser.rb +406 -0
- data/db/create_derived_spatial_attributes.sql +12 -0
- data/db/draw_methods/line.yml +6 -0
- data/db/draw_methods/scatter.yml +38 -0
- data/db/draw_methods/tone.yml +64 -0
- data/db/draw_methods/vector.yml +19 -0
- data/db/dump_db.rb +43 -0
- data/db/functions/additions.yml +10 -0
- data/db/functions/cut.yml +10 -0
- data/db/functions/division.yml +10 -0
- data/db/functions/mean.yml +28 -0
- data/db/functions/multiplication.yml +10 -0
- data/db/functions/stddev.yml +28 -0
- data/db/functions/subtraction.yml +10 -0
- data/db/migrate/001_initial_scheme.rb +289 -0
- data/db/migrate/002_add_open_id_authentication_tables.rb +20 -0
- data/db/register_directory_tree.rb +760 -0
- data/db/restore_db.rb +60 -0
- data/gfdnavi-install +828 -0
- data/install.rb +828 -0
- data/lib/activerecord_gfdnavi.rb +31 -0
- data/lib/basic_authorization.rb +50 -0
- data/lib/create_activeresources.rb +108 -0
- data/lib/execute_analysis.rb +472 -0
- data/lib/file_gfdnavi.rb +38 -0
- data/lib/gphys_gfdnavi.rb +81 -0
- data/lib/localdir.rb +110 -0
- data/lib/login_system.rb +110 -0
- data/lib/multibytes.rb +20 -0
- data/lib/narray_yaml.rb +58 -0
- data/lib/no_rdb_base.rb +40 -0
- data/lib/opendapdir.rb +171 -0
- data/lib/tar.rb +127 -0
- data/lib/tasks/clean.rake +65 -0
- data/lib/tasks/setup.rake +316 -0
- data/lib/tasks/update.rake +62 -0
- data/lib/vizshot_gfdnavi.rb +224 -0
- data/public/crossdomain.xml +4 -0
- data/public/flex/NodeTreeDescriptor.as +55 -0
- data/public/flex/TreeNode.as +253 -0
- data/public/flex/finder.mxml +304 -0
- data/public/flex/finder.swf +0 -0
- data/public/flex/gfdnavi.mxml +52 -0
- data/public/flex/gfdnavi.swf +0 -0
- data/public/images/Help_S-shots/dir_tree_with_add.jpg +0 -0
- data/public/images/analyze.gif +0 -0
- data/public/images/circle.gif +0 -0
- data/public/images/create_from_analysis_button.png +0 -0
- data/public/images/delete.png +0 -0
- data/public/images/down.png +0 -0
- data/public/images/drawbutton.gif +0 -0
- data/public/images/gfdnavi_home_logo.png +0 -0
- data/public/images/gfdnavi_logo_big.png +0 -0
- data/public/images/gfdnavi_logo_med.png +0 -0
- data/public/images/gfdnavi_logo_mini.png +0 -0
- data/public/images/gfdnavi_logo_nobg_big.png +0 -0
- data/public/images/gfdnavi_logo_nobg_med.png +0 -0
- data/public/images/gfdnavi_logo_nobg_small.png +0 -0
- data/public/images/gfdnavi_logo_small.png +0 -0
- data/public/images/gfdnavi_logo_xsmall.png +0 -0
- data/public/images/hbar.png +0 -0
- data/public/images/helpmark16.png +0 -0
- data/public/images/helpmark18.png +0 -0
- data/public/images/kikyu_g.gif +0 -0
- data/public/images/kikyu_r.gif +0 -0
- data/public/images/map_icon_g.gif +0 -0
- data/public/images/map_icon_r.gif +0 -0
- data/public/images/new_knowledge.png +0 -0
- data/public/images/openid.png +0 -0
- data/public/images/read_in_the_form.png +0 -0
- data/public/images/slider_f.gif +0 -0
- data/public/images/slider_f_red.gif +0 -0
- data/public/images/star1.gif +0 -0
- data/public/images/star2.gif +0 -0
- data/public/images/startanim.gif +0 -0
- data/public/images/stopanim.gif +0 -0
- data/public/images/tree/DL.png +0 -0
- data/public/images/tree/anal_viz.png +0 -0
- data/public/images/tree/analyze_visualize_checked_items.png +0 -0
- data/public/images/tree/binary.png +0 -0
- data/public/images/tree/details.png +0 -0
- data/public/images/tree/download_checked_items.png +0 -0
- data/public/images/tree/folder.png +0 -0
- data/public/images/tree/folder_close.gif +0 -0
- data/public/images/tree/image2.png +0 -0
- data/public/images/tree/knowledge.png +0 -0
- data/public/images/tree/knowledges.png +0 -0
- data/public/images/tree/last.gif +0 -0
- data/public/images/tree/last.png +0 -0
- data/public/images/tree/minus.gif +0 -0
- data/public/images/tree/minus_simple.gif +0 -0
- data/public/images/tree/none.gif +0 -0
- data/public/images/tree/none.png +0 -0
- data/public/images/tree/plus.gif +0 -0
- data/public/images/tree/plus_simple.gif +0 -0
- data/public/images/tree/show.png +0 -0
- data/public/images/tree/show_checked_items.png +0 -0
- data/public/images/tree/t.gif +0 -0
- data/public/images/tree/t.png +0 -0
- data/public/images/tree/tate.gif +0 -0
- data/public/images/tree/tate.png +0 -0
- data/public/images/up.png +0 -0
- data/public/images/vbar.png +0 -0
- data/public/images/white.bmp +0 -0
- data/public/images/x.gif +0 -0
- data/public/index.html +100 -0
- data/public/javascripts/AC_OETags.js +269 -0
- data/public/javascripts/analysis.js +751 -0
- data/public/javascripts/application.js +29 -0
- data/public/javascripts/directory_tree.js +102 -0
- data/public/javascripts/draw_method.js +83 -0
- data/public/javascripts/excanvas.js +704 -0
- data/public/javascripts/function.js +107 -0
- data/public/javascripts/gfdnavi.js +175 -0
- data/public/javascripts/knowledge.js +384 -0
- data/public/javascripts/mapsearch.js +313 -0
- data/public/javascripts/progress.js +42 -0
- data/public/javascripts/resizable_box.js +164 -0
- data/public/javascripts/slider.js +260 -0
- data/public/javascripts/tab.js +17 -0
- data/public/javascripts/work_flow.js +452 -0
- data/public/stylesheets/analysis.css +111 -0
- data/public/stylesheets/description.css +71 -0
- data/public/stylesheets/gfdnavi.css +141 -0
- data/public/stylesheets/knowledge.css +218 -0
- data/public/stylesheets/search.css +184 -0
- data/public/stylesheets/tree.css +45 -0
- data/public/stylesheets/tree_for_ie.css +3 -0
- data/public/stylesheets/work_flow.css +78 -0
- data/script/cleaner +11 -0
- data/script/server_ssl +131 -0
- data/test/fixtures/diagram_cache_data.yml +5 -0
- data/test/fixtures/diagram_cache_sessions.yml +6 -0
- data/test/fixtures/diagram_caches.yml +6 -0
- data/test/fixtures/directories.yml +57 -0
- data/test/fixtures/draw_parameters.yml +6 -0
- data/test/fixtures/function_arguments.yml +15 -0
- data/test/fixtures/function_outputs.yml +15 -0
- data/test/fixtures/functions.yml +29 -0
- data/test/fixtures/group_members.yml +33 -0
- data/test/fixtures/groups.yml +25 -0
- data/test/fixtures/images.yml +12 -0
- data/test/fixtures/keyword_attributes.yml +73 -0
- data/test/fixtures/knowledges.yml +10 -0
- data/test/fixtures/node_relations.yml +11 -0
- data/test/fixtures/nodes.yml +298 -0
- data/test/fixtures/sign_up_users.yml +8 -0
- data/test/fixtures/spatial_and_time_attributes.yml +29 -0
- data/test/fixtures/user_mailer/authorization_inform +11 -0
- data/test/fixtures/user_mailer/signup_accepted +10 -0
- data/test/fixtures/user_mailer/signup_confirm +17 -0
- data/test/fixtures/user_mailer/signup_inform +10 -0
- data/test/fixtures/user_mailer/signup_rejected +9 -0
- data/test/fixtures/users.yml +31 -0
- data/test/fixtures/value_types.yml +10 -0
- data/test/fixtures/variables.yml +17 -0
- data/test/functional/analysis_controller_test.rb +169 -0
- data/test/functional/description_controller_test.rb +18 -0
- data/test/functional/function_controller_test.rb +18 -0
- data/test/functional/group_controller_test.rb +18 -0
- data/test/functional/search_controller_test.rb +83 -0
- data/test/functional/user_controller_test.rb +77 -0
- data/test/functional/webservice_analysis_api_test.rb +12 -0
- data/test/functional/work_flow_controller_test.rb +18 -0
- data/test/test_helper.rb +28 -0
- data/test/unit/diagram_cache_datum_test.rb +10 -0
- data/test/unit/diagram_cache_session_test.rb +10 -0
- data/test/unit/diagram_cache_test.rb +10 -0
- data/test/unit/directory_test.rb +49 -0
- data/test/unit/draw_parameter_test.rb +10 -0
- data/test/unit/function_argument_test.rb +10 -0
- data/test/unit/function_output_test.rb +10 -0
- data/test/unit/function_test.rb +10 -0
- data/test/unit/group_test.rb +48 -0
- data/test/unit/image_test.rb +13 -0
- data/test/unit/keyword_attribute_test.rb +33 -0
- data/test/unit/knowledge_test.rb +13 -0
- data/test/unit/node_relation_test.rb +20 -0
- data/test/unit/node_test.rb +85 -0
- data/test/unit/sign_up_user_test.rb +20 -0
- data/test/unit/spatial_and_time_attribute_test.rb +29 -0
- data/test/unit/user_mailer_test.rb +101 -0
- data/test/unit/user_test.rb +134 -0
- data/test/unit/value_type_test.rb +10 -0
- data/test/unit/variable_test.rb +35 -0
- data/vendor/plugins/acts_as_list/README +23 -0
- data/vendor/plugins/acts_as_list/init.rb +3 -0
- data/vendor/plugins/acts_as_list/lib/active_record/acts/list.rb +256 -0
- data/vendor/plugins/acts_as_list/test/list_test.rb +332 -0
- data/vendor/plugins/acts_as_tree/README +26 -0
- data/vendor/plugins/acts_as_tree/Rakefile +22 -0
- data/vendor/plugins/acts_as_tree/init.rb +1 -0
- data/vendor/plugins/acts_as_tree/lib/active_record/acts/tree.rb +96 -0
- data/vendor/plugins/acts_as_tree/test/abstract_unit.rb +0 -0
- data/vendor/plugins/acts_as_tree/test/acts_as_tree_test.rb +219 -0
- data/vendor/plugins/acts_as_tree/test/database.yml +0 -0
- data/vendor/plugins/acts_as_tree/test/fixtures/mixin.rb +0 -0
- data/vendor/plugins/acts_as_tree/test/fixtures/mixins.yml +0 -0
- data/vendor/plugins/acts_as_tree/test/schema.rb +0 -0
- data/vendor/plugins/will_paginate/CHANGELOG +92 -0
- data/vendor/plugins/will_paginate/LICENSE +18 -0
- data/vendor/plugins/will_paginate/README.rdoc +131 -0
- data/vendor/plugins/will_paginate/Rakefile +62 -0
- data/vendor/plugins/will_paginate/examples/apple-circle.gif +0 -0
- data/vendor/plugins/will_paginate/examples/index.haml +69 -0
- data/vendor/plugins/will_paginate/examples/index.html +92 -0
- data/vendor/plugins/will_paginate/examples/pagination.css +90 -0
- data/vendor/plugins/will_paginate/examples/pagination.sass +91 -0
- data/vendor/plugins/will_paginate/init.rb +1 -0
- data/vendor/plugins/will_paginate/lib/will_paginate.rb +86 -0
- data/vendor/plugins/will_paginate/lib/will_paginate/array.rb +16 -0
- data/vendor/plugins/will_paginate/lib/will_paginate/collection.rb +145 -0
- data/vendor/plugins/will_paginate/lib/will_paginate/core_ext.rb +32 -0
- data/vendor/plugins/will_paginate/lib/will_paginate/finder.rb +247 -0
- data/vendor/plugins/will_paginate/lib/will_paginate/named_scope.rb +132 -0
- data/vendor/plugins/will_paginate/lib/will_paginate/named_scope_patch.rb +39 -0
- data/vendor/plugins/will_paginate/lib/will_paginate/version.rb +9 -0
- data/vendor/plugins/will_paginate/lib/will_paginate/view_helpers.rb +373 -0
- data/vendor/plugins/will_paginate/will_paginate.gemspec +21 -0
- metadata +586 -0
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
Dear <%= @user.full_name %>
|
|
2
|
+
|
|
3
|
+
Thank you for your signing up for gfdnavi(<%=@url%>).
|
|
4
|
+
This mail was automatically sent for the norification.
|
|
5
|
+
|
|
6
|
+
If you do not receive an email informing the authorization in a few days,
|
|
7
|
+
please ask to <%= GFDNAVI_ADMIN_EMAIL %>.
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
Your information:
|
|
11
|
+
login name: <%= @user.login %>
|
|
12
|
+
full name: <%= @user.full_name %>
|
|
13
|
+
email address: <%= @user.email_address %>
|
|
14
|
+
affiliation: <%= @user.affiliation %>
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
Dear gfdnavi administrators
|
|
2
|
+
|
|
3
|
+
Following user signed up for gfdnavi.
|
|
4
|
+
Please click the following link or visited to gfdnavi(<%= @url %>) and deside to accept or reject the request.
|
|
5
|
+
accept: <%= @url %>user/accept_signup/<%= @user.id %>
|
|
6
|
+
reject: <%= @url %>user/reject_signup/<%= @user.id %>
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
User's information:
|
|
10
|
+
login name: <%= @user.login %>
|
|
11
|
+
full name: <%= @user.full_name %>
|
|
12
|
+
email address: <%= @user.email_address %>
|
|
13
|
+
affiliation: <%= @user.affiliation %>
|
|
@@ -0,0 +1,11 @@
|
|
|
1
|
+
Dear <%= @user.full_name %>
|
|
2
|
+
|
|
3
|
+
We are sorry but your request to sign up gfdnavi was rejected.
|
|
4
|
+
|
|
5
|
+
URL: <%= @url %>
|
|
6
|
+
|
|
7
|
+
Your account information:
|
|
8
|
+
login name: <%= @user.login %>
|
|
9
|
+
full name: <%= @user.full_name %>
|
|
10
|
+
email address: <%= @user.email_address %>
|
|
11
|
+
affiliation: <%= @user.affiliation %>
|
|
@@ -0,0 +1,55 @@
|
|
|
1
|
+
<%
|
|
2
|
+
@wsdls.each do |wsdl|
|
|
3
|
+
apis = @apis[wsdl]
|
|
4
|
+
names = apis.keys.sort
|
|
5
|
+
forms = Array.new
|
|
6
|
+
outputs = Array.new
|
|
7
|
+
names.each{|name|
|
|
8
|
+
api = apis[name]
|
|
9
|
+
form = ""
|
|
10
|
+
if /^http:\/\// =~ wsdl
|
|
11
|
+
form += wsdl
|
|
12
|
+
form += hidden_field_tag("apis[api_id][uri_wsdl]", wsdl)
|
|
13
|
+
else
|
|
14
|
+
form += "URI of WSDL: "
|
|
15
|
+
form += text_field_tag("apis[api_id][uri_wsdl]", "http://", :size=>50)
|
|
16
|
+
end
|
|
17
|
+
form += hidden_field_tag("apis[api_id][api_name]", name)
|
|
18
|
+
form += '<hr style="margin:5px 0"/>'
|
|
19
|
+
form += 'Input'
|
|
20
|
+
form += '<ul style="margin:0">'
|
|
21
|
+
api[:input].each do |key,val|
|
|
22
|
+
html, script = get_input_html([key], val)
|
|
23
|
+
if script
|
|
24
|
+
%>
|
|
25
|
+
<%= script %>
|
|
26
|
+
<%
|
|
27
|
+
end
|
|
28
|
+
form += '<li>'
|
|
29
|
+
form += "#{key}: "
|
|
30
|
+
form += html
|
|
31
|
+
form += "</li>"
|
|
32
|
+
end
|
|
33
|
+
form += '</ul>'
|
|
34
|
+
form += '<hr style="margin:5px 0"/>'
|
|
35
|
+
form += 'Output'
|
|
36
|
+
form += '<ul style="margin:0">'
|
|
37
|
+
api[:output].each{|key,val|
|
|
38
|
+
form += '<li>'
|
|
39
|
+
form += "#{key}: "
|
|
40
|
+
form += get_output_text(val, "html")
|
|
41
|
+
form += '</li>'
|
|
42
|
+
}
|
|
43
|
+
form += '</ul>'
|
|
44
|
+
forms.push form
|
|
45
|
+
|
|
46
|
+
output = "["
|
|
47
|
+
output += api[:output].collect{|key,val|
|
|
48
|
+
get_output_text(val, "list", key)
|
|
49
|
+
}.join(",")
|
|
50
|
+
output += "]"
|
|
51
|
+
outputs.push output
|
|
52
|
+
}
|
|
53
|
+
%>
|
|
54
|
+
new Wsdl('<%= wsdl %>', ['<%= names.join("','") %>'], ['<%= forms.join("','") %>'], [<%= outputs.join(',') %>]);
|
|
55
|
+
<% end %>
|
|
@@ -0,0 +1,46 @@
|
|
|
1
|
+
<div class="list_box" style="width:30%;">
|
|
2
|
+
<div class="title">WSDL list</div>
|
|
3
|
+
<div id="wsdl_list" class="list">
|
|
4
|
+
</div>
|
|
5
|
+
<% form_remote_tag(:loading => "document.body.style.cursor='wait';",
|
|
6
|
+
:complete => "document.body.style.cursor='auto';",
|
|
7
|
+
:url => {:action=>:add_wsdl}) { %>
|
|
8
|
+
<%= text_field_tag("url", "http://", :size=>"30") %>
|
|
9
|
+
<br/>
|
|
10
|
+
<%= submit_tag("add WSDL") %>
|
|
11
|
+
<% } %>
|
|
12
|
+
</div>
|
|
13
|
+
|
|
14
|
+
<div class="list_box" style="width:10%">
|
|
15
|
+
<div class="title">API list</div>
|
|
16
|
+
<div id="api_list" class="list">
|
|
17
|
+
</div>
|
|
18
|
+
</div>
|
|
19
|
+
|
|
20
|
+
<div class="canvas_div" style="margin-left:45%;margin-top:10;width:510;padding-left:10;">
|
|
21
|
+
|
|
22
|
+
<div class="title">Api entity chart</div>
|
|
23
|
+
<div id="canvas_chart">
|
|
24
|
+
<canvas id="canvas" height="300" width="500"></canvas>
|
|
25
|
+
<div id="api_entities"></div>
|
|
26
|
+
</div>
|
|
27
|
+
|
|
28
|
+
<div id="form_div" style="width:100%;height:200">
|
|
29
|
+
<form id="entity_form">
|
|
30
|
+
</form>
|
|
31
|
+
</div>
|
|
32
|
+
|
|
33
|
+
<div>
|
|
34
|
+
<%= button_to_function("Execute", "execute()") %><br/>
|
|
35
|
+
<%= button_to_function("Get Ruby Code", "get_ruby_code(this)") %>
|
|
36
|
+
</div>
|
|
37
|
+
|
|
38
|
+
</div>
|
|
39
|
+
|
|
40
|
+
<script>
|
|
41
|
+
<%= render :partial => "push_wsdls" %>
|
|
42
|
+
window.onload = function() {
|
|
43
|
+
canvas = $('canvas');
|
|
44
|
+
ctx = canvas.getContext('2d');
|
|
45
|
+
};
|
|
46
|
+
</script>
|
|
@@ -0,0 +1,35 @@
|
|
|
1
|
+
# MySQL (default setup). Versions 4.1 and 5.0 are recommended.
|
|
2
|
+
#
|
|
3
|
+
# Install the MySQL driver:
|
|
4
|
+
# gem install mysql
|
|
5
|
+
# On MacOS X:
|
|
6
|
+
# gem install mysql -- --include=/usr/local/lib
|
|
7
|
+
# On Windows:
|
|
8
|
+
# There is no gem for Windows. Install mysql.so from RubyForApache.
|
|
9
|
+
# http://rubyforge.org/projects/rubyforapache
|
|
10
|
+
#
|
|
11
|
+
# And be sure to use new-style password hashing:
|
|
12
|
+
# http://dev.mysql.com/doc/refman/5.0/en/old-client.html
|
|
13
|
+
development:
|
|
14
|
+
adapter: mysql
|
|
15
|
+
database: gfdnavi_development
|
|
16
|
+
username: root
|
|
17
|
+
password:
|
|
18
|
+
host: localhost
|
|
19
|
+
|
|
20
|
+
# Warning: The database defined as 'test' will be erased and
|
|
21
|
+
# re-generated from your development database when you run 'rake'.
|
|
22
|
+
# Do not set this db to the same as development or production.
|
|
23
|
+
test:
|
|
24
|
+
adapter: mysql
|
|
25
|
+
database: gfdnavi_test
|
|
26
|
+
username: root
|
|
27
|
+
password:
|
|
28
|
+
host: localhost
|
|
29
|
+
|
|
30
|
+
production:
|
|
31
|
+
adapter: mysql
|
|
32
|
+
database: gfdnavi_production
|
|
33
|
+
username: root
|
|
34
|
+
password:
|
|
35
|
+
host: localhost
|
|
@@ -0,0 +1,68 @@
|
|
|
1
|
+
# Be sure to restart your server when you modify this file
|
|
2
|
+
|
|
3
|
+
# Uncomment below to force Rails into production mode when
|
|
4
|
+
# you don't control web/app server and can't set it the proper way
|
|
5
|
+
# ENV['RAILS_ENV'] ||= 'production'
|
|
6
|
+
|
|
7
|
+
# Specifies gem version of Rails to use when vendor/rails is not present
|
|
8
|
+
#RAILS_GEM_VERSION = '2.0.2' unless defined? RAILS_GEM_VERSION
|
|
9
|
+
|
|
10
|
+
# load configurations of gfdnavi in gfdnavi.yml
|
|
11
|
+
require File.join(File.dirname(__FILE__), 'load_config')
|
|
12
|
+
|
|
13
|
+
# Bootstrap the Rails environment, frameworks, and default configuration
|
|
14
|
+
require File.join(File.dirname(__FILE__), 'boot')
|
|
15
|
+
|
|
16
|
+
Rails::Initializer.run do |config|
|
|
17
|
+
# Settings in config/environments/* take precedence over those specified here.
|
|
18
|
+
# Application configuration should go into files in config/initializers
|
|
19
|
+
# -- all .rb files in that directory are automatically loaded.
|
|
20
|
+
# See Rails::Configuration for more options.
|
|
21
|
+
|
|
22
|
+
# Skip frameworks you're not going to use (only works if using vendor/rails).
|
|
23
|
+
# To use Rails without a database, you must remove the Active Record framework
|
|
24
|
+
# config.frameworks -= [ :active_record, :active_resource, :action_mailer ]
|
|
25
|
+
|
|
26
|
+
# Only load the plugins named here, in the order given. By default, all plugins
|
|
27
|
+
# in vendor/plugins are loaded in alphabetical order.
|
|
28
|
+
# :all can be used as a placeholder for all plugins not explicitly named
|
|
29
|
+
# config.plugins = [ :exception_notification, :ssl_requirement, :all ]
|
|
30
|
+
|
|
31
|
+
# Add additional load paths for your own custom dirs
|
|
32
|
+
# config.load_paths += %W( #{RAILS_ROOT}/extras )
|
|
33
|
+
|
|
34
|
+
# Force all environments to use the same logger level
|
|
35
|
+
# (by default production uses :info, the others :debug)
|
|
36
|
+
# config.log_level = :debug
|
|
37
|
+
|
|
38
|
+
# Your secret key for verifying cookie session data integrity.
|
|
39
|
+
# If you change this key, all old sessions will become invalid!
|
|
40
|
+
# Make sure the secret is at least 30 characters and all random,
|
|
41
|
+
# no regular words or you'll be exposed to dictionary attacks.
|
|
42
|
+
if config.action_controller.respond_to?("session")
|
|
43
|
+
config.action_controller.session = {
|
|
44
|
+
:session_key => '_test_session',
|
|
45
|
+
:secret => GFDNAVI_SECRET
|
|
46
|
+
}
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
# Use the database for sessions instead of the cookie-based default,
|
|
50
|
+
# which shouldn't be used to store highly confidential information
|
|
51
|
+
# (create the session table with 'rake db:sessions:create')
|
|
52
|
+
# config.action_controller.session_store = :active_record_store
|
|
53
|
+
config.action_controller.session_store = :p_store
|
|
54
|
+
|
|
55
|
+
# Use SQL instead of Active Record's schema dumper when creating the test database.
|
|
56
|
+
# This is necessary if your schema can't be completely dumped by the schema dumper,
|
|
57
|
+
# like if you have constraints or database-specific column types
|
|
58
|
+
# config.active_record.schema_format = :sql
|
|
59
|
+
|
|
60
|
+
# Activate observers that should always be running
|
|
61
|
+
# config.active_record.observers = :cacher, :garbage_collector
|
|
62
|
+
|
|
63
|
+
# Make Active Record use UTC-base instead of local time
|
|
64
|
+
# config.active_record.default_timezone = :utc
|
|
65
|
+
|
|
66
|
+
ENV['http_proxy'] = GFDNAVI_PROXY
|
|
67
|
+
|
|
68
|
+
end
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
data_path: RAILS_ROOT/data
|
|
2
|
+
|
|
3
|
+
#other_gfdnavi_servers:
|
|
4
|
+
# - http://localhost:2000/
|
|
5
|
+
|
|
6
|
+
#remote_data_paths:
|
|
7
|
+
# - http://test.opendap.org/opendap-3.7/nph-dods/data/
|
|
8
|
+
|
|
9
|
+
#diagram_path: RAILS_ROOT/public/diagrams
|
|
10
|
+
|
|
11
|
+
user_path: RAILS_ROOT/usr
|
|
12
|
+
|
|
13
|
+
work_path: RAILS_ROOT/tmp/work
|
|
14
|
+
|
|
15
|
+
ignored_dirs:
|
|
16
|
+
- !ruby/regexp /^CVS$/i
|
|
17
|
+
- cvsroot
|
|
18
|
+
|
|
19
|
+
#display: # This is obsolete; use 'DISPLAY' in 'env'
|
|
20
|
+
|
|
21
|
+
debug: true
|
|
22
|
+
|
|
23
|
+
benchmark: false
|
|
24
|
+
|
|
25
|
+
disable_user: false
|
|
26
|
+
|
|
27
|
+
proxy:
|
|
28
|
+
|
|
29
|
+
using_proxy: false
|
|
30
|
+
|
|
31
|
+
allow_any_openid: false
|
|
32
|
+
|
|
33
|
+
paginate_per: 10
|
|
34
|
+
|
|
35
|
+
diagram_cache_path: RAILS_ROOT/tmp/diagram_cache
|
|
36
|
+
|
|
37
|
+
data_cache_path: RAILS_ROOT/tmp/data_cache
|
|
38
|
+
|
|
39
|
+
google_map_key: ABQIAAAAfkj1xmBThQOFWkus8Ag_gRTJQa0g3IQ9GZqIMmInSLzwtGDKaBRqIpr19_qp5TBIIzBjbp3ONZnCeA # for localhost:3000
|
|
40
|
+
|
|
41
|
+
passphrase: You must change me!!
|
|
42
|
+
|
|
43
|
+
cross_search_center_server: http://localhost:3010/display/server_list
|
|
44
|
+
|
|
45
|
+
secret: You must change me !! (at least 30 characters)
|
|
46
|
+
|
|
47
|
+
session_duration: 180 # in minute
|
|
48
|
+
|
|
49
|
+
admin:
|
|
50
|
+
name: Gfdnavi Admin
|
|
51
|
+
email: root@example.org
|
|
52
|
+
|
|
53
|
+
enable_email: false
|
|
54
|
+
smtp:
|
|
55
|
+
:address: localhost
|
|
56
|
+
:port: 25
|
|
57
|
+
:domain: example.org
|
|
58
|
+
:authentication: :plain
|
|
59
|
+
|
|
60
|
+
env:
|
|
61
|
+
# DISPLAY: ":99.0"
|
|
62
|
+
# RAILS_ENV: production
|
|
63
|
+
|
|
64
|
+
#------------
|
|
65
|
+
# maximum array size to read in onto run-time memory (soft limit).
|
|
66
|
+
# unlimited if not set.
|
|
67
|
+
soft_limit_array_size: 2000000
|
|
68
|
+
|
|
69
|
+
#-------------
|
|
70
|
+
# maximum array size to read in onto run-time memory (hard limit).
|
|
71
|
+
# unlimited if not set.
|
|
72
|
+
#hard_limit_array_size: 5000000
|
|
73
|
+
|
|
74
|
+
ignored_attributes:
|
|
75
|
+
- _FillValue
|
|
76
|
+
- missing_value
|
|
77
|
+
- valid_min
|
|
78
|
+
- valid_max
|
|
79
|
+
- valid_range
|
|
80
|
+
- add_offset
|
|
81
|
+
- scale_factor
|
|
82
|
+
|
|
83
|
+
invisible_attributes:
|
|
84
|
+
- description
|
|
85
|
+
- Description
|
|
86
|
+
- textbody
|
|
87
|
+
- actual_range
|
|
88
|
+
- GRIB_id
|
|
89
|
+
- least_significant_digit
|
|
90
|
+
- precision
|
|
91
|
+
- coordinates
|
|
92
|
+
- var_desc
|
|
93
|
+
- level_desc
|
|
94
|
+
- parent_stat
|
|
95
|
+
|
|
@@ -0,0 +1,151 @@
|
|
|
1
|
+
# load configuration for gfdnavi
|
|
2
|
+
|
|
3
|
+
require "fileutils"
|
|
4
|
+
require "yaml"
|
|
5
|
+
require "rubygems"
|
|
6
|
+
require "action_mailer"
|
|
7
|
+
|
|
8
|
+
def gfdnavi_path( path )
|
|
9
|
+
path = path.gsub( /RAILS_ROOT/, File.expand_path(RAILS_ROOT) )
|
|
10
|
+
path.sub(/\/$/, "")
|
|
11
|
+
end
|
|
12
|
+
|
|
13
|
+
def gfdnavi_configuration( key, allow_nil = false )
|
|
14
|
+
val = @gfdnavi_configuration[key]
|
|
15
|
+
if allow_nil || val
|
|
16
|
+
return val
|
|
17
|
+
else
|
|
18
|
+
STDERR.print <<-EOS
|
|
19
|
+
*************************
|
|
20
|
+
Error occuered while reading the gfdnavi configuration file (#{@gfdnavi_configuration_file}).
|
|
21
|
+
Key "#{key}" was not found in your configuration file.
|
|
22
|
+
See config/gfdnavi.yml.example and you need to update it.
|
|
23
|
+
*************************
|
|
24
|
+
EOS
|
|
25
|
+
abort
|
|
26
|
+
end
|
|
27
|
+
end
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
@gfdnavi_configuration_file = File.join(File.dirname(__FILE__), 'gfdnavi.yml')
|
|
31
|
+
begin
|
|
32
|
+
@gfdnavi_configuration = YAML::load( File.read(@gfdnavi_configuration_file) )
|
|
33
|
+
rescue IOError, SystemCallError
|
|
34
|
+
$! = nil
|
|
35
|
+
STDERR.print <<-EOS
|
|
36
|
+
*************************
|
|
37
|
+
Error occuered while reading the gfdnavi configuration file (#{@gfdnavi_configuration_file}).
|
|
38
|
+
You probably need to copy config/gfdnavi.yml.example (and to edit it if needed).
|
|
39
|
+
*************************
|
|
40
|
+
EOS
|
|
41
|
+
abort
|
|
42
|
+
end
|
|
43
|
+
|
|
44
|
+
if (disp = gfdnavi_configuration('display',true))
|
|
45
|
+
STDERR.print "'display' is obsolete; use 'DISPLAY' in 'env'"
|
|
46
|
+
ENV['DISPLAY'] = disp
|
|
47
|
+
end
|
|
48
|
+
|
|
49
|
+
env = gfdnavi_configuration('env', true)
|
|
50
|
+
if Hash === env
|
|
51
|
+
env.each{|key, val|
|
|
52
|
+
ENV[key] = val
|
|
53
|
+
}
|
|
54
|
+
elsif ! env.nil?
|
|
55
|
+
raise "env must be a Hash"
|
|
56
|
+
end
|
|
57
|
+
|
|
58
|
+
RAILS_ENV.replace(ENV['RAILS_ENV']) if defined?(RAILS_ENV) && ENV['RAILS_ENV']
|
|
59
|
+
|
|
60
|
+
require File.join(File.dirname(__FILE__), 'boot')
|
|
61
|
+
|
|
62
|
+
|
|
63
|
+
GFDNAVI_DATA_PATH = gfdnavi_path( gfdnavi_configuration('data_path') )
|
|
64
|
+
GFDNAVI_PUBLIC_PATH = File.join(File.expand_path(RAILS_ROOT), 'public')
|
|
65
|
+
if Regexp.new('^'+GFDNAVI_PUBLIC_PATH+'(.*)') =~ GFDNAVI_DATA_PATH
|
|
66
|
+
# data are directly accessible
|
|
67
|
+
GFDNAVI_DATA_URL_PREFIX = $1 # path after '/public'
|
|
68
|
+
# GFDNAVI_DATA_URL_PREFIX.sub!(/([^\/])$/,'\1/') # Add trailing '/'
|
|
69
|
+
else
|
|
70
|
+
# data are NOT directly accessible
|
|
71
|
+
GFDNAVI_DATA_URL_PREFIX = ""
|
|
72
|
+
end
|
|
73
|
+
|
|
74
|
+
GFDNAVI_REMOTE_DATA_PATHS = gfdnavi_configuration('remote_data_paths',true)
|
|
75
|
+
if GFDNAVI_REMOTE_DATA_PATHS and !GFDNAVI_REMOTE_DATA_PATHS.is_a?(Array)
|
|
76
|
+
raise "gfdnavi config file error : remote_data_paths must be an array"
|
|
77
|
+
end
|
|
78
|
+
|
|
79
|
+
GFDNAVI_OTHER_GFDNAVI_SERVERS = gfdnavi_configuration("other_gfdnavi_servers",true)
|
|
80
|
+
if GFDNAVI_OTHER_GFDNAVI_SERVERS && !Array === GFDNAVI_OTHER_GFDNAVI_SERVERS
|
|
81
|
+
raise "gfdnavi config file error: other_gfdnavi_servers must be an array"
|
|
82
|
+
end
|
|
83
|
+
|
|
84
|
+
GFDNAVI_USER_PATH = gfdnavi_path( gfdnavi_configuration('user_path') )
|
|
85
|
+
raise("Name of the user directory must be 'usr'") if File.basename(GFDNAVI_USER_PATH) != 'usr'
|
|
86
|
+
|
|
87
|
+
GFDNAVI_WORK_PATH = gfdnavi_path( gfdnavi_configuration('work_path') )
|
|
88
|
+
|
|
89
|
+
|
|
90
|
+
[GFDNAVI_DATA_PATH, GFDNAVI_USER_PATH, GFDNAVI_WORK_PATH].each{|path|
|
|
91
|
+
FileUtils.makedirs(path) unless File.exist?(path)
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
GFDNAVI_DIAGRAM_CACHE_PATH = gfdnavi_path( gfdnavi_configuration('diagram_cache_path') )
|
|
95
|
+
FileUtils.makedirs(GFDNAVI_DIAGRAM_CACHE_PATH) unless File.exist?(GFDNAVI_DIAGRAM_CACHE_PATH)
|
|
96
|
+
|
|
97
|
+
GFDNAVI_DATA_CACHE_PATH = gfdnavi_path( gfdnavi_configuration('data_cache_path') )
|
|
98
|
+
FileUtils.makedirs(GFDNAVI_DATA_CACHE_PATH) unless File.exist?(GFDNAVI_DATA_CACHE_PATH)
|
|
99
|
+
|
|
100
|
+
|
|
101
|
+
GFDNAVI_IGNORED_DIRS = gfdnavi_configuration('ignored_dirs')
|
|
102
|
+
|
|
103
|
+
GFDNAVI_DEBUG = (gfdnavi_configuration("debug",true) == true)
|
|
104
|
+
|
|
105
|
+
GFDNAVI_BENCHMARK = (gfdnavi_configuration("benchmark",true) == true)
|
|
106
|
+
|
|
107
|
+
GFDNAVI_DISABLE_USER = (gfdnavi_configuration("disable_user",true) == true)
|
|
108
|
+
|
|
109
|
+
GFDNAVI_PROXY = gfdnavi_configuration('proxy',true)
|
|
110
|
+
|
|
111
|
+
GFDNAVI_USING_PROXY = (gfdnavi_configuration("using_proxy",true) == true)
|
|
112
|
+
|
|
113
|
+
GFDNAVI_ALLOW_ANY_OPENID = (gfdnavi_configuration("allow_any_openid",true) == true)
|
|
114
|
+
|
|
115
|
+
GFDNAVI_PAGINATE_PER = gfdnavi_configuration("paginate_per")
|
|
116
|
+
|
|
117
|
+
GFDNAVI_GOOGLE_MAP_KEY = gfdnavi_configuration('google_map_key')
|
|
118
|
+
|
|
119
|
+
GFDNAVI_CROSS_SEARCH_SERVER = gfdnavi_configuration('cross_search_center_server')
|
|
120
|
+
|
|
121
|
+
GFDNAVI_PASSPHRASE = gfdnavi_configuration('passphrase')
|
|
122
|
+
|
|
123
|
+
GFDNAVI_SECRET = gfdnavi_configuration('secret')
|
|
124
|
+
|
|
125
|
+
GFDNAVI_SESSION_DURATION = gfdnavi_configuration('session_duration')
|
|
126
|
+
|
|
127
|
+
GFDNAVI_IGNORED_ATTRS = gfdnavi_configuration('ignored_attributes')
|
|
128
|
+
|
|
129
|
+
GFDNAVI_INVISIBLE_ATTRS = gfdnavi_configuration('invisible_attributes')
|
|
130
|
+
|
|
131
|
+
admin = gfdnavi_configuration('admin')
|
|
132
|
+
GFDNAVI_ADMIN_NAME = admin['name']
|
|
133
|
+
GFDNAVI_ADMIN_EMAIL = admin['email']
|
|
134
|
+
|
|
135
|
+
GFDNAVI_ENABLE_EMAIL = (gfdnavi_configuration("enable_email",true) == true)
|
|
136
|
+
|
|
137
|
+
if GFDNAVI_ENABLE_EMAIL
|
|
138
|
+
ActionMailer::Base.smtp_settings = gfdnavi_configuration('smtp')
|
|
139
|
+
end
|
|
140
|
+
|
|
141
|
+
GPHYS_READ_SIZE_LIMIT_1 = sl =
|
|
142
|
+
gfdnavi_configuration("soft_limit_array_size",true)
|
|
143
|
+
GPHYS_READ_SIZE_LIMIT_2 = hl =
|
|
144
|
+
gfdnavi_configuration("hard_limit_array_size",true)
|
|
145
|
+
if hl && sl && hl <= sl
|
|
146
|
+
raise "hard limit must be greather than soft limit"
|
|
147
|
+
end
|
|
148
|
+
|
|
149
|
+
# clean up
|
|
150
|
+
@gfdnavi_configuration_file = nil
|
|
151
|
+
@gfdnavi_configuration = nil
|