Class: XcodeResultBundleProcessor::DirectoryResultsBundle
- Inherits:
-
Object
- Object
- XcodeResultBundleProcessor::DirectoryResultsBundle
- Defined in:
- lib/xcoderesultbundleprocessor/results_bundle.rb
Instance Method Summary collapse
- #copy_file(source, destination) ⇒ Object
-
#initialize(path) ⇒ DirectoryResultsBundle
constructor
A new instance of DirectoryResultsBundle.
- #open_file(path, &block) ⇒ Object
- #read_plist(path) ⇒ Object
Constructor Details
#initialize(path) ⇒ DirectoryResultsBundle
Returns a new instance of DirectoryResultsBundle.
3 4 5 |
# File 'lib/xcoderesultbundleprocessor/results_bundle.rb', line 3 def initialize(path) @path = Pathname.new(path) end |
Instance Method Details
#copy_file(source, destination) ⇒ Object
15 16 17 |
# File 'lib/xcoderesultbundleprocessor/results_bundle.rb', line 15 def copy_file(source, destination) FileUtils.copy(@path.join(source), destination) end |
#open_file(path, &block) ⇒ Object
11 12 13 |
# File 'lib/xcoderesultbundleprocessor/results_bundle.rb', line 11 def open_file(path, &block) File.open(@path.join(path), &block) end |
#read_plist(path) ⇒ Object
7 8 9 |
# File 'lib/xcoderesultbundleprocessor/results_bundle.rb', line 7 def read_plist(path) CFPropertyList.native_types(CFPropertyList::List.new(file: @path.join(path)).value) end |