Class: Ritsu::SrcFiles::ProjectCmakeLists::Template

Inherits:
Template
  • Object
show all
Includes:
TemplatePolicies::StrictBlockMatchingButLeaveUserTextBe
Defined in:
lib/ritsu/src_files/project_cmake_lists.rb,
lib/ritsu/ext/fake_install/src_files/project_cmake_lists.rb

Instance Attribute Summary

Attributes included from BlockMixin

#contents, #id, #indent_length, #indent_level, #local_indentation

Instance Method Summary collapse

Methods included from TemplatePolicies::StrictBlockMatchingButLeaveUserTextBe

#update_block

Methods inherited from Template

#add_content, #add_template, #child_template_with_id, #child_template_with_id_position, #child_templates, #create_block, #update_block

Methods included from BlockMixin

#add_line, #add_new_line, #block_structure?, #clear_contents, #indent, #initialize_block_mixin, #outdent

Constructor Details

#initialize(project) ⇒ Template

Returns a new instance of Template.



106
107
108
109
110
111
112
113
114
115
116
117
118
119
# File 'lib/ritsu/src_files/project_cmake_lists.rb', line 106

def initialize(project)
  super
  @project = project
  
  add_template HeaderTemplate.new(project)
  add_new_line
  add_template CustomScriptTemplate.new(project)
  add_new_line
  add_template ExternalLibrariesTemplate.new(project)
  add_new_line
  add_template DirectoriesTemplate.new(project)
  add_new_line
  add_template ConfigureFileTemplate.new(project)
end

Instance Method Details

#initialize_before_fake_installTemplate

Returns a new instance of Template.

Returns:

  • (Template)

    a new instance of Template



36
37
38
39
40
41
42
43
44
45
46
47
48
49
# File 'lib/ritsu/ext/fake_install/src_files/project_cmake_lists.rb', line 36

def initialize(project)
  super
  @project = project
  
  add_template HeaderTemplate.new(project)
  add_new_line
  add_template CustomScriptTemplate.new(project)
  add_new_line
  add_template ExternalLibrariesTemplate.new(project)
  add_new_line
  add_template DirectoriesTemplate.new(project)
  add_new_line
  add_template ConfigureFileTemplate.new(project)
end