Class: Contentful::Importer::PublishAssets

Inherits:
Command
  • Object
show all
Defined in:
lib/contentful/importer/publish_assets.rb

Instance Attribute Summary

Attributes inherited from Command

#config, #converter, #importer, #json_validator

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Command

data_options, #initialize, space_options, thread_options

Constructor Details

This class inherits a constructor from Contentful::Importer::Command

Class Method Details

.optionsObject



9
10
11
# File 'lib/contentful/importer/publish_assets.rb', line 9

def self.options
	super.concat(data_options).concat(thread_options).sort
end

.publish(settings, importer) ⇒ Object



13
14
15
# File 'lib/contentful/importer/publish_assets.rb', line 13

def self.publish(settings, importer)
	importer.publish_assets_in_threads(settings[:threads])
end

Instance Method Details

#runObject



17
18
19
20
# File 'lib/contentful/importer/publish_assets.rb', line 17

def run
	super
	self.class.publish(@settings, @importer)
end