Class: Xcake::TargetCustomBuildPhaseGenerator

Inherits:
Generator show all
Defined in:
lib/xcake/generator/target_custom_build_phase_generator.rb

Instance Attribute Summary

Attributes inherited from Generator

#context

Class Method Summary collapse

Instance Method Summary collapse

Methods inherited from Generator

#initialize, plugins_location

Methods included from Visitor

#item_name, #leave, #visit

Methods included from Plugin

included

Methods included from Dependency

included

Constructor Details

This class inherits a constructor from Xcake::Generator

Class Method Details

.dependenciesObject



3
4
5
# File 'lib/xcake/generator/target_custom_build_phase_generator.rb', line 3

def self.dependencies
  [TargetGenerator]
end

Instance Method Details

#visit_target(target) ⇒ Object



7
8
9
10
11
12
13
14
# File 'lib/xcake/generator/target_custom_build_phase_generator.rb', line 7

def visit_target(target)
  # TODO: Refactor this system.
  native_target = @context.native_object_for(target)
  target.build_phases.each do |phase|
    EventHooks.run_hook :before_adding_custom_build_phase, phase, target
    phase.generate_native_build_phase(native_target)
  end
end