Class: OrigenAppGenerators::TestEngineering::StandAloneApplication

Inherits:
Application
  • Object
show all
Defined in:
lib/origen_app_generators/test_engineering/stand_alone_application.rb

Overview

Generates a generic application shell

Instance Method Summary collapse

Methods inherited from Base

#get_common_user_input, #get_lastest_origen_version, #set_source_paths, #set_type

Instance Method Details

#concludeObject



33
34
35
36
# File 'lib/origen_app_generators/test_engineering/stand_alone_application.rb', line 33

def conclude
  # Print out anything you think the user should know about their new application at the end
  puts "New app created at: #{destination_root}"
end

#generate_filesObject



20
21
22
23
24
# File 'lib/origen_app_generators/test_engineering/stand_alone_application.rb', line 20

def generate_files
  # Calling this will build all files, directories and symlinks contained in the
  # hash returned by the filelist method
  build_filelist
end

#get_user_inputObject

Any methods that are not protected will get invoked in the order that they are defined when the generator is run, method naming is irrelevant unless you want to override a method that is defined by the parent class



12
13
14
15
16
17
18
# File 'lib/origen_app_generators/test_engineering/stand_alone_application.rb', line 12

def get_user_input
  # The methods to get the common user input that applies to all applications will
  # get called at the start automatically, you have a chance here to ask any additional
  # questions that are specific to the type of application being generated
  get_top_level_names
  get_sub_block_names
end

#modify_filesObject



26
27
28
29
30
31
# File 'lib/origen_app_generators/test_engineering/stand_alone_application.rb', line 26

def modify_files
  # If you want to modify any of the generated files you can do so now, you have access
  # to all of the Thor Action methods described here:
  # http://www.rubydoc.info/github/wycats/thor/Thor/Actions
  # See the enable method in lib/app_generators/new.rb for some examples of using these.
end