Changeset 3314
- Timestamp:
- 12/15/05 20:03:23 (3 years ago)
- Files:
-
- trunk/activesupport/CHANGELOG (modified) (1 diff)
- trunk/activesupport/lib/active_support.rb (modified) (1 diff)
- trunk/activesupport/lib/active_support/core_ext/object_and_class.rb (modified) (1 diff)
- trunk/activesupport/lib/active_support/option_merger.rb (added)
- trunk/activesupport/test/option_merger_test.rb (added)
Legend:
- Unmodified
- Added
- Removed
- Modified
- Copied
- Moved
trunk/activesupport/CHANGELOG
r3190 r3314 1 1 *SVN* 2 3 * Add Object#with_options for DRYing up multiple calls to methods having shared options. [Sam Stephenson] Example: 4 5 ActionController::Routing::Routes.draw do |map| 6 # Account routes 7 map.with_options(:controller => 'account') do |account| 8 account.home '', :action => 'dashboard' 9 account.signup 'signup', :action => 'new' 10 account.logout 'logout', :action => 'logout' 11 end 12 end 2 13 3 14 * Introduce Dependencies.warnings_on_first_load setting. If true, enables warnings on first load of a require_dependency. Otherwise, loads without warnings. Disabled (set to false) by default. [Jeremy Kemper] trunk/activesupport/lib/active_support.rb
r2421 r3314 33 33 34 34 require 'active_support/ordered_options' 35 require 'active_support/option_merger' 35 36 36 37 require 'active_support/values/time_zone' trunk/activesupport/lib/active_support/core_ext/object_and_class.rb
r3113 r3314 51 51 end 52 52 end 53 54 def with_options(options) 55 yield ActiveSupport::OptionMerger.new(self, options) 56 end 53 57 end 54 58