Class: SciYAG::Backends::BackendDescription
- Inherits:
-
MetaBuilder::Description
- Object
- MetaBuilder::Description
- SciYAG::Backends::BackendDescription
- Defined in:
- lib/SciYAG/Backends/backend.rb
Overview
A simple class to describe a backend. See the Descriptions::Description
Instance Attribute Summary
Attributes inherited from MetaBuilder::Description
#description, #group_hash, #group_list, #long_name, #name, #object_class, #param_hash, #param_list
Instance Method Summary collapse
-
#banner(instance) ⇒ Object
The backend’s banner.
-
#initialize(cls, name, long_name, desc, register = true) ⇒ BackendDescription
constructor
Creates a new backend and optionnally registers it.
Methods inherited from MetaBuilder::Description
#add_group, #add_param, #default_state, #instantiate, #option_parser_banner, #option_parser_fill, #option_parser_option, #option_parser_options, #recreate_state, #restore_state, #save_state, #switch_to_group
Constructor Details
#initialize(cls, name, long_name, desc, register = true) ⇒ BackendDescription
Creates a new backend and optionnally registers it
41 42 43 44 45 46 |
# File 'lib/SciYAG/Backends/backend.rb', line 41 def initialize(cls, name, long_name, desc, register = true) super(cls, name, long_name, desc) if register Backend.register_class(self) end end |
Instance Method Details
#banner(instance) ⇒ Object
The backend’s banner.
36 37 38 |
# File 'lib/SciYAG/Backends/backend.rb', line 36 def (instance) "Backend '#{instance.long_name}'" end |