Vaporware To Awesome

download Vaporware To Awesome

of 134

  • date post

    18-May-2015
  • Category

    Technology

  • view

    17.979
  • download

    3

Embed Size (px)

Transcript of Vaporware To Awesome

  • 1. Rails 3 Vaporware to Awesome Friday, December 4, 2009

2. Me Friday, December 4, 2009 3. Yehuda KatzFriday, December 4, 2009 4. Friday, December 4, 2009 5. Friday, December 4, 2009 6. Friday, December 4, 2009 7. @carlhudaFriday, December 4, 2009 8. Cloud Friday, December 4, 2009 9. Opt-InOpt-Out Friday, December 4, 2009 10. ActiveSupportFriday, December 4, 2009 11. active_support/core_ext/conversions.rb module ActiveSupport module CoreExtensions module Array module Conversions def to_sentence(options = {}) ... options.assert_valid_keys :words_connector, :two_words_connector, :last_word_connector, :locale ... end ... end end endFriday, December 4, 2009 12. active_support/core_ext/conversions.rb module ActiveSupport module CoreExtensions module Array module Conversions def to_sentence(options = {}) ... options.assert_valid_keys :words_connector, assert_valid_keys :two_words_connector, :last_word_connector, :locale ... end ... end end end Where? Friday, December 4, 2009 13. active_support/core_ext/conversions.rbrequire 'active_support/core_ext/hash/keys' require 'active_support/core_ext/hash/reverse_merge' require 'active_support/inflector'class Array def to_sentence(options = {}) ... options.assert_valid_keys :words_connector, :two_words_connector, :last_word_connector, :locale ... end ... end Friday, December 4, 2009 14. active_support/core_ext/conversions.rbrequire 'active_support/core_ext/hash/keys' require 'active_support/core_ext/hash/reverse_merge' require 'active_support/inflector'class Array def to_sentence(options = {}) ... options.assert_valid_keys :words_connector, :two_words_connector, :last_word_connector, :locale ... end ... end Friday, December 4, 2009 15. require 'active_support/core_ext/conversions' Friday, December 4, 2009 16. abstract_controller/logging.rbrequire 'active_support/core_ext/logger' require 'active_support/benchmarkable'module AbstractController module Logger ... end endFriday, December 4, 2009 17. abstract_controller/logging.rbrequire 'active_support/core_ext/logger' require 'active_support/benchmarkable'module AbstractController module Logger ... end endFriday, December 4, 2009 18. ModularFriday, December 4, 2009 19. action_controller$ lsrack_lint_patch.rb assertions record_identifier.rb base.rbreloader.rb benchmarking.rbrequest.rb cachingrequest_forgery_protection.rb caching.rb rescue.rb cgi_extresources.rb cgi_ext.rb response.rb cgi_process.rb routing cookies.rb routing.rb dispatcher.rbsession failsafe.rbsession_management.rb filters.rb status_codes.rb flash.rb streaming.rb headers.rb string_coercion.rb helpers.rb templates http_authentication.rb test_case.rb integration.rb test_process.rb layout.rbtranslation.rb middleware_stack.rbuploaded_file.rb middlewares.rb url_rewriter.rb mime_responds.rb vendor mime_type.rb verification.rb mime_types.rb params_parser.rb performance_test.rb polymorphic_routes.rbFriday, December 4, 2009 20. action_controller$ lsrack_lint_patch.rb assertions record_identifier.rb base.rbreloader.rb benchmarking.rbrequest.rb cachingrequest_forgery_protection.rb caching.rb rescue.rb cgi_extresources.rb cgi_ext.rb response.rb cgi_process.rb routing cookies.rb routing.rb dispatcher.rbsessionbase.rb failsafe.rbsession_management.rb filters.rb status_codes.rb flash.rb streaming.rb headers.rb string_coercion.rb helpers.rb templates http_authentication.rb test_case.rb integration.rb test_process.rb layout.rbtranslation.rb middleware_stack.rbuploaded_file.rb middlewares.rb url_rewriter.rb mime_responds.rb vendor mime_type.rb verification.rb mime_types.rb params_parser.rb performance_test.rb polymorphic_routes.rbFriday, December 4, 2009 21. action_controller$ lsrack_lint_patch.rb assertions record_identifier.rb base.rbreloader.rb benchmarking.rbrequest.rb cachingrequest_forgery_protection.rb caching.rb rescue.rb cgi_extresources.rb cgi_ext.rb response.rb cgi_process.rb routing cookies.rb routing.rb dispatcher.rbsession failsafe.rbsession_management.rb filters.rb status_codes.rb flash.rb streaming.rb headers.rb string_coercion.rb helpers.rb templates http_authentication.rb test_case.rb integration.rb test_process.rb layout.rbtranslation.rb middleware_stack.rbuploaded_file.rb middlewares.rb url_rewriter.rb mime_responds.rb vendor mime_type.rb verification.rb mime_types.rb params_parser.rb performance_test.rb polymorphic_routes.rbFriday, December 4, 2009 22. action_controller$ lsrack_lint_patch.rb assertions record_identifier.rb base.rbreloader.rb benchmarking.rbrequest.rb cachingrequest_forgery_protection.rb caching.rb rescue.rb cgi_extresources.rb cgi_ext.rb response.rb cgi_process.rb routing cookies.rb routing.rb dispatcher.rbsession cgi_ext.rb failsafe.rbsession_management.rb filters.rb status_codes.rb flash.rb streaming.rb headers.rb string_coercion.rb helpers.rb templates http_authentication.rb test_case.rb integration.rb test_process.rb layout.rbtranslation.rb middleware_stack.rbuploaded_file.rb middlewares.rb url_rewriter.rb mime_responds.rb vendor mime_type.rb verification.rb mime_types.rb params_parser.rb performance_test.rb polymorphic_routes.rbFriday, December 4, 2009 23. action_controller$ lsrack_lint_patch.rb assertions record_identifier.rb base.rbreloader.rb benchmarking.rbrequest.rb cachingrequest_forgery_protection.rb caching.rb rescue.rb cgi_extresources.rb cgi_ext.rb response.rb cgi_process.rb routing cookies.rb routing.rb dispatcher.rbsession failsafe.rbsession_management.rb filters.rb status_codes.rb flash.rb streaming.rb headers.rb string_coercion.rb helpers.rb templates http_authentication.rb test_case.rb integration.rb test_process.rb layout.rbtranslation.rb middleware_stack.rbuploaded_file.rb middlewares.rb url_rewriter.rb mime_responds.rb vendor mime_type.rb verification.rb mime_types.rb params_parser.rb performance_test.rb polymorphic_routes.rbFriday, December 4, 2009 24. action_controller$ lsrack_lint_patch.rb assertions record_identifier.rb base.rbreloader.rb benchmarking.rbrequest.rb cachingrequest_forgery_protection.rb caching.rb rescue.rb cgi_extresources.rb cgi_ext.rb response.rb cgi_process.rb routing cookies.rb routing.rb dispatcher.rbsession failsafe.rbsession_management.rb middlewares.rb filters.rb status_codes.rb flash.rb streaming.rb headers.rb string_coercion.rb helpers.rb templates http_authentication.rb test_case.rb integration.rb test_process.rb layout.rbtranslation.rb middleware_stack.rbuploaded_file.rb middlewares.rb url_rewriter.rb mime_responds.rb vendor mime_type.rb verification.rb mime_types.rb params_parser.rb performance_test.rb polymorphic_routes.rbFriday, December 4, 2009 25. action_mailer/base.rbmodule ActionMailer class Base include AdvAttrAccessor, PartContainer, Quoting, Utilsif Object.const_defined?(:ActionController) include ActionController::UrlWriter include ActionController::Layout end ... end endFriday, December 4, 2009 26. helpers.rbFriday, December 4, 2009 27. :( Friday, December 4, 2009 28. ActionController Friday, December 4, 2009 29. DispatcherRack Controller Generic Controller Friday, December 4, 2009 30. Dispatcher Rack Controller ActionDispatchActionControllerGeneric Controller AbstractControllerFriday, December 4, 2009 31. action_controller$ ls base.rb caching caching.rbdeprecated deprecated.rb dispatch legacymetal metal.rbmiddleware.rb notifications.rbtesting polymorphic_routes.rb url_rewriter.rb record_identifier.rbtranslation.rb vendor Friday, December 4, 2009 32. action_dispatch$ ls http middleware routing routing.rb testing Friday, December 4, 2009 33. abstract_controller$ ls base.rb callbacks.rb exceptions.rb helpers.rb layouts.rb logger.rb rendering_controller.rb Friday, December 4, 2009 34. module ActionMailer class Base include AdvAttrAccessor, PartContainer, Quoting, Utilsinclude AbstractController::RenderingController include AbstractController::LocalizedCache include AbstractController::Layoutsinclude AbstractController::Helpers ... end endFriday, December 4, 2009 35. Friday, December 4, 2009 36. require "action_dispatch" Friday, December 4, 2009 37. require "action_dispatch" require "abstract_controller" Friday, December 4, 2009 38. require "action_dispatch" require "abstract_controller" require "action_controller" Friday, December 4, 2009 39. DependenciesFriday, December 4, 2009 40. action_controller/base.rb def render(options = nil, extra_options = {}, &block) #:doc: elsif inline = options[:inline] raise DoubleRenderError, "Can only render or redirect once per action" render_for_text(@template.render(options.merge(:layout => layout)), if performed? options[:status]) validate_render_arguments(options, extra_options, block_given?) elsif action_name = options[:action] render_for_file(default_template(action_name.to_s), options if options.nil? [:status], layout) options = { :template => default_template, :layout => true } elsif options == :update elsif xml = options[:xml] options = extra_options.merge({ :update => true }) response.content_type ||= Mime::XML elsif options.is_a?(String) || options.is_a?(Symbol) render_for_text(xml.respond_to?(:to_xml) ? xml.to_xml : xml, options case options.to_s.index('/') [:status]) when 0 extra_options[:file] = optionselsif js = options[:js] when nilresponse.content_type ||= Mime::JS extra_options[:action] = optionsrender_for_text(js, options[:status]) else extra_options[:template] = options elsif options.include?(:json) end json = options[:json] json = ActiveSupport::JSON.encode(json) unless json.is_a?(String) options = extra_options json = "#{options[:callback]}(#{json})" unless options elsif !options.is_a?(Hash) [:callback].blank? extra_options[:partial] = options response.content_type ||= Mime::JSON options = extra_options render_for_text(json, options[:status]) end elsif options[:partial] layout = pick_layout(options) options[:partial] = default_template