instance method use

Ruby on Rails 2.2.3

Since v2.2.3 Last seen in v2.3.18 Private

Available in: v2.2.3 v2.3.18

Signature

use(k=nil, v=true)

Used internally by the keep and discard methods

use()               # marks the entire flash as used
use('msg')          # marks the "msg" entry as used
use(nil, false)     # marks the entire flash as unused (keeps it around for one more action)
use('msg', false)   # marks the "msg" entry as unused (keeps it around for one more action)

Parameters

k opt = nil
v opt = true
Source
# File actionpack/lib/action_controller/flash.rb, line 128
        def use(k=nil, v=true)
          unless k.nil?
            @used[k] = v
          else
            keys.each{ |key| use(key, v) }
          end
        end

Defined in actionpack/lib/action_controller/flash.rb line 128 · View on GitHub · Improve this page · Find usages on GitHub

Defined in ActionController::Flash::FlashHash

Type at least 2 characters to search.

↑↓ navigate · open · esc close