summaryrefslogtreecommitdiff
path: root/jni/ruby/lib/rake/contrib/compositepublisher.rb
blob: 69952a08081e66d112b33d8f153816ab8ed13c7d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
module Rake

  # Manage several publishers as a single entity.
  class CompositePublisher
    def initialize
      @publishers = []
    end

    # Add a publisher to the composite.
    def add(pub)
      @publishers << pub
    end

    # Upload all the individual publishers.
    def upload
      @publishers.each { |p| p.upload }
    end
  end

end