Class: Slackify::Parameter
- Inherits:
-
Object
- Object
- Slackify::Parameter
- Defined in:
- lib/slackify/parameter.rb
Overview
Base parameter class that any user defined parameters must inherit from
Constant Summary collapse
- @@supported_parameters =
[]
Class Method Summary collapse
-
.inherited(subclass) ⇒ Object
Any class inheriting from Slackify::Parameter will be added to the list of supported parameters.
-
.supported_parameters ⇒ Object
Show a list of the parameters supported by the app.
Class Method Details
.inherited(subclass) ⇒ Object
Any class inheriting from Slackify::Parameter will be added to the list of supported parameters
11 12 13 14 |
# File 'lib/slackify/parameter.rb', line 11 def inherited(subclass) super @@supported_parameters.push(subclass.to_s) end |
.supported_parameters ⇒ Object
Show a list of the parameters supported by the app. Since we do metaprogramming, we want to ensure we can only call defined parameter
18 19 20 |
# File 'lib/slackify/parameter.rb', line 18 def supported_parameters @@supported_parameters end |