Module: CSD::Application::Default
- Included in:
- Minisip
- Defined in:
- lib/csd/application/default.rb
Overview
This is the root class of all Applications
Instance Method Summary collapse
- #actions ⇒ Object
- #description ⇒ Object
- #human ⇒ Object
- #name ⇒ Object
- #options(action = '') ⇒ Object
- #scopes(action) ⇒ Object
Instance Method Details
#actions ⇒ Object
22 23 24 |
# File 'lib/csd/application/default.rb', line 22 def actions about.actions end |
#description ⇒ Object
14 15 16 |
# File 'lib/csd/application/default.rb', line 14 def description about.description end |
#human ⇒ Object
18 19 20 |
# File 'lib/csd/application/default.rb', line 18 def human about.human end |
#name ⇒ Object
10 11 12 |
# File 'lib/csd/application/default.rb', line 10 def name ActiveSupport::Inflector.underscore self.to_s.demodulize end |
#options(action = '') ⇒ Object
30 31 32 33 34 35 36 37 |
# File 'lib/csd/application/default.rb', line 30 def (action='') = File.join(Path.applications, name, 'options') common_file = File.join(, "common.rb") specific_file = File.join(, "#{action}.rb") = File.file?(common_file) ? File.read(common_file) : '' = File.file?(specific_file) ? File.read(specific_file) : '' + end |
#scopes(action) ⇒ Object
26 27 28 |
# File 'lib/csd/application/default.rb', line 26 def scopes(action) about.scopes[:action] end |