Class: CKick::Plugin
- Inherits:
-
Object
- Object
- CKick::Plugin
- Defined in:
- lib/ckick/plugin.rb
Overview
Base class for a CKick plugin
Direct Known Subclasses
Instance Method Summary collapse
-
#call(project) ⇒ Object
Ran after project’s structure creation (create_structure).
-
#cmake ⇒ Object
Plugin’s output to add to main CMakeLists.txt.
-
#include(project) ⇒ Object
Appends project’s includes path before structure creation.
-
#initialize(args) ⇒ Plugin
constructor
A new instance of Plugin.
-
#lib(project) ⇒ Object
Appends project’s libraries path before structure creation.
-
#name ⇒ Object
Plugin’s name, defaults to class name.
-
#run(project) ⇒ Object
Ran before project’s structure creation.
-
#to_hash ⇒ Object
Plugin to hash is :name => “class name”.
Constructor Details
#initialize(args) ⇒ Plugin
Returns a new instance of Plugin.
10 11 |
# File 'lib/ckick/plugin.rb', line 10 def initialize args end |
Instance Method Details
#call(project) ⇒ Object
Ran after project’s structure creation (create_structure)
34 35 36 |
# File 'lib/ckick/plugin.rb', line 34 def call(project) nil end |
#cmake ⇒ Object
Plugin’s output to add to main CMakeLists.txt
24 25 26 |
# File 'lib/ckick/plugin.rb', line 24 def cmake "" end |
#include(project) ⇒ Object
Appends project’s includes path before structure creation
39 40 41 |
# File 'lib/ckick/plugin.rb', line 39 def include(project) [] end |
#lib(project) ⇒ Object
Appends project’s libraries path before structure creation
44 45 46 |
# File 'lib/ckick/plugin.rb', line 44 def lib(project) [] end |
#name ⇒ Object
Plugin’s name, defaults to class name
14 15 16 |
# File 'lib/ckick/plugin.rb', line 14 def name self.class.name end |
#run(project) ⇒ Object
Ran before project’s structure creation
29 30 31 |
# File 'lib/ckick/plugin.rb', line 29 def run(project) nil end |
#to_hash ⇒ Object
Plugin to hash is :name => “class name”
19 20 21 |
# File 'lib/ckick/plugin.rb', line 19 def to_hash {name: self.class.name} end |