sprokovuln 0.2.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.
- checksums.yaml +7 -0
- data/.gitignore +8 -0
- data/Gemfile +6 -0
- data/Gemfile.lock +26 -0
- data/README.md +35 -0
- data/Rakefile +2 -0
- data/bin/console +14 -0
- data/bin/setup +8 -0
- data/lib/sprokovuln/version.rb +3 -0
- data/lib/sprokovuln.rb +5 -0
- data/sprokovuln.gemspec +26 -0
- data/vendor/ruby/bin/rackup +27 -0
- data/vendor/ruby/bin/rake +27 -0
- data/vendor/ruby/bin/sprockets +27 -0
- data/vendor/ruby/cache/concurrent-ruby-1.0.5.gem +0 -0
- data/vendor/ruby/cache/rack-2.0.5.gem +0 -0
- data/vendor/ruby/cache/rake-10.5.0.gem +0 -0
- data/vendor/ruby/cache/sprockets-3.7.1.gem +0 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/CHANGELOG.md +387 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/LICENSE.txt +21 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/README.md +247 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/agent.rb +587 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/array.rb +39 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/async.rb +445 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atom.rb +222 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/abstract_thread_local_var.rb +66 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/atomic_boolean.rb +122 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/atomic_fixnum.rb +139 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/atomic_reference.rb +51 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/count_down_latch.rb +100 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/cyclic_barrier.rb +128 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/event.rb +109 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/java_count_down_latch.rb +39 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/java_thread_local_var.rb +37 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/mutex_atomic_boolean.rb +60 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/mutex_atomic_fixnum.rb +75 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/mutex_count_down_latch.rb +43 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/mutex_semaphore.rb +115 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/read_write_lock.rb +253 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/reentrant_read_write_lock.rb +377 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/ruby_thread_local_var.rb +161 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/semaphore.rb +145 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic/thread_local_var.rb +104 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic_reference/concurrent_update_error.rb +8 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic_reference/direct_update.rb +81 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic_reference/jruby+truffle.rb +2 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic_reference/jruby.rb +16 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic_reference/mutex_atomic.rb +61 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic_reference/numeric_cas_wrapper.rb +28 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic_reference/rbx.rb +22 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomic_reference/ruby.rb +32 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/atomics.rb +53 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/collection/copy_on_notify_observer_set.rb +107 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/collection/copy_on_write_observer_set.rb +111 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/collection/java_non_concurrent_priority_queue.rb +84 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/collection/map/atomic_reference_map_backend.rb +927 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/collection/map/mri_map_backend.rb +66 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/collection/map/non_concurrent_map_backend.rb +141 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/collection/map/synchronized_map_backend.rb +82 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/collection/non_concurrent_priority_queue.rb +143 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/collection/ruby_non_concurrent_priority_queue.rb +150 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/concern/deprecation.rb +34 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/concern/dereferenceable.rb +73 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/concern/logging.rb +27 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/concern/obligation.rb +220 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/concern/observable.rb +110 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/configuration.rb +188 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/constants.rb +8 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/dataflow.rb +80 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/delay.rb +197 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/edge.rb +26 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/errors.rb +69 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/exchanger.rb +356 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/abstract_executor_service.rb +134 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/cached_thread_pool.rb +62 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/executor_service.rb +185 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/fixed_thread_pool.rb +206 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/immediate_executor.rb +66 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/indirect_immediate_executor.rb +44 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/java_executor_service.rb +100 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/java_single_thread_executor.rb +29 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/java_thread_pool_executor.rb +120 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/ruby_executor_service.rb +78 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/ruby_single_thread_executor.rb +22 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/ruby_thread_pool_executor.rb +362 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/safe_task_executor.rb +35 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/serial_executor_service.rb +34 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/serialized_execution.rb +107 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/serialized_execution_delegator.rb +28 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/simple_executor_service.rb +100 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/single_thread_executor.rb +56 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/thread_pool_executor.rb +87 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executor/timer_set.rb +175 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/executors.rb +20 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/future.rb +138 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/hash.rb +36 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/immutable_struct.rb +93 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/ivar.rb +208 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/lazy_register.rb +81 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/map.rb +240 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/maybe.rb +229 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/mutable_struct.rb +228 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/mvar.rb +242 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/options.rb +42 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/promise.rb +547 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/scheduled_task.rb +318 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/settable_struct.rb +128 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/abstract_lockable_object.rb +98 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/abstract_object.rb +24 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/abstract_struct.rb +157 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/condition.rb +58 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/jruby_lockable_object.rb +13 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/jruby_object.rb +44 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/lock.rb +34 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/lockable_object.rb +74 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/mri_lockable_object.rb +71 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/mri_object.rb +43 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/object.rb +153 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/rbx_lockable_object.rb +65 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/rbx_object.rb +48 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/truffle_lockable_object.rb +9 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/truffle_object.rb +31 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization/volatile.rb +34 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/synchronization.rb +31 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/thread_safe/synchronized_delegator.rb +50 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/thread_safe/util/adder.rb +74 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/thread_safe/util/array_hash_rbx.rb +30 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/thread_safe/util/cheap_lockable.rb +118 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/thread_safe/util/power_of_two_tuple.rb +38 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/thread_safe/util/striped64.rb +241 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/thread_safe/util/volatile.rb +75 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/thread_safe/util/xor_shift_random.rb +50 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/thread_safe/util.rb +16 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/timer_task.rb +331 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/tuple.rb +86 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/tvar.rb +258 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/utility/at_exit.rb +97 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/utility/engine.rb +56 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/utility/monotonic_time.rb +58 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/utility/native_extension_loader.rb +73 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/utility/native_integer.rb +53 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/utility/processor_counter.rb +160 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent/version.rb +4 -0
- data/vendor/ruby/gems/concurrent-ruby-1.0.5/lib/concurrent.rb +130 -0
- data/vendor/ruby/gems/rack-2.0.5/COPYING +18 -0
- data/vendor/ruby/gems/rack-2.0.5/HISTORY.md +505 -0
- data/vendor/ruby/gems/rack-2.0.5/README.rdoc +302 -0
- data/vendor/ruby/gems/rack-2.0.5/Rakefile +116 -0
- data/vendor/ruby/gems/rack-2.0.5/SPEC +263 -0
- data/vendor/ruby/gems/rack-2.0.5/bin/rackup +4 -0
- data/vendor/ruby/gems/rack-2.0.5/contrib/rack.png +0 -0
- data/vendor/ruby/gems/rack-2.0.5/contrib/rack.svg +150 -0
- data/vendor/ruby/gems/rack-2.0.5/contrib/rack_logo.svg +164 -0
- data/vendor/ruby/gems/rack-2.0.5/contrib/rdoc.css +412 -0
- data/vendor/ruby/gems/rack-2.0.5/example/lobster.ru +4 -0
- data/vendor/ruby/gems/rack-2.0.5/example/protectedlobster.rb +14 -0
- data/vendor/ruby/gems/rack-2.0.5/example/protectedlobster.ru +8 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/auth/abstract/handler.rb +37 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/auth/abstract/request.rb +47 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/auth/basic.rb +58 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/auth/digest/md5.rb +129 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/auth/digest/nonce.rb +51 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/auth/digest/params.rb +52 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/auth/digest/request.rb +41 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/body_proxy.rb +44 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/builder.rb +164 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/cascade.rb +52 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/chunked.rb +69 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/common_logger.rb +72 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/conditional_get.rb +79 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/config.rb +20 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/content_length.rb +37 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/content_type.rb +29 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/deflater.rb +119 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/directory.rb +179 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/etag.rb +74 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/events.rb +154 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/file.rb +176 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/handler/cgi.rb +60 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/handler/fastcgi.rb +100 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/handler/lsws.rb +61 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/handler/scgi.rb +70 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/handler/thin.rb +36 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/handler/webrick.rb +120 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/handler.rb +99 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/head.rb +25 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/lint.rb +760 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/lobster.rb +70 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/lock.rb +31 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/logger.rb +18 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/media_type.rb +38 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/method_override.rb +50 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/mime.rb +677 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/mock.rb +196 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/multipart/generator.rb +93 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/multipart/parser.rb +369 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/multipart/uploaded_file.rb +33 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/multipart.rb +63 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/null_logger.rb +37 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/query_parser.rb +192 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/recursive.rb +62 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/reloader.rb +110 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/request.rb +487 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/response.rb +235 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/rewindable_input.rb +93 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/runtime.rb +32 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/sendfile.rb +158 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/server.rb +395 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/session/abstract/id.rb +445 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/session/cookie.rb +195 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/session/memcache.rb +93 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/session/pool.rb +76 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/show_exceptions.rb +386 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/show_status.rb +113 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/static.rb +175 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/tempfile_reaper.rb +22 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/urlmap.rb +91 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack/utils.rb +620 -0
- data/vendor/ruby/gems/rack-2.0.5/lib/rack.rb +147 -0
- data/vendor/ruby/gems/rack-2.0.5/rack.gemspec +34 -0
- data/vendor/ruby/gems/rack-2.0.5/test/builder/an_underscore_app.rb +5 -0
- data/vendor/ruby/gems/rack-2.0.5/test/builder/anything.rb +5 -0
- data/vendor/ruby/gems/rack-2.0.5/test/builder/comment.ru +4 -0
- data/vendor/ruby/gems/rack-2.0.5/test/builder/end.ru +5 -0
- data/vendor/ruby/gems/rack-2.0.5/test/builder/line.ru +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/builder/options.ru +2 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/assets/folder/test.js +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/assets/fonts/font.eot +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/assets/images/image.png +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/assets/index.html +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/assets/javascripts/app.js +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/assets/stylesheets/app.css +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/lighttpd.conf +26 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/rackup_stub.rb +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/sample_rackup.ru +5 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/test +9 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/test+directory/test+file +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/test.fcgi +9 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/test.gz +0 -0
- data/vendor/ruby/gems/rack-2.0.5/test/cgi/test.ru +5 -0
- data/vendor/ruby/gems/rack-2.0.5/test/gemloader.rb +10 -0
- data/vendor/ruby/gems/rack-2.0.5/test/helper.rb +34 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/bad_robots +259 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/binary +0 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/content_type_and_no_filename +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/empty +10 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/fail_16384_nofile +814 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/file1.txt +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_and_modification_param +7 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_and_no_name +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_encoded_words +7 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_escaped_quotes +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_escaped_quotes_and_modification_param +7 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_null_byte +7 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_percent_escaped_quotes +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_single_quote +7 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_unescaped_percentages +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_unescaped_percentages2 +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_unescaped_percentages3 +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/filename_with_unescaped_quotes +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/ie +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/invalid_character +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/mixed_files +21 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/nested +10 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/none +9 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/quoted +15 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/rack-logo.png +0 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/semicolon +6 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/text +15 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/three_files_three_fields +31 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/unity3d_wwwform +11 -0
- data/vendor/ruby/gems/rack-2.0.5/test/multipart/webkit +32 -0
- data/vendor/ruby/gems/rack-2.0.5/test/rackup/config.ru +31 -0
- data/vendor/ruby/gems/rack-2.0.5/test/registering_handler/rack/handler/registering_myself.rb +8 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_auth_basic.rb +89 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_auth_digest.rb +260 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_body_proxy.rb +85 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_builder.rb +233 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_cascade.rb +63 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_cgi.rb +84 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_chunked.rb +103 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_common_logger.rb +95 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_conditional_get.rb +103 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_config.rb +23 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_content_length.rb +86 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_content_type.rb +46 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_deflater.rb +375 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_directory.rb +148 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_etag.rb +108 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_events.rb +133 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_fastcgi.rb +85 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_file.rb +264 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_handler.rb +57 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_head.rb +46 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_lint.rb +515 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_lobster.rb +59 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_lock.rb +204 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_logger.rb +24 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_media_type.rb +42 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_method_override.rb +110 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_mime.rb +51 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_mock.rb +359 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_multipart.rb +722 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_null_logger.rb +21 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_recursive.rb +75 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_request.rb +1393 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_response.rb +510 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_rewindable_input.rb +128 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_runtime.rb +50 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_sendfile.rb +125 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_server.rb +193 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_session_abstract_id.rb +31 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_session_abstract_session_hash.rb +45 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_session_cookie.rb +442 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_session_memcache.rb +320 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_session_pool.rb +210 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_show_exceptions.rb +80 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_show_status.rb +104 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_static.rb +184 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_tempfile_reaper.rb +64 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_thin.rb +96 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_urlmap.rb +237 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_utils.rb +742 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_version.rb +11 -0
- data/vendor/ruby/gems/rack-2.0.5/test/spec_webrick.rb +206 -0
- data/vendor/ruby/gems/rack-2.0.5/test/static/another/index.html +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/static/foo.html +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/static/index.html +1 -0
- data/vendor/ruby/gems/rack-2.0.5/test/testrequest.rb +78 -0
- data/vendor/ruby/gems/rack-2.0.5/test/unregistered_handler/rack/handler/unregistered.rb +7 -0
- data/vendor/ruby/gems/rack-2.0.5/test/unregistered_handler/rack/handler/unregistered_long_one.rb +7 -0
- data/vendor/ruby/gems/rake-10.5.0/.autotest +7 -0
- data/vendor/ruby/gems/rake-10.5.0/.rubocop.yml +27 -0
- data/vendor/ruby/gems/rake-10.5.0/.togglerc +7 -0
- data/vendor/ruby/gems/rake-10.5.0/CONTRIBUTING.rdoc +38 -0
- data/vendor/ruby/gems/rake-10.5.0/History.rdoc +659 -0
- data/vendor/ruby/gems/rake-10.5.0/MIT-LICENSE +21 -0
- data/vendor/ruby/gems/rake-10.5.0/Manifest.txt +166 -0
- data/vendor/ruby/gems/rake-10.5.0/README.rdoc +139 -0
- data/vendor/ruby/gems/rake-10.5.0/Rakefile +81 -0
- data/vendor/ruby/gems/rake-10.5.0/bin/rake +33 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/command_line_usage.rdoc +158 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/example/Rakefile1 +38 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/example/Rakefile2 +35 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/example/a.c +6 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/example/b.c +6 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/example/main.c +11 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/glossary.rdoc +42 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/jamis.rb +591 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/proto_rake.rdoc +127 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/rake.1 +141 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/rakefile.rdoc +624 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/rational.rdoc +151 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.4.14.rdoc +23 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.4.15.rdoc +35 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.5.0.rdoc +53 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.5.3.rdoc +78 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.5.4.rdoc +46 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.6.0.rdoc +141 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.7.0.rdoc +119 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.7.1.rdoc +59 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.7.2.rdoc +121 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.7.3.rdoc +47 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.8.0.rdoc +114 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.8.2.rdoc +165 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.8.3.rdoc +112 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.8.4.rdoc +147 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.8.5.rdoc +53 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.8.6.rdoc +37 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.8.7.rdoc +55 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.9.0.rdoc +112 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.9.1.rdoc +52 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.9.2.2.rdoc +55 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.9.2.rdoc +49 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.9.3.rdoc +102 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.9.4.rdoc +60 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.9.5.rdoc +55 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-0.9.6.rdoc +64 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-10.0.0.rdoc +178 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-10.0.1.rdoc +58 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-10.0.2.rdoc +53 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-10.0.3.rdoc +191 -0
- data/vendor/ruby/gems/rake-10.5.0/doc/release_notes/rake-10.1.0.rdoc +61 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/alt_system.rb +110 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/application.rb +790 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/backtrace.rb +23 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/clean.rb +76 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/cloneable.rb +16 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/contrib/.document +1 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/contrib/compositepublisher.rb +21 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/contrib/ftptools.rb +137 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/contrib/publisher.rb +81 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/contrib/rubyforgepublisher.rb +18 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/contrib/sshpublisher.rb +61 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/contrib/sys.rb +4 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/cpu_counter.rb +125 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/default_loader.rb +14 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/dsl_definition.rb +201 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/early_time.rb +21 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/ext/core.rb +25 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/ext/module.rb +2 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/ext/pathname.rb +25 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/ext/string.rb +175 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/ext/time.rb +18 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/file_creation_task.rb +24 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/file_list.rb +428 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/file_task.rb +46 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/file_utils.rb +128 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/file_utils_ext.rb +144 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/gempackagetask.rb +4 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/invocation_chain.rb +56 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/invocation_exception_mixin.rb +16 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/late_time.rb +17 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/linked_list.rb +103 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/loaders/makefile.rb +53 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/multi_task.rb +13 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/name_space.rb +38 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/packagetask.rb +199 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/pathmap.rb +3 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/phony.rb +15 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/private_reader.rb +20 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/promise.rb +99 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/pseudo_status.rb +29 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/rake_module.rb +38 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/rake_test_loader.rb +22 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/rdoctask.rb +4 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/ruby182_test_unit_fix.rb +29 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/rule_recursion_overflow_error.rb +20 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/runtest.rb +27 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/scope.rb +42 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/task.rb +383 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/task_argument_error.rb +7 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/task_arguments.rb +98 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/task_manager.rb +307 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/tasklib.rb +24 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/testtask.rb +213 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/thread_history_display.rb +48 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/thread_pool.rb +164 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/trace_output.rb +22 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/version.rb +7 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake/win32.rb +56 -0
- data/vendor/ruby/gems/rake-10.5.0/lib/rake.rb +79 -0
- data/vendor/ruby/gems/rake-10.5.0/rakelib/publish.rake +20 -0
- data/vendor/ruby/gems/rake-10.5.0/rakelib/test_times.rake +25 -0
- data/vendor/ruby/gems/rake-10.5.0/test/file_creation.rb +34 -0
- data/vendor/ruby/gems/rake-10.5.0/test/helper.rb +129 -0
- data/vendor/ruby/gems/rake-10.5.0/test/support/rakefile_definitions.rb +478 -0
- data/vendor/ruby/gems/rake-10.5.0/test/support/ruby_runner.rb +34 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_private_reader.rb +42 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake.rb +40 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_application.rb +643 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_application_options.rb +468 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_backtrace.rb +119 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_clean.rb +61 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_cpu_counter.rb +68 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_definitions.rb +84 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_directory_task.rb +76 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_dsl.rb +40 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_early_time.rb +31 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_extension.rb +59 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_file_creation_task.rb +56 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_file_list.rb +670 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_file_list_path_map.rb +8 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_file_task.rb +197 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_file_utils.rb +314 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_ftp_file.rb +74 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_functional.rb +482 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_invocation_chain.rb +64 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_late_time.rb +18 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_linked_list.rb +84 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_makefile_loader.rb +46 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_multi_task.rb +64 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_name_space.rb +57 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_package_task.rb +79 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_path_map.rb +168 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_path_map_explode.rb +34 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_path_map_partial.rb +18 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_pathname_extensions.rb +15 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_pseudo_status.rb +21 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_rake_test_loader.rb +20 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_reduce_compat.rb +26 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_require.rb +40 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_rules.rb +388 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_scope.rb +44 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_task.rb +393 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_task_argument_parsing.rb +119 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_task_arguments.rb +127 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_task_lib.rb +9 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_task_manager.rb +178 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_task_manager_argument_resolution.rb +19 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_task_with_arguments.rb +172 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_test_task.rb +146 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_thread_pool.rb +145 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_top_level_functions.rb +71 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_rake_win32.rb +72 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_thread_history_display.rb +101 -0
- data/vendor/ruby/gems/rake-10.5.0/test/test_trace_output.rb +52 -0
- data/vendor/ruby/gems/sprockets-3.7.1/CHANGELOG.md +292 -0
- data/vendor/ruby/gems/sprockets-3.7.1/LICENSE +21 -0
- data/vendor/ruby/gems/sprockets-3.7.1/README.md +509 -0
- data/vendor/ruby/gems/sprockets-3.7.1/bin/sprockets +89 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/rake/sprocketstask.rb +152 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/asset.rb +200 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/autoload/closure.rb +7 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/autoload/coffee_script.rb +7 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/autoload/eco.rb +7 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/autoload/ejs.rb +7 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/autoload/sass.rb +7 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/autoload/uglifier.rb +7 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/autoload/yui.rb +7 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/autoload.rb +11 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/base.rb +110 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/bower.rb +58 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/bundle.rb +69 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/cache/file_store.rb +186 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/cache/memory_store.rb +66 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/cache/null_store.rb +46 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/cache.rb +236 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/cached_environment.rb +69 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/closure_compressor.rb +47 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/coffee_script_processor.rb +25 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/coffee_script_template.rb +17 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/compressing.rb +94 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/configuration.rb +83 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/context.rb +231 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/dependencies.rb +73 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/deprecation.rb +90 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/digest_utils.rb +180 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/directive_processor.rb +404 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/eco_processor.rb +32 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/eco_template.rb +17 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/ejs_processor.rb +31 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/ejs_template.rb +17 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/encoding_utils.rb +261 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/engines.rb +92 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/environment.rb +41 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/erb_processor.rb +30 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/erb_template.rb +11 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/errors.rb +11 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/file_reader.rb +15 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/http_utils.rb +117 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/jst_processor.rb +49 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/legacy.rb +330 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/legacy_proc_processor.rb +35 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/legacy_tilt_processor.rb +29 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/loader.rb +325 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/manifest.rb +335 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/manifest_utils.rb +45 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/mime.rb +130 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/path_dependency_utils.rb +85 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/path_digest_utils.rb +47 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/path_utils.rb +287 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/paths.rb +81 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/processing.rb +258 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/processor_utils.rb +180 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/resolve.rb +211 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/sass_cache_store.rb +34 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/sass_compressor.rb +51 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/sass_functions.rb +2 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/sass_importer.rb +2 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/sass_processor.rb +292 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/sass_template.rb +19 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/server.rb +292 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/transformers.rb +145 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/uglifier_compressor.rb +56 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/unloaded_asset.rb +137 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/uri_tar.rb +98 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/uri_utils.rb +188 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/utils/gzip.rb +67 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/utils.rb +235 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/version.rb +3 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets/yui_compressor.rb +55 -0
- data/vendor/ruby/gems/sprockets-3.7.1/lib/sprockets.rb +169 -0
- data/vendor/ruby/specifications/concurrent-ruby-1.0.5.gemspec +23 -0
- data/vendor/ruby/specifications/rack-2.0.5.gemspec +42 -0
- data/vendor/ruby/specifications/rake-10.5.0.gemspec +43 -0
- data/vendor/ruby/specifications/sprockets-3.7.1.gemspec +78 -0
- metadata +660 -0
@@ -0,0 +1,66 @@
|
|
1
|
+
require 'thread'
|
2
|
+
require 'concurrent/collection/map/non_concurrent_map_backend'
|
3
|
+
|
4
|
+
module Concurrent
|
5
|
+
|
6
|
+
# @!visibility private
|
7
|
+
module Collection
|
8
|
+
|
9
|
+
# @!visibility private
|
10
|
+
class MriMapBackend < NonConcurrentMapBackend
|
11
|
+
|
12
|
+
def initialize(options = nil)
|
13
|
+
super(options)
|
14
|
+
@write_lock = Mutex.new
|
15
|
+
end
|
16
|
+
|
17
|
+
def []=(key, value)
|
18
|
+
@write_lock.synchronize { super }
|
19
|
+
end
|
20
|
+
|
21
|
+
def compute_if_absent(key)
|
22
|
+
if stored_value = _get(key) # fast non-blocking path for the most likely case
|
23
|
+
stored_value
|
24
|
+
else
|
25
|
+
@write_lock.synchronize { super }
|
26
|
+
end
|
27
|
+
end
|
28
|
+
|
29
|
+
def compute_if_present(key)
|
30
|
+
@write_lock.synchronize { super }
|
31
|
+
end
|
32
|
+
|
33
|
+
def compute(key)
|
34
|
+
@write_lock.synchronize { super }
|
35
|
+
end
|
36
|
+
|
37
|
+
def merge_pair(key, value)
|
38
|
+
@write_lock.synchronize { super }
|
39
|
+
end
|
40
|
+
|
41
|
+
def replace_pair(key, old_value, new_value)
|
42
|
+
@write_lock.synchronize { super }
|
43
|
+
end
|
44
|
+
|
45
|
+
def replace_if_exists(key, new_value)
|
46
|
+
@write_lock.synchronize { super }
|
47
|
+
end
|
48
|
+
|
49
|
+
def get_and_set(key, value)
|
50
|
+
@write_lock.synchronize { super }
|
51
|
+
end
|
52
|
+
|
53
|
+
def delete(key)
|
54
|
+
@write_lock.synchronize { super }
|
55
|
+
end
|
56
|
+
|
57
|
+
def delete_pair(key, value)
|
58
|
+
@write_lock.synchronize { super }
|
59
|
+
end
|
60
|
+
|
61
|
+
def clear
|
62
|
+
@write_lock.synchronize { super }
|
63
|
+
end
|
64
|
+
end
|
65
|
+
end
|
66
|
+
end
|
@@ -0,0 +1,141 @@
|
|
1
|
+
require 'concurrent/constants'
|
2
|
+
|
3
|
+
module Concurrent
|
4
|
+
|
5
|
+
# @!visibility private
|
6
|
+
module Collection
|
7
|
+
|
8
|
+
# @!visibility private
|
9
|
+
class NonConcurrentMapBackend
|
10
|
+
|
11
|
+
# WARNING: all public methods of the class must operate on the @backend
|
12
|
+
# directly without calling each other. This is important because of the
|
13
|
+
# SynchronizedMapBackend which uses a non-reentrant mutex for perfomance
|
14
|
+
# reasons.
|
15
|
+
def initialize(options = nil)
|
16
|
+
@backend = {}
|
17
|
+
end
|
18
|
+
|
19
|
+
def [](key)
|
20
|
+
@backend[key]
|
21
|
+
end
|
22
|
+
|
23
|
+
def []=(key, value)
|
24
|
+
@backend[key] = value
|
25
|
+
end
|
26
|
+
|
27
|
+
def compute_if_absent(key)
|
28
|
+
if NULL != (stored_value = @backend.fetch(key, NULL))
|
29
|
+
stored_value
|
30
|
+
else
|
31
|
+
@backend[key] = yield
|
32
|
+
end
|
33
|
+
end
|
34
|
+
|
35
|
+
def replace_pair(key, old_value, new_value)
|
36
|
+
if pair?(key, old_value)
|
37
|
+
@backend[key] = new_value
|
38
|
+
true
|
39
|
+
else
|
40
|
+
false
|
41
|
+
end
|
42
|
+
end
|
43
|
+
|
44
|
+
def replace_if_exists(key, new_value)
|
45
|
+
if NULL != (stored_value = @backend.fetch(key, NULL))
|
46
|
+
@backend[key] = new_value
|
47
|
+
stored_value
|
48
|
+
end
|
49
|
+
end
|
50
|
+
|
51
|
+
def compute_if_present(key)
|
52
|
+
if NULL != (stored_value = @backend.fetch(key, NULL))
|
53
|
+
store_computed_value(key, yield(stored_value))
|
54
|
+
end
|
55
|
+
end
|
56
|
+
|
57
|
+
def compute(key)
|
58
|
+
store_computed_value(key, yield(@backend[key]))
|
59
|
+
end
|
60
|
+
|
61
|
+
def merge_pair(key, value)
|
62
|
+
if NULL == (stored_value = @backend.fetch(key, NULL))
|
63
|
+
@backend[key] = value
|
64
|
+
else
|
65
|
+
store_computed_value(key, yield(stored_value))
|
66
|
+
end
|
67
|
+
end
|
68
|
+
|
69
|
+
def get_and_set(key, value)
|
70
|
+
stored_value = @backend[key]
|
71
|
+
@backend[key] = value
|
72
|
+
stored_value
|
73
|
+
end
|
74
|
+
|
75
|
+
def key?(key)
|
76
|
+
@backend.key?(key)
|
77
|
+
end
|
78
|
+
|
79
|
+
def delete(key)
|
80
|
+
@backend.delete(key)
|
81
|
+
end
|
82
|
+
|
83
|
+
def delete_pair(key, value)
|
84
|
+
if pair?(key, value)
|
85
|
+
@backend.delete(key)
|
86
|
+
true
|
87
|
+
else
|
88
|
+
false
|
89
|
+
end
|
90
|
+
end
|
91
|
+
|
92
|
+
def clear
|
93
|
+
@backend.clear
|
94
|
+
self
|
95
|
+
end
|
96
|
+
|
97
|
+
def each_pair
|
98
|
+
return enum_for :each_pair unless block_given?
|
99
|
+
dupped_backend.each_pair do |k, v|
|
100
|
+
yield k, v
|
101
|
+
end
|
102
|
+
self
|
103
|
+
end
|
104
|
+
|
105
|
+
def size
|
106
|
+
@backend.size
|
107
|
+
end
|
108
|
+
|
109
|
+
def get_or_default(key, default_value)
|
110
|
+
@backend.fetch(key, default_value)
|
111
|
+
end
|
112
|
+
|
113
|
+
alias_method :_get, :[]
|
114
|
+
alias_method :_set, :[]=
|
115
|
+
private :_get, :_set
|
116
|
+
private
|
117
|
+
def initialize_copy(other)
|
118
|
+
super
|
119
|
+
@backend = {}
|
120
|
+
self
|
121
|
+
end
|
122
|
+
|
123
|
+
def dupped_backend
|
124
|
+
@backend.dup
|
125
|
+
end
|
126
|
+
|
127
|
+
def pair?(key, expected_value)
|
128
|
+
NULL != (stored_value = @backend.fetch(key, NULL)) && expected_value.equal?(stored_value)
|
129
|
+
end
|
130
|
+
|
131
|
+
def store_computed_value(key, new_value)
|
132
|
+
if new_value.nil?
|
133
|
+
@backend.delete(key)
|
134
|
+
nil
|
135
|
+
else
|
136
|
+
@backend[key] = new_value
|
137
|
+
end
|
138
|
+
end
|
139
|
+
end
|
140
|
+
end
|
141
|
+
end
|
@@ -0,0 +1,82 @@
|
|
1
|
+
require 'concurrent/collection/map/non_concurrent_map_backend'
|
2
|
+
|
3
|
+
module Concurrent
|
4
|
+
|
5
|
+
# @!visibility private
|
6
|
+
module Collection
|
7
|
+
|
8
|
+
# @!visibility private
|
9
|
+
class SynchronizedMapBackend < NonConcurrentMapBackend
|
10
|
+
|
11
|
+
require 'mutex_m'
|
12
|
+
include Mutex_m
|
13
|
+
# WARNING: Mutex_m is a non-reentrant lock, so the synchronized methods are
|
14
|
+
# not allowed to call each other.
|
15
|
+
|
16
|
+
def [](key)
|
17
|
+
synchronize { super }
|
18
|
+
end
|
19
|
+
|
20
|
+
def []=(key, value)
|
21
|
+
synchronize { super }
|
22
|
+
end
|
23
|
+
|
24
|
+
def compute_if_absent(key)
|
25
|
+
synchronize { super }
|
26
|
+
end
|
27
|
+
|
28
|
+
def compute_if_present(key)
|
29
|
+
synchronize { super }
|
30
|
+
end
|
31
|
+
|
32
|
+
def compute(key)
|
33
|
+
synchronize { super }
|
34
|
+
end
|
35
|
+
|
36
|
+
def merge_pair(key, value)
|
37
|
+
synchronize { super }
|
38
|
+
end
|
39
|
+
|
40
|
+
def replace_pair(key, old_value, new_value)
|
41
|
+
synchronize { super }
|
42
|
+
end
|
43
|
+
|
44
|
+
def replace_if_exists(key, new_value)
|
45
|
+
synchronize { super }
|
46
|
+
end
|
47
|
+
|
48
|
+
def get_and_set(key, value)
|
49
|
+
synchronize { super }
|
50
|
+
end
|
51
|
+
|
52
|
+
def key?(key)
|
53
|
+
synchronize { super }
|
54
|
+
end
|
55
|
+
|
56
|
+
def delete(key)
|
57
|
+
synchronize { super }
|
58
|
+
end
|
59
|
+
|
60
|
+
def delete_pair(key, value)
|
61
|
+
synchronize { super }
|
62
|
+
end
|
63
|
+
|
64
|
+
def clear
|
65
|
+
synchronize { super }
|
66
|
+
end
|
67
|
+
|
68
|
+
def size
|
69
|
+
synchronize { super }
|
70
|
+
end
|
71
|
+
|
72
|
+
def get_or_default(key, default_value)
|
73
|
+
synchronize { super }
|
74
|
+
end
|
75
|
+
|
76
|
+
private
|
77
|
+
def dupped_backend
|
78
|
+
synchronize { super }
|
79
|
+
end
|
80
|
+
end
|
81
|
+
end
|
82
|
+
end
|
@@ -0,0 +1,143 @@
|
|
1
|
+
require 'concurrent/collection/java_non_concurrent_priority_queue'
|
2
|
+
require 'concurrent/collection/ruby_non_concurrent_priority_queue'
|
3
|
+
require 'concurrent/utility/engine'
|
4
|
+
|
5
|
+
module Concurrent
|
6
|
+
module Collection
|
7
|
+
|
8
|
+
# @!visibility private
|
9
|
+
# @!macro internal_implementation_note
|
10
|
+
NonConcurrentPriorityQueueImplementation = case
|
11
|
+
when Concurrent.on_jruby?
|
12
|
+
JavaNonConcurrentPriorityQueue
|
13
|
+
else
|
14
|
+
RubyNonConcurrentPriorityQueue
|
15
|
+
end
|
16
|
+
private_constant :NonConcurrentPriorityQueueImplementation
|
17
|
+
|
18
|
+
# @!macro [attach] priority_queue
|
19
|
+
#
|
20
|
+
# A queue collection in which the elements are sorted based on their
|
21
|
+
# comparison (spaceship) operator `<=>`. Items are added to the queue
|
22
|
+
# at a position relative to their priority. On removal the element
|
23
|
+
# with the "highest" priority is removed. By default the sort order is
|
24
|
+
# from highest to lowest, but a lowest-to-highest sort order can be
|
25
|
+
# set on construction.
|
26
|
+
#
|
27
|
+
# The API is based on the `Queue` class from the Ruby standard library.
|
28
|
+
#
|
29
|
+
# The pure Ruby implementation, `RubyNonConcurrentPriorityQueue` uses a heap algorithm
|
30
|
+
# stored in an array. The algorithm is based on the work of Robert Sedgewick
|
31
|
+
# and Kevin Wayne.
|
32
|
+
#
|
33
|
+
# The JRuby native implementation is a thin wrapper around the standard
|
34
|
+
# library `java.util.NonConcurrentPriorityQueue`.
|
35
|
+
#
|
36
|
+
# When running under JRuby the class `NonConcurrentPriorityQueue` extends `JavaNonConcurrentPriorityQueue`.
|
37
|
+
# When running under all other interpreters it extends `RubyNonConcurrentPriorityQueue`.
|
38
|
+
#
|
39
|
+
# @note This implementation is *not* thread safe.
|
40
|
+
#
|
41
|
+
# @see http://en.wikipedia.org/wiki/Priority_queue
|
42
|
+
# @see http://ruby-doc.org/stdlib-2.0.0/libdoc/thread/rdoc/Queue.html
|
43
|
+
#
|
44
|
+
# @see http://algs4.cs.princeton.edu/24pq/index.php#2.6
|
45
|
+
# @see http://algs4.cs.princeton.edu/24pq/MaxPQ.java.html
|
46
|
+
#
|
47
|
+
# @see http://docs.oracle.com/javase/7/docs/api/java/util/PriorityQueue.html
|
48
|
+
#
|
49
|
+
# @!visibility private
|
50
|
+
class NonConcurrentPriorityQueue < NonConcurrentPriorityQueueImplementation
|
51
|
+
|
52
|
+
alias_method :has_priority?, :include?
|
53
|
+
|
54
|
+
alias_method :size, :length
|
55
|
+
|
56
|
+
alias_method :deq, :pop
|
57
|
+
alias_method :shift, :pop
|
58
|
+
|
59
|
+
alias_method :<<, :push
|
60
|
+
alias_method :enq, :push
|
61
|
+
|
62
|
+
# @!method initialize(opts = {})
|
63
|
+
# @!macro [new] priority_queue_method_initialize
|
64
|
+
#
|
65
|
+
# Create a new priority queue with no items.
|
66
|
+
#
|
67
|
+
# @param [Hash] opts the options for creating the queue
|
68
|
+
# @option opts [Symbol] :order (:max) dictates the order in which items are
|
69
|
+
# stored: from highest to lowest when `:max` or `:high`; from lowest to
|
70
|
+
# highest when `:min` or `:low`
|
71
|
+
|
72
|
+
# @!method clear
|
73
|
+
# @!macro [new] priority_queue_method_clear
|
74
|
+
#
|
75
|
+
# Removes all of the elements from this priority queue.
|
76
|
+
|
77
|
+
# @!method delete(item)
|
78
|
+
# @!macro [new] priority_queue_method_delete
|
79
|
+
#
|
80
|
+
# Deletes all items from `self` that are equal to `item`.
|
81
|
+
#
|
82
|
+
# @param [Object] item the item to be removed from the queue
|
83
|
+
# @return [Object] true if the item is found else false
|
84
|
+
|
85
|
+
# @!method empty?
|
86
|
+
# @!macro [new] priority_queue_method_empty
|
87
|
+
#
|
88
|
+
# Returns `true` if `self` contains no elements.
|
89
|
+
#
|
90
|
+
# @return [Boolean] true if there are no items in the queue else false
|
91
|
+
|
92
|
+
# @!method include?(item)
|
93
|
+
# @!macro [new] priority_queue_method_include
|
94
|
+
#
|
95
|
+
# Returns `true` if the given item is present in `self` (that is, if any
|
96
|
+
# element == `item`), otherwise returns false.
|
97
|
+
#
|
98
|
+
# @param [Object] item the item to search for
|
99
|
+
#
|
100
|
+
# @return [Boolean] true if the item is found else false
|
101
|
+
|
102
|
+
# @!method length
|
103
|
+
# @!macro [new] priority_queue_method_length
|
104
|
+
#
|
105
|
+
# The current length of the queue.
|
106
|
+
#
|
107
|
+
# @return [Fixnum] the number of items in the queue
|
108
|
+
|
109
|
+
# @!method peek
|
110
|
+
# @!macro [new] priority_queue_method_peek
|
111
|
+
#
|
112
|
+
# Retrieves, but does not remove, the head of this queue, or returns `nil`
|
113
|
+
# if this queue is empty.
|
114
|
+
#
|
115
|
+
# @return [Object] the head of the queue or `nil` when empty
|
116
|
+
|
117
|
+
# @!method pop
|
118
|
+
# @!macro [new] priority_queue_method_pop
|
119
|
+
#
|
120
|
+
# Retrieves and removes the head of this queue, or returns `nil` if this
|
121
|
+
# queue is empty.
|
122
|
+
#
|
123
|
+
# @return [Object] the head of the queue or `nil` when empty
|
124
|
+
|
125
|
+
# @!method push(item)
|
126
|
+
# @!macro [new] priority_queue_method_push
|
127
|
+
#
|
128
|
+
# Inserts the specified element into this priority queue.
|
129
|
+
#
|
130
|
+
# @param [Object] item the item to insert onto the queue
|
131
|
+
|
132
|
+
# @!method self.from_list(list, opts = {})
|
133
|
+
# @!macro [new] priority_queue_method_from_list
|
134
|
+
#
|
135
|
+
# Create a new priority queue from the given list.
|
136
|
+
#
|
137
|
+
# @param [Enumerable] list the list to build the queue from
|
138
|
+
# @param [Hash] opts the options for creating the queue
|
139
|
+
#
|
140
|
+
# @return [NonConcurrentPriorityQueue] the newly created and populated queue
|
141
|
+
end
|
142
|
+
end
|
143
|
+
end
|
@@ -0,0 +1,150 @@
|
|
1
|
+
module Concurrent
|
2
|
+
module Collection
|
3
|
+
|
4
|
+
# @!macro priority_queue
|
5
|
+
#
|
6
|
+
# @!visibility private
|
7
|
+
# @!macro internal_implementation_note
|
8
|
+
class RubyNonConcurrentPriorityQueue
|
9
|
+
|
10
|
+
# @!macro priority_queue_method_initialize
|
11
|
+
def initialize(opts = {})
|
12
|
+
order = opts.fetch(:order, :max)
|
13
|
+
@comparator = [:min, :low].include?(order) ? -1 : 1
|
14
|
+
clear
|
15
|
+
end
|
16
|
+
|
17
|
+
# @!macro priority_queue_method_clear
|
18
|
+
def clear
|
19
|
+
@queue = [nil]
|
20
|
+
@length = 0
|
21
|
+
true
|
22
|
+
end
|
23
|
+
|
24
|
+
# @!macro priority_queue_method_delete
|
25
|
+
def delete(item)
|
26
|
+
return false if empty?
|
27
|
+
original_length = @length
|
28
|
+
k = 1
|
29
|
+
while k <= @length
|
30
|
+
if @queue[k] == item
|
31
|
+
swap(k, @length)
|
32
|
+
@length -= 1
|
33
|
+
sink(k)
|
34
|
+
@queue.pop
|
35
|
+
else
|
36
|
+
k += 1
|
37
|
+
end
|
38
|
+
end
|
39
|
+
@length != original_length
|
40
|
+
end
|
41
|
+
|
42
|
+
# @!macro priority_queue_method_empty
|
43
|
+
def empty?
|
44
|
+
size == 0
|
45
|
+
end
|
46
|
+
|
47
|
+
# @!macro priority_queue_method_include
|
48
|
+
def include?(item)
|
49
|
+
@queue.include?(item)
|
50
|
+
end
|
51
|
+
alias_method :has_priority?, :include?
|
52
|
+
|
53
|
+
# @!macro priority_queue_method_length
|
54
|
+
def length
|
55
|
+
@length
|
56
|
+
end
|
57
|
+
alias_method :size, :length
|
58
|
+
|
59
|
+
# @!macro priority_queue_method_peek
|
60
|
+
def peek
|
61
|
+
empty? ? nil : @queue[1]
|
62
|
+
end
|
63
|
+
|
64
|
+
# @!macro priority_queue_method_pop
|
65
|
+
def pop
|
66
|
+
return nil if empty?
|
67
|
+
max = @queue[1]
|
68
|
+
swap(1, @length)
|
69
|
+
@length -= 1
|
70
|
+
sink(1)
|
71
|
+
@queue.pop
|
72
|
+
max
|
73
|
+
end
|
74
|
+
alias_method :deq, :pop
|
75
|
+
alias_method :shift, :pop
|
76
|
+
|
77
|
+
# @!macro priority_queue_method_push
|
78
|
+
def push(item)
|
79
|
+
raise ArgumentError.new('cannot enqueue nil') if item.nil?
|
80
|
+
@length += 1
|
81
|
+
@queue << item
|
82
|
+
swim(@length)
|
83
|
+
true
|
84
|
+
end
|
85
|
+
alias_method :<<, :push
|
86
|
+
alias_method :enq, :push
|
87
|
+
|
88
|
+
# @!macro priority_queue_method_from_list
|
89
|
+
def self.from_list(list, opts = {})
|
90
|
+
queue = new(opts)
|
91
|
+
list.each{|item| queue << item }
|
92
|
+
queue
|
93
|
+
end
|
94
|
+
|
95
|
+
private
|
96
|
+
|
97
|
+
# Exchange the values at the given indexes within the internal array.
|
98
|
+
#
|
99
|
+
# @param [Integer] x the first index to swap
|
100
|
+
# @param [Integer] y the second index to swap
|
101
|
+
#
|
102
|
+
# @!visibility private
|
103
|
+
def swap(x, y)
|
104
|
+
temp = @queue[x]
|
105
|
+
@queue[x] = @queue[y]
|
106
|
+
@queue[y] = temp
|
107
|
+
end
|
108
|
+
|
109
|
+
# Are the items at the given indexes ordered based on the priority
|
110
|
+
# order specified at construction?
|
111
|
+
#
|
112
|
+
# @param [Integer] x the first index from which to retrieve a comparable value
|
113
|
+
# @param [Integer] y the second index from which to retrieve a comparable value
|
114
|
+
#
|
115
|
+
# @return [Boolean] true if the two elements are in the correct priority order
|
116
|
+
# else false
|
117
|
+
#
|
118
|
+
# @!visibility private
|
119
|
+
def ordered?(x, y)
|
120
|
+
(@queue[x] <=> @queue[y]) == @comparator
|
121
|
+
end
|
122
|
+
|
123
|
+
# Percolate down to maintain heap invariant.
|
124
|
+
#
|
125
|
+
# @param [Integer] k the index at which to start the percolation
|
126
|
+
#
|
127
|
+
# @!visibility private
|
128
|
+
def sink(k)
|
129
|
+
while (j = (2 * k)) <= @length do
|
130
|
+
j += 1 if j < @length && ! ordered?(j, j+1)
|
131
|
+
break if ordered?(k, j)
|
132
|
+
swap(k, j)
|
133
|
+
k = j
|
134
|
+
end
|
135
|
+
end
|
136
|
+
|
137
|
+
# Percolate up to maintain heap invariant.
|
138
|
+
#
|
139
|
+
# @param [Integer] k the index at which to start the percolation
|
140
|
+
#
|
141
|
+
# @!visibility private
|
142
|
+
def swim(k)
|
143
|
+
while k > 1 && ! ordered?(k/2, k) do
|
144
|
+
swap(k, k/2)
|
145
|
+
k = k/2
|
146
|
+
end
|
147
|
+
end
|
148
|
+
end
|
149
|
+
end
|
150
|
+
end
|
@@ -0,0 +1,34 @@
|
|
1
|
+
require 'concurrent/concern/logging'
|
2
|
+
|
3
|
+
module Concurrent
|
4
|
+
module Concern
|
5
|
+
|
6
|
+
# @!visibility private
|
7
|
+
# @!macro internal_implementation_note
|
8
|
+
module Deprecation
|
9
|
+
# TODO require additional parameter: a version. Display when it'll be removed based on that. Error if not removed.
|
10
|
+
include Concern::Logging
|
11
|
+
|
12
|
+
def deprecated(message, strip = 2)
|
13
|
+
caller_line = caller(strip).first if strip > 0
|
14
|
+
klass = if Module === self
|
15
|
+
self
|
16
|
+
else
|
17
|
+
self.class
|
18
|
+
end
|
19
|
+
message = if strip > 0
|
20
|
+
format("[DEPRECATED] %s\ncalled on: %s", message, caller_line)
|
21
|
+
else
|
22
|
+
format('[DEPRECATED] %s', message)
|
23
|
+
end
|
24
|
+
log WARN, klass.to_s, message
|
25
|
+
end
|
26
|
+
|
27
|
+
def deprecated_method(old_name, new_name)
|
28
|
+
deprecated "`#{old_name}` is deprecated and it'll removed in next release, use `#{new_name}` instead", 3
|
29
|
+
end
|
30
|
+
|
31
|
+
extend self
|
32
|
+
end
|
33
|
+
end
|
34
|
+
end
|
@@ -0,0 +1,73 @@
|
|
1
|
+
module Concurrent
|
2
|
+
module Concern
|
3
|
+
|
4
|
+
# Object references in Ruby are mutable. This can lead to serious problems when
|
5
|
+
# the `#value` of a concurrent object is a mutable reference. Which is always the
|
6
|
+
# case unless the value is a `Fixnum`, `Symbol`, or similar "primitive" data type.
|
7
|
+
# Most classes in this library that expose a `#value` getter method do so using the
|
8
|
+
# `Dereferenceable` mixin module.
|
9
|
+
#
|
10
|
+
# @!macro copy_options
|
11
|
+
module Dereferenceable
|
12
|
+
# NOTE: This module is going away in 2.0. In the mean time we need it to
|
13
|
+
# play nicely with the synchronization layer. This means that the
|
14
|
+
# including class SHOULD be synchronized and it MUST implement a
|
15
|
+
# `#synchronize` method. Not doing so will lead to runtime errors.
|
16
|
+
|
17
|
+
# Return the value this object represents after applying the options specified
|
18
|
+
# by the `#set_deref_options` method.
|
19
|
+
#
|
20
|
+
# @return [Object] the current value of the object
|
21
|
+
def value
|
22
|
+
synchronize { apply_deref_options(@value) }
|
23
|
+
end
|
24
|
+
alias_method :deref, :value
|
25
|
+
|
26
|
+
protected
|
27
|
+
|
28
|
+
# Set the internal value of this object
|
29
|
+
#
|
30
|
+
# @param [Object] value the new value
|
31
|
+
def value=(value)
|
32
|
+
synchronize{ @value = value }
|
33
|
+
end
|
34
|
+
|
35
|
+
# @!macro [attach] dereferenceable_set_deref_options
|
36
|
+
# Set the options which define the operations #value performs before
|
37
|
+
# returning data to the caller (dereferencing).
|
38
|
+
#
|
39
|
+
# @note Most classes that include this module will call `#set_deref_options`
|
40
|
+
# from within the constructor, thus allowing these options to be set at
|
41
|
+
# object creation.
|
42
|
+
#
|
43
|
+
# @param [Hash] opts the options defining dereference behavior.
|
44
|
+
# @option opts [String] :dup_on_deref (false) call `#dup` before returning the data
|
45
|
+
# @option opts [String] :freeze_on_deref (false) call `#freeze` before returning the data
|
46
|
+
# @option opts [String] :copy_on_deref (nil) call the given `Proc` passing
|
47
|
+
# the internal value and returning the value returned from the proc
|
48
|
+
def set_deref_options(opts = {})
|
49
|
+
synchronize{ ns_set_deref_options(opts) }
|
50
|
+
end
|
51
|
+
|
52
|
+
# @!macro dereferenceable_set_deref_options
|
53
|
+
# @!visibility private
|
54
|
+
def ns_set_deref_options(opts)
|
55
|
+
@dup_on_deref = opts[:dup_on_deref] || opts[:dup]
|
56
|
+
@freeze_on_deref = opts[:freeze_on_deref] || opts[:freeze]
|
57
|
+
@copy_on_deref = opts[:copy_on_deref] || opts[:copy]
|
58
|
+
@do_nothing_on_deref = !(@dup_on_deref || @freeze_on_deref || @copy_on_deref)
|
59
|
+
nil
|
60
|
+
end
|
61
|
+
|
62
|
+
# @!visibility private
|
63
|
+
def apply_deref_options(value)
|
64
|
+
return nil if value.nil?
|
65
|
+
return value if @do_nothing_on_deref
|
66
|
+
value = @copy_on_deref.call(value) if @copy_on_deref
|
67
|
+
value = value.dup if @dup_on_deref
|
68
|
+
value = value.freeze if @freeze_on_deref
|
69
|
+
value
|
70
|
+
end
|
71
|
+
end
|
72
|
+
end
|
73
|
+
end
|