Class: CompositePublisher

Inherits:
Object
  • Object
show all
Defined in:
lib/rake/contrib/publisher.rb

Overview

Manage several publishers as a single entity.

Instance Method Summary collapse

Constructor Details

#initializeCompositePublisher

Returns a new instance of CompositePublisher.



15
16
17
# File 'lib/rake/contrib/publisher.rb', line 15

def initialize
  @publishers = []
end

Instance Method Details

#add(pub) ⇒ Object

Add a publisher to the composite.



20
21
22
# File 'lib/rake/contrib/publisher.rb', line 20

def add(pub)
  @publishers << pub
end

#uploadObject

Upload all the individual publishers.



25
26
27
# File 'lib/rake/contrib/publisher.rb', line 25

def upload
  @publishers.each { |p| p.upload }
end