Parent

Class Index [+]

Quicksearch

Capistrano::Callback

Attributes

source[R]
options[R]
only[R]
except[R]

Public Class Methods

new(source, options={}) click to toggle source
    # File lib/capistrano/callback.rb, line 5
 5:     def initialize(source, options={})
 6:       @source = source
 7:       @options = options
 8:       @only = Array(options[:only]).map { |v| v.to_s }
 9:       @except = Array(options[:except]).map { |v| v.to_s }
10:     end

Public Instance Methods

applies_to?(task) click to toggle source
    # File lib/capistrano/callback.rb, line 12
12:     def applies_to?(task)
13:       if task && only.any?
14:         return only.include?(task.fully_qualified_name)
15:       elsif task && except.any?
16:         return !except.include?(task.fully_qualified_name)
17:       else
18:         return true
19:       end
20:     end

Disabled; run with --debug to generate this.

[Validate]

Generated with the Darkfish Rdoc Generator 1.1.6.