class Pod::Generator::FileList
Generates an xcfilelist file.
Attributes
paths[R]
@return [Array<String>] The paths of the files in the file list.
Public Class Methods
new(paths)
click to toggle source
Initialize a new instance
@param [Array<String>] paths
@see paths
# File lib/cocoapods/generator/file_list.rb, line 15 def initialize(paths) @paths = paths end
Public Instance Methods
generate()
click to toggle source
Generates the contents of the file list.
@return [String]
# File lib/cocoapods/generator/file_list.rb, line 23 def generate paths.join("\n") end
save_as(path)
click to toggle source
Generates and saves the file list to the given path.
@param [Pathname] path
The path where the file list should be stored.
@return [void]
# File lib/cocoapods/generator/file_list.rb, line 34 def save_as(path) path.open('w') { |file_list| file_list.write(generate) } end